git.fiddlerwoaroof.com
fiddlerwoaroof authored on 22/01/2016 16:54:01
Showing 10 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,7 @@
1
+*-secrets.json
2
+.*.sw?
3
+*.fasl
4
+bin/*
5
+[#]*[#]
6
+twistd.log
7
+twistd.pid
0 8
new file mode 100644
... ...
@@ -0,0 +1,195 @@
1
+/*
2
+Baseline - a designer framework
3
+Copyright (C) 2009 Stephane Curzi, ProjetUrbain.com
4
+Creative Commons Attribution-Share Alike 3.0 License
5
+version 0.5
6
+ */
7
+
8
+* { box-sizing: border-box }
9
+/******************** Reset ********************/
10
+html, body, div, span, a, img,
11
+h1, h2, h3, h4, h5, h6, hgroup, p,
12
+dl, dialog, dt, dd, ol, ul, li, 
13
+abbr, acronym, address, b, big, blockquote, 
14
+cite, code, del, dfn, em, i, ins, kbd, pre, q, 
15
+samp, tt, var, small, strong, sub, sup, 
16
+object, iframe, form, fieldset, label, legend, 
17
+table, caption, tbody, tfoot, thead, tr, th, td,
18
+article, aside, footer, header, nav, section,
19
+figure, menu, time, mark, audio, video						{
20
+  font-family: inherit;
21
+  font-size: 100%;
22
+  font-weight: inherit;
23
+  font-style: inherit;
24
+  vertical-align: baseline;
25
+  white-space: normal;
26
+  text-align: left;
27
+  margin: 0;
28
+  padding: 0;
29
+  border: 0;
30
+  outline: 0;
31
+  background: transparent;
32
+}
33
+
34
+textarea													{
35
+  font-family: inherit;
36
+  font-size: 100%;
37
+  font-weight: normal;
38
+  font-style: normal;
39
+  white-space: normal;
40
+  text-align: left;
41
+  margin: 0;
42
+  padding: 0;
43
+}
44
+
45
+article, aside, footer, header, nav, section,
46
+dialog, figure, hgroup, menu								{ display: block; }
47
+
48
+h1, h2, h3, h4, h5, h6										{ font-size: 100%; font-weight: normal; }
49
+del, ins													{ text-decoration: none; }
50
+ol, ul														{ list-style: none; }
51
+nav ul														{ list-style-type: none; }
52
+table														{ border-collapse: separate; border-spacing: 0; background-color: transparent; width: auto; height: auto; }
53
+:focus														{ outline: 0; }
54
+blockquote:before, blockquote:after, q:before, q:after		{ content: ""; }
55
+blockquote, q												{ quotes: "" ""; }
56
+input														{ margin: 0; }
57
+
58
+
59
+/********** Deprecated and obsolete elements **********/
60
+applet, basefont, dir, font, isindex, menu, s, strike, u	{ font-family: inherit; font-size: 100%; font-weight: normal; font-style: normal; white-space: normal; vertical-align: baseline; text-decoration: inherit; text-align: left; color: inherit; margin: 0; padding: 0; border: 0; outline: 0; }
61
+dir, menu													{ list-style: none; }
62
+nobr														{ white-space: normal; }
63
+blink														{ text-decoration: none; }
64
+marquee														{ overflow: visible; }/*
65
+Baseline - a designer framework
66
+Copyright (C) 2009 Stephane Curzi, ProjetUrbain.com
67
+Creative Commons Attribution-Share Alike 3.0 License
68
+version 0.5.2
69
+                                                                       */
70
+
71
+/******************** Base ********************/
72
+body											{ font-family: helvetica, arial, sans-serif; line-height: 1.5; background: white; color: black; }
73
+h1, h2, h3, h4, h5, h6							{ line-height: 1.2; }
74
+h4, h5, h6										{ font-weight: bold; }
75
+b, strong, caption, th, thead, dt, legend		{ font-weight: bold; }
76
+cite, dfn, em, i								{ font-style: italic; }
77
+code, kbd, samp, pre, tt, var					{ font-family: mono-space, monospace; }
78
+h1, h2, h3, h4, h5, h6							{ word-spacing: -0.125em; }
79
+p												{ word-spacing: 0.125em; hyphenate: auto; hyphenate-lines: 3; }
80
+p+p												{ text-indent: 1.5em; }
81
+p+p.no-indent									{ text-indent: 0; }
82
+pre												{ white-space: pre; }
83
+del												{ text-decoration: line-through; }
84
+mark											{ background: rgba(255, 255, 0, 0.4); padding: 0 .25em; }
85
+ins												{ color: #f00; }
86
+small, sup, sub									{ font-size: 80%; }
87
+big												{ font-size: 125%; line-height: 80%; }
88
+abbr, acronym									{ font-size: 85%; text-transform: uppercase; letter-spacing: .1em; }
89
+abbr[title], acronym[title], dfn[title]			{ border-bottom: 1px dotted black; cursor: help; }
90
+sup, sub										{ line-height: 0; }
91
+sup												{ vertical-align: super; }
92
+sub												{ vertical-align: sub; }
93
+blockquote										{ padding: 1.5em; }
94
+hr												{ border: none; background: #ddd; width: 100%; }
95
+ul, ol											{ margin-left: 1.5em; }
96
+ul												{ list-style: disc outside; }
97
+ol												{ list-style: decimal outside; }
98
+input, select, button							{ cursor: pointer; }
99
+table											{ font: inherit; width: 100%; }
100
+
101
+/* html 5 */
102
+article, aside, header, hgroup,
103
+nav, figure, section, footer					{ display: block; }
104
+
105
+/* Debug */
106
+.debug											{ outline: solid gold 1px; }
107
+.debug-background								{ background: rgba(255, 215, 0, 0.2) !important; }/*
108
+Baseline - a designer framework
109
+Copyright (C) 2009 Stephane Curzi, ProjetUrbain.com
110
+Creative Commons Attribution-Share Alike 3.0 License
111
+version 0.5
112
+                                                                                          */
113
+
114
+/******************** Baseline grid: 13/18px ********************/
115
+body								{ font-size: 75%; line-height: 1.5; /*12/18*/ }
116
+
117
+h1, h2, h3, h4, h5, h6				{ position: relative; }
118
+h1, h2								{ line-height: 36px; margin-bottom: 18px; }
119
+h1, h2, h3, h4						{ margin-top: 18px; }
120
+h3, h4, h5, h6						{ line-height: 18px; }
121
+h1									{ font-size: 36px; top: 5px; }
122
+h2									{ font-size: 28px; top: 8px; }
123
+h3									{ font-size: 22px; top: 1px; }
124
+h4									{ font-size: 18px; top: 2px; }
125
+h5									{ font-size: 15px; top: 4px; }
126
+h6									{ font-size: 13px; top: 5px; }
127
+h1:first-child,
128
+h2:first-child,
129
+h3:first-child,
130
+h4:first-child						{ margin-top: 0; }
131
+
132
+p, pre, address						{ font-size: 13px; line-height: 18px; position: relative; top: 5px; }
133
+small								{ font-size: 11px; }
134
+abbr, code, kbd,
135
+samp, small, var					{ line-height: 15px; }
136
+ul, ol, dl, dialog					{ font-size: 13px; line-height: 18px; position: relative; top: 5px; margin-top: 18px; margin-bottom: 18px; }
137
+li ul, li ol, ul ul, ol ol			{ top: 0; margin-top: 0; margin-bottom: 0; }
138
+li h1, li h2, li h3,
139
+li h4, li h5, li h6,
140
+li p								{ top: 0; }
141
+form, legend, label					{ font-size: 13px; line-height: 18px; }
142
+legend								{ position: relative; top: 5px; }
143
+table								{ font-size: 13px; }
144
+caption								{ font-size: 13px; line-height: 18px; position: relative; }
145
+hr									{ position: relative; height: 4px; margin: 18px 0 14px 0; }/*
146
+Baseline - a designer framework
147
+Copyright (C) 2009 Stephane Curzi, ProjetUrbain.com
148
+Creative Commons Attribution-Share Alike 3.0 License
149
+version 0.5
150
+                                                                                       */
151
+
152
+/******************** Table ********************/
153
+table								{ border-collapse: collapse; border-top: solid 3px #000; position: relative; margin-top: 18px; }
154
+
155
+th, td								{ line-height: 18px; padding: 9px 18px 8px 0; }
156
+thead th, thead td					{ padding-top: 7px; }
157
+tfoot th, tfoot td					{ padding-bottom: 8px; }
158
+tbody th, tbody td,
159
+tfoot th, tfoot td					{ border-top: solid 1px #000; }
160
+
161
+th:first-child, td:first-child		{ padding-left: 0; }
162
+th:last-child, td:last-child		{ padding-right: 0; }
163
+
164
+tr:nth-child(even) td				{ }
165
+tbody tr:nth-child(odd) th,
166
+tbody tr:nth-child(odd) td			{ background: rgba(0, 0, 0, 0.035); }
167
+
168
+caption								{ top: 5px; margin-bottom: 18px; }/*
169
+Baseline - a designer framework
170
+Copyright (C) 2009 Stephane Curzi, ProjetUrbain.com
171
+Creative Commons Attribution-Share Alike 3.0 License
172
+version 0.5
173
+                                                                 */
174
+
175
+/******************** Form ********************/
176
+
177
+form							{ overflow: auto; }
178
+legend							{ padding-bottom: 18px; }
179
+label							{ width: 100%; position: relative; top: 5px; margin-bottom: 18px; line-height: 18px; display: block; }
180
+
181
+input[type="text"],
182
+input[type="password"],
183
+input[type="select"],
184
+input[type="search"]			{ width: 100%; display: block; }
185
+
186
+input[type="radio"]				{ top: -1px; margin: 0 4px 3px 1px; }
187
+input[type="checkbox"]			{ top: -2px; margin: 0 4px 3px 1px; }
188
+input[type="file"]				{ margin: 0px 6px 3px 6px; }
189
+
190
+input[type="submit"],
191
+input[type="reset"],
192
+input[type="button"]			{ position: relative; top: 5px; margin-bottom: 18px; }
193
+
194
+select							{ display: block; margin: 0px; }
195
+textarea						{ width: 100%; line-height: 18px;  display: block; clear: left; overflow: auto; }
0 196
new file mode 100644
... ...
@@ -0,0 +1,365 @@
1
+.input_tiny {
2
+  width: 50px;
3
+}
4
+
5
+.input_small {
6
+  width: 100px;
7
+}
8
+
9
+.input_medium {
10
+  width: 150px;
11
+}
12
+
13
+.input_large {
14
+  width: 200px;
15
+}
16
+
17
+.input_xlarge {
18
+  width: 250px;
19
+}
20
+
21
+.input_xxlarge {
22
+  width: 300px;
23
+}
24
+
25
+.input_full {
26
+  width: 100%;
27
+}
28
+
29
+.input_full_wrap {
30
+  display: block;
31
+  padding-right: 8px;
32
+}
33
+
34
+input[type="search"]::-webkit-search-decoration {
35
+  display: none;
36
+}
37
+
38
+input:invalid,
39
+button:invalid,
40
+a.button:invalid,
41
+select:invalid,
42
+textarea:invalid {
43
+  -webkit-box-shadow: none;
44
+  -moz-box-shadow: none;
45
+  box-shadow: none;
46
+}
47
+input:focus,
48
+button:focus,
49
+a.button:focus,
50
+select:focus,
51
+textarea:focus {
52
+  -webkit-box-shadow: #0066ff 0 0 5px 0;
53
+  -moz-box-shadow: #0066ff 0 0 5px 0;
54
+  box-shadow: #0066ff 0 0 5px 0;
55
+  z-index: 1;
56
+}
57
+
58
+input[type="file"]:focus, input[type="file"]:active,
59
+input[type="radio"]:focus,
60
+input[type="radio"]:active,
61
+input[type="checkbox"]:focus,
62
+input[type="checkbox"]:active {
63
+  -webkit-box-shadow: none;
64
+  -moz-box-shadow: none;
65
+  box-shadow: none;
66
+}
67
+
68
+button,
69
+a.button,
70
+input[type="reset"],
71
+input[type="submit"],
72
+input[type="button"] {
73
+  -webkit-appearance: none;
74
+  -webkit-border-radius: 4px;
75
+  -moz-border-radius: 4px;
76
+  -ms-border-radius: 4px;
77
+  -o-border-radius: 4px;
78
+  border-radius: 4px;
79
+  -webkit-background-clip: padding;
80
+  -moz-background-clip: padding;
81
+  background-clip: padding-box;
82
+  background: #dddddd url('../images/button.png?1298351022') repeat-x;
83
+  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #ffffff), color-stop(100%, #dddddd));
84
+  background-image: -webkit-linear-gradient(#ffffff, #dddddd);
85
+  background-image: -moz-linear-gradient(#ffffff, #dddddd);
86
+  background-image: -o-linear-gradient(#ffffff, #dddddd);
87
+  background-image: linear-gradient(#ffffff, #dddddd);
88
+  border: 1px solid;
89
+  border-color: #dddddd #bbbbbb #999999;
90
+  cursor: pointer;
91
+  color: #333333;
92
+  display: inline-block;
93
+  font: bold 12px/1.3 "Helvetica Neue", Arial, "Liberation Sans", FreeSans, sans-serif;
94
+  outline: 0;
95
+  overflow: visible;
96
+  margin: 0;
97
+  padding: 3px 10px;
98
+  text-shadow: white 0 1px 1px;
99
+  text-decoration: none;
100
+  vertical-align: top;
101
+  width: auto;
102
+  *padding-top: 2px;
103
+  *padding-bottom: 0;
104
+}
105
+button:hover,
106
+a.button:hover,
107
+input[type="reset"]:hover,
108
+input[type="submit"]:hover,
109
+input[type="button"]:hover {
110
+  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #ffffff), color-stop(1px, #eeeeee), color-stop(100%, #cccccc));
111
+  background-image: -webkit-linear-gradient(#ffffff, #eeeeee 1px, #cccccc);
112
+  background-image: -moz-linear-gradient(#ffffff, #eeeeee 1px, #cccccc);
113
+  background-image: -o-linear-gradient(#ffffff, #eeeeee 1px, #cccccc);
114
+  background-image: linear-gradient(#ffffff, #eeeeee 1px, #cccccc);
115
+  text-decoration: none;
116
+}
117
+button:active,
118
+a.button:active,
119
+input[type="reset"]:active,
120
+input[type="submit"]:active,
121
+input[type="button"]:active {
122
+  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #dddddd), color-stop(100%, #eeeeee));
123
+  background-image: -webkit-linear-gradient(#dddddd, #eeeeee);
124
+  background-image: -moz-linear-gradient(#dddddd, #eeeeee);
125
+  background-image: -o-linear-gradient(#dddddd, #eeeeee);
126
+  background-image: linear-gradient(#dddddd, #eeeeee);
127
+  -webkit-box-shadow: inset rgba(0, 0, 0, 0.25) 0 1px 2px 0;
128
+  -moz-box-shadow: inset rgba(0, 0, 0, 0.25) 0 1px 2px 0;
129
+  box-shadow: inset rgba(0, 0, 0, 0.25) 0 1px 2px 0;
130
+  border-color: #999999 #bbbbbb #dddddd;
131
+}
132
+button::-moz-focus-inner,
133
+a.button::-moz-focus-inner,
134
+input[type="reset"]::-moz-focus-inner,
135
+input[type="submit"]::-moz-focus-inner,
136
+input[type="button"]::-moz-focus-inner {
137
+  border: 0;
138
+  padding: 0;
139
+}
140
+
141
+a.button {
142
+  *padding-bottom: 3px;
143
+}
144
+
145
+button {
146
+  *padding-top: 1px;
147
+  *padding-bottom: 1px;
148
+}
149
+
150
+textarea,
151
+select,
152
+input[type="date"],
153
+input[type="datetime"],
154
+input[type="datetime-local"],
155
+input[type="email"],
156
+input[type="month"],
157
+input[type="number"],
158
+input[type="password"],
159
+input[type="search"],
160
+input[type="tel"],
161
+input[type="text"],
162
+input[type="time"],
163
+input[type="url"],
164
+input[type="week"] {
165
+  -webkit-box-sizing: border-box;
166
+  -moz-box-sizing: border-box;
167
+  box-sizing: border-box;
168
+  -webkit-background-clip: padding;
169
+  -moz-background-clip: padding;
170
+  background-clip: padding-box;
171
+  -webkit-border-radius: 0;
172
+  -moz-border-radius: 0;
173
+  -ms-border-radius: 0;
174
+  -o-border-radius: 0;
175
+  border-radius: 0;
176
+  -webkit-appearance: none;
177
+  background-color: white;
178
+  border: 1px solid;
179
+  border-color: #848484 #c1c1c1 #e1e1e1;
180
+  color: black;
181
+  outline: 0;
182
+  margin: 0;
183
+  padding: 2px 3px;
184
+  text-align: left;
185
+  font-size: 13px;
186
+  font-family: Arial, "Liberation Sans", FreeSans, sans-serif;
187
+  height: 1.8em;
188
+  vertical-align: top;
189
+  *padding-top: 2px;
190
+  *padding-bottom: 1px;
191
+  *height: auto;
192
+}
193
+textarea[disabled],
194
+select[disabled],
195
+input[type="date"][disabled],
196
+input[type="datetime"][disabled],
197
+input[type="datetime-local"][disabled],
198
+input[type="email"][disabled],
199
+input[type="month"][disabled],
200
+input[type="number"][disabled],
201
+input[type="password"][disabled],
202
+input[type="search"][disabled],
203
+input[type="tel"][disabled],
204
+input[type="text"][disabled],
205
+input[type="time"][disabled],
206
+input[type="url"][disabled],
207
+input[type="week"][disabled] {
208
+  background-color: #eeeeee;
209
+}
210
+
211
+button[disabled],
212
+input[disabled],
213
+select[disabled],
214
+select[disabled] option,
215
+select[disabled] optgroup,
216
+textarea[disabled],
217
+a.button_disabled {
218
+  -webkit-box-shadow: none;
219
+  -moz-box-shadow: none;
220
+  box-shadow: none;
221
+  -moz-user-select: -moz-none;
222
+  -webkit-user-select: none;
223
+  -khtml-user-select: none;
224
+  user-select: none;
225
+  color: #888888;
226
+  cursor: default;
227
+}
228
+
229
+input::-webkit-input-placeholder,
230
+textarea::-webkit-input-placeholder {
231
+  color: #888888;
232
+}
233
+
234
+input:-moz-placeholder,
235
+textarea:-moz-placeholder {
236
+  color: #888888;
237
+}
238
+
239
+input.placeholder_text,
240
+textarea.placeholder_text {
241
+  color: #888888;
242
+}
243
+
244
+textarea,
245
+select[size],
246
+select[multiple] {
247
+  height: auto;
248
+}
249
+
250
+select[size="0"],
251
+select[size="1"] {
252
+  height: 1.8em;
253
+  *height: auto;
254
+}
255
+
256
+@media (-webkit-min-device-pixel-ratio: 0) {
257
+  select[size],
258
+  select[multiple],
259
+  select[multiple][size] {
260
+    background-image: none;
261
+    padding-right: 3px;
262
+  }
263
+
264
+  select,
265
+  select[size="0"],
266
+  select[size="1"] {
267
+    background-image: url(data:image/png;base64,R0lGODlhDQAEAIAAAAAAAP8A/yH5BAEHAAEALAAAAAANAAQAAAILhA+hG5jMDpxvhgIAOw==);
268
+    background-repeat: no-repeat;
269
+    background-position: right center;
270
+    padding-right: 20px;
271
+  }
272
+
273
+  ::-webkit-validation-bubble-message {
274
+    -webkit-box-shadow: none;
275
+    box-shadow: none;
276
+    background: -webkit-gradient(linear, left top, left bottom, color-stop(0, #666666), color-stop(1, black));
277
+    border: 0;
278
+    color: white;
279
+    font: 13px/17px "Lucida Grande", Arial, "Liberation Sans", FreeSans, sans-serif;
280
+    overflow: hidden;
281
+    padding: 15px 15px 17px;
282
+    text-shadow: black 0 0 1px;
283
+    min-height: 16px;
284
+  }
285
+
286
+  ::-webkit-validation-bubble-arrow,
287
+  ::-webkit-validation-bubble-top-outer-arrow,
288
+  ::-webkit-validation-bubble-top-inner-arrow {
289
+    -webkit-box-shadow: none;
290
+    box-shadow: none;
291
+    background: #666666;
292
+    border-color: #666666;
293
+  }
294
+}
295
+textarea {
296
+  min-height: 40px;
297
+  overflow: auto;
298
+  resize: vertical;
299
+  width: 100%;
300
+}
301
+
302
+optgroup {
303
+  color: black;
304
+  font-style: normal;
305
+  font-weight: normal;
306
+  font-family: Arial, "Liberation Sans", FreeSans, sans-serif;
307
+}
308
+optgroup::-moz-focus-inner {
309
+  border: 0;
310
+  padding: 0;
311
+}
312
+
313
+.ie6_button,
314
+* html button,
315
+* html a.button {
316
+  background: #dddddd url('../images/button.png?1298351022') repeat-x;
317
+  border: 1px solid;
318
+  border-color: #dddddd #bbbbbb #999999;
319
+  cursor: pointer;
320
+  color: #333333;
321
+  font: bold 12px/1.2 Arial, sans-serif;
322
+  padding: 2px 10px 0;
323
+  text-decoration: none;
324
+  overflow: visible;
325
+  vertical-align: top;
326
+  width: auto;
327
+}
328
+
329
+* html a.button {
330
+  position: relative;
331
+  top: 3px;
332
+  padding-bottom: 2px;
333
+}
334
+
335
+* html button {
336
+  padding-top: 1px;
337
+  padding-bottom: 1px;
338
+}
339
+
340
+.ie6_input,
341
+* html textarea,
342
+* html select {
343
+  background: white;
344
+  border: 1px solid;
345
+  border-color: #848484 #c1c1c1 #e1e1e1;
346
+  color: black;
347
+  padding: 2px 3px 1px;
348
+  font-size: 13px;
349
+  font-family: Arial, sans-serif;
350
+  vertical-align: top;
351
+}
352
+
353
+* html select {
354
+  margin-top: 1px;
355
+}
356
+
357
+.placeholder_text,
358
+.ie6_input_disabled,
359
+.ie6_button_disabled {
360
+  color: #888888;
361
+}
362
+
363
+.ie6_input_disabled {
364
+  background: #eeeeee;
365
+}
0 366
new file mode 100644
... ...
@@ -0,0 +1,179 @@
1
+/*@import(url(/static/css/baseline.css));*/
2
+/*@import url("/css/formalize.css");*/
3
+@import url(https://fonts.googleapis.com/css?family=Alegreya|MedievalSharp&subset=latin,latin-ext);
4
+
5
+* {
6
+  box-sizing: border-box;
7
+  margin: 0px;
8
+  padding: 0px;
9
+  -webkit-font-feature-settings: 'kern' 1, 'liga' 1;
10
+  -moz-font-feature-settings: 'kern' 1;
11
+  -o-font-feature-settings: 'kern' 1;
12
+  text-rendering: geometricPrecision;
13
+  transition: color 0.2s ease-in-out,
14
+              background-color 0.2s ease-in-out;
15
+}
16
+
17
+body {
18
+  position: relative;
19
+  font-size: 14px;
20
+  font-family: 'Alegreya Sans', sans-serif;
21
+  padding-bottom: 6em;
22
+}
23
+
24
+h1 {
25
+  padding: 0.5em;
26
+  margin: 0px;
27
+  margin-top: 0.5em;
28
+  margin-bottom: 1em;
29
+  font-size: 3em;
30
+  background: white;
31
+  width: 100%;
32
+  z-index: 100;
33
+  text-align: center;
34
+  font-variant: small-caps;
35
+  font-family: 'MedievalSharp'
36
+}
37
+
38
+main {
39
+  position: relative;
40
+  width: 87.5vw;
41
+  margin-left: 12.5vw;
42
+  padding: 2em;
43
+  padding-top: 0px;
44
+}
45
+
46
+form#submission {
47
+  width: 75vw;
48
+  position: relative;
49
+  display: block;
50
+}
51
+
52
+form#submission::after {
53
+  content: " ";
54
+  float: none;
55
+  clear: both;
56
+  display: block;
57
+}
58
+
59
+main form input[name=headline][type] {
60
+  margin-bottom: 0.5em;
61
+  border-color: #ccc;
62
+  border-style: double;
63
+  border-width: 3px;
64
+  padding: 1em;
65
+  margin-bottom: 0.5em;
66
+  display: block;
67
+}
68
+
69
+main form input[type] {
70
+  font-family: inherit;
71
+}
72
+
73
+main form input[type]:hover {
74
+  background-image: none;
75
+}
76
+
77
+main form input[type=text] {
78
+  width: 100%;
79
+}
80
+
81
+main form input[name=headline] {
82
+  font-size: 1.5em;
83
+  font-weight: bold;
84
+  padding: 0.3em;
85
+}
86
+
87
+main form input[type=submit], main form input[name=url] {
88
+  background-image: none;
89
+  font-size: 0.75em;
90
+  display: inline-block;
91
+  vertical-align: middle;
92
+  margin: 0px;
93
+  border-color: #ccc;
94
+  border-style: double;
95
+  border-width: 3px;
96
+  padding: 1em 2em;
97
+  height: 100%;
98
+}
99
+
100
+main form input[type=submit] {
101
+  /*border-left: none;*/
102
+  border-radius: 0px;
103
+  background-color: hsl(0, 50%, 50%);
104
+  color: white;
105
+  font-size: 0.8em;
106
+  width: 16%;
107
+  text-transform: uppercase;
108
+  text-align: center;
109
+  font-size: 1em;
110
+  padding: 0.66em 0px;
111
+  text-shadow: 0em 0em 0.1em black;
112
+  letter-spacing: 3px;
113
+  margin-left:  -0.75vw;
114
+  margin-right: -0.75vw;
115
+  z-index: 3;
116
+}
117
+
118
+input[type=submit]:active, input[type=submit]:hover {
119
+  cursor: pointer;
120
+  background-color: hsl(15, 70%, 40%);
121
+  color: hsl(0, 0%, 80%);
122
+  border-color: #888;
123
+  border-style: single;
124
+}
125
+
126
+
127
+main form input[name=url] {
128
+  border-right: none;
129
+  width: 85%;
130
+  font-size: 0.75em;
131
+  padding-right: 0px;
132
+  z-index: 4;
133
+}
134
+
135
+
136
+ul#submissions {
137
+  margin: 0px;
138
+  padding: 0px;
139
+}
140
+
141
+ul#submissions li::after {
142
+  content: " ";
143
+  clear: both;
144
+  float: none;
145
+  display: block;
146
+}
147
+
148
+ul#submissions li + li {
149
+  margin-top: 2.5em;
150
+}
151
+
152
+ul#submissions a {
153
+  display: block;
154
+}
155
+
156
+ul#submissions li {
157
+  list-style: none;
158
+  margin: 0px;
159
+  padding: 0px;
160
+  position:relative;
161
+  left: -6.25vw;
162
+  width: 87.5vw;
163
+}
164
+
165
+ul#submissions li.in-progress {
166
+  position: relative;
167
+  margin-top: 1.5em;
168
+  font-size: 0.9em;
169
+  background: #eee;
170
+  padding: 1em;
171
+}
172
+
173
+ul#submissions li.submission:first-child {
174
+  margin-top: 3.33em;
175
+}
176
+
177
+a { color: inherit; text-decoration: none;}
178
+a:visited { color: hsl(0, 50%, 25%); }
179
+a:active, a:hover { text-decoration: underline; }
0 180
new file mode 100644
1 181
Binary files /dev/null and b/static/images/button.png differ
2 182
new file mode 100644
3 183
Binary files /dev/null and b/static/images/select_arrow.gif differ
4 184
new file mode 100644
... ...
@@ -0,0 +1,79 @@
1
+<!DOCTYPE html>
2
+<html lang="en">
3
+<head>
4
+  <meta charset="UTF-8">
5
+  <title>In Angulis</title>
6
+  <!--<link rel="stylesheet" href="/css/baseline.css">-->
7
+  <link rel="stylesheet" href="/css/main.css">
8
+</head>
9
+<body>
10
+  <h1>In Angulis</h1>
11
+  <main id="app">
12
+  <form action="/murmuro" id="submission" name="submission" method="POST"  v-on:submit="submit">
13
+    <input type="text" name="headline" placeholder="Headline" v-model="newLink.headline">
14
+    <input type="text" name="url" placeholder="URL" v-model="newLink.url">
15
+    <input type="submit" value="Go" title='Murmuro'>
16
+  </form>
17
+
18
+  <ul id="submissions">
19
+    <li class="in-progress" v-if="newLink.headline !== undefined || newLink.url !== undefined">
20
+      <a href="#">
21
+        <h2>{{ newLink.headline }}</h2>
22
+        <p>{{ newLink.url }}</p>
23
+      </a>
24
+    </li>
25
+    <li class="submission" v-for="link in links">
26
+      <a href="{{ link.url }}">
27
+        <h2>{{ link.headline }}</h2>
28
+        <p>{{ link.url }}</p>
29
+      </a>
30
+    </li>
31
+  </ul>
32
+  </main>
33
+
34
+  <script src="/js/jquery.js"></script>
35
+  <script src="/js/jquery.formalize.js"></script>
36
+  <script src="/js/vue.js"></script>
37
+  <script type="text/javascript">
38
+new Vue({
39
+  el: '#app',
40
+
41
+  methods: {
42
+    submit: function(e) {
43
+      e.preventDefault();
44
+      this.links.unshift(0,Object.create(this.newLink));
45
+      this.newLink = {};
46
+      return false;
47
+    }
48
+  },
49
+
50
+  data: {
51
+    newLink: {
52
+    },
53
+    links: [
54
+    { headline: "Against the axiom of nature’s infinite precision",
55
+      url: "https://thomism.wordpress.com/2016/01/19/against-the-axiom-of-natures-infinite-precision/"},
56
+    { headline: "The opposition between \"strongly held intuitions\" and science",
57
+      url: "https://thomism.wordpress.com/2010/07/10/the-battle-between-strongly-held-intuitions-and-science/"},
58
+    { headline: "Against the axiom of nature’s infinite precision",
59
+      url: "https://thomism.wordpress.com/2016/01/19/against-the-axiom-of-natures-infinite-precision/"},
60
+    { headline: "The opposition between \"strongly held intuitions\" and science",
61
+      url: "https://thomism.wordpress.com/2010/07/10/the-battle-between-strongly-held-intuitions-and-science/"},
62
+    { headline: "Against the axiom of nature’s infinite precision",
63
+      url: "https://thomism.wordpress.com/2016/01/19/against-the-axiom-of-natures-infinite-precision/"},
64
+    { headline: "The opposition between \"strongly held intuitions\" and science",
65
+      url: "https://thomism.wordpress.com/2010/07/10/the-battle-between-strongly-held-intuitions-and-science/"},
66
+    { headline: "Against the axiom of nature’s infinite precision",
67
+      url: "https://thomism.wordpress.com/2016/01/19/against-the-axiom-of-natures-infinite-precision/"},
68
+    { headline: "The opposition between \"strongly held intuitions\" and science",
69
+      url: "https://thomism.wordpress.com/2010/07/10/the-battle-between-strongly-held-intuitions-and-science/"},
70
+    { headline: "Against the axiom of nature’s infinite precision",
71
+      url: "https://thomism.wordpress.com/2016/01/19/against-the-axiom-of-natures-infinite-precision/"},
72
+    { headline: "The opposition between \"strongly held intuitions\" and science",
73
+      url: "https://thomism.wordpress.com/2010/07/10/the-battle-between-strongly-held-intuitions-and-science/"},
74
+    ]
75
+  }
76
+});
77
+  </script>
78
+</body>
79
+</html>
0 80
new file mode 100644
... ...
@@ -0,0 +1,181 @@
1
+/*
2
+  Formalize - version 1.2
3
+
4
+  Note: This file depends on the jQuery library.
5
+*/
6
+
7
+// Module pattern:
8
+// http://yuiblog.com/blog/2007/06/12/module-pattern
9
+var FORMALIZE = (function($, window, document, undefined) {
10
+  // Internet Explorer detection.
11
+  function IE(version) {
12
+    var b = document.createElement('b');
13
+    b.innerHTML = '<!--[if IE ' + version + ']><br><![endif]-->';
14
+    return !!b.getElementsByTagName('br').length;
15
+  }
16
+
17
+  // Private constants.
18
+  var PLACEHOLDER_SUPPORTED = 'placeholder' in document.createElement('input');
19
+  var AUTOFOCUS_SUPPORTED = 'autofocus' in document.createElement('input');
20
+  var IE6 = IE(6);
21
+  var IE7 = IE(7);
22
+
23
+  // Expose innards of FORMALIZE.
24
+  return {
25
+    // FORMALIZE.go
26
+    go: function() {
27
+      var i, j = this.init;
28
+
29
+      for (i in j) {
30
+        j.hasOwnProperty(i) && j[i]();
31
+      }
32
+    },
33
+    // FORMALIZE.init
34
+    init: {
35
+      // FORMALIZE.init.disable_link_button
36
+      disable_link_button: function() {
37
+        $(document.documentElement).on('click', 'a.button_disabled', function() {
38
+          return false;
39
+        });
40
+      },
41
+      // FORMALIZE.init.full_input_size
42
+      full_input_size: function() {
43
+        if (!IE7 || !$('textarea, input.input_full').length) {
44
+          return;
45
+        }
46
+
47
+        // This fixes width: 100% on <textarea> and class="input_full".
48
+        // It ensures that form elements don't go wider than container.
49
+        $('textarea, input.input_full').wrap('<span class="input_full_wrap"></span>');
50
+      },
51
+      // FORMALIZE.init.ie6_skin_inputs
52
+      ie6_skin_inputs: function() {
53
+        // Test for Internet Explorer 6.
54
+        if (!IE6 || !$('input, select, textarea').length) {
55
+          // Exit if the browser is not IE6,
56
+          // or if no form elements exist.
57
+          return;
58
+        }
59
+
60
+        // For <input type="submit" />, etc.
61
+        var button_regex = /button|submit|reset/;
62
+
63
+        // For <input type="text" />, etc.
64
+        var type_regex = /date|datetime|datetime-local|email|month|number|password|range|search|tel|text|time|url|week/;
65
+
66
+        $('input').each(function() {
67
+          var el = $(this);
68
+
69
+          // Is it a button?
70
+          if (this.getAttribute('type').match(button_regex)) {
71
+            el.addClass('ie6_button');
72
+
73
+            /* Is it disabled? */
74
+            if (this.disabled) {
75
+              el.addClass('ie6_button_disabled');
76
+            }
77
+          }
78
+          // Or is it a textual input?
79
+          else if (this.getAttribute('type').match(type_regex)) {
80
+            el.addClass('ie6_input');
81
+
82
+            /* Is it disabled? */
83
+            if (this.disabled) {
84
+              el.addClass('ie6_input_disabled');
85
+            }
86
+          }
87
+        });
88
+
89
+        $('textarea, select').each(function() {
90
+          /* Is it disabled? */
91
+          if (this.disabled) {
92
+            $(this).addClass('ie6_input_disabled');
93
+          }
94
+        });
95
+      },
96
+      // FORMALIZE.init.autofocus
97
+      autofocus: function() {
98
+        if (AUTOFOCUS_SUPPORTED || !$(':input[autofocus]').length) {
99
+          return;
100
+        }
101
+
102
+        var el = $('[autofocus]')[0];
103
+
104
+        if (!el.disabled) {
105
+          el.focus();
106
+        }
107
+      },
108
+      // FORMALIZE.init.placeholder
109
+      placeholder: function() {
110
+        if (PLACEHOLDER_SUPPORTED || !$(':input[placeholder]').length) {
111
+          // Exit if placeholder is supported natively,
112
+          // or if page does not have any placeholder.
113
+          return;
114
+        }
115
+
116
+        FORMALIZE.misc.add_placeholder();
117
+
118
+        $(':input[placeholder]').each(function() {
119
+          // Placeholder obscured in older browsers,
120
+          // so there's no point adding to password.
121
+          if (this.type === 'password') {
122
+            return;
123
+          }
124
+
125
+          var el = $(this);
126
+          var text = el.attr('placeholder');
127
+
128
+          el.focus(function() {
129
+            if (el.val() === text) {
130
+              el.val('').removeClass('placeholder_text');
131
+            }
132
+          }).blur(function() {
133
+            FORMALIZE.misc.add_placeholder();
134
+          });
135
+
136
+          // Prevent <form> from accidentally
137
+          // submitting the placeholder text.
138
+          el.closest('form').submit(function() {
139
+            if (el.val() === text) {
140
+              el.val('').removeClass('placeholder_text');
141
+            }
142
+          }).on('reset', function() {
143
+            setTimeout(FORMALIZE.misc.add_placeholder, 50);
144
+          });
145
+        });
146
+      }
147
+    },
148
+    // FORMALIZE.misc
149
+    misc: {
150
+      // FORMALIZE.misc.add_placeholder
151
+      add_placeholder: function() {
152
+        if (PLACEHOLDER_SUPPORTED || !$(':input[placeholder]').length) {
153
+          // Exit if placeholder is supported natively,
154
+          // or if page does not have any placeholder.
155
+          return;
156
+        }
157
+
158
+        $(':input[placeholder]').each(function() {
159
+          // Placeholder obscured in older browsers,
160
+          // so there's no point adding to password.
161
+          if (this.type === 'password') {
162
+            return;
163
+          }
164
+
165
+          var el = $(this);
166
+          var text = el.attr('placeholder');
167
+
168
+          if (!el.val() || el.val() === text) {
169
+            el.val(text).addClass('placeholder_text');
170
+          }
171
+        });
172
+      }
173
+    }
174
+  };
175
+// Alias jQuery, window, document.
176
+})(jQuery, this, this.document);
177
+
178
+// Automatically calls all functions in FORMALIZE.init
179
+jQuery(document).ready(function() {
180
+  FORMALIZE.go();
181
+});
0 182
\ No newline at end of file
1 183
new file mode 100644
... ...
@@ -0,0 +1,9831 @@
1
+/*!
2
+ * jQuery JavaScript Library v2.2.0
3
+ * http://jquery.com/
4
+ *
5
+ * Includes Sizzle.js
6
+ * http://sizzlejs.com/
7
+ *
8
+ * Copyright jQuery Foundation and other contributors
9
+ * Released under the MIT license
10
+ * http://jquery.org/license
11
+ *
12
+ * Date: 2016-01-08T20:02Z
13
+ */
14
+
15
+(function( global, factory ) {
16
+
17
+	if ( typeof module === "object" && typeof module.exports === "object" ) {
18
+		// For CommonJS and CommonJS-like environments where a proper `window`
19
+		// is present, execute the factory and get jQuery.
20
+		// For environments that do not have a `window` with a `document`
21
+		// (such as Node.js), expose a factory as module.exports.
22
+		// This accentuates the need for the creation of a real `window`.
23
+		// e.g. var jQuery = require("jquery")(window);
24
+		// See ticket #14549 for more info.
25
+		module.exports = global.document ?
26
+			factory( global, true ) :
27
+			function( w ) {
28
+				if ( !w.document ) {
29
+					throw new Error( "jQuery requires a window with a document" );
30
+				}
31
+				return factory( w );
32
+			};
33
+	} else {
34
+		factory( global );
35
+	}
36
+
37
+// Pass this if window is not defined yet
38
+}(typeof window !== "undefined" ? window : this, function( window, noGlobal ) {
39
+
40
+// Support: Firefox 18+
41
+// Can't be in strict mode, several libs including ASP.NET trace
42
+// the stack via arguments.caller.callee and Firefox dies if
43
+// you try to trace through "use strict" call chains. (#13335)
44
+//"use strict";
45
+var arr = [];
46
+
47
+var document = window.document;
48
+
49
+var slice = arr.slice;
50
+
51
+var concat = arr.concat;
52
+
53
+var push = arr.push;
54
+
55
+var indexOf = arr.indexOf;
56
+
57
+var class2type = {};
58
+
59
+var toString = class2type.toString;
60
+
61
+var hasOwn = class2type.hasOwnProperty;
62
+
63
+var support = {};
64
+
65
+
66
+
67
+var
68
+	version = "2.2.0",
69
+
70
+	// Define a local copy of jQuery
71
+	jQuery = function( selector, context ) {
72
+
73
+		// The jQuery object is actually just the init constructor 'enhanced'
74
+		// Need init if jQuery is called (just allow error to be thrown if not included)
75
+		return new jQuery.fn.init( selector, context );
76
+	},
77
+
78
+	// Support: Android<4.1
79
+	// Make sure we trim BOM and NBSP
80
+	rtrim = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,
81
+
82
+	// Matches dashed string for camelizing
83
+	rmsPrefix = /^-ms-/,
84
+	rdashAlpha = /-([\da-z])/gi,
85
+
86
+	// Used by jQuery.camelCase as callback to replace()
87
+	fcamelCase = function( all, letter ) {
88
+		return letter.toUpperCase();
89
+	};
90
+
91
+jQuery.fn = jQuery.prototype = {
92
+
93
+	// The current version of jQuery being used
94
+	jquery: version,
95
+
96
+	constructor: jQuery,
97
+
98
+	// Start with an empty selector
99
+	selector: "",
100
+
101
+	// The default length of a jQuery object is 0
102
+	length: 0,
103
+
104
+	toArray: function() {
105
+		return slice.call( this );
106
+	},
107
+
108
+	// Get the Nth element in the matched element set OR
109
+	// Get the whole matched element set as a clean array
110
+	get: function( num ) {
111
+		return num != null ?
112
+
113
+			// Return just the one element from the set
114
+			( num < 0 ? this[ num + this.length ] : this[ num ] ) :
115
+
116
+			// Return all the elements in a clean array
117
+			slice.call( this );
118
+	},
119
+
120
+	// Take an array of elements and push it onto the stack
121
+	// (returning the new matched element set)
122
+	pushStack: function( elems ) {
123
+
124
+		// Build a new jQuery matched element set
125
+		var ret = jQuery.merge( this.constructor(), elems );
126
+
127
+		// Add the old object onto the stack (as a reference)
128
+		ret.prevObject = this;
129
+		ret.context = this.context;
130
+
131
+		// Return the newly-formed element set
132
+		return ret;
133
+	},
134
+
135
+	// Execute a callback for every element in the matched set.
136
+	each: function( callback ) {
137
+		return jQuery.each( this, callback );
138
+	},
139
+
140
+	map: function( callback ) {
141
+		return this.pushStack( jQuery.map( this, function( elem, i ) {
142
+			return callback.call( elem, i, elem );
143
+		} ) );
144
+	},
145
+
146
+	slice: function() {
147
+		return this.pushStack( slice.apply( this, arguments ) );
148
+	},
149
+
150
+	first: function() {
151
+		return this.eq( 0 );
152
+	},
153
+
154
+	last: function() {
155
+		return this.eq( -1 );
156
+	},
157
+
158
+	eq: function( i ) {
159
+		var len = this.length,
160
+			j = +i + ( i < 0 ? len : 0 );
161
+		return this.pushStack( j >= 0 && j < len ? [ this[ j ] ] : [] );
162
+	},
163
+
164
+	end: function() {
165
+		return this.prevObject || this.constructor();
166
+	},
167
+
168
+	// For internal use only.
169
+	// Behaves like an Array's method, not like a jQuery method.
170
+	push: push,
171
+	sort: arr.sort,
172
+	splice: arr.splice
173
+};
174
+
175
+jQuery.extend = jQuery.fn.extend = function() {
176
+	var options, name, src, copy, copyIsArray, clone,
177
+		target = arguments[ 0 ] || {},
178
+		i = 1,
179
+		length = arguments.length,
180
+		deep = false;
181
+
182
+	// Handle a deep copy situation
183
+	if ( typeof target === "boolean" ) {
184
+		deep = target;
185
+
186
+		// Skip the boolean and the target
187
+		target = arguments[ i ] || {};
188
+		i++;
189
+	}
190
+
191
+	// Handle case when target is a string or something (possible in deep copy)
192
+	if ( typeof target !== "object" && !jQuery.isFunction( target ) ) {
193
+		target = {};
194
+	}
195
+
196
+	// Extend jQuery itself if only one argument is passed
197
+	if ( i === length ) {
198
+		target = this;
199
+		i--;
200
+	}
201
+
202
+	for ( ; i < length; i++ ) {
203
+
204
+		// Only deal with non-null/undefined values
205
+		if ( ( options = arguments[ i ] ) != null ) {
206
+
207
+			// Extend the base object
208
+			for ( name in options ) {
209
+				src = target[ name ];
210
+				copy = options[ name ];
211
+
212
+				// Prevent never-ending loop
213
+				if ( target === copy ) {
214
+					continue;
215
+				}
216
+
217
+				// Recurse if we're merging plain objects or arrays
218
+				if ( deep && copy && ( jQuery.isPlainObject( copy ) ||
219
+					( copyIsArray = jQuery.isArray( copy ) ) ) ) {
220
+
221
+					if ( copyIsArray ) {
222
+						copyIsArray = false;
223
+						clone = src && jQuery.isArray( src ) ? src : [];
224
+
225
+					} else {
226
+						clone = src && jQuery.isPlainObject( src ) ? src : {};
227
+					}
228
+
229
+					// Never move original objects, clone them
230
+					target[ name ] = jQuery.extend( deep, clone, copy );
231
+
232
+				// Don't bring in undefined values
233
+				} else if ( copy !== undefined ) {
234
+					target[ name ] = copy;
235
+				}
236
+			}
237
+		}
238
+	}
239
+
240
+	// Return the modified object
241
+	return target;
242
+};
243
+
244
+jQuery.extend( {
245
+
246
+	// Unique for each copy of jQuery on the page
247
+	expando: "jQuery" + ( version + Math.random() ).replace( /\D/g, "" ),
248
+
249
+	// Assume jQuery is ready without the ready module
250
+	isReady: true,
251
+
252
+	error: function( msg ) {
253
+		throw new Error( msg );
254
+	},
255
+
256
+	noop: function() {},
257
+
258
+	isFunction: function( obj ) {
259
+		return jQuery.type( obj ) === "function";
260
+	},
261
+
262
+	isArray: Array.isArray,
263
+
264
+	isWindow: function( obj ) {
265
+		return obj != null && obj === obj.window;
266
+	},
267
+
268
+	isNumeric: function( obj ) {
269
+
270
+		// parseFloat NaNs numeric-cast false positives (null|true|false|"")
271
+		// ...but misinterprets leading-number strings, particularly hex literals ("0x...")
272
+		// subtraction forces infinities to NaN
273
+		// adding 1 corrects loss of precision from parseFloat (#15100)
274
+		var realStringObj = obj && obj.toString();
275
+		return !jQuery.isArray( obj ) && ( realStringObj - parseFloat( realStringObj ) + 1 ) >= 0;
276
+	},
277
+
278
+	isPlainObject: function( obj ) {
279
+
280
+		// Not plain objects:
281
+		// - Any object or value whose internal [[Class]] property is not "[object Object]"
282
+		// - DOM nodes
283
+		// - window
284
+		if ( jQuery.type( obj ) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) {
285
+			return false;
286
+		}
287
+
288
+		if ( obj.constructor &&
289
+				!hasOwn.call( obj.constructor.prototype, "isPrototypeOf" ) ) {
290
+			return false;
291
+		}
292
+
293
+		// If the function hasn't returned already, we're confident that
294
+		// |obj| is a plain object, created by {} or constructed with new Object
295
+		return true;
296
+	},
297
+
298
+	isEmptyObject: function( obj ) {
299
+		var name;
300
+		for ( name in obj ) {
301
+			return false;
302
+		}
303
+		return true;
304
+	},
305
+
306
+	type: function( obj ) {
307
+		if ( obj == null ) {
308
+			return obj + "";
309
+		}
310
+
311
+		// Support: Android<4.0, iOS<6 (functionish RegExp)
312
+		return typeof obj === "object" || typeof obj === "function" ?
313
+			class2type[ toString.call( obj ) ] || "object" :
314
+			typeof obj;
315
+	},
316
+
317
+	// Evaluates a script in a global context
318
+	globalEval: function( code ) {
319
+		var script,
320
+			indirect = eval;
321
+
322
+		code = jQuery.trim( code );
323
+
324
+		if ( code ) {
325
+
326
+			// If the code includes a valid, prologue position
327
+			// strict mode pragma, execute code by injecting a
328
+			// script tag into the document.
329
+			if ( code.indexOf( "use strict" ) === 1 ) {
330
+				script = document.createElement( "script" );
331
+				script.text = code;
332
+				document.head.appendChild( script ).parentNode.removeChild( script );
333
+			} else {
334
+
335
+				// Otherwise, avoid the DOM node creation, insertion
336
+				// and removal by using an indirect global eval
337
+
338
+				indirect( code );
339
+			}
340
+		}
341
+	},
342
+
343
+	// Convert dashed to camelCase; used by the css and data modules
344
+	// Support: IE9-11+
345
+	// Microsoft forgot to hump their vendor prefix (#9572)
346
+	camelCase: function( string ) {
347
+		return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase );
348
+	},
349
+
350
+	nodeName: function( elem, name ) {
351
+		return elem.nodeName && elem.nodeName.toLowerCase() === name.toLowerCase();
352
+	},
353
+
354
+	each: function( obj, callback ) {
355
+		var length, i = 0;
356
+
357
+		if ( isArrayLike( obj ) ) {
358
+			length = obj.length;
359
+			for ( ; i < length; i++ ) {
360
+				if ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {
361
+					break;
362
+				}
363
+			}
364
+		} else {
365
+			for ( i in obj ) {
366
+				if ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {
367
+					break;
368
+				}
369
+			}
370
+		}
371
+
372
+		return obj;
373
+	},
374
+
375
+	// Support: Android<4.1
376
+	trim: function( text ) {
377
+		return text == null ?
378
+			"" :
379
+			( text + "" ).replace( rtrim, "" );
380
+	},
381
+
382
+	// results is for internal usage only
383
+	makeArray: function( arr, results ) {
384
+		var ret = results || [];
385
+
386
+		if ( arr != null ) {
387
+			if ( isArrayLike( Object( arr ) ) ) {
388
+				jQuery.merge( ret,
389
+					typeof arr === "string" ?
390
+					[ arr ] : arr
391
+				);
392
+			} else {
393
+				push.call( ret, arr );
394
+			}
395
+		}
396
+
397
+		return ret;
398
+	},
399
+
400
+	inArray: function( elem, arr, i ) {
401
+		return arr == null ? -1 : indexOf.call( arr, elem, i );
402
+	},
403
+
404
+	merge: function( first, second ) {
405
+		var len = +second.length,
406
+			j = 0,
407
+			i = first.length;
408
+
409
+		for ( ; j < len; j++ ) {
410
+			first[ i++ ] = second[ j ];
411
+		}
412
+
413
+		first.length = i;
414
+
415
+		return first;
416
+	},
417
+
418
+	grep: function( elems, callback, invert ) {
419
+		var callbackInverse,
420
+			matches = [],
421
+			i = 0,
422
+			length = elems.length,
423
+			callbackExpect = !invert;
424
+
425
+		// Go through the array, only saving the items
426
+		// that pass the validator function
427
+		for ( ; i < length; i++ ) {
428
+			callbackInverse = !callback( elems[ i ], i );
429
+			if ( callbackInverse !== callbackExpect ) {
430
+				matches.push( elems[ i ] );
431
+			}
432
+		}
433
+
434
+		return matches;
435
+	},
436
+
437
+	// arg is for internal usage only
438
+	map: function( elems, callback, arg ) {
439
+		var length, value,
440
+			i = 0,
441
+			ret = [];
442
+
443
+		// Go through the array, translating each of the items to their new values
444
+		if ( isArrayLike( elems ) ) {
445
+			length = elems.length;
446
+			for ( ; i < length; i++ ) {
447
+				value = callback( elems[ i ], i, arg );
448
+
449
+				if ( value != null ) {
450
+					ret.push( value );
451
+				}
452
+			}
453
+
454
+		// Go through every key on the object,
455
+		} else {
456
+			for ( i in elems ) {
457
+				value = callback( elems[ i ], i, arg );
458
+
459
+				if ( value != null ) {
460
+					ret.push( value );
461
+				}
462
+			}
463
+		}
464
+
465
+		// Flatten any nested arrays
466
+		return concat.apply( [], ret );
467
+	},
468
+
469
+	// A global GUID counter for objects
470
+	guid: 1,
471
+
472
+	// Bind a function to a context, optionally partially applying any
473
+	// arguments.
474
+	proxy: function( fn, context ) {
475
+		var tmp, args, proxy;
476
+
477
+		if ( typeof context === "string" ) {
478
+			tmp = fn[ context ];
479
+			context = fn;
480
+			fn = tmp;
481
+		}
482
+
483
+		// Quick check to determine if target is callable, in the spec
484
+		// this throws a TypeError, but we will just return undefined.
485
+		if ( !jQuery.isFunction( fn ) ) {
486
+			return undefined;
487
+		}
488
+
489
+		// Simulated bind
490
+		args = slice.call( arguments, 2 );
491
+		proxy = function() {
492
+			return fn.apply( context || this, args.concat( slice.call( arguments ) ) );
493
+		};
494
+
495
+		// Set the guid of unique handler to the same of original handler, so it can be removed
496
+		proxy.guid = fn.guid = fn.guid || jQuery.guid++;
497
+
498
+		return proxy;
499
+	},
500
+
501
+	now: Date.now,
502
+
503
+	// jQuery.support is not used in Core but other projects attach their
504
+	// properties to it so it needs to exist.
505
+	support: support
506
+} );
507
+
508
+// JSHint would error on this code due to the Symbol not being defined in ES5.
509
+// Defining this global in .jshintrc would create a danger of using the global
510
+// unguarded in another place, it seems safer to just disable JSHint for these
511
+// three lines.
512
+/* jshint ignore: start */
513
+if ( typeof Symbol === "function" ) {
514
+	jQuery.fn[ Symbol.iterator ] = arr[ Symbol.iterator ];
515
+}
516
+/* jshint ignore: end */
517
+
518
+// Populate the class2type map
519
+jQuery.each( "Boolean Number String Function Array Date RegExp Object Error Symbol".split( " " ),
520
+function( i, name ) {
521
+	class2type[ "[object " + name + "]" ] = name.toLowerCase();
522
+} );
523
+
524
+function isArrayLike( obj ) {
525
+
526
+	// Support: iOS 8.2 (not reproducible in simulator)
527
+	// `in` check used to prevent JIT error (gh-2145)
528
+	// hasOwn isn't used here due to false negatives
529
+	// regarding Nodelist length in IE
530
+	var length = !!obj && "length" in obj && obj.length,
531
+		type = jQuery.type( obj );
532
+
533
+	if ( type === "function" || jQuery.isWindow( obj ) ) {
534
+		return false;
535
+	}
536
+
537
+	return type === "array" || length === 0 ||
538
+		typeof length === "number" && length > 0 && ( length - 1 ) in obj;
539
+}
540
+var Sizzle =
541
+/*!
542
+ * Sizzle CSS Selector Engine v2.2.1
543
+ * http://sizzlejs.com/
544
+ *
545
+ * Copyright jQuery Foundation and other contributors
546
+ * Released under the MIT license
547
+ * http://jquery.org/license
548
+ *
549
+ * Date: 2015-10-17
550
+ */
551
+(function( window ) {
552
+
553
+var i,
554
+	support,
555
+	Expr,
556
+	getText,
557
+	isXML,
558
+	tokenize,
559
+	compile,
560
+	select,
561
+	outermostContext,
562
+	sortInput,
563
+	hasDuplicate,
564
+
565
+	// Local document vars
566
+	setDocument,
567
+	document,
568
+	docElem,
569
+	documentIsHTML,
570
+	rbuggyQSA,
571
+	rbuggyMatches,
572
+	matches,
573
+	contains,
574
+
575
+	// Instance-specific data
576
+	expando = "sizzle" + 1 * new Date(),
577
+	preferredDoc = window.document,
578
+	dirruns = 0,
579
+	done = 0,
580
+	classCache = createCache(),
581
+	tokenCache = createCache(),
582
+	compilerCache = createCache(),
583
+	sortOrder = function( a, b ) {
584
+		if ( a === b ) {
585
+			hasDuplicate = true;
586
+		}
587
+		return 0;
588
+	},
589
+
590
+	// General-purpose constants
591
+	MAX_NEGATIVE = 1 << 31,
592
+
593
+	// Instance methods
594
+	hasOwn = ({}).hasOwnProperty,
595
+	arr = [],
596
+	pop = arr.pop,
597
+	push_native = arr.push,
598
+	push = arr.push,
599
+	slice = arr.slice,
600
+	// Use a stripped-down indexOf as it's faster than native
601
+	// http://jsperf.com/thor-indexof-vs-for/5
602
+	indexOf = function( list, elem ) {
603
+		var i = 0,
604
+			len = list.length;
605
+		for ( ; i < len; i++ ) {
606
+			if ( list[i] === elem ) {
607
+				return i;
608
+			}
609
+		}
610
+		return -1;
611
+	},
612
+
613
+	booleans = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",
614
+
615
+	// Regular expressions
616
+
617
+	// http://www.w3.org/TR/css3-selectors/#whitespace
618
+	whitespace = "[\\x20\\t\\r\\n\\f]",
619
+
620
+	// http://www.w3.org/TR/CSS21/syndata.html#value-def-identifier
621
+	identifier = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",
622
+
623
+	// Attribute selectors: http://www.w3.org/TR/selectors/#attribute-selectors
624
+	attributes = "\\[" + whitespace + "*(" + identifier + ")(?:" + whitespace +
625
+		// Operator (capture 2)
626
+		"*([*^$|!~]?=)" + whitespace +
627
+		// "Attribute values must be CSS identifiers [capture 5] or strings [capture 3 or capture 4]"
628
+		"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + identifier + "))|)" + whitespace +
629
+		"*\\]",
630
+
631
+	pseudos = ":(" + identifier + ")(?:\\((" +
632
+		// To reduce the number of selectors needing tokenize in the preFilter, prefer arguments:
633
+		// 1. quoted (capture 3; capture 4 or capture 5)
634
+		"('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|" +
635
+		// 2. simple (capture 6)
636
+		"((?:\\\\.|[^\\\\()[\\]]|" + attributes + ")*)|" +
637
+		// 3. anything else (capture 2)
638
+		".*" +
639
+		")\\)|)",
640
+
641
+	// Leading and non-escaped trailing whitespace, capturing some non-whitespace characters preceding the latter
642
+	rwhitespace = new RegExp( whitespace + "+", "g" ),
643
+	rtrim = new RegExp( "^" + whitespace + "+|((?:^|[^\\\\])(?:\\\\.)*)" + whitespace + "+$", "g" ),
644
+
645
+	rcomma = new RegExp( "^" + whitespace + "*," + whitespace + "*" ),
646
+	rcombinators = new RegExp( "^" + whitespace + "*([>+~]|" + whitespace + ")" + whitespace + "*" ),
647
+
648
+	rattributeQuotes = new RegExp( "=" + whitespace + "*([^\\]'\"]*?)" + whitespace + "*\\]", "g" ),
649
+
650
+	rpseudo = new RegExp( pseudos ),
651
+	ridentifier = new RegExp( "^" + identifier + "$" ),
652
+
653
+	matchExpr = {
654
+		"ID": new RegExp( "^#(" + identifier + ")" ),
655
+		"CLASS": new RegExp( "^\\.(" + identifier + ")" ),
656
+		"TAG": new RegExp( "^(" + identifier + "|[*])" ),
657
+		"ATTR": new RegExp( "^" + attributes ),
658
+		"PSEUDO": new RegExp( "^" + pseudos ),
659
+		"CHILD": new RegExp( "^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + whitespace +
660
+			"*(even|odd|(([+-]|)(\\d*)n|)" + whitespace + "*(?:([+-]|)" + whitespace +
661
+			"*(\\d+)|))" + whitespace + "*\\)|)", "i" ),
662
+		"bool": new RegExp( "^(?:" + booleans + ")$", "i" ),
663
+		// For use in libraries implementing .is()
664
+		// We use this for POS matching in `select`
665
+		"needsContext": new RegExp( "^" + whitespace + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" +
666
+			whitespace + "*((?:-\\d)?\\d*)" + whitespace + "*\\)|)(?=[^-]|$)", "i" )
667
+	},
668
+
669
+	rinputs = /^(?:input|select|textarea|button)$/i,
670
+	rheader = /^h\d$/i,
671
+
672
+	rnative = /^[^{]+\{\s*\[native \w/,
673
+
674
+	// Easily-parseable/retrievable ID or TAG or CLASS selectors
675
+	rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,
676
+
677
+	rsibling = /[+~]/,
678
+	rescape = /'|\\/g,
679
+
680
+	// CSS escapes http://www.w3.org/TR/CSS21/syndata.html#escaped-characters
681
+	runescape = new RegExp( "\\\\([\\da-f]{1,6}" + whitespace + "?|(" + whitespace + ")|.)", "ig" ),
682
+	funescape = function( _, escaped, escapedWhitespace ) {
683
+		var high = "0x" + escaped - 0x10000;
684
+		// NaN means non-codepoint
685
+		// Support: Firefox<24
686
+		// Workaround erroneous numeric interpretation of +"0x"
687
+		return high !== high || escapedWhitespace ?
688
+			escaped :
689
+			high < 0 ?
690
+				// BMP codepoint
691
+				String.fromCharCode( high + 0x10000 ) :
692
+				// Supplemental Plane codepoint (surrogate pair)
693
+				String.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 );
694
+	},
695
+
696
+	// Used for iframes
697
+	// See setDocument()
698
+	// Removing the function wrapper causes a "Permission Denied"
699
+	// error in IE
700
+	unloadHandler = function() {
701
+		setDocument();
702
+	};
703
+
704
+// Optimize for push.apply( _, NodeList )
705
+try {
706
+	push.apply(
707
+		(arr = slice.call( preferredDoc.childNodes )),
708
+		preferredDoc.childNodes
709
+	);
710
+	// Support: Android<4.0
711
+	// Detect silently failing push.apply
712
+	arr[ preferredDoc.childNodes.length ].nodeType;
713
+} catch ( e ) {
714
+	push = { apply: arr.length ?
715
+
716
+		// Leverage slice if possible
717
+		function( target, els ) {
718
+			push_native.apply( target, slice.call(els) );
719
+		} :
720
+
721
+		// Support: IE<9
722
+		// Otherwise append directly
723
+		function( target, els ) {
724
+			var j = target.length,
725
+				i = 0;
726
+			// Can't trust NodeList.length
727
+			while ( (target[j++] = els[i++]) ) {}
728
+			target.length = j - 1;
729
+		}
730
+	};
731
+}
732
+
733
+function Sizzle( selector, context, results, seed ) {
734
+	var m, i, elem, nid, nidselect, match, groups, newSelector,
735
+		newContext = context && context.ownerDocument,
736
+
737
+		// nodeType defaults to 9, since context defaults to document
738
+		nodeType = context ? context.nodeType : 9;
739
+
740
+	results = results || [];
741
+
742
+	// Return early from calls with invalid selector or context
743
+	if ( typeof selector !== "string" || !selector ||
744
+		nodeType !== 1 && nodeType !== 9 && nodeType !== 11 ) {
745
+
746
+		return results;
747
+	}
748
+
749
+	// Try to shortcut find operations (as opposed to filters) in HTML documents
750
+	if ( !seed ) {
751
+
752
+		if ( ( context ? context.ownerDocument || context : preferredDoc ) !== document ) {
753
+			setDocument( context );
754
+		}
755
+		context = context || document;
756
+
757
+		if ( documentIsHTML ) {
758
+
759
+			// If the selector is sufficiently simple, try using a "get*By*" DOM method
760
+			// (excepting DocumentFragment context, where the methods don't exist)
761
+			if ( nodeType !== 11 && (match = rquickExpr.exec( selector )) ) {
762
+
763
+				// ID selector
764
+				if ( (m = match[1]) ) {
765
+
766
+					// Document context
767
+					if ( nodeType === 9 ) {
768
+						if ( (elem = context.getElementById( m )) ) {
769
+
770
+							// Support: IE, Opera, Webkit
771
+							// TODO: identify versions
772
+							// getElementById can match elements by name instead of ID
773
+							if ( elem.id === m ) {
774
+								results.push( elem );
775
+								return results;
776
+							}
777
+						} else {
778
+							return results;
779
+						}
780
+
781
+					// Element context
782
+					} else {
783
+
784
+						// Support: IE, Opera, Webkit
785
+						// TODO: identify versions
786
+						// getElementById can match elements by name instead of ID
787
+						if ( newContext && (elem = newContext.getElementById( m )) &&
788
+							contains( context, elem ) &&
789
+							elem.id === m ) {
790
+
791
+							results.push( elem );
792
+							return results;
793
+						}
794
+					}
795
+
796
+				// Type selector
797
+				} else if ( match[2] ) {
798
+					push.apply( results, context.getElementsByTagName( selector ) );
799
+					return results;
800
+
801
+				// Class selector
802
+				} else if ( (m = match[3]) && support.getElementsByClassName &&
803
+					context.getElementsByClassName ) {
804
+
805
+					push.apply( results, context.getElementsByClassName( m ) );
806
+					return results;
807
+				}
808
+			}
809
+
810
+			// Take advantage of querySelectorAll
811
+			if ( support.qsa &&
812
+				!compilerCache[ selector + " " ] &&
813
+				(!rbuggyQSA || !rbuggyQSA.test( selector )) ) {
814
+
815
+				if ( nodeType !== 1 ) {
816
+					newContext = context;
817
+					newSelector = selector;
818
+
819
+				// qSA looks outside Element context, which is not what we want
820
+				// Thanks to Andrew Dupont for this workaround technique
821
+				// Support: IE <=8
822
+				// Exclude object elements
823
+				} else if ( context.nodeName.toLowerCase() !== "object" ) {
824
+
825
+					// Capture the context ID, setting it first if necessary
826
+					if ( (nid = context.getAttribute( "id" )) ) {
827
+						nid = nid.replace( rescape, "\\$&" );
828
+					} else {
829
+						context.setAttribute( "id", (nid = expando) );
830
+					}
831
+
832
+					// Prefix every selector in the list
833
+					groups = tokenize( selector );
834
+					i = groups.length;
835
+					nidselect = ridentifier.test( nid ) ? "#" + nid : "[id='" + nid + "']";
836
+					while ( i-- ) {
837
+						groups[i] = nidselect + " " + toSelector( groups[i] );
838
+					}
839
+					newSelector = groups.join( "," );
840
+
841
+					// Expand context for sibling selectors
842
+					newContext = rsibling.test( selector ) && testContext( context.parentNode ) ||
843
+						context;
844
+				}
845
+
846
+				if ( newSelector ) {
847
+					try {
848
+						push.apply( results,
849
+							newContext.querySelectorAll( newSelector )
850
+						);
851
+						return results;
852
+					} catch ( qsaError ) {
853
+					} finally {
854
+						if ( nid === expando ) {
855
+							context.removeAttribute( "id" );
856
+						}
857
+					}
858
+				}
859
+			}
860
+		}
861
+	}
862
+
863
+	// All others
864
+	return select( selector.replace( rtrim, "$1" ), context, results, seed );
865
+}
866
+
867
+/**
868
+ * Create key-value caches of limited size
869
+ * @returns {function(string, object)} Returns the Object data after storing it on itself with
870
+ *	property name the (space-suffixed) string and (if the cache is larger than Expr.cacheLength)
871
+ *	deleting the oldest entry
872
+ */
873
+function createCache() {
874
+	var keys = [];
875
+
876
+	function cache( key, value ) {
877
+		// Use (key + " ") to avoid collision with native prototype properties (see Issue #157)
878
+		if ( keys.push( key + " " ) > Expr.cacheLength ) {
879
+			// Only keep the most recent entries
880
+			delete cache[ keys.shift() ];
881
+		}
882
+		return (cache[ key + " " ] = value);
883
+	}
884
+	return cache;
885
+}
886
+
887
+/**
888
+ * Mark a function for special use by Sizzle
889
+ * @param {Function} fn The function to mark
890
+ */
891
+function markFunction( fn ) {
892
+	fn[ expando ] = true;
893
+	return fn;
894
+}
895
+
896
+/**
897
+ * Support testing using an element
898
+ * @param {Function} fn Passed the created div and expects a boolean result
899
+ */
900
+function assert( fn ) {
901
+	var div = document.createElement("div");
902
+
903
+	try {
904
+		return !!fn( div );
905
+	} catch (e) {
906
+		return false;
907
+	} finally {
908
+		// Remove from its parent by default
909
+		if ( div.parentNode ) {
910
+			div.parentNode.removeChild( div );
911
+		}
912
+		// release memory in IE
913
+		div = null;
914
+	}
915
+}
916
+
917
+/**
918
+ * Adds the same handler for all of the specified attrs
919
+ * @param {String} attrs Pipe-separated list of attributes
920
+ * @param {Function} handler The method that will be applied
921
+ */
922
+function addHandle( attrs, handler ) {
923
+	var arr = attrs.split("|"),
924
+		i = arr.length;
925
+
926
+	while ( i-- ) {
927
+		Expr.attrHandle[ arr[i] ] = handler;
928
+	}
929
+}
930
+
931
+/**
932
+ * Checks document order of two siblings
933
+ * @param {Element} a
934
+ * @param {Element} b
935
+ * @returns {Number} Returns less than 0 if a precedes b, greater than 0 if a follows b
936
+ */
937
+function siblingCheck( a, b ) {
938
+	var cur = b && a,
939
+		diff = cur && a.nodeType === 1 && b.nodeType === 1 &&
940
+			( ~b.sourceIndex || MAX_NEGATIVE ) -
941
+			( ~a.sourceIndex || MAX_NEGATIVE );
942
+
943
+	// Use IE sourceIndex if available on both nodes
944
+	if ( diff ) {
945
+		return diff;
946
+	}
947
+
948
+	// Check if b follows a
949
+	if ( cur ) {
950
+		while ( (cur = cur.nextSibling) ) {
951
+			if ( cur === b ) {
952
+				return -1;
953
+			}
954
+		}
955
+	}
956
+
957
+	return a ? 1 : -1;
958
+}
959
+
960
+/**
961
+ * Returns a function to use in pseudos for input types
962
+ * @param {String} type
963
+ */
964
+function createInputPseudo( type ) {
965
+	return function( elem ) {
966
+		var name = elem.nodeName.toLowerCase();
967
+		return name === "input" && elem.type === type;
968
+	};
969
+}
970
+
971
+/**
972
+ * Returns a function to use in pseudos for buttons
973
+ * @param {String} type
974
+ */
975
+function createButtonPseudo( type ) {
976
+	return function( elem ) {
977
+		var name = elem.nodeName.toLowerCase();
978
+		return (name === "input" || name === "button") && elem.type === type;
979
+	};
980
+}
981
+
982
+/**
983
+ * Returns a function to use in pseudos for positionals
984
+ * @param {Function} fn
985
+ */
986
+function createPositionalPseudo( fn ) {
987
+	return markFunction(function( argument ) {
988
+		argument = +argument;
989
+		return markFunction(function( seed, matches ) {
990
+			var j,
991
+				matchIndexes = fn( [], seed.length, argument ),
992
+				i = matchIndexes.length;
993
+
994
+			// Match elements found at the specified indexes
995
+			while ( i-- ) {
996
+				if ( seed[ (j = matchIndexes[i]) ] ) {
997
+					seed[j] = !(matches[j] = seed[j]);
998
+				}
999
+			}
1000
+		});
1001
+	});
1002
+}
1003
+
1004
+/**
1005
+ * Checks a node for validity as a Sizzle context
1006
+ * @param {Element|Object=} context
1007
+ * @returns {Element|Object|Boolean} The input node if acceptable, otherwise a falsy value
1008
+ */
1009
+function testContext( context ) {
1010
+	return context && typeof context.getElementsByTagName !== "undefined" && context;
1011
+}
1012
+
1013
+// Expose support vars for convenience
1014
+support = Sizzle.support = {};
1015
+
1016
+/**
1017
+ * Detects XML nodes
1018
+ * @param {Element|Object} elem An element or a document
1019
+ * @returns {Boolean} True iff elem is a non-HTML XML node
1020
+ */
1021
+isXML = Sizzle.isXML = function( elem ) {
1022
+	// documentElement is verified for cases where it doesn't yet exist
1023
+	// (such as loading iframes in IE - #4833)
1024
+	var documentElement = elem && (elem.ownerDocument || elem).documentElement;
1025
+	return documentElement ? documentElement.nodeName !== "HTML" : false;
1026
+};
1027
+
1028
+/**
1029
+ * Sets document-related variables once based on the current document
1030
+ * @param {Element|Object} [doc] An element or document object to use to set the document
1031
+ * @returns {Object} Returns the current document
1032
+ */
1033
+setDocument = Sizzle.setDocument = function( node ) {
1034
+	var hasCompare, parent,
1035
+		doc = node ? node.ownerDocument || node : preferredDoc;
1036
+
1037
+	// Return early if doc is invalid or already selected
1038
+	if ( doc === document || doc.nodeType !== 9 || !doc.documentElement ) {
1039
+		return document;
1040
+	}
1041
+
1042
+	// Update global variables
1043
+	document = doc;
1044
+	docElem = document.documentElement;
1045
+	documentIsHTML = !isXML( document );
1046
+
1047
+	// Support: IE 9-11, Edge
1048
+	// Accessing iframe documents after unload throws "permission denied" errors (jQuery #13936)
1049
+	if ( (parent = document.defaultView) && parent.top !== parent ) {
1050
+		// Support: IE 11
1051
+		if ( parent.addEventListener ) {
1052
+			parent.addEventListener( "unload", unloadHandler, false );
1053
+
1054
+		// Support: IE 9 - 10 only
1055
+		} else if ( parent.attachEvent ) {
1056
+			parent.attachEvent( "onunload", unloadHandler );
1057
+		}
1058
+	}
1059
+
1060
+	/* Attributes
1061
+	---------------------------------------------------------------------- */
1062
+
1063
+	// Support: IE<8
1064
+	// Verify that getAttribute really returns attributes and not properties
1065
+	// (excepting IE8 booleans)
1066
+	support.attributes = assert(function( div ) {
1067
+		div.className = "i";
1068
+		return !div.getAttribute("className");
1069
+	});
1070
+
1071
+	/* getElement(s)By*
1072
+	---------------------------------------------------------------------- */
1073
+
1074
+	// Check if getElementsByTagName("*") returns only elements
1075
+	support.getElementsByTagName = assert(function( div ) {
1076
+		div.appendChild( document.createComment("") );
1077
+		return !div.getElementsByTagName("*").length;
1078
+	});
1079
+
1080
+	// Support: IE<9
1081
+	support.getElementsByClassName = rnative.test( document.getElementsByClassName );
1082
+
1083
+	// Support: IE<10
1084
+	// Check if getElementById returns elements by name
1085
+	// The broken getElementById methods don't pick up programatically-set names,
1086
+	// so use a roundabout getElementsByName test
1087
+	support.getById = assert(function( div ) {
1088
+		docElem.appendChild( div ).id = expando;
1089
+		return !document.getElementsByName || !document.getElementsByName( expando ).length;
1090
+	});
1091
+
1092
+	// ID find and filter
1093
+	if ( support.getById ) {
1094
+		Expr.find["ID"] = function( id, context ) {
1095
+			if ( typeof context.getElementById !== "undefined" && documentIsHTML ) {
1096
+				var m = context.getElementById( id );
1097
+				return m ? [ m ] : [];
1098
+			}
1099
+		};
1100
+		Expr.filter["ID"] = function( id ) {
1101
+			var attrId = id.replace( runescape, funescape );
1102
+			return function( elem ) {
1103
+				return elem.getAttribute("id") === attrId;
1104
+			};
1105
+		};
1106
+	} else {
1107
+		// Support: IE6/7
1108
+		// getElementById is not reliable as a find shortcut
1109
+		delete Expr.find["ID"];
1110
+
1111
+		Expr.filter["ID"] =  function( id ) {
1112
+			var attrId = id.replace( runescape, funescape );
1113
+			return function( elem ) {
1114
+				var node = typeof elem.getAttributeNode !== "undefined" &&
1115
+					elem.getAttributeNode("id");
1116
+				return node && node.value === attrId;
1117
+			};
1118
+		};
1119
+	}
1120
+
1121
+	// Tag
1122
+	Expr.find["TAG"] = support.getElementsByTagName ?
1123
+		function( tag, context ) {
1124
+			if ( typeof context.getElementsByTagName !== "undefined" ) {
1125
+				return context.getElementsByTagName( tag );
1126
+
1127
+			// DocumentFragment nodes don't have gEBTN
1128
+			} else if ( support.qsa ) {
1129
+				return context.querySelectorAll( tag );
1130
+			}
1131
+		} :
1132
+
1133
+		function( tag, context ) {
1134
+			var elem,
1135
+				tmp = [],
1136
+				i = 0,
1137
+				// By happy coincidence, a (broken) gEBTN appears on DocumentFragment nodes too
1138
+				results = context.getElementsByTagName( tag );
1139
+
1140
+			// Filter out possible comments
1141
+			if ( tag === "*" ) {
1142
+				while ( (elem = results[i++]) ) {
1143
+					if ( elem.nodeType === 1 ) {
1144
+						tmp.push( elem );
1145
+					}
1146
+				}
1147
+
1148
+				return tmp;
1149
+			}
1150
+			return results;
1151
+		};
1152
+
1153
+	// Class
1154
+	Expr.find["CLASS"] = support.getElementsByClassName && function( className, context ) {
1155
+		if ( typeof context.getElementsByClassName !== "undefined" && documentIsHTML ) {
1156
+			return context.getElementsByClassName( className );
1157
+		}
1158
+	};
1159
+
1160
+	/* QSA/matchesSelector
1161
+	---------------------------------------------------------------------- */
1162
+
1163
+	// QSA and matchesSelector support
1164
+
1165
+	// matchesSelector(:active) reports false when true (IE9/Opera 11.5)
1166
+	rbuggyMatches = [];
1167
+
1168
+	// qSa(:focus) reports false when true (Chrome 21)
1169
+	// We allow this because of a bug in IE8/9 that throws an error
1170
+	// whenever `document.activeElement` is accessed on an iframe
1171
+	// So, we allow :focus to pass through QSA all the time to avoid the IE error
1172
+	// See http://bugs.jquery.com/ticket/13378
1173
+	rbuggyQSA = [];
1174
+
1175
+	if ( (support.qsa = rnative.test( document.querySelectorAll )) ) {
1176
+		// Build QSA regex
1177
+		// Regex strategy adopted from Diego Perini
1178
+		assert(function( div ) {
1179
+			// Select is set to empty string on purpose
1180
+			// This is to test IE's treatment of not explicitly
1181
+			// setting a boolean content attribute,
1182
+			// since its presence should be enough
1183
+			// http://bugs.jquery.com/ticket/12359
1184
+			docElem.appendChild( div ).innerHTML = "<a id='" + expando + "'></a>" +
1185
+				"<select id='" + expando + "-\r\\' msallowcapture=''>" +
1186
+				"<option selected=''></option></select>";
1187
+
1188
+			// Support: IE8, Opera 11-12.16
1189
+			// Nothing should be selected when empty strings follow ^= or $= or *=
1190
+			// The test attribute must be unknown in Opera but "safe" for WinRT
1191
+			// http://msdn.microsoft.com/en-us/library/ie/hh465388.aspx#attribute_section
1192
+			if ( div.querySelectorAll("[msallowcapture^='']").length ) {
1193
+				rbuggyQSA.push( "[*^$]=" + whitespace + "*(?:''|\"\")" );
1194
+			}
1195
+
1196
+			// Support: IE8
1197
+			// Boolean attributes and "value" are not treated correctly
1198
+			if ( !div.querySelectorAll("[selected]").length ) {
1199
+				rbuggyQSA.push( "\\[" + whitespace + "*(?:value|" + booleans + ")" );
1200
+			}
1201
+
1202
+			// Support: Chrome<29, Android<4.4, Safari<7.0+, iOS<7.0+, PhantomJS<1.9.8+
1203
+			if ( !div.querySelectorAll( "[id~=" + expando + "-]" ).length ) {
1204
+				rbuggyQSA.push("~=");
1205
+			}
1206
+
1207
+			// Webkit/Opera - :checked should return selected option elements
1208
+			// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked
1209
+			// IE8 throws error here and will not see later tests
1210
+			if ( !div.querySelectorAll(":checked").length ) {
1211
+				rbuggyQSA.push(":checked");
1212
+			}
1213
+
1214
+			// Support: Safari 8+, iOS 8+
1215
+			// https://bugs.webkit.org/show_bug.cgi?id=136851
1216
+			// In-page `selector#id sibing-combinator selector` fails
1217
+			if ( !div.querySelectorAll( "a#" + expando + "+*" ).length ) {
1218
+				rbuggyQSA.push(".#.+[+~]");
1219
+			}
1220
+		});
1221
+
1222
+		assert(function( div ) {
1223
+			// Support: Windows 8 Native Apps
1224
+			// The type and name attributes are restricted during .innerHTML assignment
1225
+			var input = document.createElement("input");
1226
+			input.setAttribute( "type", "hidden" );
1227
+			div.appendChild( input ).setAttribute( "name", "D" );
1228
+
1229
+			// Support: IE8
1230
+			// Enforce case-sensitivity of name attribute
1231
+			if ( div.querySelectorAll("[name=d]").length ) {
1232
+				rbuggyQSA.push( "name" + whitespace + "*[*^$|!~]?=" );
1233
+			}
1234
+
1235
+			// FF 3.5 - :enabled/:disabled and hidden elements (hidden elements are still enabled)
1236
+			// IE8 throws error here and will not see later tests
1237
+			if ( !div.querySelectorAll(":enabled").length ) {
1238
+				rbuggyQSA.push( ":enabled", ":disabled" );
1239
+			}
1240
+
1241
+			// Opera 10-11 does not throw on post-comma invalid pseudos
1242
+			div.querySelectorAll("*,:x");
1243
+			rbuggyQSA.push(",.*:");
1244
+		});
1245
+	}
1246
+
1247
+	if ( (support.matchesSelector = rnative.test( (matches = docElem.matches ||
1248
+		docElem.webkitMatchesSelector ||
1249
+		docElem.mozMatchesSelector ||
1250
+		docElem.oMatchesSelector ||
1251
+		docElem.msMatchesSelector) )) ) {
1252
+
1253
+		assert(function( div ) {
1254
+			// Check to see if it's possible to do matchesSelector
1255
+			// on a disconnected node (IE 9)
1256
+			support.disconnectedMatch = matches.call( div, "div" );
1257
+
1258
+			// This should fail with an exception
1259
+			// Gecko does not error, returns false instead
1260
+			matches.call( div, "[s!='']:x" );
1261
+			rbuggyMatches.push( "!=", pseudos );
1262
+		});
1263
+	}
1264
+
1265
+	rbuggyQSA = rbuggyQSA.length && new RegExp( rbuggyQSA.join("|") );
1266
+	rbuggyMatches = rbuggyMatches.length && new RegExp( rbuggyMatches.join("|") );
1267
+
1268
+	/* Contains
1269
+	---------------------------------------------------------------------- */
1270
+	hasCompare = rnative.test( docElem.compareDocumentPosition );
1271
+
1272
+	// Element contains another
1273
+	// Purposefully self-exclusive
1274
+	// As in, an element does not contain itself
1275
+	contains = hasCompare || rnative.test( docElem.contains ) ?
1276
+		function( a, b ) {
1277
+			var adown = a.nodeType === 9 ? a.documentElement : a,
1278
+				bup = b && b.parentNode;
1279
+			return a === bup || !!( bup && bup.nodeType === 1 && (
1280
+				adown.contains ?
1281
+					adown.contains( bup ) :
1282
+					a.compareDocumentPosition && a.compareDocumentPosition( bup ) & 16
1283
+			));
1284
+		} :
1285
+		function( a, b ) {
1286
+			if ( b ) {
1287
+				while ( (b = b.parentNode) ) {
1288
+					if ( b === a ) {
1289
+						return true;
1290
+					}
1291
+				}
1292
+			}
1293
+			return false;
1294
+		};
1295
+
1296
+	/* Sorting
1297
+	---------------------------------------------------------------------- */
1298
+
1299
+	// Document order sorting
1300
+	sortOrder = hasCompare ?
1301
+	function( a, b ) {
1302
+
1303
+		// Flag for duplicate removal
1304
+		if ( a === b ) {
1305
+			hasDuplicate = true;
1306
+			return 0;
1307
+		}
1308
+
1309
+		// Sort on method existence if only one input has compareDocumentPosition
1310
+		var compare = !a.compareDocumentPosition - !b.compareDocumentPosition;
1311
+		if ( compare ) {
1312
+			return compare;
1313
+		}
1314
+
1315
+		// Calculate position if both inputs belong to the same document
1316
+		compare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?
1317
+			a.compareDocumentPosition( b ) :
1318
+
1319
+			// Otherwise we know they are disconnected
1320
+			1;
1321
+
1322
+		// Disconnected nodes
1323
+		if ( compare & 1 ||
1324
+			(!support.sortDetached && b.compareDocumentPosition( a ) === compare) ) {
1325
+
1326
+			// Choose the first element that is related to our preferred document
1327
+			if ( a === document || a.ownerDocument === preferredDoc && contains(preferredDoc, a) ) {
1328
+				return -1;
1329
+			}
1330
+			if ( b === document || b.ownerDocument === preferredDoc && contains(preferredDoc, b) ) {
1331
+				return 1;
1332
+			}
1333
+
1334
+			// Maintain original order
1335
+			return sortInput ?
1336
+				( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :
1337
+				0;
1338
+		}
1339
+
1340
+		return compare & 4 ? -1 : 1;
1341
+	} :
1342
+	function( a, b ) {
1343
+		// Exit early if the nodes are identical
1344
+		if ( a === b ) {
1345
+			hasDuplicate = true;
1346
+			return 0;
1347
+		}
1348
+
1349
+		var cur,
1350
+			i = 0,
1351
+			aup = a.parentNode,
1352
+			bup = b.parentNode,
1353
+			ap = [ a ],
1354
+			bp = [ b ];
1355
+
1356
+		// Parentless nodes are either documents or disconnected
1357
+		if ( !aup || !bup ) {
1358
+			return a === document ? -1 :
1359
+				b === document ? 1 :
1360
+				aup ? -1 :
1361
+				bup ? 1 :
1362
+				sortInput ?
1363
+				( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :
1364
+				0;
1365
+
1366
+		// If the nodes are siblings, we can do a quick check
1367
+		} else if ( aup === bup ) {
1368
+			return siblingCheck( a, b );
1369
+		}
1370
+
1371
+		// Otherwise we need full lists of their ancestors for comparison
1372
+		cur = a;
1373
+		while ( (cur = cur.parentNode) ) {
1374
+			ap.unshift( cur );
1375
+		}
1376
+		cur = b;
1377
+		while ( (cur = cur.parentNode) ) {
1378
+			bp.unshift( cur );
1379
+		}
1380
+
1381
+		// Walk down the tree looking for a discrepancy
1382
+		while ( ap[i] === bp[i] ) {
1383
+			i++;
1384
+		}
1385
+
1386
+		return i ?
1387
+			// Do a sibling check if the nodes have a common ancestor
1388
+			siblingCheck( ap[i], bp[i] ) :
1389
+
1390
+			// Otherwise nodes in our document sort first
1391
+			ap[i] === preferredDoc ? -1 :
1392
+			bp[i] === preferredDoc ? 1 :
1393
+			0;
1394
+	};
1395
+
1396
+	return document;
1397
+};
1398
+
1399
+Sizzle.matches = function( expr, elements ) {
1400
+	return Sizzle( expr, null, null, elements );
1401
+};
1402
+
1403
+Sizzle.matchesSelector = function( elem, expr ) {
1404
+	// Set document vars if needed
1405
+	if ( ( elem.ownerDocument || elem ) !== document ) {
1406
+		setDocument( elem );
1407
+	}
1408
+
1409
+	// Make sure that attribute selectors are quoted
1410
+	expr = expr.replace( rattributeQuotes, "='$1']" );
1411
+
1412
+	if ( support.matchesSelector && documentIsHTML &&
1413
+		!compilerCache[ expr + " " ] &&
1414
+		( !rbuggyMatches || !rbuggyMatches.test( expr ) ) &&
1415
+		( !rbuggyQSA     || !rbuggyQSA.test( expr ) ) ) {
1416
+
1417
+		try {
1418
+			var ret = matches.call( elem, expr );
1419
+
1420
+			// IE 9's matchesSelector returns false on disconnected nodes
1421
+			if ( ret || support.disconnectedMatch ||
1422
+					// As well, disconnected nodes are said to be in a document
1423
+					// fragment in IE 9
1424
+					elem.document && elem.document.nodeType !== 11 ) {
1425
+				return ret;
1426
+			}
1427
+		} catch (e) {}
1428
+	}
1429
+
1430
+	return Sizzle( expr, document, null, [ elem ] ).length > 0;
1431
+};
1432
+
1433
+Sizzle.contains = function( context, elem ) {
1434
+	// Set document vars if needed
1435
+	if ( ( context.ownerDocument || context ) !== document ) {
1436
+		setDocument( context );
1437
+	}
1438
+	return contains( context, elem );
1439
+};
1440
+
1441
+Sizzle.attr = function( elem, name ) {
1442
+	// Set document vars if needed
1443
+	if ( ( elem.ownerDocument || elem ) !== document ) {
1444
+		setDocument( elem );
1445
+	}
1446
+
1447
+	var fn = Expr.attrHandle[ name.toLowerCase() ],
1448
+		// Don't get fooled by Object.prototype properties (jQuery #13807)
1449
+		val = fn && hasOwn.call( Expr.attrHandle, name.toLowerCase() ) ?
1450
+			fn( elem, name, !documentIsHTML ) :
1451
+			undefined;
1452
+
1453
+	return val !== undefined ?
1454
+		val :
1455
+		support.attributes || !documentIsHTML ?
1456
+			elem.getAttribute( name ) :
1457
+			(val = elem.getAttributeNode(name)) && val.specified ?
1458
+				val.value :
1459
+				null;
1460
+};
1461
+
1462
+Sizzle.error = function( msg ) {
1463
+	throw new Error( "Syntax error, unrecognized expression: " + msg );
1464
+};
1465
+
1466
+/**
1467
+ * Document sorting and removing duplicates
1468
+ * @param {ArrayLike} results
1469
+ */
1470
+Sizzle.uniqueSort = function( results ) {
1471
+	var elem,
1472
+		duplicates = [],
1473
+		j = 0,
1474
+		i = 0;
1475
+
1476
+	// Unless we *know* we can detect duplicates, assume their presence
1477
+	hasDuplicate = !support.detectDuplicates;
1478
+	sortInput = !support.sortStable && results.slice( 0 );
1479
+	results.sort( sortOrder );
1480
+
1481
+	if ( hasDuplicate ) {
1482
+		while ( (elem = results[i++]) ) {
1483
+			if ( elem === results[ i ] ) {
1484
+				j = duplicates.push( i );
1485
+			}
1486
+		}
1487
+		while ( j-- ) {
1488
+			results.splice( duplicates[ j ], 1 );
1489
+		}
1490
+	}
1491
+
1492
+	// Clear input after sorting to release objects
1493
+	// See https://github.com/jquery/sizzle/pull/225
1494
+	sortInput = null;
1495
+
1496
+	return results;
1497
+};
1498
+
1499
+/**
1500
+ * Utility function for retrieving the text value of an array of DOM nodes
1501
+ * @param {Array|Element} elem
1502
+ */
1503
+getText = Sizzle.getText = function( elem ) {
1504
+	var node,
1505
+		ret = "",
1506
+		i = 0,
1507
+		nodeType = elem.nodeType;
1508
+
1509
+	if ( !nodeType ) {
1510
+		// If no nodeType, this is expected to be an array
1511
+		while ( (node = elem[i++]) ) {
1512
+			// Do not traverse comment nodes
1513
+			ret += getText( node );
1514
+		}
1515
+	} else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {
1516
+		// Use textContent for elements
1517
+		// innerText usage removed for consistency of new lines (jQuery #11153)
1518
+		if ( typeof elem.textContent === "string" ) {
1519
+			return elem.textContent;
1520
+		} else {
1521
+			// Traverse its children
1522
+			for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {
1523
+				ret += getText( elem );
1524
+			}
1525
+		}
1526
+	} else if ( nodeType === 3 || nodeType === 4 ) {
1527
+		return elem.nodeValue;
1528
+	}
1529
+	// Do not include comment or processing instruction nodes
1530
+
1531
+	return ret;
1532
+};
1533
+
1534
+Expr = Sizzle.selectors = {
1535
+
1536
+	// Can be adjusted by the user
1537
+	cacheLength: 50,
1538
+
1539
+	createPseudo: markFunction,
1540
+
1541
+	match: matchExpr,
1542
+
1543
+	attrHandle: {},
1544
+
1545
+	find: {},
1546
+
1547
+	relative: {
1548
+		">": { dir: "parentNode", first: true },
1549
+		" ": { dir: "parentNode" },
1550
+		"+": { dir: "previousSibling", first: true },
1551
+		"~": { dir: "previousSibling" }
1552
+	},
1553
+
1554
+	preFilter: {
1555
+		"ATTR": function( match ) {
1556
+			match[1] = match[1].replace( runescape, funescape );
1557
+
1558
+			// Move the given value to match[3] whether quoted or unquoted
1559
+			match[3] = ( match[3] || match[4] || match[5] || "" ).replace( runescape, funescape );
1560
+
1561
+			if ( match[2] === "~=" ) {
1562
+				match[3] = " " + match[3] + " ";
1563
+			}
1564
+
1565
+			return match.slice( 0, 4 );
1566
+		},
1567
+
1568
+		"CHILD": function( match ) {
1569
+			/* matches from matchExpr["CHILD"]
1570
+				1 type (only|nth|...)
1571
+				2 what (child|of-type)
1572
+				3 argument (even|odd|\d*|\d*n([+-]\d+)?|...)
1573
+				4 xn-component of xn+y argument ([+-]?\d*n|)
1574
+				5 sign of xn-component
1575
+				6 x of xn-component
1576
+				7 sign of y-component
1577
+				8 y of y-component
1578
+			*/
1579
+			match[1] = match[1].toLowerCase();
1580
+
1581
+			if ( match[1].slice( 0, 3 ) === "nth" ) {
1582
+				// nth-* requires argument
1583
+				if ( !match[3] ) {
1584
+					Sizzle.error( match[0] );
1585
+				}
1586
+
1587
+				// numeric x and y parameters for Expr.filter.CHILD
1588
+				// remember that false/true cast respectively to 0/1
1589
+				match[4] = +( match[4] ? match[5] + (match[6] || 1) : 2 * ( match[3] === "even" || match[3] === "odd" ) );
1590
+				match[5] = +( ( match[7] + match[8] ) || match[3] === "odd" );
1591
+
1592
+			// other types prohibit arguments
1593
+			} else if ( match[3] ) {
1594
+				Sizzle.error( match[0] );
1595
+			}
1596
+
1597
+			return match;
1598
+		},
1599
+
1600
+		"PSEUDO": function( match ) {
1601
+			var excess,
1602
+				unquoted = !match[6] && match[2];
1603
+
1604
+			if ( matchExpr["CHILD"].test( match[0] ) ) {
1605
+				return null;
1606
+			}
1607
+
1608
+			// Accept quoted arguments as-is
1609
+			if ( match[3] ) {
1610
+				match[2] = match[4] || match[5] || "";
1611
+
1612
+			// Strip excess characters from unquoted arguments
1613
+			} else if ( unquoted && rpseudo.test( unquoted ) &&
1614
+				// Get excess from tokenize (recursively)
1615
+				(excess = tokenize( unquoted, true )) &&
1616
+				// advance to the next closing parenthesis
1617
+				(excess = unquoted.indexOf( ")", unquoted.length - excess ) - unquoted.length) ) {
1618
+
1619
+				// excess is a negative index
1620
+				match[0] = match[0].slice( 0, excess );
1621
+				match[2] = unquoted.slice( 0, excess );
1622
+			}
1623
+
1624
+			// Return only captures needed by the pseudo filter method (type and argument)
1625
+			return match.slice( 0, 3 );
1626
+		}
1627
+	},
1628
+
1629
+	filter: {
1630
+
1631
+		"TAG": function( nodeNameSelector ) {
1632
+			var nodeName = nodeNameSelector.replace( runescape, funescape ).toLowerCase();
1633
+			return nodeNameSelector === "*" ?
1634
+				function() { return true; } :
1635
+				function( elem ) {
1636
+					return elem.nodeName && elem.nodeName.toLowerCase() === nodeName;
1637
+				};
1638
+		},
1639
+
1640
+		"CLASS": function( className ) {
1641
+			var pattern = classCache[ className + " " ];
1642
+
1643
+			return pattern ||
1644
+				(pattern = new RegExp( "(^|" + whitespace + ")" + className + "(" + whitespace + "|$)" )) &&
1645
+				classCache( className, function( elem ) {
1646
+					return pattern.test( typeof elem.className === "string" && elem.className || typeof elem.getAttribute !== "undefined" && elem.getAttribute("class") || "" );
1647
+				});
1648
+		},
1649
+
1650
+		"ATTR": function( name, operator, check ) {
1651
+			return function( elem ) {
1652
+				var result = Sizzle.attr( elem, name );
1653
+
1654
+				if ( result == null ) {
1655
+					return operator === "!=";
1656
+				}
1657
+				if ( !operator ) {
1658
+					return true;
1659
+				}
1660
+
1661
+				result += "";
1662
+
1663
+				return operator === "=" ? result === check :
1664
+					operator === "!=" ? result !== check :
1665
+					operator === "^=" ? check && result.indexOf( check ) === 0 :
1666
+					operator === "*=" ? check && result.indexOf( check ) > -1 :
1667
+					operator === "$=" ? check && result.slice( -check.length ) === check :
1668
+					operator === "~=" ? ( " " + result.replace( rwhitespace, " " ) + " " ).indexOf( check ) > -1 :
1669
+					operator === "|=" ? result === check || result.slice( 0, check.length + 1 ) === check + "-" :
1670
+					false;
1671
+			};
1672
+		},
1673
+
1674
+		"CHILD": function( type, what, argument, first, last ) {
1675
+			var simple = type.slice( 0, 3 ) !== "nth",
1676
+				forward = type.slice( -4 ) !== "last",
1677
+				ofType = what === "of-type";
1678
+
1679
+			return first === 1 && last === 0 ?
1680
+
1681
+				// Shortcut for :nth-*(n)
1682
+				function( elem ) {
1683
+					return !!elem.parentNode;
1684
+				} :
1685
+
1686
+				function( elem, context, xml ) {
1687
+					var cache, uniqueCache, outerCache, node, nodeIndex, start,
1688
+						dir = simple !== forward ? "nextSibling" : "previousSibling",
1689
+						parent = elem.parentNode,
1690
+						name = ofType && elem.nodeName.toLowerCase(),
1691
+						useCache = !xml && !ofType,
1692
+						diff = false;
1693
+
1694
+					if ( parent ) {
1695
+
1696
+						// :(first|last|only)-(child|of-type)
1697
+						if ( simple ) {
1698
+							while ( dir ) {
1699
+								node = elem;
1700
+								while ( (node = node[ dir ]) ) {
1701
+									if ( ofType ?
1702
+										node.nodeName.toLowerCase() === name :
1703
+										node.nodeType === 1 ) {
1704
+
1705
+										return false;
1706
+									}
1707
+								}
1708
+								// Reverse direction for :only-* (if we haven't yet done so)
1709
+								start = dir = type === "only" && !start && "nextSibling";
1710
+							}
1711
+							return true;
1712
+						}
1713
+
1714
+						start = [ forward ? parent.firstChild : parent.lastChild ];
1715
+
1716
+						// non-xml :nth-child(...) stores cache data on `parent`
1717
+						if ( forward && useCache ) {
1718
+
1719
+							// Seek `elem` from a previously-cached index
1720
+
1721
+							// ...in a gzip-friendly way
1722
+							node = parent;
1723
+							outerCache = node[ expando ] || (node[ expando ] = {});
1724
+
1725
+							// Support: IE <9 only
1726
+							// Defend against cloned attroperties (jQuery gh-1709)
1727
+							uniqueCache = outerCache[ node.uniqueID ] ||
1728
+								(outerCache[ node.uniqueID ] = {});
1729
+
1730
+							cache = uniqueCache[ type ] || [];
1731
+							nodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];
1732
+							diff = nodeIndex && cache[ 2 ];
1733
+							node = nodeIndex && parent.childNodes[ nodeIndex ];
1734
+
1735
+							while ( (node = ++nodeIndex && node && node[ dir ] ||
1736
+
1737
+								// Fallback to seeking `elem` from the start
1738
+								(diff = nodeIndex = 0) || start.pop()) ) {
1739
+
1740
+								// When found, cache indexes on `parent` and break
1741
+								if ( node.nodeType === 1 && ++diff && node === elem ) {
1742
+									uniqueCache[ type ] = [ dirruns, nodeIndex, diff ];
1743
+									break;
1744
+								}
1745
+							}
1746
+
1747
+						} else {
1748
+							// Use previously-cached element index if available
1749
+							if ( useCache ) {
1750
+								// ...in a gzip-friendly way
1751
+								node = elem;
1752
+								outerCache = node[ expando ] || (node[ expando ] = {});
1753
+
1754
+								// Support: IE <9 only
1755
+								// Defend against cloned attroperties (jQuery gh-1709)
1756
+								uniqueCache = outerCache[ node.uniqueID ] ||
1757
+									(outerCache[ node.uniqueID ] = {});
1758
+
1759
+								cache = uniqueCache[ type ] || [];
1760
+								nodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];
1761
+								diff = nodeIndex;
1762
+							}
1763
+
1764
+							// xml :nth-child(...)
1765
+							// or :nth-last-child(...) or :nth(-last)?-of-type(...)
1766
+							if ( diff === false ) {
1767
+								// Use the same loop as above to seek `elem` from the start
1768
+								while ( (node = ++nodeIndex && node && node[ dir ] ||
1769
+									(diff = nodeIndex = 0) || start.pop()) ) {
1770
+
1771
+									if ( ( ofType ?
1772
+										node.nodeName.toLowerCase() === name :
1773
+										node.nodeType === 1 ) &&
1774
+										++diff ) {
1775
+
1776
+										// Cache the index of each encountered element
1777
+										if ( useCache ) {
1778
+											outerCache = node[ expando ] || (node[ expando ] = {});
1779
+
1780
+											// Support: IE <9 only
1781
+											// Defend against cloned attroperties (jQuery gh-1709)
1782
+											uniqueCache = outerCache[ node.uniqueID ] ||
1783
+												(outerCache[ node.uniqueID ] = {});
1784
+
1785
+											uniqueCache[ type ] = [ dirruns, diff ];
1786
+										}
1787
+
1788
+										if ( node === elem ) {
1789
+											break;
1790
+										}
1791
+									}
1792
+								}
1793
+							}
1794
+						}
1795
+
1796
+						// Incorporate the offset, then check against cycle size
1797
+						diff -= last;
1798
+						return diff === first || ( diff % first === 0 && diff / first >= 0 );
1799
+					}
1800
+				};
1801
+		},
1802
+
1803
+		"PSEUDO": function( pseudo, argument ) {
1804
+			// pseudo-class names are case-insensitive
1805
+			// http://www.w3.org/TR/selectors/#pseudo-classes
1806
+			// Prioritize by case sensitivity in case custom pseudos are added with uppercase letters
1807
+			// Remember that setFilters inherits from pseudos
1808
+			var args,
1809
+				fn = Expr.pseudos[ pseudo ] || Expr.setFilters[ pseudo.toLowerCase() ] ||
1810
+					Sizzle.error( "unsupported pseudo: " + pseudo );
1811
+
1812
+			// The user may use createPseudo to indicate that
1813
+			// arguments are needed to create the filter function
1814
+			// just as Sizzle does
1815
+			if ( fn[ expando ] ) {
1816
+				return fn( argument );
1817
+			}
1818
+
1819
+			// But maintain support for old signatures
1820
+			if ( fn.length > 1 ) {
1821
+				args = [ pseudo, pseudo, "", argument ];
1822
+				return Expr.setFilters.hasOwnProperty( pseudo.toLowerCase() ) ?
1823
+					markFunction(function( seed, matches ) {
1824
+						var idx,
1825
+							matched = fn( seed, argument ),
1826
+							i = matched.length;
1827
+						while ( i-- ) {
1828
+							idx = indexOf( seed, matched[i] );
1829
+							seed[ idx ] = !( matches[ idx ] = matched[i] );
1830
+						}
1831
+					}) :
1832
+					function( elem ) {
1833
+						return fn( elem, 0, args );
1834
+					};
1835
+			}
1836
+
1837
+			return fn;
1838
+		}
1839
+	},
1840
+
1841
+	pseudos: {
1842
+		// Potentially complex pseudos
1843
+		"not": markFunction(function( selector ) {
1844
+			// Trim the selector passed to compile
1845
+			// to avoid treating leading and trailing
1846
+			// spaces as combinators
1847
+			var input = [],
1848
+				results = [],
1849
+				matcher = compile( selector.replace( rtrim, "$1" ) );
1850
+
1851
+			return matcher[ expando ] ?
1852
+				markFunction(function( seed, matches, context, xml ) {
1853
+					var elem,
1854
+						unmatched = matcher( seed, null, xml, [] ),
1855
+						i = seed.length;
1856
+
1857
+					// Match elements unmatched by `matcher`
1858
+					while ( i-- ) {
1859
+						if ( (elem = unmatched[i]) ) {
1860
+							seed[i] = !(matches[i] = elem);
1861
+						}
1862
+					}
1863
+				}) :
1864
+				function( elem, context, xml ) {
1865
+					input[0] = elem;
1866
+					matcher( input, null, xml, results );
1867
+					// Don't keep the element (issue #299)
1868
+					input[0] = null;
1869
+					return !results.pop();
1870
+				};
1871
+		}),
1872
+
1873
+		"has": markFunction(function( selector ) {
1874
+			return function( elem ) {
1875
+				return Sizzle( selector, elem ).length > 0;
1876
+			};
1877
+		}),
1878
+
1879
+		"contains": markFunction(function( text ) {
1880
+			text = text.replace( runescape, funescape );
1881
+			return function( elem ) {
1882
+				return ( elem.textContent || elem.innerText || getText( elem ) ).indexOf( text ) > -1;
1883
+			};
1884
+		}),
1885
+
1886
+		// "Whether an element is represented by a :lang() selector
1887
+		// is based solely on the element's language value
1888
+		// being equal to the identifier C,
1889
+		// or beginning with the identifier C immediately followed by "-".
1890
+		// The matching of C against the element's language value is performed case-insensitively.
1891
+		// The identifier C does not have to be a valid language name."
1892
+		// http://www.w3.org/TR/selectors/#lang-pseudo
1893
+		"lang": markFunction( function( lang ) {
1894
+			// lang value must be a valid identifier
1895
+			if ( !ridentifier.test(lang || "") ) {
1896
+				Sizzle.error( "unsupported lang: " + lang );
1897
+			}
1898
+			lang = lang.replace( runescape, funescape ).toLowerCase();
1899
+			return function( elem ) {
1900
+				var elemLang;
1901
+				do {
1902
+					if ( (elemLang = documentIsHTML ?
1903
+						elem.lang :
1904
+						elem.getAttribute("xml:lang") || elem.getAttribute("lang")) ) {
1905
+
1906
+						elemLang = elemLang.toLowerCase();
1907
+						return elemLang === lang || elemLang.indexOf( lang + "-" ) === 0;
1908
+					}
1909
+				} while ( (elem = elem.parentNode) && elem.nodeType === 1 );
1910
+				return false;
1911
+			};
1912
+		}),
1913
+
1914
+		// Miscellaneous
1915
+		"target": function( elem ) {
1916
+			var hash = window.location && window.location.hash;
1917
+			return hash && hash.slice( 1 ) === elem.id;
1918
+		},
1919
+
1920
+		"root": function( elem ) {
1921
+			return elem === docElem;
1922
+		},
1923
+
1924
+		"focus": function( elem ) {
1925
+			return elem === document.activeElement && (!document.hasFocus || document.hasFocus()) && !!(elem.type || elem.href || ~elem.tabIndex);
1926
+		},
1927
+
1928
+		// Boolean properties
1929
+		"enabled": function( elem ) {
1930
+			return elem.disabled === false;
1931
+		},
1932
+
1933
+		"disabled": function( elem ) {
1934
+			return elem.disabled === true;
1935
+		},
1936
+
1937
+		"checked": function( elem ) {
1938
+			// In CSS3, :checked should return both checked and selected elements
1939
+			// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked
1940
+			var nodeName = elem.nodeName.toLowerCase();
1941
+			return (nodeName === "input" && !!elem.checked) || (nodeName === "option" && !!elem.selected);
1942
+		},
1943
+
1944
+		"selected": function( elem ) {
1945
+			// Accessing this property makes selected-by-default
1946
+			// options in Safari work properly
1947
+			if ( elem.parentNode ) {
1948
+				elem.parentNode.selectedIndex;
1949
+			}
1950
+
1951
+			return elem.selected === true;
1952
+		},
1953
+
1954
+		// Contents
1955
+		"empty": function( elem ) {
1956
+			// http://www.w3.org/TR/selectors/#empty-pseudo
1957
+			// :empty is negated by element (1) or content nodes (text: 3; cdata: 4; entity ref: 5),
1958
+			//   but not by others (comment: 8; processing instruction: 7; etc.)
1959
+			// nodeType < 6 works because attributes (2) do not appear as children
1960
+			for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {
1961
+				if ( elem.nodeType < 6 ) {
1962
+					return false;
1963
+				}
1964
+			}
1965
+			return true;
1966
+		},
1967
+
1968
+		"parent": function( elem ) {
1969
+			return !Expr.pseudos["empty"]( elem );
1970
+		},
1971
+
1972
+		// Element/input types
1973
+		"header": function( elem ) {
1974
+			return rheader.test( elem.nodeName );
1975
+		},
1976
+
1977
+		"input": function( elem ) {
1978
+			return rinputs.test( elem.nodeName );
1979
+		},
1980
+
1981
+		"button": function( elem ) {
1982
+			var name = elem.nodeName.toLowerCase();
1983
+			return name === "input" && elem.type === "button" || name === "button";
1984
+		},
1985
+
1986
+		"text": function( elem ) {
1987
+			var attr;
1988
+			return elem.nodeName.toLowerCase() === "input" &&
1989
+				elem.type === "text" &&
1990
+
1991
+				// Support: IE<8
1992
+				// New HTML5 attribute values (e.g., "search") appear with elem.type === "text"
1993
+				( (attr = elem.getAttribute("type")) == null || attr.toLowerCase() === "text" );
1994
+		},
1995
+
1996
+		// Position-in-collection
1997
+		"first": createPositionalPseudo(function() {
1998
+			return [ 0 ];
1999
+		}),
2000
+
2001
+		"last": createPositionalPseudo(function( matchIndexes, length ) {
2002
+			return [ length - 1 ];
2003
+		}),
2004
+
2005
+		"eq": createPositionalPseudo(function( matchIndexes, length, argument ) {
2006
+			return [ argument < 0 ? argument + length : argument ];
2007
+		}),
2008
+
2009
+		"even": createPositionalPseudo(function( matchIndexes, length ) {
2010
+			var i = 0;
2011
+			for ( ; i < length; i += 2 ) {
2012
+				matchIndexes.push( i );
2013
+			}
2014
+			return matchIndexes;
2015
+		}),
2016
+
2017
+		"odd": createPositionalPseudo(function( matchIndexes, length ) {
2018
+			var i = 1;
2019
+			for ( ; i < length; i += 2 ) {
2020
+				matchIndexes.push( i );
2021
+			}
2022
+			return matchIndexes;
2023
+		}),
2024
+
2025
+		"lt": createPositionalPseudo(function( matchIndexes, length, argument ) {
2026
+			var i = argument < 0 ? argument + length : argument;
2027
+			for ( ; --i >= 0; ) {
2028
+				matchIndexes.push( i );
2029
+			}
2030
+			return matchIndexes;
2031
+		}),
2032
+
2033
+		"gt": createPositionalPseudo(function( matchIndexes, length, argument ) {
2034
+			var i = argument < 0 ? argument + length : argument;
2035
+			for ( ; ++i < length; ) {
2036
+				matchIndexes.push( i );
2037
+			}
2038
+			return matchIndexes;
2039
+		})
2040
+	}
2041
+};
2042
+
2043
+Expr.pseudos["nth"] = Expr.pseudos["eq"];
2044
+
2045
+// Add button/input type pseudos
2046
+for ( i in { radio: true, checkbox: true, file: true, password: true, image: true } ) {
2047
+	Expr.pseudos[ i ] = createInputPseudo( i );
2048
+}
2049
+for ( i in { submit: true, reset: true } ) {
2050
+	Expr.pseudos[ i ] = createButtonPseudo( i );
2051
+}
2052
+
2053
+// Easy API for creating new setFilters
2054
+function setFilters() {}
2055
+setFilters.prototype = Expr.filters = Expr.pseudos;
2056
+Expr.setFilters = new setFilters();
2057
+
2058
+tokenize = Sizzle.tokenize = function( selector, parseOnly ) {
2059
+	var matched, match, tokens, type,
2060
+		soFar, groups, preFilters,
2061
+		cached = tokenCache[ selector + " " ];
2062
+
2063
+	if ( cached ) {
2064
+		return parseOnly ? 0 : cached.slice( 0 );
2065
+	}
2066
+
2067
+	soFar = selector;
2068
+	groups = [];
2069
+	preFilters = Expr.preFilter;
2070
+
2071
+	while ( soFar ) {
2072
+
2073
+		// Comma and first run
2074
+		if ( !matched || (match = rcomma.exec( soFar )) ) {
2075
+			if ( match ) {
2076
+				// Don't consume trailing commas as valid
2077
+				soFar = soFar.slice( match[0].length ) || soFar;
2078
+			}
2079
+			groups.push( (tokens = []) );
2080
+		}
2081
+
2082
+		matched = false;
2083
+
2084
+		// Combinators
2085
+		if ( (match = rcombinators.exec( soFar )) ) {
2086
+			matched = match.shift();
2087
+			tokens.push({
2088
+				value: matched,
2089
+				// Cast descendant combinators to space
2090
+				type: match[0].replace( rtrim, " " )
2091
+			});
2092
+			soFar = soFar.slice( matched.length );
2093
+		}
2094
+
2095
+		// Filters
2096
+		for ( type in Expr.filter ) {
2097
+			if ( (match = matchExpr[ type ].exec( soFar )) && (!preFilters[ type ] ||
2098
+				(match = preFilters[ type ]( match ))) ) {
2099
+				matched = match.shift();
2100
+				tokens.push({
2101
+					value: matched,
2102
+					type: type,
2103
+					matches: match
2104
+				});
2105
+				soFar = soFar.slice( matched.length );
2106
+			}
2107
+		}
2108
+
2109
+		if ( !matched ) {
2110
+			break;
2111
+		}
2112
+	}
2113
+
2114
+	// Return the length of the invalid excess
2115
+	// if we're just parsing
2116
+	// Otherwise, throw an error or return tokens
2117
+	return parseOnly ?
2118
+		soFar.length :
2119
+		soFar ?
2120
+			Sizzle.error( selector ) :
2121
+			// Cache the tokens
2122
+			tokenCache( selector, groups ).slice( 0 );
2123
+};
2124
+
2125
+function toSelector( tokens ) {
2126
+	var i = 0,
2127
+		len = tokens.length,
2128
+		selector = "";
2129
+	for ( ; i < len; i++ ) {
2130
+		selector += tokens[i].value;
2131
+	}
2132
+	return selector;
2133
+}
2134
+
2135
+function addCombinator( matcher, combinator, base ) {
2136
+	var dir = combinator.dir,
2137
+		checkNonElements = base && dir === "parentNode",
2138
+		doneName = done++;
2139
+
2140
+	return combinator.first ?
2141
+		// Check against closest ancestor/preceding element
2142
+		function( elem, context, xml ) {
2143
+			while ( (elem = elem[ dir ]) ) {
2144
+				if ( elem.nodeType === 1 || checkNonElements ) {
2145
+					return matcher( elem, context, xml );
2146
+				}
2147
+			}
2148
+		} :
2149
+
2150
+		// Check against all ancestor/preceding elements
2151
+		function( elem, context, xml ) {
2152
+			var oldCache, uniqueCache, outerCache,
2153
+				newCache = [ dirruns, doneName ];
2154
+
2155
+			// We can't set arbitrary data on XML nodes, so they don't benefit from combinator caching
2156
+			if ( xml ) {
2157
+				while ( (elem = elem[ dir ]) ) {
2158
+					if ( elem.nodeType === 1 || checkNonElements ) {
2159
+						if ( matcher( elem, context, xml ) ) {
2160
+							return true;
2161
+						}
2162
+					}
2163
+				}
2164
+			} else {
2165
+				while ( (elem = elem[ dir ]) ) {
2166
+					if ( elem.nodeType === 1 || checkNonElements ) {
2167
+						outerCache = elem[ expando ] || (elem[ expando ] = {});
2168
+
2169
+						// Support: IE <9 only
2170
+						// Defend against cloned attroperties (jQuery gh-1709)
2171
+						uniqueCache = outerCache[ elem.uniqueID ] || (outerCache[ elem.uniqueID ] = {});
2172
+
2173
+						if ( (oldCache = uniqueCache[ dir ]) &&
2174
+							oldCache[ 0 ] === dirruns && oldCache[ 1 ] === doneName ) {
2175
+
2176
+							// Assign to newCache so results back-propagate to previous elements
2177
+							return (newCache[ 2 ] = oldCache[ 2 ]);
2178
+						} else {
2179
+							// Reuse newcache so results back-propagate to previous elements
2180
+							uniqueCache[ dir ] = newCache;
2181
+
2182
+							// A match means we're done; a fail means we have to keep checking
2183
+							if ( (newCache[ 2 ] = matcher( elem, context, xml )) ) {
2184
+								return true;
2185
+							}
2186
+						}
2187
+					}
2188
+				}
2189
+			}
2190
+		};
2191
+}
2192
+
2193
+function elementMatcher( matchers ) {
2194
+	return matchers.length > 1 ?
2195
+		function( elem, context, xml ) {
2196
+			var i = matchers.length;
2197
+			while ( i-- ) {
2198
+				if ( !matchers[i]( elem, context, xml ) ) {
2199
+					return false;
2200
+				}
2201
+			}
2202
+			return true;
2203
+		} :
2204
+		matchers[0];
2205
+}
2206
+
2207
+function multipleContexts( selector, contexts, results ) {
2208
+	var i = 0,
2209
+		len = contexts.length;
2210
+	for ( ; i < len; i++ ) {
2211
+		Sizzle( selector, contexts[i], results );
2212
+	}
2213
+	return results;
2214
+}
2215
+
2216
+function condense( unmatched, map, filter, context, xml ) {
2217
+	var elem,
2218
+		newUnmatched = [],
2219
+		i = 0,
2220
+		len = unmatched.length,
2221
+		mapped = map != null;
2222
+
2223
+	for ( ; i < len; i++ ) {
2224
+		if ( (elem = unmatched[i]) ) {
2225
+			if ( !filter || filter( elem, context, xml ) ) {
2226
+				newUnmatched.push( elem );
2227
+				if ( mapped ) {
2228
+					map.push( i );
2229
+				}
2230
+			}
2231
+		}
2232
+	}
2233
+
2234
+	return newUnmatched;
2235
+}
2236
+
2237
+function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {
2238
+	if ( postFilter && !postFilter[ expando ] ) {
2239
+		postFilter = setMatcher( postFilter );
2240
+	}
2241
+	if ( postFinder && !postFinder[ expando ] ) {
2242
+		postFinder = setMatcher( postFinder, postSelector );
2243
+	}
2244
+	return markFunction(function( seed, results, context, xml ) {
2245
+		var temp, i, elem,
2246
+			preMap = [],
2247
+			postMap = [],
2248
+			preexisting = results.length,
2249
+
2250
+			// Get initial elements from seed or context
2251
+			elems = seed || multipleContexts( selector || "*", context.nodeType ? [ context ] : context, [] ),
2252
+
2253
+			// Prefilter to get matcher input, preserving a map for seed-results synchronization
2254
+			matcherIn = preFilter && ( seed || !selector ) ?
2255
+				condense( elems, preMap, preFilter, context, xml ) :
2256
+				elems,
2257
+
2258
+			matcherOut = matcher ?
2259
+				// If we have a postFinder, or filtered seed, or non-seed postFilter or preexisting results,
2260
+				postFinder || ( seed ? preFilter : preexisting || postFilter ) ?
2261
+
2262
+					// ...intermediate processing is necessary
2263
+					[] :
2264
+
2265
+					// ...otherwise use results directly
2266
+					results :
2267
+				matcherIn;
2268
+
2269
+		// Find primary matches
2270
+		if ( matcher ) {
2271
+			matcher( matcherIn, matcherOut, context, xml );
2272
+		}
2273
+
2274
+		// Apply postFilter
2275
+		if ( postFilter ) {
2276
+			temp = condense( matcherOut, postMap );
2277
+			postFilter( temp, [], context, xml );
2278
+
2279
+			// Un-match failing elements by moving them back to matcherIn
2280
+			i = temp.length;
2281
+			while ( i-- ) {
2282
+				if ( (elem = temp[i]) ) {
2283
+					matcherOut[ postMap[i] ] = !(matcherIn[ postMap[i] ] = elem);
2284
+				}
2285
+			}
2286
+		}
2287
+
2288
+		if ( seed ) {
2289
+			if ( postFinder || preFilter ) {
2290
+				if ( postFinder ) {
2291
+					// Get the final matcherOut by condensing this intermediate into postFinder contexts
2292
+					temp = [];
2293
+					i = matcherOut.length;
2294
+					while ( i-- ) {
2295
+						if ( (elem = matcherOut[i]) ) {
2296
+							// Restore matcherIn since elem is not yet a final match
2297
+							temp.push( (matcherIn[i] = elem) );
2298
+						}
2299
+					}
2300
+					postFinder( null, (matcherOut = []), temp, xml );
2301
+				}
2302
+
2303
+				// Move matched elements from seed to results to keep them synchronized
2304
+				i = matcherOut.length;
2305
+				while ( i-- ) {
2306
+					if ( (elem = matcherOut[i]) &&
2307
+						(temp = postFinder ? indexOf( seed, elem ) : preMap[i]) > -1 ) {
2308
+
2309
+						seed[temp] = !(results[temp] = elem);
2310
+					}
2311
+				}
2312
+			}
2313
+
2314
+		// Add elements to results, through postFinder if defined
2315
+		} else {
2316
+			matcherOut = condense(
2317
+				matcherOut === results ?
2318
+					matcherOut.splice( preexisting, matcherOut.length ) :
2319
+					matcherOut
2320
+			);
2321
+			if ( postFinder ) {
2322
+				postFinder( null, results, matcherOut, xml );
2323
+			} else {
2324
+				push.apply( results, matcherOut );
2325
+			}
2326
+		}
2327
+	});
2328
+}
2329
+
2330
+function matcherFromTokens( tokens ) {
2331
+	var checkContext, matcher, j,
2332
+		len = tokens.length,
2333
+		leadingRelative = Expr.relative[ tokens[0].type ],
2334
+		implicitRelative = leadingRelative || Expr.relative[" "],
2335
+		i = leadingRelative ? 1 : 0,
2336
+
2337
+		// The foundational matcher ensures that elements are reachable from top-level context(s)
2338
+		matchContext = addCombinator( function( elem ) {
2339
+			return elem === checkContext;
2340
+		}, implicitRelative, true ),
2341
+		matchAnyContext = addCombinator( function( elem ) {
2342
+			return indexOf( checkContext, elem ) > -1;
2343
+		}, implicitRelative, true ),
2344
+		matchers = [ function( elem, context, xml ) {
2345
+			var ret = ( !leadingRelative && ( xml || context !== outermostContext ) ) || (
2346
+				(checkContext = context).nodeType ?
2347
+					matchContext( elem, context, xml ) :
2348
+					matchAnyContext( elem, context, xml ) );
2349
+			// Avoid hanging onto element (issue #299)
2350
+			checkContext = null;
2351
+			return ret;
2352
+		} ];
2353
+
2354
+	for ( ; i < len; i++ ) {
2355
+		if ( (matcher = Expr.relative[ tokens[i].type ]) ) {
2356
+			matchers = [ addCombinator(elementMatcher( matchers ), matcher) ];
2357
+		} else {
2358
+			matcher = Expr.filter[ tokens[i].type ].apply( null, tokens[i].matches );
2359
+
2360
+			// Return special upon seeing a positional matcher
2361
+			if ( matcher[ expando ] ) {
2362
+				// Find the next relative operator (if any) for proper handling
2363
+				j = ++i;
2364
+				for ( ; j < len; j++ ) {
2365
+					if ( Expr.relative[ tokens[j].type ] ) {
2366
+						break;
2367
+					}
2368
+				}
2369
+				return setMatcher(
2370
+					i > 1 && elementMatcher( matchers ),
2371
+					i > 1 && toSelector(
2372
+						// If the preceding token was a descendant combinator, insert an implicit any-element `*`
2373
+						tokens.slice( 0, i - 1 ).concat({ value: tokens[ i - 2 ].type === " " ? "*" : "" })
2374
+					).replace( rtrim, "$1" ),
2375
+					matcher,
2376
+					i < j && matcherFromTokens( tokens.slice( i, j ) ),
2377
+					j < len && matcherFromTokens( (tokens = tokens.slice( j )) ),
2378
+					j < len && toSelector( tokens )
2379
+				);
2380
+			}
2381
+			matchers.push( matcher );
2382
+		}
2383
+	}
2384
+
2385
+	return elementMatcher( matchers );
2386
+}
2387
+
2388
+function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
2389
+	var bySet = setMatchers.length > 0,
2390
+		byElement = elementMatchers.length > 0,
2391
+		superMatcher = function( seed, context, xml, results, outermost ) {
2392
+			var elem, j, matcher,
2393
+				matchedCount = 0,
2394
+				i = "0",
2395
+				unmatched = seed && [],
2396
+				setMatched = [],
2397
+				contextBackup = outermostContext,
2398
+				// We must always have either seed elements or outermost context
2399
+				elems = seed || byElement && Expr.find["TAG"]( "*", outermost ),
2400
+				// Use integer dirruns iff this is the outermost matcher
2401
+				dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1),
2402
+				len = elems.length;
2403
+
2404
+			if ( outermost ) {
2405
+				outermostContext = context === document || context || outermost;
2406
+			}
2407
+
2408
+			// Add elements passing elementMatchers directly to results
2409
+			// Support: IE<9, Safari
2410
+			// Tolerate NodeList properties (IE: "length"; Safari: <number>) matching elements by id
2411
+			for ( ; i !== len && (elem = elems[i]) != null; i++ ) {
2412
+				if ( byElement && elem ) {
2413
+					j = 0;
2414
+					if ( !context && elem.ownerDocument !== document ) {
2415
+						setDocument( elem );
2416
+						xml = !documentIsHTML;
2417
+					}
2418
+					while ( (matcher = elementMatchers[j++]) ) {
2419
+						if ( matcher( elem, context || document, xml) ) {
2420
+							results.push( elem );
2421
+							break;
2422
+						}
2423
+					}
2424
+					if ( outermost ) {
2425
+						dirruns = dirrunsUnique;
2426
+					}
2427
+				}
2428
+
2429
+				// Track unmatched elements for set filters
2430
+				if ( bySet ) {
2431
+					// They will have gone through all possible matchers
2432
+					if ( (elem = !matcher && elem) ) {
2433
+						matchedCount--;
2434
+					}
2435
+
2436
+					// Lengthen the array for every element, matched or not
2437
+					if ( seed ) {
2438
+						unmatched.push( elem );
2439
+					}
2440
+				}
2441
+			}
2442
+
2443
+			// `i` is now the count of elements visited above, and adding it to `matchedCount`
2444
+			// makes the latter nonnegative.
2445
+			matchedCount += i;
2446
+
2447
+			// Apply set filters to unmatched elements
2448
+			// NOTE: This can be skipped if there are no unmatched elements (i.e., `matchedCount`
2449
+			// equals `i`), unless we didn't visit _any_ elements in the above loop because we have
2450
+			// no element matchers and no seed.
2451
+			// Incrementing an initially-string "0" `i` allows `i` to remain a string only in that
2452
+			// case, which will result in a "00" `matchedCount` that differs from `i` but is also
2453
+			// numerically zero.
2454
+			if ( bySet && i !== matchedCount ) {
2455
+				j = 0;
2456
+				while ( (matcher = setMatchers[j++]) ) {
2457
+					matcher( unmatched, setMatched, context, xml );
2458
+				}
2459
+
2460
+				if ( seed ) {
2461
+					// Reintegrate element matches to eliminate the need for sorting
2462
+					if ( matchedCount > 0 ) {
2463
+						while ( i-- ) {
2464
+							if ( !(unmatched[i] || setMatched[i]) ) {
2465
+								setMatched[i] = pop.call( results );
2466
+							}
2467
+						}
2468
+					}
2469
+
2470
+					// Discard index placeholder values to get only actual matches
2471
+					setMatched = condense( setMatched );
2472
+				}
2473
+
2474
+				// Add matches to results
2475
+				push.apply( results, setMatched );
2476
+
2477
+				// Seedless set matches succeeding multiple successful matchers stipulate sorting
2478
+				if ( outermost && !seed && setMatched.length > 0 &&
2479
+					( matchedCount + setMatchers.length ) > 1 ) {
2480
+
2481
+					Sizzle.uniqueSort( results );
2482
+				}
2483
+			}
2484
+
2485
+			// Override manipulation of globals by nested matchers
2486
+			if ( outermost ) {
2487
+				dirruns = dirrunsUnique;
2488
+				outermostContext = contextBackup;
2489
+			}
2490
+
2491
+			return unmatched;
2492
+		};
2493
+
2494
+	return bySet ?
2495
+		markFunction( superMatcher ) :
2496
+		superMatcher;
2497
+}
2498
+
2499
+compile = Sizzle.compile = function( selector, match /* Internal Use Only */ ) {
2500
+	var i,
2501
+		setMatchers = [],
2502
+		elementMatchers = [],
2503
+		cached = compilerCache[ selector + " " ];
2504
+
2505
+	if ( !cached ) {
2506
+		// Generate a function of recursive functions that can be used to check each element
2507
+		if ( !match ) {
2508
+			match = tokenize( selector );
2509
+		}
2510
+		i = match.length;
2511
+		while ( i-- ) {
2512
+			cached = matcherFromTokens( match[i] );
2513
+			if ( cached[ expando ] ) {
2514
+				setMatchers.push( cached );
2515
+			} else {
2516
+				elementMatchers.push( cached );
2517
+			}
2518
+		}
2519
+
2520
+		// Cache the compiled function
2521
+		cached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) );
2522
+
2523
+		// Save selector and tokenization
2524
+		cached.selector = selector;
2525
+	}
2526
+	return cached;
2527
+};
2528
+
2529
+/**
2530
+ * A low-level selection function that works with Sizzle's compiled
2531
+ *  selector functions
2532
+ * @param {String|Function} selector A selector or a pre-compiled
2533
+ *  selector function built with Sizzle.compile
2534
+ * @param {Element} context
2535
+ * @param {Array} [results]
2536
+ * @param {Array} [seed] A set of elements to match against
2537
+ */
2538
+select = Sizzle.select = function( selector, context, results, seed ) {
2539
+	var i, tokens, token, type, find,
2540
+		compiled = typeof selector === "function" && selector,
2541
+		match = !seed && tokenize( (selector = compiled.selector || selector) );
2542
+
2543
+	results = results || [];
2544
+
2545
+	// Try to minimize operations if there is only one selector in the list and no seed
2546
+	// (the latter of which guarantees us context)
2547
+	if ( match.length === 1 ) {
2548
+
2549
+		// Reduce context if the leading compound selector is an ID
2550
+		tokens = match[0] = match[0].slice( 0 );
2551
+		if ( tokens.length > 2 && (token = tokens[0]).type === "ID" &&
2552
+				support.getById && context.nodeType === 9 && documentIsHTML &&
2553
+				Expr.relative[ tokens[1].type ] ) {
2554
+
2555
+			context = ( Expr.find["ID"]( token.matches[0].replace(runescape, funescape), context ) || [] )[0];
2556
+			if ( !context ) {
2557
+				return results;
2558
+
2559
+			// Precompiled matchers will still verify ancestry, so step up a level
2560
+			} else if ( compiled ) {
2561
+				context = context.parentNode;
2562
+			}
2563
+
2564
+			selector = selector.slice( tokens.shift().value.length );
2565
+		}
2566
+
2567
+		// Fetch a seed set for right-to-left matching
2568
+		i = matchExpr["needsContext"].test( selector ) ? 0 : tokens.length;
2569
+		while ( i-- ) {
2570
+			token = tokens[i];
2571
+
2572
+			// Abort if we hit a combinator
2573
+			if ( Expr.relative[ (type = token.type) ] ) {
2574
+				break;
2575
+			}
2576
+			if ( (find = Expr.find[ type ]) ) {
2577
+				// Search, expanding context for leading sibling combinators
2578
+				if ( (seed = find(
2579
+					token.matches[0].replace( runescape, funescape ),
2580
+					rsibling.test( tokens[0].type ) && testContext( context.parentNode ) || context
2581
+				)) ) {
2582
+
2583
+					// If seed is empty or no tokens remain, we can return early
2584
+					tokens.splice( i, 1 );
2585
+					selector = seed.length && toSelector( tokens );
2586
+					if ( !selector ) {
2587
+						push.apply( results, seed );
2588
+						return results;
2589
+					}
2590
+
2591
+					break;
2592
+				}
2593
+			}
2594
+		}
2595
+	}
2596
+
2597
+	// Compile and execute a filtering function if one is not provided
2598
+	// Provide `match` to avoid retokenization if we modified the selector above
2599
+	( compiled || compile( selector, match ) )(
2600
+		seed,
2601
+		context,
2602
+		!documentIsHTML,
2603
+		results,
2604
+		!context || rsibling.test( selector ) && testContext( context.parentNode ) || context
2605
+	);
2606
+	return results;
2607
+};
2608
+
2609
+// One-time assignments
2610
+
2611
+// Sort stability
2612
+support.sortStable = expando.split("").sort( sortOrder ).join("") === expando;
2613
+
2614
+// Support: Chrome 14-35+
2615
+// Always assume duplicates if they aren't passed to the comparison function
2616
+support.detectDuplicates = !!hasDuplicate;
2617
+
2618
+// Initialize against the default document
2619
+setDocument();
2620
+
2621
+// Support: Webkit<537.32 - Safari 6.0.3/Chrome 25 (fixed in Chrome 27)
2622
+// Detached nodes confoundingly follow *each other*
2623
+support.sortDetached = assert(function( div1 ) {
2624
+	// Should return 1, but returns 4 (following)
2625
+	return div1.compareDocumentPosition( document.createElement("div") ) & 1;
2626
+});
2627
+
2628
+// Support: IE<8
2629
+// Prevent attribute/property "interpolation"
2630
+// http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx
2631
+if ( !assert(function( div ) {
2632
+	div.innerHTML = "<a href='#'></a>";
2633
+	return div.firstChild.getAttribute("href") === "#" ;
2634
+}) ) {
2635
+	addHandle( "type|href|height|width", function( elem, name, isXML ) {
2636
+		if ( !isXML ) {
2637
+			return elem.getAttribute( name, name.toLowerCase() === "type" ? 1 : 2 );
2638
+		}
2639
+	});
2640
+}
2641
+
2642
+// Support: IE<9
2643
+// Use defaultValue in place of getAttribute("value")
2644
+if ( !support.attributes || !assert(function( div ) {
2645
+	div.innerHTML = "<input/>";
2646
+	div.firstChild.setAttribute( "value", "" );
2647
+	return div.firstChild.getAttribute( "value" ) === "";
2648
+}) ) {
2649
+	addHandle( "value", function( elem, name, isXML ) {
2650
+		if ( !isXML && elem.nodeName.toLowerCase() === "input" ) {
2651
+			return elem.defaultValue;
2652
+		}
2653
+	});
2654
+}
2655
+
2656
+// Support: IE<9
2657
+// Use getAttributeNode to fetch booleans when getAttribute lies
2658
+if ( !assert(function( div ) {
2659
+	return div.getAttribute("disabled") == null;
2660
+}) ) {
2661
+	addHandle( booleans, function( elem, name, isXML ) {
2662
+		var val;
2663
+		if ( !isXML ) {
2664
+			return elem[ name ] === true ? name.toLowerCase() :
2665
+					(val = elem.getAttributeNode( name )) && val.specified ?
2666
+					val.value :
2667
+				null;
2668
+		}
2669
+	});
2670
+}
2671
+
2672
+return Sizzle;
2673
+
2674
+})( window );
2675
+
2676
+
2677
+
2678
+jQuery.find = Sizzle;
2679
+jQuery.expr = Sizzle.selectors;
2680
+jQuery.expr[ ":" ] = jQuery.expr.pseudos;
2681
+jQuery.uniqueSort = jQuery.unique = Sizzle.uniqueSort;
2682
+jQuery.text = Sizzle.getText;
2683
+jQuery.isXMLDoc = Sizzle.isXML;
2684
+jQuery.contains = Sizzle.contains;
2685
+
2686
+
2687
+
2688
+var dir = function( elem, dir, until ) {
2689
+	var matched = [],
2690
+		truncate = until !== undefined;
2691
+
2692
+	while ( ( elem = elem[ dir ] ) && elem.nodeType !== 9 ) {
2693
+		if ( elem.nodeType === 1 ) {
2694
+			if ( truncate && jQuery( elem ).is( until ) ) {
2695
+				break;
2696
+			}
2697
+			matched.push( elem );
2698
+		}
2699
+	}
2700
+	return matched;
2701
+};
2702
+
2703
+
2704
+var siblings = function( n, elem ) {
2705
+	var matched = [];
2706
+
2707
+	for ( ; n; n = n.nextSibling ) {
2708
+		if ( n.nodeType === 1 && n !== elem ) {
2709
+			matched.push( n );
2710
+		}
2711
+	}
2712
+
2713
+	return matched;
2714
+};
2715
+
2716
+
2717
+var rneedsContext = jQuery.expr.match.needsContext;
2718
+
2719
+var rsingleTag = ( /^<([\w-]+)\s*\/?>(?:<\/\1>|)$/ );
2720
+
2721
+
2722
+
2723
+var risSimple = /^.[^:#\[\.,]*$/;
2724
+
2725
+// Implement the identical functionality for filter and not
2726
+function winnow( elements, qualifier, not ) {
2727
+	if ( jQuery.isFunction( qualifier ) ) {
2728
+		return jQuery.grep( elements, function( elem, i ) {
2729
+			/* jshint -W018 */
2730
+			return !!qualifier.call( elem, i, elem ) !== not;
2731
+		} );
2732
+
2733
+	}
2734
+
2735
+	if ( qualifier.nodeType ) {
2736
+		return jQuery.grep( elements, function( elem ) {
2737
+			return ( elem === qualifier ) !== not;
2738
+		} );
2739
+
2740
+	}
2741
+
2742
+	if ( typeof qualifier === "string" ) {
2743
+		if ( risSimple.test( qualifier ) ) {
2744
+			return jQuery.filter( qualifier, elements, not );
2745
+		}
2746
+
2747
+		qualifier = jQuery.filter( qualifier, elements );
2748
+	}
2749
+
2750
+	return jQuery.grep( elements, function( elem ) {
2751
+		return ( indexOf.call( qualifier, elem ) > -1 ) !== not;
2752
+	} );
2753
+}
2754
+
2755
+jQuery.filter = function( expr, elems, not ) {
2756
+	var elem = elems[ 0 ];
2757
+
2758
+	if ( not ) {
2759
+		expr = ":not(" + expr + ")";
2760
+	}
2761
+
2762
+	return elems.length === 1 && elem.nodeType === 1 ?
2763
+		jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [] :
2764
+		jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {
2765
+			return elem.nodeType === 1;
2766
+		} ) );
2767
+};
2768
+
2769
+jQuery.fn.extend( {
2770
+	find: function( selector ) {
2771
+		var i,
2772
+			len = this.length,
2773
+			ret = [],
2774
+			self = this;
2775
+
2776
+		if ( typeof selector !== "string" ) {
2777
+			return this.pushStack( jQuery( selector ).filter( function() {
2778
+				for ( i = 0; i < len; i++ ) {
2779
+					if ( jQuery.contains( self[ i ], this ) ) {
2780
+						return true;
2781
+					}
2782
+				}
2783
+			} ) );
2784
+		}
2785
+
2786
+		for ( i = 0; i < len; i++ ) {
2787
+			jQuery.find( selector, self[ i ], ret );
2788
+		}
2789
+
2790
+		// Needed because $( selector, context ) becomes $( context ).find( selector )
2791
+		ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );
2792
+		ret.selector = this.selector ? this.selector + " " + selector : selector;
2793
+		return ret;
2794
+	},
2795
+	filter: function( selector ) {
2796
+		return this.pushStack( winnow( this, selector || [], false ) );
2797
+	},
2798
+	not: function( selector ) {
2799
+		return this.pushStack( winnow( this, selector || [], true ) );
2800
+	},
2801
+	is: function( selector ) {
2802
+		return !!winnow(
2803
+			this,
2804
+
2805
+			// If this is a positional/relative selector, check membership in the returned set
2806
+			// so $("p:first").is("p:last") won't return true for a doc with two "p".
2807
+			typeof selector === "string" && rneedsContext.test( selector ) ?
2808
+				jQuery( selector ) :
2809
+				selector || [],
2810
+			false
2811
+		).length;
2812
+	}
2813
+} );
2814
+
2815
+
2816
+// Initialize a jQuery object
2817
+
2818
+
2819
+// A central reference to the root jQuery(document)
2820
+var rootjQuery,
2821
+
2822
+	// A simple way to check for HTML strings
2823
+	// Prioritize #id over <tag> to avoid XSS via location.hash (#9521)
2824
+	// Strict HTML recognition (#11290: must start with <)
2825
+	rquickExpr = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,
2826
+
2827
+	init = jQuery.fn.init = function( selector, context, root ) {
2828
+		var match, elem;
2829
+
2830
+		// HANDLE: $(""), $(null), $(undefined), $(false)
2831
+		if ( !selector ) {
2832
+			return this;
2833
+		}
2834
+
2835
+		// Method init() accepts an alternate rootjQuery
2836
+		// so migrate can support jQuery.sub (gh-2101)
2837
+		root = root || rootjQuery;
2838
+
2839
+		// Handle HTML strings
2840
+		if ( typeof selector === "string" ) {
2841
+			if ( selector[ 0 ] === "<" &&
2842
+				selector[ selector.length - 1 ] === ">" &&
2843
+				selector.length >= 3 ) {
2844
+
2845
+				// Assume that strings that start and end with <> are HTML and skip the regex check
2846
+				match = [ null, selector, null ];
2847
+
2848
+			} else {
2849
+				match = rquickExpr.exec( selector );
2850
+			}
2851
+
2852
+			// Match html or make sure no context is specified for #id
2853
+			if ( match && ( match[ 1 ] || !context ) ) {
2854
+
2855
+				// HANDLE: $(html) -> $(array)
2856
+				if ( match[ 1 ] ) {
2857
+					context = context instanceof jQuery ? context[ 0 ] : context;
2858
+
2859
+					// Option to run scripts is true for back-compat
2860
+					// Intentionally let the error be thrown if parseHTML is not present
2861
+					jQuery.merge( this, jQuery.parseHTML(
2862
+						match[ 1 ],
2863
+						context && context.nodeType ? context.ownerDocument || context : document,
2864
+						true
2865
+					) );
2866
+
2867
+					// HANDLE: $(html, props)
2868
+					if ( rsingleTag.test( match[ 1 ] ) && jQuery.isPlainObject( context ) ) {
2869
+						for ( match in context ) {
2870
+
2871
+							// Properties of context are called as methods if possible
2872
+							if ( jQuery.isFunction( this[ match ] ) ) {
2873
+								this[ match ]( context[ match ] );
2874
+
2875
+							// ...and otherwise set as attributes
2876
+							} else {
2877
+								this.attr( match, context[ match ] );
2878
+							}
2879
+						}
2880
+					}
2881
+
2882
+					return this;
2883
+
2884
+				// HANDLE: $(#id)
2885
+				} else {
2886
+					elem = document.getElementById( match[ 2 ] );
2887
+
2888
+					// Support: Blackberry 4.6
2889
+					// gEBID returns nodes no longer in the document (#6963)
2890
+					if ( elem && elem.parentNode ) {
2891
+
2892
+						// Inject the element directly into the jQuery object
2893
+						this.length = 1;
2894
+						this[ 0 ] = elem;
2895
+					}
2896
+
2897
+					this.context = document;
2898
+					this.selector = selector;
2899
+					return this;
2900
+				}
2901
+
2902
+			// HANDLE: $(expr, $(...))
2903
+			} else if ( !context || context.jquery ) {
2904
+				return ( context || root ).find( selector );
2905
+
2906
+			// HANDLE: $(expr, context)
2907
+			// (which is just equivalent to: $(context).find(expr)
2908
+			} else {
2909
+				return this.constructor( context ).find( selector );
2910
+			}
2911
+
2912
+		// HANDLE: $(DOMElement)
2913
+		} else if ( selector.nodeType ) {
2914
+			this.context = this[ 0 ] = selector;
2915
+			this.length = 1;
2916
+			return this;
2917
+
2918
+		// HANDLE: $(function)
2919
+		// Shortcut for document ready
2920
+		} else if ( jQuery.isFunction( selector ) ) {
2921
+			return root.ready !== undefined ?
2922
+				root.ready( selector ) :
2923
+
2924
+				// Execute immediately if ready is not present
2925
+				selector( jQuery );
2926
+		}
2927
+
2928
+		if ( selector.selector !== undefined ) {
2929
+			this.selector = selector.selector;
2930
+			this.context = selector.context;
2931
+		}
2932
+
2933
+		return jQuery.makeArray( selector, this );
2934
+	};
2935
+
2936
+// Give the init function the jQuery prototype for later instantiation
2937
+init.prototype = jQuery.fn;
2938
+
2939
+// Initialize central reference
2940
+rootjQuery = jQuery( document );
2941
+
2942
+
2943
+var rparentsprev = /^(?:parents|prev(?:Until|All))/,
2944
+
2945
+	// Methods guaranteed to produce a unique set when starting from a unique set
2946
+	guaranteedUnique = {
2947
+		children: true,
2948
+		contents: true,
2949
+		next: true,
2950
+		prev: true
2951
+	};
2952
+
2953
+jQuery.fn.extend( {
2954
+	has: function( target ) {
2955
+		var targets = jQuery( target, this ),
2956
+			l = targets.length;
2957
+
2958
+		return this.filter( function() {
2959
+			var i = 0;
2960
+			for ( ; i < l; i++ ) {
2961
+				if ( jQuery.contains( this, targets[ i ] ) ) {
2962
+					return true;
2963
+				}
2964
+			}
2965
+		} );
2966
+	},
2967
+
2968
+	closest: function( selectors, context ) {
2969
+		var cur,
2970
+			i = 0,
2971
+			l = this.length,
2972
+			matched = [],
2973
+			pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?
2974
+				jQuery( selectors, context || this.context ) :
2975
+				0;
2976
+
2977
+		for ( ; i < l; i++ ) {
2978
+			for ( cur = this[ i ]; cur && cur !== context; cur = cur.parentNode ) {
2979
+
2980
+				// Always skip document fragments
2981
+				if ( cur.nodeType < 11 && ( pos ?
2982
+					pos.index( cur ) > -1 :
2983
+
2984
+					// Don't pass non-elements to Sizzle
2985
+					cur.nodeType === 1 &&
2986
+						jQuery.find.matchesSelector( cur, selectors ) ) ) {
2987
+
2988
+					matched.push( cur );
2989
+					break;
2990
+				}
2991
+			}
2992
+		}
2993
+
2994
+		return this.pushStack( matched.length > 1 ? jQuery.uniqueSort( matched ) : matched );
2995
+	},
2996
+
2997
+	// Determine the position of an element within the set
2998
+	index: function( elem ) {
2999
+
3000
+		// No argument, return index in parent
3001
+		if ( !elem ) {
3002
+			return ( this[ 0 ] && this[ 0 ].parentNode ) ? this.first().prevAll().length : -1;
3003
+		}
3004
+
3005
+		// Index in selector
3006
+		if ( typeof elem === "string" ) {
3007
+			return indexOf.call( jQuery( elem ), this[ 0 ] );
3008
+		}
3009
+
3010
+		// Locate the position of the desired element
3011
+		return indexOf.call( this,
3012
+
3013
+			// If it receives a jQuery object, the first element is used
3014
+			elem.jquery ? elem[ 0 ] : elem
3015
+		);
3016
+	},
3017
+
3018
+	add: function( selector, context ) {
3019
+		return this.pushStack(
3020
+			jQuery.uniqueSort(
3021
+				jQuery.merge( this.get(), jQuery( selector, context ) )
3022
+			)
3023
+		);
3024
+	},
3025
+
3026
+	addBack: function( selector ) {
3027
+		return this.add( selector == null ?
3028
+			this.prevObject : this.prevObject.filter( selector )
3029
+		);
3030
+	}
3031
+} );
3032
+
3033
+function sibling( cur, dir ) {
3034
+	while ( ( cur = cur[ dir ] ) && cur.nodeType !== 1 ) {}
3035
+	return cur;
3036
+}
3037
+
3038
+jQuery.each( {
3039
+	parent: function( elem ) {
3040
+		var parent = elem.parentNode;
3041
+		return parent && parent.nodeType !== 11 ? parent : null;
3042
+	},
3043
+	parents: function( elem ) {
3044
+		return dir( elem, "parentNode" );
3045
+	},
3046
+	parentsUntil: function( elem, i, until ) {
3047
+		return dir( elem, "parentNode", until );
3048
+	},
3049
+	next: function( elem ) {
3050
+		return sibling( elem, "nextSibling" );
3051
+	},
3052
+	prev: function( elem ) {
3053
+		return sibling( elem, "previousSibling" );
3054
+	},
3055
+	nextAll: function( elem ) {
3056
+		return dir( elem, "nextSibling" );
3057
+	},
3058
+	prevAll: function( elem ) {
3059
+		return dir( elem, "previousSibling" );
3060
+	},
3061
+	nextUntil: function( elem, i, until ) {
3062
+		return dir( elem, "nextSibling", until );
3063
+	},
3064
+	prevUntil: function( elem, i, until ) {
3065
+		return dir( elem, "previousSibling", until );
3066
+	},
3067
+	siblings: function( elem ) {
3068
+		return siblings( ( elem.parentNode || {} ).firstChild, elem );
3069
+	},
3070
+	children: function( elem ) {
3071
+		return siblings( elem.firstChild );
3072
+	},
3073
+	contents: function( elem ) {
3074
+		return elem.contentDocument || jQuery.merge( [], elem.childNodes );
3075
+	}
3076
+}, function( name, fn ) {
3077
+	jQuery.fn[ name ] = function( until, selector ) {
3078
+		var matched = jQuery.map( this, fn, until );
3079
+
3080
+		if ( name.slice( -5 ) !== "Until" ) {
3081
+			selector = until;
3082
+		}
3083
+
3084
+		if ( selector && typeof selector === "string" ) {
3085
+			matched = jQuery.filter( selector, matched );
3086
+		}
3087
+
3088
+		if ( this.length > 1 ) {
3089
+
3090
+			// Remove duplicates
3091
+			if ( !guaranteedUnique[ name ] ) {
3092
+				jQuery.uniqueSort( matched );
3093
+			}
3094
+
3095
+			// Reverse order for parents* and prev-derivatives
3096
+			if ( rparentsprev.test( name ) ) {
3097
+				matched.reverse();
3098
+			}
3099
+		}
3100
+
3101
+		return this.pushStack( matched );
3102
+	};
3103
+} );
3104
+var rnotwhite = ( /\S+/g );
3105
+
3106
+
3107
+
3108
+// Convert String-formatted options into Object-formatted ones
3109
+function createOptions( options ) {
3110
+	var object = {};
3111
+	jQuery.each( options.match( rnotwhite ) || [], function( _, flag ) {
3112
+		object[ flag ] = true;
3113
+	} );
3114
+	return object;
3115
+}
3116
+
3117
+/*
3118
+ * Create a callback list using the following parameters:
3119
+ *
3120
+ *	options: an optional list of space-separated options that will change how
3121
+ *			the callback list behaves or a more traditional option object
3122
+ *
3123
+ * By default a callback list will act like an event callback list and can be
3124
+ * "fired" multiple times.
3125
+ *
3126
+ * Possible options:
3127
+ *
3128
+ *	once:			will ensure the callback list can only be fired once (like a Deferred)
3129
+ *
3130
+ *	memory:			will keep track of previous values and will call any callback added
3131
+ *					after the list has been fired right away with the latest "memorized"
3132
+ *					values (like a Deferred)
3133
+ *
3134
+ *	unique:			will ensure a callback can only be added once (no duplicate in the list)
3135
+ *
3136
+ *	stopOnFalse:	interrupt callings when a callback returns false
3137
+ *
3138
+ */
3139
+jQuery.Callbacks = function( options ) {
3140
+
3141
+	// Convert options from String-formatted to Object-formatted if needed
3142
+	// (we check in cache first)
3143
+	options = typeof options === "string" ?
3144
+		createOptions( options ) :
3145
+		jQuery.extend( {}, options );
3146
+
3147
+	var // Flag to know if list is currently firing
3148
+		firing,
3149
+
3150
+		// Last fire value for non-forgettable lists
3151
+		memory,
3152
+
3153
+		// Flag to know if list was already fired
3154
+		fired,
3155
+
3156
+		// Flag to prevent firing
3157
+		locked,
3158
+
3159
+		// Actual callback list
3160
+		list = [],
3161
+
3162
+		// Queue of execution data for repeatable lists
3163
+		queue = [],
3164
+
3165
+		// Index of currently firing callback (modified by add/remove as needed)
3166
+		firingIndex = -1,
3167
+
3168
+		// Fire callbacks
3169
+		fire = function() {
3170
+
3171
+			// Enforce single-firing
3172
+			locked = options.once;
3173
+
3174
+			// Execute callbacks for all pending executions,
3175
+			// respecting firingIndex overrides and runtime changes
3176
+			fired = firing = true;
3177
+			for ( ; queue.length; firingIndex = -1 ) {
3178
+				memory = queue.shift();
3179
+				while ( ++firingIndex < list.length ) {
3180
+
3181
+					// Run callback and check for early termination
3182
+					if ( list[ firingIndex ].apply( memory[ 0 ], memory[ 1 ] ) === false &&
3183
+						options.stopOnFalse ) {
3184
+
3185
+						// Jump to end and forget the data so .add doesn't re-fire
3186
+						firingIndex = list.length;
3187
+						memory = false;
3188
+					}
3189
+				}
3190
+			}
3191
+
3192
+			// Forget the data if we're done with it
3193
+			if ( !options.memory ) {
3194
+				memory = false;
3195
+			}
3196
+
3197
+			firing = false;
3198
+
3199
+			// Clean up if we're done firing for good
3200
+			if ( locked ) {
3201
+
3202
+				// Keep an empty list if we have data for future add calls
3203
+				if ( memory ) {
3204
+					list = [];
3205
+
3206
+				// Otherwise, this object is spent
3207
+				} else {
3208
+					list = "";
3209
+				}
3210
+			}
3211
+		},
3212
+
3213
+		// Actual Callbacks object
3214
+		self = {
3215
+
3216
+			// Add a callback or a collection of callbacks to the list
3217
+			add: function() {
3218
+				if ( list ) {
3219
+
3220
+					// If we have memory from a past run, we should fire after adding
3221
+					if ( memory && !firing ) {
3222
+						firingIndex = list.length - 1;
3223
+						queue.push( memory );
3224
+					}
3225
+
3226
+					( function add( args ) {
3227
+						jQuery.each( args, function( _, arg ) {
3228
+							if ( jQuery.isFunction( arg ) ) {
3229
+								if ( !options.unique || !self.has( arg ) ) {
3230
+									list.push( arg );
3231
+								}
3232
+							} else if ( arg && arg.length && jQuery.type( arg ) !== "string" ) {
3233
+
3234
+								// Inspect recursively
3235
+								add( arg );
3236
+							}
3237
+						} );
3238
+					} )( arguments );
3239
+
3240
+					if ( memory && !firing ) {
3241
+						fire();
3242
+					}
3243
+				}
3244
+				return this;
3245
+			},
3246
+
3247
+			// Remove a callback from the list
3248
+			remove: function() {
3249
+				jQuery.each( arguments, function( _, arg ) {
3250
+					var index;
3251
+					while ( ( index = jQuery.inArray( arg, list, index ) ) > -1 ) {
3252
+						list.splice( index, 1 );
3253
+
3254
+						// Handle firing indexes
3255
+						if ( index <= firingIndex ) {
3256
+							firingIndex--;
3257
+						}
3258
+					}
3259
+				} );
3260
+				return this;
3261
+			},
3262
+
3263
+			// Check if a given callback is in the list.
3264
+			// If no argument is given, return whether or not list has callbacks attached.
3265
+			has: function( fn ) {
3266
+				return fn ?
3267
+					jQuery.inArray( fn, list ) > -1 :
3268
+					list.length > 0;
3269
+			},
3270
+
3271
+			// Remove all callbacks from the list
3272
+			empty: function() {
3273
+				if ( list ) {
3274
+					list = [];
3275
+				}
3276
+				return this;
3277
+			},
3278
+
3279
+			// Disable .fire and .add
3280
+			// Abort any current/pending executions
3281
+			// Clear all callbacks and values
3282
+			disable: function() {
3283
+				locked = queue = [];
3284
+				list = memory = "";
3285
+				return this;
3286
+			},
3287
+			disabled: function() {
3288
+				return !list;
3289
+			},
3290
+
3291
+			// Disable .fire
3292
+			// Also disable .add unless we have memory (since it would have no effect)
3293
+			// Abort any pending executions
3294
+			lock: function() {
3295
+				locked = queue = [];
3296
+				if ( !memory ) {
3297
+					list = memory = "";
3298
+				}
3299
+				return this;
3300
+			},
3301
+			locked: function() {
3302
+				return !!locked;
3303
+			},
3304
+
3305
+			// Call all callbacks with the given context and arguments
3306
+			fireWith: function( context, args ) {
3307
+				if ( !locked ) {
3308
+					args = args || [];
3309
+					args = [ context, args.slice ? args.slice() : args ];
3310
+					queue.push( args );
3311
+					if ( !firing ) {
3312
+						fire();
3313
+					}
3314
+				}
3315
+				return this;
3316
+			},
3317
+
3318
+			// Call all the callbacks with the given arguments
3319
+			fire: function() {
3320
+				self.fireWith( this, arguments );
3321
+				return this;
3322
+			},
3323
+
3324
+			// To know if the callbacks have already been called at least once
3325
+			fired: function() {
3326
+				return !!fired;
3327
+			}
3328
+		};
3329
+
3330
+	return self;
3331
+};
3332
+
3333
+
3334
+jQuery.extend( {
3335
+
3336
+	Deferred: function( func ) {
3337
+		var tuples = [
3338
+
3339
+				// action, add listener, listener list, final state
3340
+				[ "resolve", "done", jQuery.Callbacks( "once memory" ), "resolved" ],
3341
+				[ "reject", "fail", jQuery.Callbacks( "once memory" ), "rejected" ],
3342
+				[ "notify", "progress", jQuery.Callbacks( "memory" ) ]
3343
+			],
3344
+			state = "pending",
3345
+			promise = {
3346
+				state: function() {
3347
+					return state;
3348
+				},
3349
+				always: function() {
3350
+					deferred.done( arguments ).fail( arguments );
3351
+					return this;
3352
+				},
3353
+				then: function( /* fnDone, fnFail, fnProgress */ ) {
3354
+					var fns = arguments;
3355
+					return jQuery.Deferred( function( newDefer ) {
3356
+						jQuery.each( tuples, function( i, tuple ) {
3357
+							var fn = jQuery.isFunction( fns[ i ] ) && fns[ i ];
3358
+
3359
+							// deferred[ done | fail | progress ] for forwarding actions to newDefer
3360
+							deferred[ tuple[ 1 ] ]( function() {
3361
+								var returned = fn && fn.apply( this, arguments );
3362
+								if ( returned && jQuery.isFunction( returned.promise ) ) {
3363
+									returned.promise()
3364
+										.progress( newDefer.notify )
3365
+										.done( newDefer.resolve )
3366
+										.fail( newDefer.reject );
3367
+								} else {
3368
+									newDefer[ tuple[ 0 ] + "With" ](
3369
+										this === promise ? newDefer.promise() : this,
3370
+										fn ? [ returned ] : arguments
3371
+									);
3372
+								}
3373
+							} );
3374
+						} );
3375
+						fns = null;
3376
+					} ).promise();
3377
+				},
3378
+
3379
+				// Get a promise for this deferred
3380
+				// If obj is provided, the promise aspect is added to the object
3381
+				promise: function( obj ) {
3382
+					return obj != null ? jQuery.extend( obj, promise ) : promise;
3383
+				}
3384
+			},
3385
+			deferred = {};
3386
+
3387
+		// Keep pipe for back-compat
3388
+		promise.pipe = promise.then;
3389
+
3390
+		// Add list-specific methods
3391
+		jQuery.each( tuples, function( i, tuple ) {
3392
+			var list = tuple[ 2 ],
3393
+				stateString = tuple[ 3 ];
3394
+
3395
+			// promise[ done | fail | progress ] = list.add
3396
+			promise[ tuple[ 1 ] ] = list.add;
3397
+
3398
+			// Handle state
3399
+			if ( stateString ) {
3400
+				list.add( function() {
3401
+
3402
+					// state = [ resolved | rejected ]
3403
+					state = stateString;
3404
+
3405
+				// [ reject_list | resolve_list ].disable; progress_list.lock
3406
+				}, tuples[ i ^ 1 ][ 2 ].disable, tuples[ 2 ][ 2 ].lock );
3407
+			}
3408
+
3409
+			// deferred[ resolve | reject | notify ]
3410
+			deferred[ tuple[ 0 ] ] = function() {
3411
+				deferred[ tuple[ 0 ] + "With" ]( this === deferred ? promise : this, arguments );
3412
+				return this;
3413
+			};
3414
+			deferred[ tuple[ 0 ] + "With" ] = list.fireWith;
3415
+		} );
3416
+
3417
+		// Make the deferred a promise
3418
+		promise.promise( deferred );
3419
+
3420
+		// Call given func if any
3421
+		if ( func ) {
3422
+			func.call( deferred, deferred );
3423
+		}
3424
+
3425
+		// All done!
3426
+		return deferred;
3427
+	},
3428
+
3429
+	// Deferred helper
3430
+	when: function( subordinate /* , ..., subordinateN */ ) {
3431
+		var i = 0,
3432
+			resolveValues = slice.call( arguments ),
3433
+			length = resolveValues.length,
3434
+
3435
+			// the count of uncompleted subordinates
3436
+			remaining = length !== 1 ||
3437
+				( subordinate && jQuery.isFunction( subordinate.promise ) ) ? length : 0,
3438
+
3439
+			// the master Deferred.
3440
+			// If resolveValues consist of only a single Deferred, just use that.
3441
+			deferred = remaining === 1 ? subordinate : jQuery.Deferred(),
3442
+
3443
+			// Update function for both resolve and progress values
3444
+			updateFunc = function( i, contexts, values ) {
3445
+				return function( value ) {
3446
+					contexts[ i ] = this;
3447
+					values[ i ] = arguments.length > 1 ? slice.call( arguments ) : value;
3448
+					if ( values === progressValues ) {
3449
+						deferred.notifyWith( contexts, values );
3450
+					} else if ( !( --remaining ) ) {
3451
+						deferred.resolveWith( contexts, values );
3452
+					}
3453
+				};
3454
+			},
3455
+
3456
+			progressValues, progressContexts, resolveContexts;
3457
+
3458
+		// Add listeners to Deferred subordinates; treat others as resolved
3459
+		if ( length > 1 ) {
3460
+			progressValues = new Array( length );
3461
+			progressContexts = new Array( length );
3462
+			resolveContexts = new Array( length );
3463
+			for ( ; i < length; i++ ) {
3464
+				if ( resolveValues[ i ] && jQuery.isFunction( resolveValues[ i ].promise ) ) {
3465
+					resolveValues[ i ].promise()
3466
+						.progress( updateFunc( i, progressContexts, progressValues ) )
3467
+						.done( updateFunc( i, resolveContexts, resolveValues ) )
3468
+						.fail( deferred.reject );
3469
+				} else {
3470
+					--remaining;
3471
+				}
3472
+			}
3473
+		}
3474
+
3475
+		// If we're not waiting on anything, resolve the master
3476
+		if ( !remaining ) {
3477
+			deferred.resolveWith( resolveContexts, resolveValues );
3478
+		}
3479
+
3480
+		return deferred.promise();
3481
+	}
3482
+} );
3483
+
3484
+
3485
+// The deferred used on DOM ready
3486
+var readyList;
3487
+
3488
+jQuery.fn.ready = function( fn ) {
3489
+
3490
+	// Add the callback
3491
+	jQuery.ready.promise().done( fn );
3492
+
3493
+	return this;
3494
+};
3495
+
3496
+jQuery.extend( {
3497
+
3498
+	// Is the DOM ready to be used? Set to true once it occurs.
3499
+	isReady: false,
3500
+
3501
+	// A counter to track how many items to wait for before
3502
+	// the ready event fires. See #6781
3503
+	readyWait: 1,
3504
+
3505
+	// Hold (or release) the ready event
3506
+	holdReady: function( hold ) {
3507
+		if ( hold ) {
3508
+			jQuery.readyWait++;
3509
+		} else {
3510
+			jQuery.ready( true );
3511
+		}
3512
+	},
3513
+
3514
+	// Handle when the DOM is ready
3515
+	ready: function( wait ) {
3516
+
3517
+		// Abort if there are pending holds or we're already ready
3518
+		if ( wait === true ? --jQuery.readyWait : jQuery.isReady ) {
3519
+			return;
3520
+		}
3521
+
3522
+		// Remember that the DOM is ready
3523
+		jQuery.isReady = true;
3524
+
3525
+		// If a normal DOM Ready event fired, decrement, and wait if need be
3526
+		if ( wait !== true && --jQuery.readyWait > 0 ) {
3527
+			return;
3528
+		}
3529
+
3530
+		// If there are functions bound, to execute
3531
+		readyList.resolveWith( document, [ jQuery ] );
3532
+
3533
+		// Trigger any bound ready events
3534
+		if ( jQuery.fn.triggerHandler ) {
3535
+			jQuery( document ).triggerHandler( "ready" );
3536
+			jQuery( document ).off( "ready" );
3537
+		}
3538
+	}
3539
+} );
3540
+
3541
+/**
3542
+ * The ready event handler and self cleanup method
3543
+ */
3544
+function completed() {
3545
+	document.removeEventListener( "DOMContentLoaded", completed );
3546
+	window.removeEventListener( "load", completed );
3547
+	jQuery.ready();
3548
+}
3549
+
3550
+jQuery.ready.promise = function( obj ) {
3551
+	if ( !readyList ) {
3552
+
3553
+		readyList = jQuery.Deferred();
3554
+
3555
+		// Catch cases where $(document).ready() is called
3556
+		// after the browser event has already occurred.
3557
+		// Support: IE9-10 only
3558
+		// Older IE sometimes signals "interactive" too soon
3559
+		if ( document.readyState === "complete" ||
3560
+			( document.readyState !== "loading" && !document.documentElement.doScroll ) ) {
3561
+
3562
+			// Handle it asynchronously to allow scripts the opportunity to delay ready
3563
+			window.setTimeout( jQuery.ready );
3564
+
3565
+		} else {
3566
+
3567
+			// Use the handy event callback
3568
+			document.addEventListener( "DOMContentLoaded", completed );
3569
+
3570
+			// A fallback to window.onload, that will always work
3571
+			window.addEventListener( "load", completed );
3572
+		}
3573
+	}
3574
+	return readyList.promise( obj );
3575
+};
3576
+
3577
+// Kick off the DOM ready check even if the user does not
3578
+jQuery.ready.promise();
3579
+
3580
+
3581
+
3582
+
3583
+// Multifunctional method to get and set values of a collection
3584
+// The value/s can optionally be executed if it's a function
3585
+var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
3586
+	var i = 0,
3587
+		len = elems.length,
3588
+		bulk = key == null;
3589
+
3590
+	// Sets many values
3591
+	if ( jQuery.type( key ) === "object" ) {
3592
+		chainable = true;
3593
+		for ( i in key ) {
3594
+			access( elems, fn, i, key[ i ], true, emptyGet, raw );
3595
+		}
3596
+
3597
+	// Sets one value
3598
+	} else if ( value !== undefined ) {
3599
+		chainable = true;
3600
+
3601
+		if ( !jQuery.isFunction( value ) ) {
3602
+			raw = true;
3603
+		}
3604
+
3605
+		if ( bulk ) {
3606
+
3607
+			// Bulk operations run against the entire set
3608
+			if ( raw ) {
3609
+				fn.call( elems, value );
3610
+				fn = null;
3611
+
3612
+			// ...except when executing function values
3613
+			} else {
3614
+				bulk = fn;
3615
+				fn = function( elem, key, value ) {
3616
+					return bulk.call( jQuery( elem ), value );
3617
+				};
3618
+			}
3619
+		}
3620
+
3621
+		if ( fn ) {
3622
+			for ( ; i < len; i++ ) {
3623
+				fn(
3624
+					elems[ i ], key, raw ?
3625
+					value :
3626
+					value.call( elems[ i ], i, fn( elems[ i ], key ) )
3627
+				);
3628
+			}
3629
+		}
3630
+	}
3631
+
3632
+	return chainable ?
3633
+		elems :
3634
+
3635
+		// Gets
3636
+		bulk ?
3637
+			fn.call( elems ) :
3638
+			len ? fn( elems[ 0 ], key ) : emptyGet;
3639
+};
3640
+var acceptData = function( owner ) {
3641
+
3642
+	// Accepts only:
3643
+	//  - Node
3644
+	//    - Node.ELEMENT_NODE
3645
+	//    - Node.DOCUMENT_NODE
3646
+	//  - Object
3647
+	//    - Any
3648
+	/* jshint -W018 */
3649
+	return owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType );
3650
+};
3651
+
3652
+
3653
+
3654
+
3655
+function Data() {
3656
+	this.expando = jQuery.expando + Data.uid++;
3657
+}
3658
+
3659
+Data.uid = 1;
3660
+
3661
+Data.prototype = {
3662
+
3663
+	register: function( owner, initial ) {
3664
+		var value = initial || {};
3665
+
3666
+		// If it is a node unlikely to be stringify-ed or looped over
3667
+		// use plain assignment
3668
+		if ( owner.nodeType ) {
3669
+			owner[ this.expando ] = value;
3670
+
3671
+		// Otherwise secure it in a non-enumerable, non-writable property
3672
+		// configurability must be true to allow the property to be
3673
+		// deleted with the delete operator
3674
+		} else {
3675
+			Object.defineProperty( owner, this.expando, {
3676
+				value: value,
3677
+				writable: true,
3678
+				configurable: true
3679
+			} );
3680
+		}
3681
+		return owner[ this.expando ];
3682
+	},
3683
+	cache: function( owner ) {
3684
+
3685
+		// We can accept data for non-element nodes in modern browsers,
3686
+		// but we should not, see #8335.
3687
+		// Always return an empty object.
3688
+		if ( !acceptData( owner ) ) {
3689
+			return {};
3690
+		}
3691
+
3692
+		// Check if the owner object already has a cache
3693
+		var value = owner[ this.expando ];
3694
+
3695
+		// If not, create one
3696
+		if ( !value ) {
3697
+			value = {};
3698
+
3699
+			// We can accept data for non-element nodes in modern browsers,
3700
+			// but we should not, see #8335.
3701
+			// Always return an empty object.
3702
+			if ( acceptData( owner ) ) {
3703
+
3704
+				// If it is a node unlikely to be stringify-ed or looped over
3705
+				// use plain assignment
3706
+				if ( owner.nodeType ) {
3707
+					owner[ this.expando ] = value;
3708
+
3709
+				// Otherwise secure it in a non-enumerable property
3710
+				// configurable must be true to allow the property to be
3711
+				// deleted when data is removed
3712
+				} else {
3713
+					Object.defineProperty( owner, this.expando, {
3714
+						value: value,
3715
+						configurable: true
3716
+					} );
3717
+				}
3718
+			}
3719
+		}
3720
+
3721
+		return value;
3722
+	},
3723
+	set: function( owner, data, value ) {
3724
+		var prop,
3725
+			cache = this.cache( owner );
3726
+
3727
+		// Handle: [ owner, key, value ] args
3728
+		if ( typeof data === "string" ) {
3729
+			cache[ data ] = value;
3730
+
3731
+		// Handle: [ owner, { properties } ] args
3732
+		} else {
3733
+
3734
+			// Copy the properties one-by-one to the cache object
3735
+			for ( prop in data ) {
3736
+				cache[ prop ] = data[ prop ];
3737
+			}
3738
+		}
3739
+		return cache;
3740
+	},
3741
+	get: function( owner, key ) {
3742
+		return key === undefined ?
3743
+			this.cache( owner ) :
3744
+			owner[ this.expando ] && owner[ this.expando ][ key ];
3745
+	},
3746
+	access: function( owner, key, value ) {
3747
+		var stored;
3748
+
3749
+		// In cases where either:
3750
+		//
3751
+		//   1. No key was specified
3752
+		//   2. A string key was specified, but no value provided
3753
+		//
3754
+		// Take the "read" path and allow the get method to determine
3755
+		// which value to return, respectively either:
3756
+		//
3757
+		//   1. The entire cache object
3758
+		//   2. The data stored at the key
3759
+		//
3760
+		if ( key === undefined ||
3761
+				( ( key && typeof key === "string" ) && value === undefined ) ) {
3762
+
3763
+			stored = this.get( owner, key );
3764
+
3765
+			return stored !== undefined ?
3766
+				stored : this.get( owner, jQuery.camelCase( key ) );
3767
+		}
3768
+
3769
+		// When the key is not a string, or both a key and value
3770
+		// are specified, set or extend (existing objects) with either:
3771
+		//
3772
+		//   1. An object of properties
3773
+		//   2. A key and value
3774
+		//
3775
+		this.set( owner, key, value );
3776
+
3777
+		// Since the "set" path can have two possible entry points
3778
+		// return the expected data based on which path was taken[*]
3779
+		return value !== undefined ? value : key;
3780
+	},
3781
+	remove: function( owner, key ) {
3782
+		var i, name, camel,
3783
+			cache = owner[ this.expando ];
3784
+
3785
+		if ( cache === undefined ) {
3786
+			return;
3787
+		}
3788
+
3789
+		if ( key === undefined ) {
3790
+			this.register( owner );
3791
+
3792
+		} else {
3793
+
3794
+			// Support array or space separated string of keys
3795
+			if ( jQuery.isArray( key ) ) {
3796
+
3797
+				// If "name" is an array of keys...
3798
+				// When data is initially created, via ("key", "val") signature,
3799
+				// keys will be converted to camelCase.
3800
+				// Since there is no way to tell _how_ a key was added, remove
3801
+				// both plain key and camelCase key. #12786
3802
+				// This will only penalize the array argument path.
3803
+				name = key.concat( key.map( jQuery.camelCase ) );
3804
+			} else {
3805
+				camel = jQuery.camelCase( key );
3806
+
3807
+				// Try the string as a key before any manipulation
3808
+				if ( key in cache ) {
3809
+					name = [ key, camel ];
3810
+				} else {
3811
+
3812
+					// If a key with the spaces exists, use it.
3813
+					// Otherwise, create an array by matching non-whitespace
3814
+					name = camel;
3815
+					name = name in cache ?
3816
+						[ name ] : ( name.match( rnotwhite ) || [] );
3817
+				}
3818
+			}
3819
+
3820
+			i = name.length;
3821
+
3822
+			while ( i-- ) {
3823
+				delete cache[ name[ i ] ];
3824
+			}
3825
+		}
3826
+
3827
+		// Remove the expando if there's no more data
3828
+		if ( key === undefined || jQuery.isEmptyObject( cache ) ) {
3829
+
3830
+			// Support: Chrome <= 35-45+
3831
+			// Webkit & Blink performance suffers when deleting properties
3832
+			// from DOM nodes, so set to undefined instead
3833
+			// https://code.google.com/p/chromium/issues/detail?id=378607
3834
+			if ( owner.nodeType ) {
3835
+				owner[ this.expando ] = undefined;
3836
+			} else {
3837
+				delete owner[ this.expando ];
3838
+			}
3839
+		}
3840
+	},
3841
+	hasData: function( owner ) {
3842
+		var cache = owner[ this.expando ];
3843
+		return cache !== undefined && !jQuery.isEmptyObject( cache );
3844
+	}
3845
+};
3846
+var dataPriv = new Data();
3847
+
3848
+var dataUser = new Data();
3849
+
3850
+
3851
+
3852
+//	Implementation Summary
3853
+//
3854
+//	1. Enforce API surface and semantic compatibility with 1.9.x branch
3855
+//	2. Improve the module's maintainability by reducing the storage
3856
+//		paths to a single mechanism.
3857
+//	3. Use the same single mechanism to support "private" and "user" data.
3858
+//	4. _Never_ expose "private" data to user code (TODO: Drop _data, _removeData)
3859
+//	5. Avoid exposing implementation details on user objects (eg. expando properties)
3860
+//	6. Provide a clear path for implementation upgrade to WeakMap in 2014
3861
+
3862
+var rbrace = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,
3863
+	rmultiDash = /[A-Z]/g;
3864
+
3865
+function dataAttr( elem, key, data ) {
3866
+	var name;
3867
+
3868
+	// If nothing was found internally, try to fetch any
3869
+	// data from the HTML5 data-* attribute
3870
+	if ( data === undefined && elem.nodeType === 1 ) {
3871
+		name = "data-" + key.replace( rmultiDash, "-$&" ).toLowerCase();
3872
+		data = elem.getAttribute( name );
3873
+
3874
+		if ( typeof data === "string" ) {
3875
+			try {
3876
+				data = data === "true" ? true :
3877
+					data === "false" ? false :
3878
+					data === "null" ? null :
3879
+
3880
+					// Only convert to a number if it doesn't change the string
3881
+					+data + "" === data ? +data :
3882
+					rbrace.test( data ) ? jQuery.parseJSON( data ) :
3883
+					data;
3884
+			} catch ( e ) {}
3885
+
3886
+			// Make sure we set the data so it isn't changed later
3887
+			dataUser.set( elem, key, data );
3888
+		} else {
3889
+			data = undefined;
3890
+		}
3891
+	}
3892
+	return data;
3893
+}
3894
+
3895
+jQuery.extend( {
3896
+	hasData: function( elem ) {
3897
+		return dataUser.hasData( elem ) || dataPriv.hasData( elem );
3898
+	},
3899
+
3900
+	data: function( elem, name, data ) {
3901
+		return dataUser.access( elem, name, data );
3902
+	},
3903
+
3904
+	removeData: function( elem, name ) {
3905
+		dataUser.remove( elem, name );
3906
+	},
3907
+
3908
+	// TODO: Now that all calls to _data and _removeData have been replaced
3909
+	// with direct calls to dataPriv methods, these can be deprecated.
3910
+	_data: function( elem, name, data ) {
3911
+		return dataPriv.access( elem, name, data );
3912
+	},
3913
+
3914
+	_removeData: function( elem, name ) {
3915
+		dataPriv.remove( elem, name );
3916
+	}
3917
+} );
3918
+
3919
+jQuery.fn.extend( {
3920
+	data: function( key, value ) {
3921
+		var i, name, data,
3922
+			elem = this[ 0 ],
3923
+			attrs = elem && elem.attributes;
3924
+
3925
+		// Gets all values
3926
+		if ( key === undefined ) {
3927
+			if ( this.length ) {
3928
+				data = dataUser.get( elem );
3929
+
3930
+				if ( elem.nodeType === 1 && !dataPriv.get( elem, "hasDataAttrs" ) ) {
3931
+					i = attrs.length;
3932
+					while ( i-- ) {
3933
+
3934
+						// Support: IE11+
3935
+						// The attrs elements can be null (#14894)
3936
+						if ( attrs[ i ] ) {
3937
+							name = attrs[ i ].name;
3938
+							if ( name.indexOf( "data-" ) === 0 ) {
3939
+								name = jQuery.camelCase( name.slice( 5 ) );
3940
+								dataAttr( elem, name, data[ name ] );
3941
+							}
3942
+						}
3943
+					}
3944
+					dataPriv.set( elem, "hasDataAttrs", true );
3945
+				}
3946
+			}
3947
+
3948
+			return data;
3949
+		}
3950
+
3951
+		// Sets multiple values
3952
+		if ( typeof key === "object" ) {
3953
+			return this.each( function() {
3954
+				dataUser.set( this, key );
3955
+			} );
3956
+		}
3957
+
3958
+		return access( this, function( value ) {
3959
+			var data, camelKey;
3960
+
3961
+			// The calling jQuery object (element matches) is not empty
3962
+			// (and therefore has an element appears at this[ 0 ]) and the
3963
+			// `value` parameter was not undefined. An empty jQuery object
3964
+			// will result in `undefined` for elem = this[ 0 ] which will
3965
+			// throw an exception if an attempt to read a data cache is made.
3966
+			if ( elem && value === undefined ) {
3967
+
3968
+				// Attempt to get data from the cache
3969
+				// with the key as-is
3970
+				data = dataUser.get( elem, key ) ||
3971
+
3972
+					// Try to find dashed key if it exists (gh-2779)
3973
+					// This is for 2.2.x only
3974
+					dataUser.get( elem, key.replace( rmultiDash, "-$&" ).toLowerCase() );
3975
+
3976
+				if ( data !== undefined ) {
3977
+					return data;
3978
+				}
3979
+
3980
+				camelKey = jQuery.camelCase( key );
3981
+
3982
+				// Attempt to get data from the cache
3983
+				// with the key camelized
3984
+				data = dataUser.get( elem, camelKey );
3985
+				if ( data !== undefined ) {
3986
+					return data;
3987
+				}
3988
+
3989
+				// Attempt to "discover" the data in
3990
+				// HTML5 custom data-* attrs
3991
+				data = dataAttr( elem, camelKey, undefined );
3992
+				if ( data !== undefined ) {
3993
+					return data;
3994
+				}
3995
+
3996
+				// We tried really hard, but the data doesn't exist.
3997
+				return;
3998
+			}
3999
+
4000
+			// Set the data...
4001
+			camelKey = jQuery.camelCase( key );
4002
+			this.each( function() {
4003
+
4004
+				// First, attempt to store a copy or reference of any
4005
+				// data that might've been store with a camelCased key.
4006
+				var data = dataUser.get( this, camelKey );
4007
+
4008
+				// For HTML5 data-* attribute interop, we have to
4009
+				// store property names with dashes in a camelCase form.
4010
+				// This might not apply to all properties...*
4011
+				dataUser.set( this, camelKey, value );
4012
+
4013
+				// *... In the case of properties that might _actually_
4014
+				// have dashes, we need to also store a copy of that
4015
+				// unchanged property.
4016
+				if ( key.indexOf( "-" ) > -1 && data !== undefined ) {
4017
+					dataUser.set( this, key, value );
4018
+				}
4019
+			} );
4020
+		}, null, value, arguments.length > 1, null, true );
4021
+	},
4022
+
4023
+	removeData: function( key ) {
4024
+		return this.each( function() {
4025
+			dataUser.remove( this, key );
4026
+		} );
4027
+	}
4028
+} );
4029
+
4030
+
4031
+jQuery.extend( {
4032
+	queue: function( elem, type, data ) {
4033
+		var queue;
4034
+
4035
+		if ( elem ) {
4036
+			type = ( type || "fx" ) + "queue";
4037
+			queue = dataPriv.get( elem, type );
4038
+
4039
+			// Speed up dequeue by getting out quickly if this is just a lookup
4040
+			if ( data ) {
4041
+				if ( !queue || jQuery.isArray( data ) ) {
4042
+					queue = dataPriv.access( elem, type, jQuery.makeArray( data ) );
4043
+				} else {
4044
+					queue.push( data );
4045
+				}
4046
+			}
4047
+			return queue || [];
4048
+		}
4049
+	},
4050
+
4051
+	dequeue: function( elem, type ) {
4052
+		type = type || "fx";
4053
+
4054
+		var queue = jQuery.queue( elem, type ),
4055
+			startLength = queue.length,
4056
+			fn = queue.shift(),
4057
+			hooks = jQuery._queueHooks( elem, type ),
4058
+			next = function() {
4059
+				jQuery.dequeue( elem, type );
4060
+			};
4061
+
4062
+		// If the fx queue is dequeued, always remove the progress sentinel
4063
+		if ( fn === "inprogress" ) {
4064
+			fn = queue.shift();
4065
+			startLength--;
4066
+		}
4067
+
4068
+		if ( fn ) {
4069
+
4070
+			// Add a progress sentinel to prevent the fx queue from being
4071
+			// automatically dequeued
4072
+			if ( type === "fx" ) {
4073
+				queue.unshift( "inprogress" );
4074
+			}
4075
+
4076
+			// Clear up the last queue stop function
4077
+			delete hooks.stop;
4078
+			fn.call( elem, next, hooks );
4079
+		}
4080
+
4081
+		if ( !startLength && hooks ) {
4082
+			hooks.empty.fire();
4083
+		}
4084
+	},
4085
+
4086
+	// Not public - generate a queueHooks object, or return the current one
4087
+	_queueHooks: function( elem, type ) {
4088
+		var key = type + "queueHooks";
4089
+		return dataPriv.get( elem, key ) || dataPriv.access( elem, key, {
4090
+			empty: jQuery.Callbacks( "once memory" ).add( function() {
4091
+				dataPriv.remove( elem, [ type + "queue", key ] );
4092
+			} )
4093
+		} );
4094
+	}
4095
+} );
4096
+
4097
+jQuery.fn.extend( {
4098
+	queue: function( type, data ) {
4099
+		var setter = 2;
4100
+
4101
+		if ( typeof type !== "string" ) {
4102
+			data = type;
4103
+			type = "fx";
4104
+			setter--;
4105
+		}
4106
+
4107
+		if ( arguments.length < setter ) {
4108
+			return jQuery.queue( this[ 0 ], type );
4109
+		}
4110
+
4111
+		return data === undefined ?
4112
+			this :
4113
+			this.each( function() {
4114
+				var queue = jQuery.queue( this, type, data );
4115
+
4116
+				// Ensure a hooks for this queue
4117
+				jQuery._queueHooks( this, type );
4118
+
4119
+				if ( type === "fx" && queue[ 0 ] !== "inprogress" ) {
4120
+					jQuery.dequeue( this, type );
4121
+				}
4122
+			} );
4123
+	},
4124
+	dequeue: function( type ) {
4125
+		return this.each( function() {
4126
+			jQuery.dequeue( this, type );
4127
+		} );
4128
+	},
4129
+	clearQueue: function( type ) {
4130
+		return this.queue( type || "fx", [] );
4131
+	},
4132
+
4133
+	// Get a promise resolved when queues of a certain type
4134
+	// are emptied (fx is the type by default)
4135
+	promise: function( type, obj ) {
4136
+		var tmp,
4137
+			count = 1,
4138
+			defer = jQuery.Deferred(),
4139
+			elements = this,
4140
+			i = this.length,
4141
+			resolve = function() {
4142
+				if ( !( --count ) ) {
4143
+					defer.resolveWith( elements, [ elements ] );
4144
+				}
4145
+			};
4146
+
4147
+		if ( typeof type !== "string" ) {
4148
+			obj = type;
4149
+			type = undefined;
4150
+		}
4151
+		type = type || "fx";
4152
+
4153
+		while ( i-- ) {
4154
+			tmp = dataPriv.get( elements[ i ], type + "queueHooks" );
4155
+			if ( tmp && tmp.empty ) {
4156
+				count++;
4157
+				tmp.empty.add( resolve );
4158
+			}
4159
+		}
4160
+		resolve();
4161
+		return defer.promise( obj );
4162
+	}
4163
+} );
4164
+var pnum = ( /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/ ).source;
4165
+
4166
+var rcssNum = new RegExp( "^(?:([+-])=|)(" + pnum + ")([a-z%]*)$", "i" );
4167
+
4168
+
4169
+var cssExpand = [ "Top", "Right", "Bottom", "Left" ];
4170
+
4171
+var isHidden = function( elem, el ) {
4172
+
4173
+		// isHidden might be called from jQuery#filter function;
4174
+		// in that case, element will be second argument
4175
+		elem = el || elem;
4176
+		return jQuery.css( elem, "display" ) === "none" ||
4177
+			!jQuery.contains( elem.ownerDocument, elem );
4178
+	};
4179
+
4180
+
4181
+
4182
+function adjustCSS( elem, prop, valueParts, tween ) {
4183
+	var adjusted,
4184
+		scale = 1,
4185
+		maxIterations = 20,
4186
+		currentValue = tween ?
4187
+			function() { return tween.cur(); } :
4188
+			function() { return jQuery.css( elem, prop, "" ); },
4189
+		initial = currentValue(),
4190
+		unit = valueParts && valueParts[ 3 ] || ( jQuery.cssNumber[ prop ] ? "" : "px" ),
4191
+
4192
+		// Starting value computation is required for potential unit mismatches
4193
+		initialInUnit = ( jQuery.cssNumber[ prop ] || unit !== "px" && +initial ) &&
4194
+			rcssNum.exec( jQuery.css( elem, prop ) );
4195
+
4196
+	if ( initialInUnit && initialInUnit[ 3 ] !== unit ) {
4197
+
4198
+		// Trust units reported by jQuery.css
4199
+		unit = unit || initialInUnit[ 3 ];
4200
+
4201
+		// Make sure we update the tween properties later on
4202
+		valueParts = valueParts || [];
4203
+
4204
+		// Iteratively approximate from a nonzero starting point
4205
+		initialInUnit = +initial || 1;
4206
+
4207
+		do {
4208
+
4209
+			// If previous iteration zeroed out, double until we get *something*.
4210
+			// Use string for doubling so we don't accidentally see scale as unchanged below
4211
+			scale = scale || ".5";
4212
+
4213
+			// Adjust and apply
4214
+			initialInUnit = initialInUnit / scale;
4215
+			jQuery.style( elem, prop, initialInUnit + unit );
4216
+
4217
+		// Update scale, tolerating zero or NaN from tween.cur()
4218
+		// Break the loop if scale is unchanged or perfect, or if we've just had enough.
4219
+		} while (
4220
+			scale !== ( scale = currentValue() / initial ) && scale !== 1 && --maxIterations
4221
+		);
4222
+	}
4223
+
4224
+	if ( valueParts ) {
4225
+		initialInUnit = +initialInUnit || +initial || 0;
4226
+
4227
+		// Apply relative offset (+=/-=) if specified
4228
+		adjusted = valueParts[ 1 ] ?
4229
+			initialInUnit + ( valueParts[ 1 ] + 1 ) * valueParts[ 2 ] :
4230
+			+valueParts[ 2 ];
4231
+		if ( tween ) {
4232
+			tween.unit = unit;
4233
+			tween.start = initialInUnit;
4234
+			tween.end = adjusted;
4235
+		}
4236
+	}
4237
+	return adjusted;
4238
+}
4239
+var rcheckableType = ( /^(?:checkbox|radio)$/i );
4240
+
4241
+var rtagName = ( /<([\w:-]+)/ );
4242
+
4243
+var rscriptType = ( /^$|\/(?:java|ecma)script/i );
4244
+
4245
+
4246
+
4247
+// We have to close these tags to support XHTML (#13200)
4248
+var wrapMap = {
4249
+
4250
+	// Support: IE9
4251
+	option: [ 1, "<select multiple='multiple'>", "</select>" ],
4252
+
4253
+	// XHTML parsers do not magically insert elements in the
4254
+	// same way that tag soup parsers do. So we cannot shorten
4255
+	// this by omitting <tbody> or other required elements.
4256
+	thead: [ 1, "<table>", "</table>" ],
4257
+	col: [ 2, "<table><colgroup>", "</colgroup></table>" ],
4258
+	tr: [ 2, "<table><tbody>", "</tbody></table>" ],
4259
+	td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
4260
+
4261
+	_default: [ 0, "", "" ]
4262
+};
4263
+
4264
+// Support: IE9
4265
+wrapMap.optgroup = wrapMap.option;
4266
+
4267
+wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;
4268
+wrapMap.th = wrapMap.td;
4269
+
4270
+
4271
+function getAll( context, tag ) {
4272
+
4273
+	// Support: IE9-11+
4274
+	// Use typeof to avoid zero-argument method invocation on host objects (#15151)
4275
+	var ret = typeof context.getElementsByTagName !== "undefined" ?
4276
+			context.getElementsByTagName( tag || "*" ) :
4277
+			typeof context.querySelectorAll !== "undefined" ?
4278
+				context.querySelectorAll( tag || "*" ) :
4279
+			[];
4280
+
4281
+	return tag === undefined || tag && jQuery.nodeName( context, tag ) ?
4282
+		jQuery.merge( [ context ], ret ) :
4283
+		ret;
4284
+}
4285
+
4286
+
4287
+// Mark scripts as having already been evaluated
4288
+function setGlobalEval( elems, refElements ) {
4289
+	var i = 0,
4290
+		l = elems.length;
4291
+
4292
+	for ( ; i < l; i++ ) {
4293
+		dataPriv.set(
4294
+			elems[ i ],
4295
+			"globalEval",
4296
+			!refElements || dataPriv.get( refElements[ i ], "globalEval" )
4297
+		);
4298
+	}
4299
+}
4300
+
4301
+
4302
+var rhtml = /<|&#?\w+;/;
4303
+
4304
+function buildFragment( elems, context, scripts, selection, ignored ) {
4305
+	var elem, tmp, tag, wrap, contains, j,
4306
+		fragment = context.createDocumentFragment(),
4307
+		nodes = [],
4308
+		i = 0,
4309
+		l = elems.length;
4310
+
4311
+	for ( ; i < l; i++ ) {
4312
+		elem = elems[ i ];
4313
+
4314
+		if ( elem || elem === 0 ) {
4315
+
4316
+			// Add nodes directly
4317
+			if ( jQuery.type( elem ) === "object" ) {
4318
+
4319
+				// Support: Android<4.1, PhantomJS<2
4320
+				// push.apply(_, arraylike) throws on ancient WebKit
4321
+				jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );
4322
+
4323
+			// Convert non-html into a text node
4324
+			} else if ( !rhtml.test( elem ) ) {
4325
+				nodes.push( context.createTextNode( elem ) );
4326
+
4327
+			// Convert html into DOM nodes
4328
+			} else {
4329
+				tmp = tmp || fragment.appendChild( context.createElement( "div" ) );
4330
+
4331
+				// Deserialize a standard representation
4332
+				tag = ( rtagName.exec( elem ) || [ "", "" ] )[ 1 ].toLowerCase();
4333
+				wrap = wrapMap[ tag ] || wrapMap._default;
4334
+				tmp.innerHTML = wrap[ 1 ] + jQuery.htmlPrefilter( elem ) + wrap[ 2 ];
4335
+
4336
+				// Descend through wrappers to the right content
4337
+				j = wrap[ 0 ];
4338
+				while ( j-- ) {
4339
+					tmp = tmp.lastChild;
4340
+				}
4341
+
4342
+				// Support: Android<4.1, PhantomJS<2
4343
+				// push.apply(_, arraylike) throws on ancient WebKit
4344
+				jQuery.merge( nodes, tmp.childNodes );
4345
+
4346
+				// Remember the top-level container
4347
+				tmp = fragment.firstChild;
4348
+
4349
+				// Ensure the created nodes are orphaned (#12392)
4350
+				tmp.textContent = "";
4351
+			}
4352
+		}
4353
+	}
4354
+
4355
+	// Remove wrapper from fragment
4356
+	fragment.textContent = "";
4357
+
4358
+	i = 0;
4359
+	while ( ( elem = nodes[ i++ ] ) ) {
4360
+
4361
+		// Skip elements already in the context collection (trac-4087)
4362
+		if ( selection && jQuery.inArray( elem, selection ) > -1 ) {
4363
+			if ( ignored ) {
4364
+				ignored.push( elem );
4365
+			}
4366
+			continue;
4367
+		}
4368
+
4369
+		contains = jQuery.contains( elem.ownerDocument, elem );
4370
+
4371
+		// Append to fragment
4372
+		tmp = getAll( fragment.appendChild( elem ), "script" );
4373
+
4374
+		// Preserve script evaluation history
4375
+		if ( contains ) {
4376
+			setGlobalEval( tmp );
4377
+		}
4378
+
4379
+		// Capture executables
4380
+		if ( scripts ) {
4381
+			j = 0;
4382
+			while ( ( elem = tmp[ j++ ] ) ) {
4383
+				if ( rscriptType.test( elem.type || "" ) ) {
4384
+					scripts.push( elem );
4385
+				}
4386
+			}
4387
+		}
4388
+	}
4389
+
4390
+	return fragment;
4391
+}
4392
+
4393
+
4394
+( function() {
4395
+	var fragment = document.createDocumentFragment(),
4396
+		div = fragment.appendChild( document.createElement( "div" ) ),
4397
+		input = document.createElement( "input" );
4398
+
4399
+	// Support: Android 4.0-4.3, Safari<=5.1
4400
+	// Check state lost if the name is set (#11217)
4401
+	// Support: Windows Web Apps (WWA)
4402
+	// `name` and `type` must use .setAttribute for WWA (#14901)
4403
+	input.setAttribute( "type", "radio" );
4404
+	input.setAttribute( "checked", "checked" );
4405
+	input.setAttribute( "name", "t" );
4406
+
4407
+	div.appendChild( input );
4408
+
4409
+	// Support: Safari<=5.1, Android<4.2
4410
+	// Older WebKit doesn't clone checked state correctly in fragments
4411
+	support.checkClone = div.cloneNode( true ).cloneNode( true ).lastChild.checked;
4412
+
4413
+	// Support: IE<=11+
4414
+	// Make sure textarea (and checkbox) defaultValue is properly cloned
4415
+	div.innerHTML = "<textarea>x</textarea>";
4416
+	support.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue;
4417
+} )();
4418
+
4419
+
4420
+var
4421
+	rkeyEvent = /^key/,
4422
+	rmouseEvent = /^(?:mouse|pointer|contextmenu|drag|drop)|click/,
4423
+	rtypenamespace = /^([^.]*)(?:\.(.+)|)/;
4424
+
4425
+function returnTrue() {
4426
+	return true;
4427
+}
4428
+
4429
+function returnFalse() {
4430
+	return false;
4431
+}
4432
+
4433
+// Support: IE9
4434
+// See #13393 for more info
4435
+function safeActiveElement() {
4436
+	try {
4437
+		return document.activeElement;
4438
+	} catch ( err ) { }
4439
+}
4440
+
4441
+function on( elem, types, selector, data, fn, one ) {
4442
+	var origFn, type;
4443
+
4444
+	// Types can be a map of types/handlers
4445
+	if ( typeof types === "object" ) {
4446
+
4447
+		// ( types-Object, selector, data )
4448
+		if ( typeof selector !== "string" ) {
4449
+
4450
+			// ( types-Object, data )
4451
+			data = data || selector;
4452
+			selector = undefined;
4453
+		}
4454
+		for ( type in types ) {
4455
+			on( elem, type, selector, data, types[ type ], one );
4456
+		}
4457
+		return elem;
4458
+	}
4459
+
4460
+	if ( data == null && fn == null ) {
4461
+
4462
+		// ( types, fn )
4463
+		fn = selector;
4464
+		data = selector = undefined;
4465
+	} else if ( fn == null ) {
4466
+		if ( typeof selector === "string" ) {
4467
+
4468
+			// ( types, selector, fn )
4469
+			fn = data;
4470
+			data = undefined;
4471
+		} else {
4472
+
4473
+			// ( types, data, fn )
4474
+			fn = data;
4475
+			data = selector;
4476
+			selector = undefined;
4477
+		}
4478
+	}
4479
+	if ( fn === false ) {
4480
+		fn = returnFalse;
4481
+	} else if ( !fn ) {
4482
+		return this;
4483
+	}
4484
+
4485
+	if ( one === 1 ) {
4486
+		origFn = fn;
4487
+		fn = function( event ) {
4488
+
4489
+			// Can use an empty set, since event contains the info
4490
+			jQuery().off( event );
4491
+			return origFn.apply( this, arguments );
4492
+		};
4493
+
4494
+		// Use same guid so caller can remove using origFn
4495
+		fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ );
4496
+	}
4497
+	return elem.each( function() {
4498
+		jQuery.event.add( this, types, fn, data, selector );
4499
+	} );
4500
+}
4501
+
4502
+/*
4503
+ * Helper functions for managing events -- not part of the public interface.
4504
+ * Props to Dean Edwards' addEvent library for many of the ideas.
4505
+ */
4506
+jQuery.event = {
4507
+
4508
+	global: {},
4509
+
4510
+	add: function( elem, types, handler, data, selector ) {
4511
+
4512
+		var handleObjIn, eventHandle, tmp,
4513
+			events, t, handleObj,
4514
+			special, handlers, type, namespaces, origType,
4515
+			elemData = dataPriv.get( elem );
4516
+
4517
+		// Don't attach events to noData or text/comment nodes (but allow plain objects)
4518
+		if ( !elemData ) {
4519
+			return;
4520
+		}
4521
+
4522
+		// Caller can pass in an object of custom data in lieu of the handler
4523
+		if ( handler.handler ) {
4524
+			handleObjIn = handler;
4525
+			handler = handleObjIn.handler;
4526
+			selector = handleObjIn.selector;
4527
+		}
4528
+
4529
+		// Make sure that the handler has a unique ID, used to find/remove it later
4530
+		if ( !handler.guid ) {
4531
+			handler.guid = jQuery.guid++;
4532
+		}
4533
+
4534
+		// Init the element's event structure and main handler, if this is the first
4535
+		if ( !( events = elemData.events ) ) {
4536
+			events = elemData.events = {};
4537
+		}
4538
+		if ( !( eventHandle = elemData.handle ) ) {
4539
+			eventHandle = elemData.handle = function( e ) {
4540
+
4541
+				// Discard the second event of a jQuery.event.trigger() and
4542
+				// when an event is called after a page has unloaded
4543
+				return typeof jQuery !== "undefined" && jQuery.event.triggered !== e.type ?
4544
+					jQuery.event.dispatch.apply( elem, arguments ) : undefined;
4545
+			};
4546
+		}
4547
+
4548
+		// Handle multiple events separated by a space
4549
+		types = ( types || "" ).match( rnotwhite ) || [ "" ];
4550
+		t = types.length;
4551
+		while ( t-- ) {
4552
+			tmp = rtypenamespace.exec( types[ t ] ) || [];
4553
+			type = origType = tmp[ 1 ];
4554
+			namespaces = ( tmp[ 2 ] || "" ).split( "." ).sort();
4555
+
4556
+			// There *must* be a type, no attaching namespace-only handlers
4557
+			if ( !type ) {
4558
+				continue;
4559
+			}
4560
+
4561
+			// If event changes its type, use the special event handlers for the changed type
4562
+			special = jQuery.event.special[ type ] || {};
4563
+
4564
+			// If selector defined, determine special event api type, otherwise given type
4565
+			type = ( selector ? special.delegateType : special.bindType ) || type;
4566
+
4567
+			// Update special based on newly reset type
4568
+			special = jQuery.event.special[ type ] || {};
4569
+
4570
+			// handleObj is passed to all event handlers
4571
+			handleObj = jQuery.extend( {
4572
+				type: type,
4573
+				origType: origType,
4574
+				data: data,
4575
+				handler: handler,
4576
+				guid: handler.guid,
4577
+				selector: selector,
4578
+				needsContext: selector && jQuery.expr.match.needsContext.test( selector ),
4579
+				namespace: namespaces.join( "." )
4580
+			}, handleObjIn );
4581
+
4582
+			// Init the event handler queue if we're the first
4583
+			if ( !( handlers = events[ type ] ) ) {
4584
+				handlers = events[ type ] = [];
4585
+				handlers.delegateCount = 0;
4586
+
4587
+				// Only use addEventListener if the special events handler returns false
4588
+				if ( !special.setup ||
4589
+					special.setup.call( elem, data, namespaces, eventHandle ) === false ) {
4590
+
4591
+					if ( elem.addEventListener ) {
4592
+						elem.addEventListener( type, eventHandle );
4593
+					}
4594
+				}
4595
+			}
4596
+
4597
+			if ( special.add ) {
4598
+				special.add.call( elem, handleObj );
4599
+
4600
+				if ( !handleObj.handler.guid ) {
4601
+					handleObj.handler.guid = handler.guid;
4602
+				}
4603
+			}
4604
+
4605
+			// Add to the element's handler list, delegates in front
4606
+			if ( selector ) {
4607
+				handlers.splice( handlers.delegateCount++, 0, handleObj );
4608
+			} else {
4609
+				handlers.push( handleObj );
4610
+			}
4611
+
4612
+			// Keep track of which events have ever been used, for event optimization
4613
+			jQuery.event.global[ type ] = true;
4614
+		}
4615
+
4616
+	},
4617
+
4618
+	// Detach an event or set of events from an element
4619
+	remove: function( elem, types, handler, selector, mappedTypes ) {
4620
+
4621
+		var j, origCount, tmp,
4622
+			events, t, handleObj,
4623
+			special, handlers, type, namespaces, origType,
4624
+			elemData = dataPriv.hasData( elem ) && dataPriv.get( elem );
4625
+
4626
+		if ( !elemData || !( events = elemData.events ) ) {
4627
+			return;
4628
+		}
4629
+
4630
+		// Once for each type.namespace in types; type may be omitted
4631
+		types = ( types || "" ).match( rnotwhite ) || [ "" ];
4632
+		t = types.length;
4633
+		while ( t-- ) {
4634
+			tmp = rtypenamespace.exec( types[ t ] ) || [];
4635
+			type = origType = tmp[ 1 ];
4636
+			namespaces = ( tmp[ 2 ] || "" ).split( "." ).sort();
4637
+
4638
+			// Unbind all events (on this namespace, if provided) for the element
4639
+			if ( !type ) {
4640
+				for ( type in events ) {
4641
+					jQuery.event.remove( elem, type + types[ t ], handler, selector, true );
4642
+				}
4643
+				continue;
4644
+			}
4645
+
4646
+			special = jQuery.event.special[ type ] || {};
4647
+			type = ( selector ? special.delegateType : special.bindType ) || type;
4648
+			handlers = events[ type ] || [];
4649
+			tmp = tmp[ 2 ] &&
4650
+				new RegExp( "(^|\\.)" + namespaces.join( "\\.(?:.*\\.|)" ) + "(\\.|$)" );
4651
+
4652
+			// Remove matching events
4653
+			origCount = j = handlers.length;
4654
+			while ( j-- ) {
4655
+				handleObj = handlers[ j ];
4656
+
4657
+				if ( ( mappedTypes || origType === handleObj.origType ) &&
4658
+					( !handler || handler.guid === handleObj.guid ) &&
4659
+					( !tmp || tmp.test( handleObj.namespace ) ) &&
4660
+					( !selector || selector === handleObj.selector ||
4661
+						selector === "**" && handleObj.selector ) ) {
4662
+					handlers.splice( j, 1 );
4663
+
4664
+					if ( handleObj.selector ) {
4665
+						handlers.delegateCount--;
4666
+					}
4667
+					if ( special.remove ) {
4668
+						special.remove.call( elem, handleObj );
4669
+					}
4670
+				}
4671
+			}
4672
+
4673
+			// Remove generic event handler if we removed something and no more handlers exist
4674
+			// (avoids potential for endless recursion during removal of special event handlers)
4675
+			if ( origCount && !handlers.length ) {
4676
+				if ( !special.teardown ||
4677
+					special.teardown.call( elem, namespaces, elemData.handle ) === false ) {
4678
+
4679
+					jQuery.removeEvent( elem, type, elemData.handle );
4680
+				}
4681
+
4682
+				delete events[ type ];
4683
+			}
4684
+		}
4685
+
4686
+		// Remove data and the expando if it's no longer used
4687
+		if ( jQuery.isEmptyObject( events ) ) {
4688
+			dataPriv.remove( elem, "handle events" );
4689
+		}
4690
+	},
4691
+
4692
+	dispatch: function( event ) {
4693
+
4694
+		// Make a writable jQuery.Event from the native event object
4695
+		event = jQuery.event.fix( event );
4696
+
4697
+		var i, j, ret, matched, handleObj,
4698
+			handlerQueue = [],
4699
+			args = slice.call( arguments ),
4700
+			handlers = ( dataPriv.get( this, "events" ) || {} )[ event.type ] || [],
4701
+			special = jQuery.event.special[ event.type ] || {};
4702
+
4703
+		// Use the fix-ed jQuery.Event rather than the (read-only) native event
4704
+		args[ 0 ] = event;
4705
+		event.delegateTarget = this;
4706
+
4707
+		// Call the preDispatch hook for the mapped type, and let it bail if desired
4708
+		if ( special.preDispatch && special.preDispatch.call( this, event ) === false ) {
4709
+			return;
4710
+		}
4711
+
4712
+		// Determine handlers
4713
+		handlerQueue = jQuery.event.handlers.call( this, event, handlers );
4714
+
4715
+		// Run delegates first; they may want to stop propagation beneath us
4716
+		i = 0;
4717
+		while ( ( matched = handlerQueue[ i++ ] ) && !event.isPropagationStopped() ) {
4718
+			event.currentTarget = matched.elem;
4719
+
4720
+			j = 0;
4721
+			while ( ( handleObj = matched.handlers[ j++ ] ) &&
4722
+				!event.isImmediatePropagationStopped() ) {
4723
+
4724
+				// Triggered event must either 1) have no namespace, or 2) have namespace(s)
4725
+				// a subset or equal to those in the bound event (both can have no namespace).
4726
+				if ( !event.rnamespace || event.rnamespace.test( handleObj.namespace ) ) {
4727
+
4728
+					event.handleObj = handleObj;
4729
+					event.data = handleObj.data;
4730
+
4731
+					ret = ( ( jQuery.event.special[ handleObj.origType ] || {} ).handle ||
4732
+						handleObj.handler ).apply( matched.elem, args );
4733
+
4734
+					if ( ret !== undefined ) {
4735
+						if ( ( event.result = ret ) === false ) {
4736
+							event.preventDefault();
4737
+							event.stopPropagation();
4738
+						}
4739
+					}
4740
+				}
4741
+			}
4742
+		}
4743
+
4744
+		// Call the postDispatch hook for the mapped type
4745
+		if ( special.postDispatch ) {
4746
+			special.postDispatch.call( this, event );
4747
+		}
4748
+
4749
+		return event.result;
4750
+	},
4751
+
4752
+	handlers: function( event, handlers ) {
4753
+		var i, matches, sel, handleObj,
4754
+			handlerQueue = [],
4755
+			delegateCount = handlers.delegateCount,
4756
+			cur = event.target;
4757
+
4758
+		// Support (at least): Chrome, IE9
4759
+		// Find delegate handlers
4760
+		// Black-hole SVG <use> instance trees (#13180)
4761
+		//
4762
+		// Support: Firefox<=42+
4763
+		// Avoid non-left-click in FF but don't block IE radio events (#3861, gh-2343)
4764
+		if ( delegateCount && cur.nodeType &&
4765
+			( event.type !== "click" || isNaN( event.button ) || event.button < 1 ) ) {
4766
+
4767
+			for ( ; cur !== this; cur = cur.parentNode || this ) {
4768
+
4769
+				// Don't check non-elements (#13208)
4770
+				// Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)
4771
+				if ( cur.nodeType === 1 && ( cur.disabled !== true || event.type !== "click" ) ) {
4772
+					matches = [];
4773
+					for ( i = 0; i < delegateCount; i++ ) {
4774
+						handleObj = handlers[ i ];
4775
+
4776
+						// Don't conflict with Object.prototype properties (#13203)
4777
+						sel = handleObj.selector + " ";
4778
+
4779
+						if ( matches[ sel ] === undefined ) {
4780
+							matches[ sel ] = handleObj.needsContext ?
4781
+								jQuery( sel, this ).index( cur ) > -1 :
4782
+								jQuery.find( sel, this, null, [ cur ] ).length;
4783
+						}
4784
+						if ( matches[ sel ] ) {
4785
+							matches.push( handleObj );
4786
+						}
4787
+					}
4788
+					if ( matches.length ) {
4789
+						handlerQueue.push( { elem: cur, handlers: matches } );
4790
+					}
4791
+				}
4792
+			}
4793
+		}
4794
+
4795
+		// Add the remaining (directly-bound) handlers
4796
+		if ( delegateCount < handlers.length ) {
4797
+			handlerQueue.push( { elem: this, handlers: handlers.slice( delegateCount ) } );
4798
+		}
4799
+
4800
+		return handlerQueue;
4801
+	},
4802
+
4803
+	// Includes some event props shared by KeyEvent and MouseEvent
4804
+	props: ( "altKey bubbles cancelable ctrlKey currentTarget detail eventPhase " +
4805
+		"metaKey relatedTarget shiftKey target timeStamp view which" ).split( " " ),
4806
+
4807
+	fixHooks: {},
4808
+
4809
+	keyHooks: {
4810
+		props: "char charCode key keyCode".split( " " ),
4811
+		filter: function( event, original ) {
4812
+
4813
+			// Add which for key events
4814
+			if ( event.which == null ) {
4815
+				event.which = original.charCode != null ? original.charCode : original.keyCode;
4816
+			}
4817
+
4818
+			return event;
4819
+		}
4820
+	},
4821
+
4822
+	mouseHooks: {
4823
+		props: ( "button buttons clientX clientY offsetX offsetY pageX pageY " +
4824
+			"screenX screenY toElement" ).split( " " ),
4825
+		filter: function( event, original ) {
4826
+			var eventDoc, doc, body,
4827
+				button = original.button;
4828
+
4829
+			// Calculate pageX/Y if missing and clientX/Y available
4830
+			if ( event.pageX == null && original.clientX != null ) {
4831
+				eventDoc = event.target.ownerDocument || document;
4832
+				doc = eventDoc.documentElement;
4833
+				body = eventDoc.body;
4834
+
4835
+				event.pageX = original.clientX +
4836
+					( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) -
4837
+					( doc && doc.clientLeft || body && body.clientLeft || 0 );
4838
+				event.pageY = original.clientY +
4839
+					( doc && doc.scrollTop  || body && body.scrollTop  || 0 ) -
4840
+					( doc && doc.clientTop  || body && body.clientTop  || 0 );
4841
+			}
4842
+
4843
+			// Add which for click: 1 === left; 2 === middle; 3 === right
4844
+			// Note: button is not normalized, so don't use it
4845
+			if ( !event.which && button !== undefined ) {
4846
+				event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) );
4847
+			}
4848
+
4849
+			return event;
4850
+		}
4851
+	},
4852
+
4853
+	fix: function( event ) {
4854
+		if ( event[ jQuery.expando ] ) {
4855
+			return event;
4856
+		}
4857
+
4858
+		// Create a writable copy of the event object and normalize some properties
4859
+		var i, prop, copy,
4860
+			type = event.type,
4861
+			originalEvent = event,
4862
+			fixHook = this.fixHooks[ type ];
4863
+
4864
+		if ( !fixHook ) {
4865
+			this.fixHooks[ type ] = fixHook =
4866
+				rmouseEvent.test( type ) ? this.mouseHooks :
4867
+				rkeyEvent.test( type ) ? this.keyHooks :
4868
+				{};
4869
+		}
4870
+		copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props;
4871
+
4872
+		event = new jQuery.Event( originalEvent );
4873
+
4874
+		i = copy.length;
4875
+		while ( i-- ) {
4876
+			prop = copy[ i ];
4877
+			event[ prop ] = originalEvent[ prop ];
4878
+		}
4879
+
4880
+		// Support: Cordova 2.5 (WebKit) (#13255)
4881
+		// All events should have a target; Cordova deviceready doesn't
4882
+		if ( !event.target ) {
4883
+			event.target = document;
4884
+		}
4885
+
4886
+		// Support: Safari 6.0+, Chrome<28
4887
+		// Target should not be a text node (#504, #13143)
4888
+		if ( event.target.nodeType === 3 ) {
4889
+			event.target = event.target.parentNode;
4890
+		}
4891
+
4892
+		return fixHook.filter ? fixHook.filter( event, originalEvent ) : event;
4893
+	},
4894
+
4895
+	special: {
4896
+		load: {
4897
+
4898
+			// Prevent triggered image.load events from bubbling to window.load
4899
+			noBubble: true
4900
+		},
4901
+		focus: {
4902
+
4903
+			// Fire native event if possible so blur/focus sequence is correct
4904
+			trigger: function() {
4905
+				if ( this !== safeActiveElement() && this.focus ) {
4906
+					this.focus();
4907
+					return false;
4908
+				}
4909
+			},
4910
+			delegateType: "focusin"
4911
+		},
4912
+		blur: {
4913
+			trigger: function() {
4914
+				if ( this === safeActiveElement() && this.blur ) {
4915
+					this.blur();
4916
+					return false;
4917
+				}
4918
+			},
4919
+			delegateType: "focusout"
4920
+		},
4921
+		click: {
4922
+
4923
+			// For checkbox, fire native event so checked state will be right
4924
+			trigger: function() {
4925
+				if ( this.type === "checkbox" && this.click && jQuery.nodeName( this, "input" ) ) {
4926
+					this.click();
4927
+					return false;
4928
+				}
4929
+			},
4930
+
4931
+			// For cross-browser consistency, don't fire native .click() on links
4932
+			_default: function( event ) {
4933
+				return jQuery.nodeName( event.target, "a" );
4934
+			}
4935
+		},
4936
+
4937
+		beforeunload: {
4938
+			postDispatch: function( event ) {
4939
+
4940
+				// Support: Firefox 20+
4941
+				// Firefox doesn't alert if the returnValue field is not set.
4942
+				if ( event.result !== undefined && event.originalEvent ) {
4943
+					event.originalEvent.returnValue = event.result;
4944
+				}
4945
+			}
4946
+		}
4947
+	}
4948
+};
4949
+
4950
+jQuery.removeEvent = function( elem, type, handle ) {
4951
+
4952
+	// This "if" is needed for plain objects
4953
+	if ( elem.removeEventListener ) {
4954
+		elem.removeEventListener( type, handle );
4955
+	}
4956
+};
4957
+
4958
+jQuery.Event = function( src, props ) {
4959
+
4960
+	// Allow instantiation without the 'new' keyword
4961
+	if ( !( this instanceof jQuery.Event ) ) {
4962
+		return new jQuery.Event( src, props );
4963
+	}
4964
+
4965
+	// Event object
4966
+	if ( src && src.type ) {
4967
+		this.originalEvent = src;
4968
+		this.type = src.type;
4969
+
4970
+		// Events bubbling up the document may have been marked as prevented
4971
+		// by a handler lower down the tree; reflect the correct value.
4972
+		this.isDefaultPrevented = src.defaultPrevented ||
4973
+				src.defaultPrevented === undefined &&
4974
+
4975
+				// Support: Android<4.0
4976
+				src.returnValue === false ?
4977
+			returnTrue :
4978
+			returnFalse;
4979
+
4980
+	// Event type
4981
+	} else {
4982
+		this.type = src;
4983
+	}
4984
+
4985
+	// Put explicitly provided properties onto the event object
4986
+	if ( props ) {
4987
+		jQuery.extend( this, props );
4988
+	}
4989
+
4990
+	// Create a timestamp if incoming event doesn't have one
4991
+	this.timeStamp = src && src.timeStamp || jQuery.now();
4992
+
4993
+	// Mark it as fixed
4994
+	this[ jQuery.expando ] = true;
4995
+};
4996
+
4997
+// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding
4998
+// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html
4999
+jQuery.Event.prototype = {
5000
+	constructor: jQuery.Event,
5001
+	isDefaultPrevented: returnFalse,
5002
+	isPropagationStopped: returnFalse,
5003
+	isImmediatePropagationStopped: returnFalse,
5004
+
5005
+	preventDefault: function() {
5006
+		var e = this.originalEvent;
5007
+
5008
+		this.isDefaultPrevented = returnTrue;
5009
+
5010
+		if ( e ) {
5011
+			e.preventDefault();
5012
+		}
5013
+	},
5014
+	stopPropagation: function() {
5015
+		var e = this.originalEvent;
5016
+
5017
+		this.isPropagationStopped = returnTrue;
5018
+
5019
+		if ( e ) {
5020
+			e.stopPropagation();
5021
+		}
5022
+	},
5023
+	stopImmediatePropagation: function() {
5024
+		var e = this.originalEvent;
5025
+
5026
+		this.isImmediatePropagationStopped = returnTrue;
5027
+
5028
+		if ( e ) {
5029
+			e.stopImmediatePropagation();
5030
+		}
5031
+
5032
+		this.stopPropagation();
5033
+	}
5034
+};
5035
+
5036
+// Create mouseenter/leave events using mouseover/out and event-time checks
5037
+// so that event delegation works in jQuery.
5038
+// Do the same for pointerenter/pointerleave and pointerover/pointerout
5039
+//
5040
+// Support: Safari 7 only
5041
+// Safari sends mouseenter too often; see:
5042
+// https://code.google.com/p/chromium/issues/detail?id=470258
5043
+// for the description of the bug (it existed in older Chrome versions as well).
5044
+jQuery.each( {
5045
+	mouseenter: "mouseover",
5046
+	mouseleave: "mouseout",
5047
+	pointerenter: "pointerover",
5048
+	pointerleave: "pointerout"
5049
+}, function( orig, fix ) {
5050
+	jQuery.event.special[ orig ] = {
5051
+		delegateType: fix,
5052
+		bindType: fix,
5053
+
5054
+		handle: function( event ) {
5055
+			var ret,
5056
+				target = this,
5057
+				related = event.relatedTarget,
5058
+				handleObj = event.handleObj;
5059
+
5060
+			// For mouseenter/leave call the handler if related is outside the target.
5061
+			// NB: No relatedTarget if the mouse left/entered the browser window
5062
+			if ( !related || ( related !== target && !jQuery.contains( target, related ) ) ) {
5063
+				event.type = handleObj.origType;
5064
+				ret = handleObj.handler.apply( this, arguments );
5065
+				event.type = fix;
5066
+			}
5067
+			return ret;
5068
+		}
5069
+	};
5070
+} );
5071
+
5072
+jQuery.fn.extend( {
5073
+	on: function( types, selector, data, fn ) {
5074
+		return on( this, types, selector, data, fn );
5075
+	},
5076
+	one: function( types, selector, data, fn ) {
5077
+		return on( this, types, selector, data, fn, 1 );
5078
+	},
5079
+	off: function( types, selector, fn ) {
5080
+		var handleObj, type;
5081
+		if ( types && types.preventDefault && types.handleObj ) {
5082
+
5083
+			// ( event )  dispatched jQuery.Event
5084
+			handleObj = types.handleObj;
5085
+			jQuery( types.delegateTarget ).off(
5086
+				handleObj.namespace ?
5087
+					handleObj.origType + "." + handleObj.namespace :
5088
+					handleObj.origType,
5089
+				handleObj.selector,
5090
+				handleObj.handler
5091
+			);
5092
+			return this;
5093
+		}
5094
+		if ( typeof types === "object" ) {
5095
+
5096
+			// ( types-object [, selector] )
5097
+			for ( type in types ) {
5098
+				this.off( type, selector, types[ type ] );
5099
+			}
5100
+			return this;
5101
+		}
5102
+		if ( selector === false || typeof selector === "function" ) {
5103
+
5104
+			// ( types [, fn] )
5105
+			fn = selector;
5106
+			selector = undefined;
5107
+		}
5108
+		if ( fn === false ) {
5109
+			fn = returnFalse;
5110
+		}
5111
+		return this.each( function() {
5112
+			jQuery.event.remove( this, types, fn, selector );
5113
+		} );
5114
+	}
5115
+} );
5116
+
5117
+
5118
+var
5119
+	rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,
5120
+
5121
+	// Support: IE 10-11, Edge 10240+
5122
+	// In IE/Edge using regex groups here causes severe slowdowns.
5123
+	// See https://connect.microsoft.com/IE/feedback/details/1736512/
5124
+	rnoInnerhtml = /<script|<style|<link/i,
5125
+
5126
+	// checked="checked" or checked
5127
+	rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,
5128
+	rscriptTypeMasked = /^true\/(.*)/,
5129
+	rcleanScript = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;
5130
+
5131
+function manipulationTarget( elem, content ) {
5132
+	if ( jQuery.nodeName( elem, "table" ) &&
5133
+		jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ) {
5134
+
5135
+		return elem.getElementsByTagName( "tbody" )[ 0 ] || elem;
5136
+	}
5137
+
5138
+	return elem;
5139
+}
5140
+
5141
+// Replace/restore the type attribute of script elements for safe DOM manipulation
5142
+function disableScript( elem ) {
5143
+	elem.type = ( elem.getAttribute( "type" ) !== null ) + "/" + elem.type;
5144
+	return elem;
5145
+}
5146
+function restoreScript( elem ) {
5147
+	var match = rscriptTypeMasked.exec( elem.type );
5148
+
5149
+	if ( match ) {
5150
+		elem.type = match[ 1 ];
5151
+	} else {
5152
+		elem.removeAttribute( "type" );
5153
+	}
5154
+
5155
+	return elem;
5156
+}
5157
+
5158
+function cloneCopyEvent( src, dest ) {
5159
+	var i, l, type, pdataOld, pdataCur, udataOld, udataCur, events;
5160
+
5161
+	if ( dest.nodeType !== 1 ) {
5162
+		return;
5163
+	}
5164
+
5165
+	// 1. Copy private data: events, handlers, etc.
5166
+	if ( dataPriv.hasData( src ) ) {
5167
+		pdataOld = dataPriv.access( src );
5168
+		pdataCur = dataPriv.set( dest, pdataOld );
5169
+		events = pdataOld.events;
5170
+
5171
+		if ( events ) {
5172
+			delete pdataCur.handle;
5173
+			pdataCur.events = {};
5174
+
5175
+			for ( type in events ) {
5176
+				for ( i = 0, l = events[ type ].length; i < l; i++ ) {
5177
+					jQuery.event.add( dest, type, events[ type ][ i ] );
5178
+				}
5179
+			}
5180
+		}
5181
+	}
5182
+
5183
+	// 2. Copy user data
5184
+	if ( dataUser.hasData( src ) ) {
5185
+		udataOld = dataUser.access( src );
5186
+		udataCur = jQuery.extend( {}, udataOld );
5187
+
5188
+		dataUser.set( dest, udataCur );
5189
+	}
5190
+}
5191
+
5192
+// Fix IE bugs, see support tests
5193
+function fixInput( src, dest ) {
5194
+	var nodeName = dest.nodeName.toLowerCase();
5195
+
5196
+	// Fails to persist the checked state of a cloned checkbox or radio button.
5197
+	if ( nodeName === "input" && rcheckableType.test( src.type ) ) {
5198
+		dest.checked = src.checked;
5199
+
5200
+	// Fails to return the selected option to the default selected state when cloning options
5201
+	} else if ( nodeName === "input" || nodeName === "textarea" ) {
5202
+		dest.defaultValue = src.defaultValue;
5203
+	}
5204
+}
5205
+
5206
+function domManip( collection, args, callback, ignored ) {
5207
+
5208
+	// Flatten any nested arrays
5209
+	args = concat.apply( [], args );
5210
+
5211
+	var fragment, first, scripts, hasScripts, node, doc,
5212
+		i = 0,
5213
+		l = collection.length,
5214
+		iNoClone = l - 1,
5215
+		value = args[ 0 ],
5216
+		isFunction = jQuery.isFunction( value );
5217
+
5218
+	// We can't cloneNode fragments that contain checked, in WebKit
5219
+	if ( isFunction ||
5220
+			( l > 1 && typeof value === "string" &&
5221
+				!support.checkClone && rchecked.test( value ) ) ) {
5222
+		return collection.each( function( index ) {
5223
+			var self = collection.eq( index );
5224
+			if ( isFunction ) {
5225
+				args[ 0 ] = value.call( this, index, self.html() );
5226
+			}
5227
+			domManip( self, args, callback, ignored );
5228
+		} );
5229
+	}
5230
+
5231
+	if ( l ) {
5232
+		fragment = buildFragment( args, collection[ 0 ].ownerDocument, false, collection, ignored );
5233
+		first = fragment.firstChild;
5234
+
5235
+		if ( fragment.childNodes.length === 1 ) {
5236
+			fragment = first;
5237
+		}
5238
+
5239
+		// Require either new content or an interest in ignored elements to invoke the callback
5240
+		if ( first || ignored ) {
5241
+			scripts = jQuery.map( getAll( fragment, "script" ), disableScript );
5242
+			hasScripts = scripts.length;
5243
+
5244
+			// Use the original fragment for the last item
5245
+			// instead of the first because it can end up
5246
+			// being emptied incorrectly in certain situations (#8070).
5247
+			for ( ; i < l; i++ ) {
5248
+				node = fragment;
5249
+
5250
+				if ( i !== iNoClone ) {
5251
+					node = jQuery.clone( node, true, true );
5252
+
5253
+					// Keep references to cloned scripts for later restoration
5254
+					if ( hasScripts ) {
5255
+
5256
+						// Support: Android<4.1, PhantomJS<2
5257
+						// push.apply(_, arraylike) throws on ancient WebKit
5258
+						jQuery.merge( scripts, getAll( node, "script" ) );
5259
+					}
5260
+				}
5261
+
5262
+				callback.call( collection[ i ], node, i );
5263
+			}
5264
+
5265
+			if ( hasScripts ) {
5266
+				doc = scripts[ scripts.length - 1 ].ownerDocument;
5267
+
5268
+				// Reenable scripts
5269
+				jQuery.map( scripts, restoreScript );
5270
+
5271
+				// Evaluate executable scripts on first document insertion
5272
+				for ( i = 0; i < hasScripts; i++ ) {
5273
+					node = scripts[ i ];
5274
+					if ( rscriptType.test( node.type || "" ) &&
5275
+						!dataPriv.access( node, "globalEval" ) &&
5276
+						jQuery.contains( doc, node ) ) {
5277
+
5278
+						if ( node.src ) {
5279
+
5280
+							// Optional AJAX dependency, but won't run scripts if not present
5281
+							if ( jQuery._evalUrl ) {
5282
+								jQuery._evalUrl( node.src );
5283
+							}
5284
+						} else {
5285
+							jQuery.globalEval( node.textContent.replace( rcleanScript, "" ) );
5286
+						}
5287
+					}
5288
+				}
5289
+			}
5290
+		}
5291
+	}
5292
+
5293
+	return collection;
5294
+}
5295
+
5296
+function remove( elem, selector, keepData ) {
5297
+	var node,
5298
+		nodes = selector ? jQuery.filter( selector, elem ) : elem,
5299
+		i = 0;
5300
+
5301
+	for ( ; ( node = nodes[ i ] ) != null; i++ ) {
5302
+		if ( !keepData && node.nodeType === 1 ) {
5303
+			jQuery.cleanData( getAll( node ) );
5304
+		}
5305
+
5306
+		if ( node.parentNode ) {
5307
+			if ( keepData && jQuery.contains( node.ownerDocument, node ) ) {
5308
+				setGlobalEval( getAll( node, "script" ) );
5309
+			}
5310
+			node.parentNode.removeChild( node );
5311
+		}
5312
+	}
5313
+
5314
+	return elem;
5315
+}
5316
+
5317
+jQuery.extend( {
5318
+	htmlPrefilter: function( html ) {
5319
+		return html.replace( rxhtmlTag, "<$1></$2>" );
5320
+	},
5321
+
5322
+	clone: function( elem, dataAndEvents, deepDataAndEvents ) {
5323
+		var i, l, srcElements, destElements,
5324
+			clone = elem.cloneNode( true ),
5325
+			inPage = jQuery.contains( elem.ownerDocument, elem );
5326
+
5327
+		// Fix IE cloning issues
5328
+		if ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) &&
5329
+				!jQuery.isXMLDoc( elem ) ) {
5330
+
5331
+			// We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2
5332
+			destElements = getAll( clone );
5333
+			srcElements = getAll( elem );
5334
+
5335
+			for ( i = 0, l = srcElements.length; i < l; i++ ) {
5336
+				fixInput( srcElements[ i ], destElements[ i ] );
5337
+			}
5338
+		}
5339
+
5340
+		// Copy the events from the original to the clone
5341
+		if ( dataAndEvents ) {
5342
+			if ( deepDataAndEvents ) {
5343
+				srcElements = srcElements || getAll( elem );
5344
+				destElements = destElements || getAll( clone );
5345
+
5346
+				for ( i = 0, l = srcElements.length; i < l; i++ ) {
5347
+					cloneCopyEvent( srcElements[ i ], destElements[ i ] );
5348
+				}
5349
+			} else {
5350
+				cloneCopyEvent( elem, clone );
5351
+			}
5352
+		}
5353
+
5354
+		// Preserve script evaluation history
5355
+		destElements = getAll( clone, "script" );
5356
+		if ( destElements.length > 0 ) {
5357
+			setGlobalEval( destElements, !inPage && getAll( elem, "script" ) );
5358
+		}
5359
+
5360
+		// Return the cloned set
5361
+		return clone;
5362
+	},
5363
+
5364
+	cleanData: function( elems ) {
5365
+		var data, elem, type,
5366
+			special = jQuery.event.special,
5367
+			i = 0;
5368
+
5369
+		for ( ; ( elem = elems[ i ] ) !== undefined; i++ ) {
5370
+			if ( acceptData( elem ) ) {
5371
+				if ( ( data = elem[ dataPriv.expando ] ) ) {
5372
+					if ( data.events ) {
5373
+						for ( type in data.events ) {
5374
+							if ( special[ type ] ) {
5375
+								jQuery.event.remove( elem, type );
5376
+
5377
+							// This is a shortcut to avoid jQuery.event.remove's overhead
5378
+							} else {
5379
+								jQuery.removeEvent( elem, type, data.handle );
5380
+							}
5381
+						}
5382
+					}
5383
+
5384
+					// Support: Chrome <= 35-45+
5385
+					// Assign undefined instead of using delete, see Data#remove
5386
+					elem[ dataPriv.expando ] = undefined;
5387
+				}
5388
+				if ( elem[ dataUser.expando ] ) {
5389
+
5390
+					// Support: Chrome <= 35-45+
5391
+					// Assign undefined instead of using delete, see Data#remove
5392
+					elem[ dataUser.expando ] = undefined;
5393
+				}
5394
+			}
5395
+		}
5396
+	}
5397
+} );
5398
+
5399
+jQuery.fn.extend( {
5400
+
5401
+	// Keep domManip exposed until 3.0 (gh-2225)
5402
+	domManip: domManip,
5403
+
5404
+	detach: function( selector ) {
5405
+		return remove( this, selector, true );
5406
+	},
5407
+
5408
+	remove: function( selector ) {
5409
+		return remove( this, selector );
5410
+	},
5411
+
5412
+	text: function( value ) {
5413
+		return access( this, function( value ) {
5414
+			return value === undefined ?
5415
+				jQuery.text( this ) :
5416
+				this.empty().each( function() {
5417
+					if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
5418
+						this.textContent = value;
5419
+					}
5420
+				} );
5421
+		}, null, value, arguments.length );
5422
+	},
5423
+
5424
+	append: function() {
5425
+		return domManip( this, arguments, function( elem ) {
5426
+			if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
5427
+				var target = manipulationTarget( this, elem );
5428
+				target.appendChild( elem );
5429
+			}
5430
+		} );
5431
+	},
5432
+
5433
+	prepend: function() {
5434
+		return domManip( this, arguments, function( elem ) {
5435
+			if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
5436
+				var target = manipulationTarget( this, elem );
5437
+				target.insertBefore( elem, target.firstChild );
5438
+			}
5439
+		} );
5440
+	},
5441
+
5442
+	before: function() {
5443
+		return domManip( this, arguments, function( elem ) {
5444
+			if ( this.parentNode ) {
5445
+				this.parentNode.insertBefore( elem, this );
5446
+			}
5447
+		} );
5448
+	},
5449
+
5450
+	after: function() {
5451
+		return domManip( this, arguments, function( elem ) {
5452
+			if ( this.parentNode ) {
5453
+				this.parentNode.insertBefore( elem, this.nextSibling );
5454
+			}
5455
+		} );
5456
+	},
5457
+
5458
+	empty: function() {
5459
+		var elem,
5460
+			i = 0;
5461
+
5462
+		for ( ; ( elem = this[ i ] ) != null; i++ ) {
5463
+			if ( elem.nodeType === 1 ) {
5464
+
5465
+				// Prevent memory leaks
5466
+				jQuery.cleanData( getAll( elem, false ) );
5467
+
5468
+				// Remove any remaining nodes
5469
+				elem.textContent = "";
5470
+			}
5471
+		}
5472
+
5473
+		return this;
5474
+	},
5475
+
5476
+	clone: function( dataAndEvents, deepDataAndEvents ) {
5477
+		dataAndEvents = dataAndEvents == null ? false : dataAndEvents;
5478
+		deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;
5479
+
5480
+		return this.map( function() {
5481
+			return jQuery.clone( this, dataAndEvents, deepDataAndEvents );
5482
+		} );
5483
+	},
5484
+
5485
+	html: function( value ) {
5486
+		return access( this, function( value ) {
5487
+			var elem = this[ 0 ] || {},
5488
+				i = 0,
5489
+				l = this.length;
5490
+
5491
+			if ( value === undefined && elem.nodeType === 1 ) {
5492
+				return elem.innerHTML;
5493
+			}
5494
+
5495
+			// See if we can take a shortcut and just use innerHTML
5496
+			if ( typeof value === "string" && !rnoInnerhtml.test( value ) &&
5497
+				!wrapMap[ ( rtagName.exec( value ) || [ "", "" ] )[ 1 ].toLowerCase() ] ) {
5498
+
5499
+				value = jQuery.htmlPrefilter( value );
5500
+
5501
+				try {
5502
+					for ( ; i < l; i++ ) {
5503
+						elem = this[ i ] || {};
5504
+
5505
+						// Remove element nodes and prevent memory leaks
5506
+						if ( elem.nodeType === 1 ) {
5507
+							jQuery.cleanData( getAll( elem, false ) );
5508
+							elem.innerHTML = value;
5509
+						}
5510
+					}
5511
+
5512
+					elem = 0;
5513
+
5514
+				// If using innerHTML throws an exception, use the fallback method
5515
+				} catch ( e ) {}
5516
+			}
5517
+
5518
+			if ( elem ) {
5519
+				this.empty().append( value );
5520
+			}
5521
+		}, null, value, arguments.length );
5522
+	},
5523
+
5524
+	replaceWith: function() {
5525
+		var ignored = [];
5526
+
5527
+		// Make the changes, replacing each non-ignored context element with the new content
5528
+		return domManip( this, arguments, function( elem ) {
5529
+			var parent = this.parentNode;
5530
+
5531
+			if ( jQuery.inArray( this, ignored ) < 0 ) {
5532
+				jQuery.cleanData( getAll( this ) );
5533
+				if ( parent ) {
5534
+					parent.replaceChild( elem, this );
5535
+				}
5536
+			}
5537
+
5538
+		// Force callback invocation
5539
+		}, ignored );
5540
+	}
5541
+} );
5542
+
5543
+jQuery.each( {
5544
+	appendTo: "append",
5545
+	prependTo: "prepend",
5546
+	insertBefore: "before",
5547
+	insertAfter: "after",
5548
+	replaceAll: "replaceWith"
5549
+}, function( name, original ) {
5550
+	jQuery.fn[ name ] = function( selector ) {
5551
+		var elems,
5552
+			ret = [],
5553
+			insert = jQuery( selector ),
5554
+			last = insert.length - 1,
5555
+			i = 0;
5556
+
5557
+		for ( ; i <= last; i++ ) {
5558
+			elems = i === last ? this : this.clone( true );
5559
+			jQuery( insert[ i ] )[ original ]( elems );
5560
+
5561
+			// Support: QtWebKit
5562
+			// .get() because push.apply(_, arraylike) throws
5563
+			push.apply( ret, elems.get() );
5564
+		}
5565
+
5566
+		return this.pushStack( ret );
5567
+	};
5568
+} );
5569
+
5570
+
5571
+var iframe,
5572
+	elemdisplay = {
5573
+
5574
+		// Support: Firefox
5575
+		// We have to pre-define these values for FF (#10227)
5576
+		HTML: "block",
5577
+		BODY: "block"
5578
+	};
5579
+
5580
+/**
5581
+ * Retrieve the actual display of a element
5582
+ * @param {String} name nodeName of the element
5583
+ * @param {Object} doc Document object
5584
+ */
5585
+
5586
+// Called only from within defaultDisplay
5587
+function actualDisplay( name, doc ) {
5588
+	var elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ),
5589
+
5590
+		display = jQuery.css( elem[ 0 ], "display" );
5591
+
5592
+	// We don't have any data stored on the element,
5593
+	// so use "detach" method as fast way to get rid of the element
5594
+	elem.detach();
5595
+
5596
+	return display;
5597
+}
5598
+
5599
+/**
5600
+ * Try to determine the default display value of an element
5601
+ * @param {String} nodeName
5602
+ */
5603
+function defaultDisplay( nodeName ) {
5604
+	var doc = document,
5605
+		display = elemdisplay[ nodeName ];
5606
+
5607
+	if ( !display ) {
5608
+		display = actualDisplay( nodeName, doc );
5609
+
5610
+		// If the simple way fails, read from inside an iframe
5611
+		if ( display === "none" || !display ) {
5612
+
5613
+			// Use the already-created iframe if possible
5614
+			iframe = ( iframe || jQuery( "<iframe frameborder='0' width='0' height='0'/>" ) )
5615
+				.appendTo( doc.documentElement );
5616
+
5617
+			// Always write a new HTML skeleton so Webkit and Firefox don't choke on reuse
5618
+			doc = iframe[ 0 ].contentDocument;
5619
+
5620
+			// Support: IE
5621
+			doc.write();
5622
+			doc.close();
5623
+
5624
+			display = actualDisplay( nodeName, doc );
5625
+			iframe.detach();
5626
+		}
5627
+
5628
+		// Store the correct default display
5629
+		elemdisplay[ nodeName ] = display;
5630
+	}
5631
+
5632
+	return display;
5633
+}
5634
+var rmargin = ( /^margin/ );
5635
+
5636
+var rnumnonpx = new RegExp( "^(" + pnum + ")(?!px)[a-z%]+$", "i" );
5637
+
5638
+var getStyles = function( elem ) {
5639
+
5640
+		// Support: IE<=11+, Firefox<=30+ (#15098, #14150)
5641
+		// IE throws on elements created in popups
5642
+		// FF meanwhile throws on frame elements through "defaultView.getComputedStyle"
5643
+		var view = elem.ownerDocument.defaultView;
5644
+
5645
+		if ( !view.opener ) {
5646
+			view = window;
5647
+		}
5648
+
5649
+		return view.getComputedStyle( elem );
5650
+	};
5651
+
5652
+var swap = function( elem, options, callback, args ) {
5653
+	var ret, name,
5654
+		old = {};
5655
+
5656
+	// Remember the old values, and insert the new ones
5657
+	for ( name in options ) {
5658
+		old[ name ] = elem.style[ name ];
5659
+		elem.style[ name ] = options[ name ];
5660
+	}
5661
+
5662
+	ret = callback.apply( elem, args || [] );
5663
+
5664
+	// Revert the old values
5665
+	for ( name in options ) {
5666
+		elem.style[ name ] = old[ name ];
5667
+	}
5668
+
5669
+	return ret;
5670
+};
5671
+
5672
+
5673
+var documentElement = document.documentElement;
5674
+
5675
+
5676
+
5677
+( function() {
5678
+	var pixelPositionVal, boxSizingReliableVal, pixelMarginRightVal, reliableMarginLeftVal,
5679
+		container = document.createElement( "div" ),
5680
+		div = document.createElement( "div" );
5681
+
5682
+	// Finish early in limited (non-browser) environments
5683
+	if ( !div.style ) {
5684
+		return;
5685
+	}
5686
+
5687
+	// Support: IE9-11+
5688
+	// Style of cloned element affects source element cloned (#8908)
5689
+	div.style.backgroundClip = "content-box";
5690
+	div.cloneNode( true ).style.backgroundClip = "";
5691
+	support.clearCloneStyle = div.style.backgroundClip === "content-box";
5692
+
5693
+	container.style.cssText = "border:0;width:8px;height:0;top:0;left:-9999px;" +
5694
+		"padding:0;margin-top:1px;position:absolute";
5695
+	container.appendChild( div );
5696
+
5697
+	// Executing both pixelPosition & boxSizingReliable tests require only one layout
5698
+	// so they're executed at the same time to save the second computation.
5699
+	function computeStyleTests() {
5700
+		div.style.cssText =
5701
+
5702
+			// Support: Firefox<29, Android 2.3
5703
+			// Vendor-prefix box-sizing
5704
+			"-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;" +
5705
+			"position:relative;display:block;" +
5706
+			"margin:auto;border:1px;padding:1px;" +
5707
+			"top:1%;width:50%";
5708
+		div.innerHTML = "";
5709
+		documentElement.appendChild( container );
5710
+
5711
+		var divStyle = window.getComputedStyle( div );
5712
+		pixelPositionVal = divStyle.top !== "1%";
5713
+		reliableMarginLeftVal = divStyle.marginLeft === "2px";
5714
+		boxSizingReliableVal = divStyle.width === "4px";
5715
+
5716
+		// Support: Android 4.0 - 4.3 only
5717
+		// Some styles come back with percentage values, even though they shouldn't
5718
+		div.style.marginRight = "50%";
5719
+		pixelMarginRightVal = divStyle.marginRight === "4px";
5720
+
5721
+		documentElement.removeChild( container );
5722
+	}
5723
+
5724
+	jQuery.extend( support, {
5725
+		pixelPosition: function() {
5726
+
5727
+			// This test is executed only once but we still do memoizing
5728
+			// since we can use the boxSizingReliable pre-computing.
5729
+			// No need to check if the test was already performed, though.
5730
+			computeStyleTests();
5731
+			return pixelPositionVal;
5732
+		},
5733
+		boxSizingReliable: function() {
5734
+			if ( boxSizingReliableVal == null ) {
5735
+				computeStyleTests();
5736
+			}
5737
+			return boxSizingReliableVal;
5738
+		},
5739
+		pixelMarginRight: function() {
5740
+
5741
+			// Support: Android 4.0-4.3
5742
+			// We're checking for boxSizingReliableVal here instead of pixelMarginRightVal
5743
+			// since that compresses better and they're computed together anyway.
5744
+			if ( boxSizingReliableVal == null ) {
5745
+				computeStyleTests();
5746
+			}
5747
+			return pixelMarginRightVal;
5748
+		},
5749
+		reliableMarginLeft: function() {
5750
+
5751
+			// Support: IE <=8 only, Android 4.0 - 4.3 only, Firefox <=3 - 37
5752
+			if ( boxSizingReliableVal == null ) {
5753
+				computeStyleTests();
5754
+			}
5755
+			return reliableMarginLeftVal;
5756
+		},
5757
+		reliableMarginRight: function() {
5758
+
5759
+			// Support: Android 2.3
5760
+			// Check if div with explicit width and no margin-right incorrectly
5761
+			// gets computed margin-right based on width of container. (#3333)
5762
+			// WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
5763
+			// This support function is only executed once so no memoizing is needed.
5764
+			var ret,
5765
+				marginDiv = div.appendChild( document.createElement( "div" ) );
5766
+
5767
+			// Reset CSS: box-sizing; display; margin; border; padding
5768
+			marginDiv.style.cssText = div.style.cssText =
5769
+
5770
+				// Support: Android 2.3
5771
+				// Vendor-prefix box-sizing
5772
+				"-webkit-box-sizing:content-box;box-sizing:content-box;" +
5773
+				"display:block;margin:0;border:0;padding:0";
5774
+			marginDiv.style.marginRight = marginDiv.style.width = "0";
5775
+			div.style.width = "1px";
5776
+			documentElement.appendChild( container );
5777
+
5778
+			ret = !parseFloat( window.getComputedStyle( marginDiv ).marginRight );
5779
+
5780
+			documentElement.removeChild( container );
5781
+			div.removeChild( marginDiv );
5782
+
5783
+			return ret;
5784
+		}
5785
+	} );
5786
+} )();
5787
+
5788
+
5789
+function curCSS( elem, name, computed ) {
5790
+	var width, minWidth, maxWidth, ret,
5791
+		style = elem.style;
5792
+
5793
+	computed = computed || getStyles( elem );
5794
+
5795
+	// Support: IE9
5796
+	// getPropertyValue is only needed for .css('filter') (#12537)
5797
+	if ( computed ) {
5798
+		ret = computed.getPropertyValue( name ) || computed[ name ];
5799
+
5800
+		if ( ret === "" && !jQuery.contains( elem.ownerDocument, elem ) ) {
5801
+			ret = jQuery.style( elem, name );
5802
+		}
5803
+
5804
+		// A tribute to the "awesome hack by Dean Edwards"
5805
+		// Android Browser returns percentage for some values,
5806
+		// but width seems to be reliably pixels.
5807
+		// This is against the CSSOM draft spec:
5808
+		// http://dev.w3.org/csswg/cssom/#resolved-values
5809
+		if ( !support.pixelMarginRight() && rnumnonpx.test( ret ) && rmargin.test( name ) ) {
5810
+
5811
+			// Remember the original values
5812
+			width = style.width;
5813
+			minWidth = style.minWidth;
5814
+			maxWidth = style.maxWidth;
5815
+
5816
+			// Put in the new values to get a computed value out
5817
+			style.minWidth = style.maxWidth = style.width = ret;
5818
+			ret = computed.width;
5819
+
5820
+			// Revert the changed values
5821
+			style.width = width;
5822
+			style.minWidth = minWidth;
5823
+			style.maxWidth = maxWidth;
5824
+		}
5825
+	}
5826
+
5827
+	return ret !== undefined ?
5828
+
5829
+		// Support: IE9-11+
5830
+		// IE returns zIndex value as an integer.
5831
+		ret + "" :
5832
+		ret;
5833
+}
5834
+
5835
+
5836
+function addGetHookIf( conditionFn, hookFn ) {
5837
+
5838
+	// Define the hook, we'll check on the first run if it's really needed.
5839
+	return {
5840
+		get: function() {
5841
+			if ( conditionFn() ) {
5842
+
5843
+				// Hook not needed (or it's not possible to use it due
5844
+				// to missing dependency), remove it.
5845
+				delete this.get;
5846
+				return;
5847
+			}
5848
+
5849
+			// Hook needed; redefine it so that the support test is not executed again.
5850
+			return ( this.get = hookFn ).apply( this, arguments );
5851
+		}
5852
+	};
5853
+}
5854
+
5855
+
5856
+var
5857
+
5858
+	// Swappable if display is none or starts with table
5859
+	// except "table", "table-cell", or "table-caption"
5860
+	// See here for display values: https://developer.mozilla.org/en-US/docs/CSS/display
5861
+	rdisplayswap = /^(none|table(?!-c[ea]).+)/,
5862
+
5863
+	cssShow = { position: "absolute", visibility: "hidden", display: "block" },
5864
+	cssNormalTransform = {
5865
+		letterSpacing: "0",
5866
+		fontWeight: "400"
5867
+	},
5868
+
5869
+	cssPrefixes = [ "Webkit", "O", "Moz", "ms" ],
5870
+	emptyStyle = document.createElement( "div" ).style;
5871
+
5872
+// Return a css property mapped to a potentially vendor prefixed property
5873
+function vendorPropName( name ) {
5874
+
5875
+	// Shortcut for names that are not vendor prefixed
5876
+	if ( name in emptyStyle ) {
5877
+		return name;
5878
+	}
5879
+
5880
+	// Check for vendor prefixed names
5881
+	var capName = name[ 0 ].toUpperCase() + name.slice( 1 ),
5882
+		i = cssPrefixes.length;
5883
+
5884
+	while ( i-- ) {
5885
+		name = cssPrefixes[ i ] + capName;
5886
+		if ( name in emptyStyle ) {
5887
+			return name;
5888
+		}
5889
+	}
5890
+}
5891
+
5892
+function setPositiveNumber( elem, value, subtract ) {
5893
+
5894
+	// Any relative (+/-) values have already been
5895
+	// normalized at this point
5896
+	var matches = rcssNum.exec( value );
5897
+	return matches ?
5898
+
5899
+		// Guard against undefined "subtract", e.g., when used as in cssHooks
5900
+		Math.max( 0, matches[ 2 ] - ( subtract || 0 ) ) + ( matches[ 3 ] || "px" ) :
5901
+		value;
5902
+}
5903
+
5904
+function augmentWidthOrHeight( elem, name, extra, isBorderBox, styles ) {
5905
+	var i = extra === ( isBorderBox ? "border" : "content" ) ?
5906
+
5907
+		// If we already have the right measurement, avoid augmentation
5908
+		4 :
5909
+
5910
+		// Otherwise initialize for horizontal or vertical properties
5911
+		name === "width" ? 1 : 0,
5912
+
5913
+		val = 0;
5914
+
5915
+	for ( ; i < 4; i += 2 ) {
5916
+
5917
+		// Both box models exclude margin, so add it if we want it
5918
+		if ( extra === "margin" ) {
5919
+			val += jQuery.css( elem, extra + cssExpand[ i ], true, styles );
5920
+		}
5921
+
5922
+		if ( isBorderBox ) {
5923
+
5924
+			// border-box includes padding, so remove it if we want content
5925
+			if ( extra === "content" ) {
5926
+				val -= jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );
5927
+			}
5928
+
5929
+			// At this point, extra isn't border nor margin, so remove border
5930
+			if ( extra !== "margin" ) {
5931
+				val -= jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );
5932
+			}
5933
+		} else {
5934
+
5935
+			// At this point, extra isn't content, so add padding
5936
+			val += jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );
5937
+
5938
+			// At this point, extra isn't content nor padding, so add border
5939
+			if ( extra !== "padding" ) {
5940
+				val += jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );
5941
+			}
5942
+		}
5943
+	}
5944
+
5945
+	return val;
5946
+}
5947
+
5948
+function getWidthOrHeight( elem, name, extra ) {
5949
+
5950
+	// Start with offset property, which is equivalent to the border-box value
5951
+	var valueIsBorderBox = true,
5952
+		val = name === "width" ? elem.offsetWidth : elem.offsetHeight,
5953
+		styles = getStyles( elem ),
5954
+		isBorderBox = jQuery.css( elem, "boxSizing", false, styles ) === "border-box";
5955
+
5956
+	// Support: IE11 only
5957
+	// In IE 11 fullscreen elements inside of an iframe have
5958
+	// 100x too small dimensions (gh-1764).
5959
+	if ( document.msFullscreenElement && window.top !== window ) {
5960
+
5961
+		// Support: IE11 only
5962
+		// Running getBoundingClientRect on a disconnected node
5963
+		// in IE throws an error.
5964
+		if ( elem.getClientRects().length ) {
5965
+			val = Math.round( elem.getBoundingClientRect()[ name ] * 100 );
5966
+		}
5967
+	}
5968
+
5969
+	// Some non-html elements return undefined for offsetWidth, so check for null/undefined
5970
+	// svg - https://bugzilla.mozilla.org/show_bug.cgi?id=649285
5971
+	// MathML - https://bugzilla.mozilla.org/show_bug.cgi?id=491668
5972
+	if ( val <= 0 || val == null ) {
5973
+
5974
+		// Fall back to computed then uncomputed css if necessary
5975
+		val = curCSS( elem, name, styles );
5976
+		if ( val < 0 || val == null ) {
5977
+			val = elem.style[ name ];
5978
+		}
5979
+
5980
+		// Computed unit is not pixels. Stop here and return.
5981
+		if ( rnumnonpx.test( val ) ) {
5982
+			return val;
5983
+		}
5984
+
5985
+		// Check for style in case a browser which returns unreliable values
5986
+		// for getComputedStyle silently falls back to the reliable elem.style
5987
+		valueIsBorderBox = isBorderBox &&
5988
+			( support.boxSizingReliable() || val === elem.style[ name ] );
5989
+
5990
+		// Normalize "", auto, and prepare for extra
5991
+		val = parseFloat( val ) || 0;
5992
+	}
5993
+
5994
+	// Use the active box-sizing model to add/subtract irrelevant styles
5995
+	return ( val +
5996
+		augmentWidthOrHeight(
5997
+			elem,
5998
+			name,
5999
+			extra || ( isBorderBox ? "border" : "content" ),
6000
+			valueIsBorderBox,
6001
+			styles
6002
+		)
6003
+	) + "px";
6004
+}
6005
+
6006
+function showHide( elements, show ) {
6007
+	var display, elem, hidden,
6008
+		values = [],
6009
+		index = 0,
6010
+		length = elements.length;
6011
+
6012
+	for ( ; index < length; index++ ) {
6013
+		elem = elements[ index ];
6014
+		if ( !elem.style ) {
6015
+			continue;
6016
+		}
6017
+
6018
+		values[ index ] = dataPriv.get( elem, "olddisplay" );
6019
+		display = elem.style.display;
6020
+		if ( show ) {
6021
+
6022
+			// Reset the inline display of this element to learn if it is
6023
+			// being hidden by cascaded rules or not
6024
+			if ( !values[ index ] && display === "none" ) {
6025
+				elem.style.display = "";
6026
+			}
6027
+
6028
+			// Set elements which have been overridden with display: none
6029
+			// in a stylesheet to whatever the default browser style is
6030
+			// for such an element
6031
+			if ( elem.style.display === "" && isHidden( elem ) ) {
6032
+				values[ index ] = dataPriv.access(
6033
+					elem,
6034
+					"olddisplay",
6035
+					defaultDisplay( elem.nodeName )
6036
+				);
6037
+			}
6038
+		} else {
6039
+			hidden = isHidden( elem );
6040
+
6041
+			if ( display !== "none" || !hidden ) {
6042
+				dataPriv.set(
6043
+					elem,
6044
+					"olddisplay",
6045
+					hidden ? display : jQuery.css( elem, "display" )
6046
+				);
6047
+			}
6048
+		}
6049
+	}
6050
+
6051
+	// Set the display of most of the elements in a second loop
6052
+	// to avoid the constant reflow
6053
+	for ( index = 0; index < length; index++ ) {
6054
+		elem = elements[ index ];
6055
+		if ( !elem.style ) {
6056
+			continue;
6057
+		}
6058
+		if ( !show || elem.style.display === "none" || elem.style.display === "" ) {
6059
+			elem.style.display = show ? values[ index ] || "" : "none";
6060
+		}
6061
+	}
6062
+
6063
+	return elements;
6064
+}
6065
+
6066
+jQuery.extend( {
6067
+
6068
+	// Add in style property hooks for overriding the default
6069
+	// behavior of getting and setting a style property
6070
+	cssHooks: {
6071
+		opacity: {
6072
+			get: function( elem, computed ) {
6073
+				if ( computed ) {
6074
+
6075
+					// We should always get a number back from opacity
6076
+					var ret = curCSS( elem, "opacity" );
6077
+					return ret === "" ? "1" : ret;
6078
+				}
6079
+			}
6080
+		}
6081
+	},
6082
+
6083
+	// Don't automatically add "px" to these possibly-unitless properties
6084
+	cssNumber: {
6085
+		"animationIterationCount": true,
6086
+		"columnCount": true,
6087
+		"fillOpacity": true,
6088
+		"flexGrow": true,
6089
+		"flexShrink": true,
6090
+		"fontWeight": true,
6091
+		"lineHeight": true,
6092
+		"opacity": true,
6093
+		"order": true,
6094
+		"orphans": true,
6095
+		"widows": true,
6096
+		"zIndex": true,
6097
+		"zoom": true
6098
+	},
6099
+
6100
+	// Add in properties whose names you wish to fix before
6101
+	// setting or getting the value
6102
+	cssProps: {
6103
+		"float": "cssFloat"
6104
+	},
6105
+
6106
+	// Get and set the style property on a DOM Node
6107
+	style: function( elem, name, value, extra ) {
6108
+
6109
+		// Don't set styles on text and comment nodes
6110
+		if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {
6111
+			return;
6112
+		}
6113
+
6114
+		// Make sure that we're working with the right name
6115
+		var ret, type, hooks,
6116
+			origName = jQuery.camelCase( name ),
6117
+			style = elem.style;
6118
+
6119
+		name = jQuery.cssProps[ origName ] ||
6120
+			( jQuery.cssProps[ origName ] = vendorPropName( origName ) || origName );
6121
+
6122
+		// Gets hook for the prefixed version, then unprefixed version
6123
+		hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];
6124
+
6125
+		// Check if we're setting a value
6126
+		if ( value !== undefined ) {
6127
+			type = typeof value;
6128
+
6129
+			// Convert "+=" or "-=" to relative numbers (#7345)
6130
+			if ( type === "string" && ( ret = rcssNum.exec( value ) ) && ret[ 1 ] ) {
6131
+				value = adjustCSS( elem, name, ret );
6132
+
6133
+				// Fixes bug #9237
6134
+				type = "number";
6135
+			}
6136
+
6137
+			// Make sure that null and NaN values aren't set (#7116)
6138
+			if ( value == null || value !== value ) {
6139
+				return;
6140
+			}
6141
+
6142
+			// If a number was passed in, add the unit (except for certain CSS properties)
6143
+			if ( type === "number" ) {
6144
+				value += ret && ret[ 3 ] || ( jQuery.cssNumber[ origName ] ? "" : "px" );
6145
+			}
6146
+
6147
+			// Support: IE9-11+
6148
+			// background-* props affect original clone's values
6149
+			if ( !support.clearCloneStyle && value === "" && name.indexOf( "background" ) === 0 ) {
6150
+				style[ name ] = "inherit";
6151
+			}
6152
+
6153
+			// If a hook was provided, use that value, otherwise just set the specified value
6154
+			if ( !hooks || !( "set" in hooks ) ||
6155
+				( value = hooks.set( elem, value, extra ) ) !== undefined ) {
6156
+
6157
+				style[ name ] = value;
6158
+			}
6159
+
6160
+		} else {
6161
+
6162
+			// If a hook was provided get the non-computed value from there
6163
+			if ( hooks && "get" in hooks &&
6164
+				( ret = hooks.get( elem, false, extra ) ) !== undefined ) {
6165
+
6166
+				return ret;
6167
+			}
6168
+
6169
+			// Otherwise just get the value from the style object
6170
+			return style[ name ];
6171
+		}
6172
+	},
6173
+
6174
+	css: function( elem, name, extra, styles ) {
6175
+		var val, num, hooks,
6176
+			origName = jQuery.camelCase( name );
6177
+
6178
+		// Make sure that we're working with the right name
6179
+		name = jQuery.cssProps[ origName ] ||
6180
+			( jQuery.cssProps[ origName ] = vendorPropName( origName ) || origName );
6181
+
6182
+		// Try prefixed name followed by the unprefixed name
6183
+		hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];
6184
+
6185
+		// If a hook was provided get the computed value from there
6186
+		if ( hooks && "get" in hooks ) {
6187
+			val = hooks.get( elem, true, extra );
6188
+		}
6189
+
6190
+		// Otherwise, if a way to get the computed value exists, use that
6191
+		if ( val === undefined ) {
6192
+			val = curCSS( elem, name, styles );
6193
+		}
6194
+
6195
+		// Convert "normal" to computed value
6196
+		if ( val === "normal" && name in cssNormalTransform ) {
6197
+			val = cssNormalTransform[ name ];
6198
+		}
6199
+
6200
+		// Make numeric if forced or a qualifier was provided and val looks numeric
6201
+		if ( extra === "" || extra ) {
6202
+			num = parseFloat( val );
6203
+			return extra === true || isFinite( num ) ? num || 0 : val;
6204
+		}
6205
+		return val;
6206
+	}
6207
+} );
6208
+
6209
+jQuery.each( [ "height", "width" ], function( i, name ) {
6210
+	jQuery.cssHooks[ name ] = {
6211
+		get: function( elem, computed, extra ) {
6212
+			if ( computed ) {
6213
+
6214
+				// Certain elements can have dimension info if we invisibly show them
6215
+				// but it must have a current display style that would benefit
6216
+				return rdisplayswap.test( jQuery.css( elem, "display" ) ) &&
6217
+					elem.offsetWidth === 0 ?
6218
+						swap( elem, cssShow, function() {
6219
+							return getWidthOrHeight( elem, name, extra );
6220
+						} ) :
6221
+						getWidthOrHeight( elem, name, extra );
6222
+			}
6223
+		},
6224
+
6225
+		set: function( elem, value, extra ) {
6226
+			var matches,
6227
+				styles = extra && getStyles( elem ),
6228
+				subtract = extra && augmentWidthOrHeight(
6229
+					elem,
6230
+					name,
6231
+					extra,
6232
+					jQuery.css( elem, "boxSizing", false, styles ) === "border-box",
6233
+					styles
6234
+				);
6235
+
6236
+			// Convert to pixels if value adjustment is needed
6237
+			if ( subtract && ( matches = rcssNum.exec( value ) ) &&
6238
+				( matches[ 3 ] || "px" ) !== "px" ) {
6239
+
6240
+				elem.style[ name ] = value;
6241
+				value = jQuery.css( elem, name );
6242
+			}
6243
+
6244
+			return setPositiveNumber( elem, value, subtract );
6245
+		}
6246
+	};
6247
+} );
6248
+
6249
+jQuery.cssHooks.marginLeft = addGetHookIf( support.reliableMarginLeft,
6250
+	function( elem, computed ) {
6251
+		if ( computed ) {
6252
+			return ( parseFloat( curCSS( elem, "marginLeft" ) ) ||
6253
+				elem.getBoundingClientRect().left -
6254
+					swap( elem, { marginLeft: 0 }, function() {
6255
+						return elem.getBoundingClientRect().left;
6256
+					} )
6257
+				) + "px";
6258
+		}
6259
+	}
6260
+);
6261
+
6262
+// Support: Android 2.3
6263
+jQuery.cssHooks.marginRight = addGetHookIf( support.reliableMarginRight,
6264
+	function( elem, computed ) {
6265
+		if ( computed ) {
6266
+			return swap( elem, { "display": "inline-block" },
6267
+				curCSS, [ elem, "marginRight" ] );
6268
+		}
6269
+	}
6270
+);
6271
+
6272
+// These hooks are used by animate to expand properties
6273
+jQuery.each( {
6274
+	margin: "",
6275
+	padding: "",
6276
+	border: "Width"
6277
+}, function( prefix, suffix ) {
6278
+	jQuery.cssHooks[ prefix + suffix ] = {
6279
+		expand: function( value ) {
6280
+			var i = 0,
6281
+				expanded = {},
6282
+
6283
+				// Assumes a single number if not a string
6284
+				parts = typeof value === "string" ? value.split( " " ) : [ value ];
6285
+
6286
+			for ( ; i < 4; i++ ) {
6287
+				expanded[ prefix + cssExpand[ i ] + suffix ] =
6288
+					parts[ i ] || parts[ i - 2 ] || parts[ 0 ];
6289
+			}
6290
+
6291
+			return expanded;
6292
+		}
6293
+	};
6294
+
6295
+	if ( !rmargin.test( prefix ) ) {
6296
+		jQuery.cssHooks[ prefix + suffix ].set = setPositiveNumber;
6297
+	}
6298
+} );
6299
+
6300
+jQuery.fn.extend( {
6301
+	css: function( name, value ) {
6302
+		return access( this, function( elem, name, value ) {
6303
+			var styles, len,
6304
+				map = {},
6305
+				i = 0;
6306
+
6307
+			if ( jQuery.isArray( name ) ) {
6308
+				styles = getStyles( elem );
6309
+				len = name.length;
6310
+
6311
+				for ( ; i < len; i++ ) {
6312
+					map[ name[ i ] ] = jQuery.css( elem, name[ i ], false, styles );
6313
+				}
6314
+
6315
+				return map;
6316
+			}
6317
+
6318
+			return value !== undefined ?
6319
+				jQuery.style( elem, name, value ) :
6320
+				jQuery.css( elem, name );
6321
+		}, name, value, arguments.length > 1 );
6322
+	},
6323
+	show: function() {
6324
+		return showHide( this, true );
6325
+	},
6326
+	hide: function() {
6327
+		return showHide( this );
6328
+	},
6329
+	toggle: function( state ) {
6330
+		if ( typeof state === "boolean" ) {
6331
+			return state ? this.show() : this.hide();
6332
+		}
6333
+
6334
+		return this.each( function() {
6335
+			if ( isHidden( this ) ) {
6336
+				jQuery( this ).show();
6337
+			} else {
6338
+				jQuery( this ).hide();
6339
+			}
6340
+		} );
6341
+	}
6342
+} );
6343
+
6344
+
6345
+function Tween( elem, options, prop, end, easing ) {
6346
+	return new Tween.prototype.init( elem, options, prop, end, easing );
6347
+}
6348
+jQuery.Tween = Tween;
6349
+
6350
+Tween.prototype = {
6351
+	constructor: Tween,
6352
+	init: function( elem, options, prop, end, easing, unit ) {
6353
+		this.elem = elem;
6354
+		this.prop = prop;
6355
+		this.easing = easing || jQuery.easing._default;
6356
+		this.options = options;
6357
+		this.start = this.now = this.cur();
6358
+		this.end = end;
6359
+		this.unit = unit || ( jQuery.cssNumber[ prop ] ? "" : "px" );
6360
+	},
6361
+	cur: function() {
6362
+		var hooks = Tween.propHooks[ this.prop ];
6363
+
6364
+		return hooks && hooks.get ?
6365
+			hooks.get( this ) :
6366
+			Tween.propHooks._default.get( this );
6367
+	},
6368
+	run: function( percent ) {
6369
+		var eased,
6370
+			hooks = Tween.propHooks[ this.prop ];
6371
+
6372
+		if ( this.options.duration ) {
6373
+			this.pos = eased = jQuery.easing[ this.easing ](
6374
+				percent, this.options.duration * percent, 0, 1, this.options.duration
6375
+			);
6376
+		} else {
6377
+			this.pos = eased = percent;
6378
+		}
6379
+		this.now = ( this.end - this.start ) * eased + this.start;
6380
+
6381
+		if ( this.options.step ) {
6382
+			this.options.step.call( this.elem, this.now, this );
6383
+		}
6384
+
6385
+		if ( hooks && hooks.set ) {
6386
+			hooks.set( this );
6387
+		} else {
6388
+			Tween.propHooks._default.set( this );
6389
+		}
6390
+		return this;
6391
+	}
6392
+};
6393
+
6394
+Tween.prototype.init.prototype = Tween.prototype;
6395
+
6396
+Tween.propHooks = {
6397
+	_default: {
6398
+		get: function( tween ) {
6399
+			var result;
6400
+
6401
+			// Use a property on the element directly when it is not a DOM element,
6402
+			// or when there is no matching style property that exists.
6403
+			if ( tween.elem.nodeType !== 1 ||
6404
+				tween.elem[ tween.prop ] != null && tween.elem.style[ tween.prop ] == null ) {
6405
+				return tween.elem[ tween.prop ];
6406
+			}
6407
+
6408
+			// Passing an empty string as a 3rd parameter to .css will automatically
6409
+			// attempt a parseFloat and fallback to a string if the parse fails.
6410
+			// Simple values such as "10px" are parsed to Float;
6411
+			// complex values such as "rotate(1rad)" are returned as-is.
6412
+			result = jQuery.css( tween.elem, tween.prop, "" );
6413
+
6414
+			// Empty strings, null, undefined and "auto" are converted to 0.
6415
+			return !result || result === "auto" ? 0 : result;
6416
+		},
6417
+		set: function( tween ) {
6418
+
6419
+			// Use step hook for back compat.
6420
+			// Use cssHook if its there.
6421
+			// Use .style if available and use plain properties where available.
6422
+			if ( jQuery.fx.step[ tween.prop ] ) {
6423
+				jQuery.fx.step[ tween.prop ]( tween );
6424
+			} else if ( tween.elem.nodeType === 1 &&
6425
+				( tween.elem.style[ jQuery.cssProps[ tween.prop ] ] != null ||
6426
+					jQuery.cssHooks[ tween.prop ] ) ) {
6427
+				jQuery.style( tween.elem, tween.prop, tween.now + tween.unit );
6428
+			} else {
6429
+				tween.elem[ tween.prop ] = tween.now;
6430
+			}
6431
+		}
6432
+	}
6433
+};
6434
+
6435
+// Support: IE9
6436
+// Panic based approach to setting things on disconnected nodes
6437
+Tween.propHooks.scrollTop = Tween.propHooks.scrollLeft = {
6438
+	set: function( tween ) {
6439
+		if ( tween.elem.nodeType && tween.elem.parentNode ) {
6440
+			tween.elem[ tween.prop ] = tween.now;
6441
+		}
6442
+	}
6443
+};
6444
+
6445
+jQuery.easing = {
6446
+	linear: function( p ) {
6447
+		return p;
6448
+	},
6449
+	swing: function( p ) {
6450
+		return 0.5 - Math.cos( p * Math.PI ) / 2;
6451
+	},
6452
+	_default: "swing"
6453
+};
6454
+
6455
+jQuery.fx = Tween.prototype.init;
6456
+
6457
+// Back Compat <1.8 extension point
6458
+jQuery.fx.step = {};
6459
+
6460
+
6461
+
6462
+
6463
+var
6464
+	fxNow, timerId,
6465
+	rfxtypes = /^(?:toggle|show|hide)$/,
6466
+	rrun = /queueHooks$/;
6467
+
6468
+// Animations created synchronously will run synchronously
6469
+function createFxNow() {
6470
+	window.setTimeout( function() {
6471
+		fxNow = undefined;
6472
+	} );
6473
+	return ( fxNow = jQuery.now() );
6474
+}
6475
+
6476
+// Generate parameters to create a standard animation
6477
+function genFx( type, includeWidth ) {
6478
+	var which,
6479
+		i = 0,
6480
+		attrs = { height: type };
6481
+
6482
+	// If we include width, step value is 1 to do all cssExpand values,
6483
+	// otherwise step value is 2 to skip over Left and Right
6484
+	includeWidth = includeWidth ? 1 : 0;
6485
+	for ( ; i < 4 ; i += 2 - includeWidth ) {
6486
+		which = cssExpand[ i ];
6487
+		attrs[ "margin" + which ] = attrs[ "padding" + which ] = type;
6488
+	}
6489
+
6490
+	if ( includeWidth ) {
6491
+		attrs.opacity = attrs.width = type;
6492
+	}
6493
+
6494
+	return attrs;
6495
+}
6496
+
6497
+function createTween( value, prop, animation ) {
6498
+	var tween,
6499
+		collection = ( Animation.tweeners[ prop ] || [] ).concat( Animation.tweeners[ "*" ] ),
6500
+		index = 0,
6501
+		length = collection.length;
6502
+	for ( ; index < length; index++ ) {
6503
+		if ( ( tween = collection[ index ].call( animation, prop, value ) ) ) {
6504
+
6505
+			// We're done with this property
6506
+			return tween;
6507
+		}
6508
+	}
6509
+}
6510
+
6511
+function defaultPrefilter( elem, props, opts ) {
6512
+	/* jshint validthis: true */
6513
+	var prop, value, toggle, tween, hooks, oldfire, display, checkDisplay,
6514
+		anim = this,
6515
+		orig = {},
6516
+		style = elem.style,
6517
+		hidden = elem.nodeType && isHidden( elem ),
6518
+		dataShow = dataPriv.get( elem, "fxshow" );
6519
+
6520
+	// Handle queue: false promises
6521
+	if ( !opts.queue ) {
6522
+		hooks = jQuery._queueHooks( elem, "fx" );
6523
+		if ( hooks.unqueued == null ) {
6524
+			hooks.unqueued = 0;
6525
+			oldfire = hooks.empty.fire;
6526
+			hooks.empty.fire = function() {
6527
+				if ( !hooks.unqueued ) {
6528
+					oldfire();
6529
+				}
6530
+			};
6531
+		}
6532
+		hooks.unqueued++;
6533
+
6534
+		anim.always( function() {
6535
+
6536
+			// Ensure the complete handler is called before this completes
6537
+			anim.always( function() {
6538
+				hooks.unqueued--;
6539
+				if ( !jQuery.queue( elem, "fx" ).length ) {
6540
+					hooks.empty.fire();
6541
+				}
6542
+			} );
6543
+		} );
6544
+	}
6545
+
6546
+	// Height/width overflow pass
6547
+	if ( elem.nodeType === 1 && ( "height" in props || "width" in props ) ) {
6548
+
6549
+		// Make sure that nothing sneaks out
6550
+		// Record all 3 overflow attributes because IE9-10 do not
6551
+		// change the overflow attribute when overflowX and
6552
+		// overflowY are set to the same value
6553
+		opts.overflow = [ style.overflow, style.overflowX, style.overflowY ];
6554
+
6555
+		// Set display property to inline-block for height/width
6556
+		// animations on inline elements that are having width/height animated
6557
+		display = jQuery.css( elem, "display" );
6558
+
6559
+		// Test default display if display is currently "none"
6560
+		checkDisplay = display === "none" ?
6561
+			dataPriv.get( elem, "olddisplay" ) || defaultDisplay( elem.nodeName ) : display;
6562
+
6563
+		if ( checkDisplay === "inline" && jQuery.css( elem, "float" ) === "none" ) {
6564
+			style.display = "inline-block";
6565
+		}
6566
+	}
6567
+
6568
+	if ( opts.overflow ) {
6569
+		style.overflow = "hidden";
6570
+		anim.always( function() {
6571
+			style.overflow = opts.overflow[ 0 ];
6572
+			style.overflowX = opts.overflow[ 1 ];
6573
+			style.overflowY = opts.overflow[ 2 ];
6574
+		} );
6575
+	}
6576
+
6577
+	// show/hide pass
6578
+	for ( prop in props ) {
6579
+		value = props[ prop ];
6580
+		if ( rfxtypes.exec( value ) ) {
6581
+			delete props[ prop ];
6582
+			toggle = toggle || value === "toggle";
6583
+			if ( value === ( hidden ? "hide" : "show" ) ) {
6584
+
6585
+				// If there is dataShow left over from a stopped hide or show
6586
+				// and we are going to proceed with show, we should pretend to be hidden
6587
+				if ( value === "show" && dataShow && dataShow[ prop ] !== undefined ) {
6588
+					hidden = true;
6589
+				} else {
6590
+					continue;
6591
+				}
6592
+			}
6593
+			orig[ prop ] = dataShow && dataShow[ prop ] || jQuery.style( elem, prop );
6594
+
6595
+		// Any non-fx value stops us from restoring the original display value
6596
+		} else {
6597
+			display = undefined;
6598
+		}
6599
+	}
6600
+
6601
+	if ( !jQuery.isEmptyObject( orig ) ) {
6602
+		if ( dataShow ) {
6603
+			if ( "hidden" in dataShow ) {
6604
+				hidden = dataShow.hidden;
6605
+			}
6606
+		} else {
6607
+			dataShow = dataPriv.access( elem, "fxshow", {} );
6608
+		}
6609
+
6610
+		// Store state if its toggle - enables .stop().toggle() to "reverse"
6611
+		if ( toggle ) {
6612
+			dataShow.hidden = !hidden;
6613
+		}
6614
+		if ( hidden ) {
6615
+			jQuery( elem ).show();
6616
+		} else {
6617
+			anim.done( function() {
6618
+				jQuery( elem ).hide();
6619
+			} );
6620
+		}
6621
+		anim.done( function() {
6622
+			var prop;
6623
+
6624
+			dataPriv.remove( elem, "fxshow" );
6625
+			for ( prop in orig ) {
6626
+				jQuery.style( elem, prop, orig[ prop ] );
6627
+			}
6628
+		} );
6629
+		for ( prop in orig ) {
6630
+			tween = createTween( hidden ? dataShow[ prop ] : 0, prop, anim );
6631
+
6632
+			if ( !( prop in dataShow ) ) {
6633
+				dataShow[ prop ] = tween.start;
6634
+				if ( hidden ) {
6635
+					tween.end = tween.start;
6636
+					tween.start = prop === "width" || prop === "height" ? 1 : 0;
6637
+				}
6638
+			}
6639
+		}
6640
+
6641
+	// If this is a noop like .hide().hide(), restore an overwritten display value
6642
+	} else if ( ( display === "none" ? defaultDisplay( elem.nodeName ) : display ) === "inline" ) {
6643
+		style.display = display;
6644
+	}
6645
+}
6646
+
6647
+function propFilter( props, specialEasing ) {
6648
+	var index, name, easing, value, hooks;
6649
+
6650
+	// camelCase, specialEasing and expand cssHook pass
6651
+	for ( index in props ) {
6652
+		name = jQuery.camelCase( index );
6653
+		easing = specialEasing[ name ];
6654
+		value = props[ index ];
6655
+		if ( jQuery.isArray( value ) ) {
6656
+			easing = value[ 1 ];
6657
+			value = props[ index ] = value[ 0 ];
6658
+		}
6659
+
6660
+		if ( index !== name ) {
6661
+			props[ name ] = value;
6662
+			delete props[ index ];
6663
+		}
6664
+
6665
+		hooks = jQuery.cssHooks[ name ];
6666
+		if ( hooks && "expand" in hooks ) {
6667
+			value = hooks.expand( value );
6668
+			delete props[ name ];
6669
+
6670
+			// Not quite $.extend, this won't overwrite existing keys.
6671
+			// Reusing 'index' because we have the correct "name"
6672
+			for ( index in value ) {
6673
+				if ( !( index in props ) ) {
6674
+					props[ index ] = value[ index ];
6675
+					specialEasing[ index ] = easing;
6676
+				}
6677
+			}
6678
+		} else {
6679
+			specialEasing[ name ] = easing;
6680
+		}
6681
+	}
6682
+}
6683
+
6684
+function Animation( elem, properties, options ) {
6685
+	var result,
6686
+		stopped,
6687
+		index = 0,
6688
+		length = Animation.prefilters.length,
6689
+		deferred = jQuery.Deferred().always( function() {
6690
+
6691
+			// Don't match elem in the :animated selector
6692
+			delete tick.elem;
6693
+		} ),
6694
+		tick = function() {
6695
+			if ( stopped ) {
6696
+				return false;
6697
+			}
6698
+			var currentTime = fxNow || createFxNow(),
6699
+				remaining = Math.max( 0, animation.startTime + animation.duration - currentTime ),
6700
+
6701
+				// Support: Android 2.3
6702
+				// Archaic crash bug won't allow us to use `1 - ( 0.5 || 0 )` (#12497)
6703
+				temp = remaining / animation.duration || 0,
6704
+				percent = 1 - temp,
6705
+				index = 0,
6706
+				length = animation.tweens.length;
6707
+
6708
+			for ( ; index < length ; index++ ) {
6709
+				animation.tweens[ index ].run( percent );
6710
+			}
6711
+
6712
+			deferred.notifyWith( elem, [ animation, percent, remaining ] );
6713
+
6714
+			if ( percent < 1 && length ) {
6715
+				return remaining;
6716
+			} else {
6717
+				deferred.resolveWith( elem, [ animation ] );
6718
+				return false;
6719
+			}
6720
+		},
6721
+		animation = deferred.promise( {
6722
+			elem: elem,
6723
+			props: jQuery.extend( {}, properties ),
6724
+			opts: jQuery.extend( true, {
6725
+				specialEasing: {},
6726
+				easing: jQuery.easing._default
6727
+			}, options ),
6728
+			originalProperties: properties,
6729
+			originalOptions: options,
6730
+			startTime: fxNow || createFxNow(),
6731
+			duration: options.duration,
6732
+			tweens: [],
6733
+			createTween: function( prop, end ) {
6734
+				var tween = jQuery.Tween( elem, animation.opts, prop, end,
6735
+						animation.opts.specialEasing[ prop ] || animation.opts.easing );
6736
+				animation.tweens.push( tween );
6737
+				return tween;
6738
+			},
6739
+			stop: function( gotoEnd ) {
6740
+				var index = 0,
6741
+
6742
+					// If we are going to the end, we want to run all the tweens
6743
+					// otherwise we skip this part
6744
+					length = gotoEnd ? animation.tweens.length : 0;
6745
+				if ( stopped ) {
6746
+					return this;
6747
+				}
6748
+				stopped = true;
6749
+				for ( ; index < length ; index++ ) {
6750
+					animation.tweens[ index ].run( 1 );
6751
+				}
6752
+
6753
+				// Resolve when we played the last frame; otherwise, reject
6754
+				if ( gotoEnd ) {
6755
+					deferred.notifyWith( elem, [ animation, 1, 0 ] );
6756
+					deferred.resolveWith( elem, [ animation, gotoEnd ] );
6757
+				} else {
6758
+					deferred.rejectWith( elem, [ animation, gotoEnd ] );
6759
+				}
6760
+				return this;
6761
+			}
6762
+		} ),
6763
+		props = animation.props;
6764
+
6765
+	propFilter( props, animation.opts.specialEasing );
6766
+
6767
+	for ( ; index < length ; index++ ) {
6768
+		result = Animation.prefilters[ index ].call( animation, elem, props, animation.opts );
6769
+		if ( result ) {
6770
+			if ( jQuery.isFunction( result.stop ) ) {
6771
+				jQuery._queueHooks( animation.elem, animation.opts.queue ).stop =
6772
+					jQuery.proxy( result.stop, result );
6773
+			}
6774
+			return result;
6775
+		}
6776
+	}
6777
+
6778
+	jQuery.map( props, createTween, animation );
6779
+
6780
+	if ( jQuery.isFunction( animation.opts.start ) ) {
6781
+		animation.opts.start.call( elem, animation );
6782
+	}
6783
+
6784
+	jQuery.fx.timer(
6785
+		jQuery.extend( tick, {
6786
+			elem: elem,
6787
+			anim: animation,
6788
+			queue: animation.opts.queue
6789
+		} )
6790
+	);
6791
+
6792
+	// attach callbacks from options
6793
+	return animation.progress( animation.opts.progress )
6794
+		.done( animation.opts.done, animation.opts.complete )
6795
+		.fail( animation.opts.fail )
6796
+		.always( animation.opts.always );
6797
+}
6798
+
6799
+jQuery.Animation = jQuery.extend( Animation, {
6800
+	tweeners: {
6801
+		"*": [ function( prop, value ) {
6802
+			var tween = this.createTween( prop, value );
6803
+			adjustCSS( tween.elem, prop, rcssNum.exec( value ), tween );
6804
+			return tween;
6805
+		} ]
6806
+	},
6807
+
6808
+	tweener: function( props, callback ) {
6809
+		if ( jQuery.isFunction( props ) ) {
6810
+			callback = props;
6811
+			props = [ "*" ];
6812
+		} else {
6813
+			props = props.match( rnotwhite );
6814
+		}
6815
+
6816
+		var prop,
6817
+			index = 0,
6818
+			length = props.length;
6819
+
6820
+		for ( ; index < length ; index++ ) {
6821
+			prop = props[ index ];
6822
+			Animation.tweeners[ prop ] = Animation.tweeners[ prop ] || [];
6823
+			Animation.tweeners[ prop ].unshift( callback );
6824
+		}
6825
+	},
6826
+
6827
+	prefilters: [ defaultPrefilter ],
6828
+
6829
+	prefilter: function( callback, prepend ) {
6830
+		if ( prepend ) {
6831
+			Animation.prefilters.unshift( callback );
6832
+		} else {
6833
+			Animation.prefilters.push( callback );
6834
+		}
6835
+	}
6836
+} );
6837
+
6838
+jQuery.speed = function( speed, easing, fn ) {
6839
+	var opt = speed && typeof speed === "object" ? jQuery.extend( {}, speed ) : {
6840
+		complete: fn || !fn && easing ||
6841
+			jQuery.isFunction( speed ) && speed,
6842
+		duration: speed,
6843
+		easing: fn && easing || easing && !jQuery.isFunction( easing ) && easing
6844
+	};
6845
+
6846
+	opt.duration = jQuery.fx.off ? 0 : typeof opt.duration === "number" ?
6847
+		opt.duration : opt.duration in jQuery.fx.speeds ?
6848
+			jQuery.fx.speeds[ opt.duration ] : jQuery.fx.speeds._default;
6849
+
6850
+	// Normalize opt.queue - true/undefined/null -> "fx"
6851
+	if ( opt.queue == null || opt.queue === true ) {
6852
+		opt.queue = "fx";
6853
+	}
6854
+
6855
+	// Queueing
6856
+	opt.old = opt.complete;
6857
+
6858
+	opt.complete = function() {
6859
+		if ( jQuery.isFunction( opt.old ) ) {
6860
+			opt.old.call( this );
6861
+		}
6862
+
6863
+		if ( opt.queue ) {
6864
+			jQuery.dequeue( this, opt.queue );
6865
+		}
6866
+	};
6867
+
6868
+	return opt;
6869
+};
6870
+
6871
+jQuery.fn.extend( {
6872
+	fadeTo: function( speed, to, easing, callback ) {
6873
+
6874
+		// Show any hidden elements after setting opacity to 0
6875
+		return this.filter( isHidden ).css( "opacity", 0 ).show()
6876
+
6877
+			// Animate to the value specified
6878
+			.end().animate( { opacity: to }, speed, easing, callback );
6879
+	},
6880
+	animate: function( prop, speed, easing, callback ) {
6881
+		var empty = jQuery.isEmptyObject( prop ),
6882
+			optall = jQuery.speed( speed, easing, callback ),
6883
+			doAnimation = function() {
6884
+
6885
+				// Operate on a copy of prop so per-property easing won't be lost
6886
+				var anim = Animation( this, jQuery.extend( {}, prop ), optall );
6887
+
6888
+				// Empty animations, or finishing resolves immediately
6889
+				if ( empty || dataPriv.get( this, "finish" ) ) {
6890
+					anim.stop( true );
6891
+				}
6892
+			};
6893
+			doAnimation.finish = doAnimation;
6894
+
6895
+		return empty || optall.queue === false ?
6896
+			this.each( doAnimation ) :
6897
+			this.queue( optall.queue, doAnimation );
6898
+	},
6899
+	stop: function( type, clearQueue, gotoEnd ) {
6900
+		var stopQueue = function( hooks ) {
6901
+			var stop = hooks.stop;
6902
+			delete hooks.stop;
6903
+			stop( gotoEnd );
6904
+		};
6905
+
6906
+		if ( typeof type !== "string" ) {
6907
+			gotoEnd = clearQueue;
6908
+			clearQueue = type;
6909
+			type = undefined;
6910
+		}
6911
+		if ( clearQueue && type !== false ) {
6912
+			this.queue( type || "fx", [] );
6913
+		}
6914
+
6915
+		return this.each( function() {
6916
+			var dequeue = true,
6917
+				index = type != null && type + "queueHooks",
6918
+				timers = jQuery.timers,
6919
+				data = dataPriv.get( this );
6920
+
6921
+			if ( index ) {
6922
+				if ( data[ index ] && data[ index ].stop ) {
6923
+					stopQueue( data[ index ] );
6924
+				}
6925
+			} else {
6926
+				for ( index in data ) {
6927
+					if ( data[ index ] && data[ index ].stop && rrun.test( index ) ) {
6928
+						stopQueue( data[ index ] );
6929
+					}
6930
+				}
6931
+			}
6932
+
6933
+			for ( index = timers.length; index--; ) {
6934
+				if ( timers[ index ].elem === this &&
6935
+					( type == null || timers[ index ].queue === type ) ) {
6936
+
6937
+					timers[ index ].anim.stop( gotoEnd );
6938
+					dequeue = false;
6939
+					timers.splice( index, 1 );
6940
+				}
6941
+			}
6942
+
6943
+			// Start the next in the queue if the last step wasn't forced.
6944
+			// Timers currently will call their complete callbacks, which
6945
+			// will dequeue but only if they were gotoEnd.
6946
+			if ( dequeue || !gotoEnd ) {
6947
+				jQuery.dequeue( this, type );
6948
+			}
6949
+		} );
6950
+	},
6951
+	finish: function( type ) {
6952
+		if ( type !== false ) {
6953
+			type = type || "fx";
6954
+		}
6955
+		return this.each( function() {
6956
+			var index,
6957
+				data = dataPriv.get( this ),
6958
+				queue = data[ type + "queue" ],
6959
+				hooks = data[ type + "queueHooks" ],
6960
+				timers = jQuery.timers,
6961
+				length = queue ? queue.length : 0;
6962
+
6963
+			// Enable finishing flag on private data
6964
+			data.finish = true;
6965
+
6966
+			// Empty the queue first
6967
+			jQuery.queue( this, type, [] );
6968
+
6969
+			if ( hooks && hooks.stop ) {
6970
+				hooks.stop.call( this, true );
6971
+			}
6972
+
6973
+			// Look for any active animations, and finish them
6974
+			for ( index = timers.length; index--; ) {
6975
+				if ( timers[ index ].elem === this && timers[ index ].queue === type ) {
6976
+					timers[ index ].anim.stop( true );
6977
+					timers.splice( index, 1 );
6978
+				}
6979
+			}
6980
+
6981
+			// Look for any animations in the old queue and finish them
6982
+			for ( index = 0; index < length; index++ ) {
6983
+				if ( queue[ index ] && queue[ index ].finish ) {
6984
+					queue[ index ].finish.call( this );
6985
+				}
6986
+			}
6987
+
6988
+			// Turn off finishing flag
6989
+			delete data.finish;
6990
+		} );
6991
+	}
6992
+} );
6993
+
6994
+jQuery.each( [ "toggle", "show", "hide" ], function( i, name ) {
6995
+	var cssFn = jQuery.fn[ name ];
6996
+	jQuery.fn[ name ] = function( speed, easing, callback ) {
6997
+		return speed == null || typeof speed === "boolean" ?
6998
+			cssFn.apply( this, arguments ) :
6999
+			this.animate( genFx( name, true ), speed, easing, callback );
7000
+	};
7001
+} );
7002
+
7003
+// Generate shortcuts for custom animations
7004
+jQuery.each( {
7005
+	slideDown: genFx( "show" ),
7006
+	slideUp: genFx( "hide" ),
7007
+	slideToggle: genFx( "toggle" ),
7008
+	fadeIn: { opacity: "show" },
7009
+	fadeOut: { opacity: "hide" },
7010
+	fadeToggle: { opacity: "toggle" }
7011
+}, function( name, props ) {
7012
+	jQuery.fn[ name ] = function( speed, easing, callback ) {
7013
+		return this.animate( props, speed, easing, callback );
7014
+	};
7015
+} );
7016
+
7017
+jQuery.timers = [];
7018
+jQuery.fx.tick = function() {
7019
+	var timer,
7020
+		i = 0,
7021
+		timers = jQuery.timers;
7022
+
7023
+	fxNow = jQuery.now();
7024
+
7025
+	for ( ; i < timers.length; i++ ) {
7026
+		timer = timers[ i ];
7027
+
7028
+		// Checks the timer has not already been removed
7029
+		if ( !timer() && timers[ i ] === timer ) {
7030
+			timers.splice( i--, 1 );
7031
+		}
7032
+	}
7033
+
7034
+	if ( !timers.length ) {
7035
+		jQuery.fx.stop();
7036
+	}
7037
+	fxNow = undefined;
7038
+};
7039
+
7040
+jQuery.fx.timer = function( timer ) {
7041
+	jQuery.timers.push( timer );
7042
+	if ( timer() ) {
7043
+		jQuery.fx.start();
7044
+	} else {
7045
+		jQuery.timers.pop();
7046
+	}
7047
+};
7048
+
7049
+jQuery.fx.interval = 13;
7050
+jQuery.fx.start = function() {
7051
+	if ( !timerId ) {
7052
+		timerId = window.setInterval( jQuery.fx.tick, jQuery.fx.interval );
7053
+	}
7054
+};
7055
+
7056
+jQuery.fx.stop = function() {
7057
+	window.clearInterval( timerId );
7058
+
7059
+	timerId = null;
7060
+};
7061
+
7062
+jQuery.fx.speeds = {
7063
+	slow: 600,
7064
+	fast: 200,
7065
+
7066
+	// Default speed
7067
+	_default: 400
7068
+};
7069
+
7070
+
7071
+// Based off of the plugin by Clint Helfers, with permission.
7072
+// http://web.archive.org/web/20100324014747/http://blindsignals.com/index.php/2009/07/jquery-delay/
7073
+jQuery.fn.delay = function( time, type ) {
7074
+	time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;
7075
+	type = type || "fx";
7076
+
7077
+	return this.queue( type, function( next, hooks ) {
7078
+		var timeout = window.setTimeout( next, time );
7079
+		hooks.stop = function() {
7080
+			window.clearTimeout( timeout );
7081
+		};
7082
+	} );
7083
+};
7084
+
7085
+
7086
+( function() {
7087
+	var input = document.createElement( "input" ),
7088
+		select = document.createElement( "select" ),
7089
+		opt = select.appendChild( document.createElement( "option" ) );
7090
+
7091
+	input.type = "checkbox";
7092
+
7093
+	// Support: iOS<=5.1, Android<=4.2+
7094
+	// Default value for a checkbox should be "on"
7095
+	support.checkOn = input.value !== "";
7096
+
7097
+	// Support: IE<=11+
7098
+	// Must access selectedIndex to make default options select
7099
+	support.optSelected = opt.selected;
7100
+
7101
+	// Support: Android<=2.3
7102
+	// Options inside disabled selects are incorrectly marked as disabled
7103
+	select.disabled = true;
7104
+	support.optDisabled = !opt.disabled;
7105
+
7106
+	// Support: IE<=11+
7107
+	// An input loses its value after becoming a radio
7108
+	input = document.createElement( "input" );
7109
+	input.value = "t";
7110
+	input.type = "radio";
7111
+	support.radioValue = input.value === "t";
7112
+} )();
7113
+
7114
+
7115
+var boolHook,
7116
+	attrHandle = jQuery.expr.attrHandle;
7117
+
7118
+jQuery.fn.extend( {
7119
+	attr: function( name, value ) {
7120
+		return access( this, jQuery.attr, name, value, arguments.length > 1 );
7121
+	},
7122
+
7123
+	removeAttr: function( name ) {
7124
+		return this.each( function() {
7125
+			jQuery.removeAttr( this, name );
7126
+		} );
7127
+	}
7128
+} );
7129
+
7130
+jQuery.extend( {
7131
+	attr: function( elem, name, value ) {
7132
+		var ret, hooks,
7133
+			nType = elem.nodeType;
7134
+
7135
+		// Don't get/set attributes on text, comment and attribute nodes
7136
+		if ( nType === 3 || nType === 8 || nType === 2 ) {
7137
+			return;
7138
+		}
7139
+
7140
+		// Fallback to prop when attributes are not supported
7141
+		if ( typeof elem.getAttribute === "undefined" ) {
7142
+			return jQuery.prop( elem, name, value );
7143
+		}
7144
+
7145
+		// All attributes are lowercase
7146
+		// Grab necessary hook if one is defined
7147
+		if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {
7148
+			name = name.toLowerCase();
7149
+			hooks = jQuery.attrHooks[ name ] ||
7150
+				( jQuery.expr.match.bool.test( name ) ? boolHook : undefined );
7151
+		}
7152
+
7153
+		if ( value !== undefined ) {
7154
+			if ( value === null ) {
7155
+				jQuery.removeAttr( elem, name );
7156
+				return;
7157
+			}
7158
+
7159
+			if ( hooks && "set" in hooks &&
7160
+				( ret = hooks.set( elem, value, name ) ) !== undefined ) {
7161
+				return ret;
7162
+			}
7163
+
7164
+			elem.setAttribute( name, value + "" );
7165
+			return value;
7166
+		}
7167
+
7168
+		if ( hooks && "get" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {
7169
+			return ret;
7170
+		}
7171
+
7172
+		ret = jQuery.find.attr( elem, name );
7173
+
7174
+		// Non-existent attributes return null, we normalize to undefined
7175
+		return ret == null ? undefined : ret;
7176
+	},
7177
+
7178
+	attrHooks: {
7179
+		type: {
7180
+			set: function( elem, value ) {
7181
+				if ( !support.radioValue && value === "radio" &&
7182
+					jQuery.nodeName( elem, "input" ) ) {
7183
+					var val = elem.value;
7184
+					elem.setAttribute( "type", value );
7185
+					if ( val ) {
7186
+						elem.value = val;
7187
+					}
7188
+					return value;
7189
+				}
7190
+			}
7191
+		}
7192
+	},
7193
+
7194
+	removeAttr: function( elem, value ) {
7195
+		var name, propName,
7196
+			i = 0,
7197
+			attrNames = value && value.match( rnotwhite );
7198
+
7199
+		if ( attrNames && elem.nodeType === 1 ) {
7200
+			while ( ( name = attrNames[ i++ ] ) ) {
7201
+				propName = jQuery.propFix[ name ] || name;
7202
+
7203
+				// Boolean attributes get special treatment (#10870)
7204
+				if ( jQuery.expr.match.bool.test( name ) ) {
7205
+
7206
+					// Set corresponding property to false
7207
+					elem[ propName ] = false;
7208
+				}
7209
+
7210
+				elem.removeAttribute( name );
7211
+			}
7212
+		}
7213
+	}
7214
+} );
7215
+
7216
+// Hooks for boolean attributes
7217
+boolHook = {
7218
+	set: function( elem, value, name ) {
7219
+		if ( value === false ) {
7220
+
7221
+			// Remove boolean attributes when set to false
7222
+			jQuery.removeAttr( elem, name );
7223
+		} else {
7224
+			elem.setAttribute( name, name );
7225
+		}
7226
+		return name;
7227
+	}
7228
+};
7229
+jQuery.each( jQuery.expr.match.bool.source.match( /\w+/g ), function( i, name ) {
7230
+	var getter = attrHandle[ name ] || jQuery.find.attr;
7231
+
7232
+	attrHandle[ name ] = function( elem, name, isXML ) {
7233
+		var ret, handle;
7234
+		if ( !isXML ) {
7235
+
7236
+			// Avoid an infinite loop by temporarily removing this function from the getter
7237
+			handle = attrHandle[ name ];
7238
+			attrHandle[ name ] = ret;
7239
+			ret = getter( elem, name, isXML ) != null ?
7240
+				name.toLowerCase() :
7241
+				null;
7242
+			attrHandle[ name ] = handle;
7243
+		}
7244
+		return ret;
7245
+	};
7246
+} );
7247
+
7248
+
7249
+
7250
+
7251
+var rfocusable = /^(?:input|select|textarea|button)$/i,
7252
+	rclickable = /^(?:a|area)$/i;
7253
+
7254
+jQuery.fn.extend( {
7255
+	prop: function( name, value ) {
7256
+		return access( this, jQuery.prop, name, value, arguments.length > 1 );
7257
+	},
7258
+
7259
+	removeProp: function( name ) {
7260
+		return this.each( function() {
7261
+			delete this[ jQuery.propFix[ name ] || name ];
7262
+		} );
7263
+	}
7264
+} );
7265
+
7266
+jQuery.extend( {
7267
+	prop: function( elem, name, value ) {
7268
+		var ret, hooks,
7269
+			nType = elem.nodeType;
7270
+
7271
+		// Don't get/set properties on text, comment and attribute nodes
7272
+		if ( nType === 3 || nType === 8 || nType === 2 ) {
7273
+			return;
7274
+		}
7275
+
7276
+		if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {
7277
+
7278
+			// Fix name and attach hooks
7279
+			name = jQuery.propFix[ name ] || name;
7280
+			hooks = jQuery.propHooks[ name ];
7281
+		}
7282
+
7283
+		if ( value !== undefined ) {
7284
+			if ( hooks && "set" in hooks &&
7285
+				( ret = hooks.set( elem, value, name ) ) !== undefined ) {
7286
+				return ret;
7287
+			}
7288
+
7289
+			return ( elem[ name ] = value );
7290
+		}
7291
+
7292
+		if ( hooks && "get" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {
7293
+			return ret;
7294
+		}
7295
+
7296
+		return elem[ name ];
7297
+	},
7298
+
7299
+	propHooks: {
7300
+		tabIndex: {
7301
+			get: function( elem ) {
7302
+
7303
+				// elem.tabIndex doesn't always return the
7304
+				// correct value when it hasn't been explicitly set
7305
+				// http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
7306
+				// Use proper attribute retrieval(#12072)
7307
+				var tabindex = jQuery.find.attr( elem, "tabindex" );
7308
+
7309
+				return tabindex ?
7310
+					parseInt( tabindex, 10 ) :
7311
+					rfocusable.test( elem.nodeName ) ||
7312
+						rclickable.test( elem.nodeName ) && elem.href ?
7313
+							0 :
7314
+							-1;
7315
+			}
7316
+		}
7317
+	},
7318
+
7319
+	propFix: {
7320
+		"for": "htmlFor",
7321
+		"class": "className"
7322
+	}
7323
+} );
7324
+
7325
+if ( !support.optSelected ) {
7326
+	jQuery.propHooks.selected = {
7327
+		get: function( elem ) {
7328
+			var parent = elem.parentNode;
7329
+			if ( parent && parent.parentNode ) {
7330
+				parent.parentNode.selectedIndex;
7331
+			}
7332
+			return null;
7333
+		}
7334
+	};
7335
+}
7336
+
7337
+jQuery.each( [
7338
+	"tabIndex",
7339
+	"readOnly",
7340
+	"maxLength",
7341
+	"cellSpacing",
7342
+	"cellPadding",
7343
+	"rowSpan",
7344
+	"colSpan",
7345
+	"useMap",
7346
+	"frameBorder",
7347
+	"contentEditable"
7348
+], function() {
7349
+	jQuery.propFix[ this.toLowerCase() ] = this;
7350
+} );
7351
+
7352
+
7353
+
7354
+
7355
+var rclass = /[\t\r\n\f]/g;
7356
+
7357
+function getClass( elem ) {
7358
+	return elem.getAttribute && elem.getAttribute( "class" ) || "";
7359
+}
7360
+
7361
+jQuery.fn.extend( {
7362
+	addClass: function( value ) {
7363
+		var classes, elem, cur, curValue, clazz, j, finalValue,
7364
+			i = 0;
7365
+
7366
+		if ( jQuery.isFunction( value ) ) {
7367
+			return this.each( function( j ) {
7368
+				jQuery( this ).addClass( value.call( this, j, getClass( this ) ) );
7369
+			} );
7370
+		}
7371
+
7372
+		if ( typeof value === "string" && value ) {
7373
+			classes = value.match( rnotwhite ) || [];
7374
+
7375
+			while ( ( elem = this[ i++ ] ) ) {
7376
+				curValue = getClass( elem );
7377
+				cur = elem.nodeType === 1 &&
7378
+					( " " + curValue + " " ).replace( rclass, " " );
7379
+
7380
+				if ( cur ) {
7381
+					j = 0;
7382
+					while ( ( clazz = classes[ j++ ] ) ) {
7383
+						if ( cur.indexOf( " " + clazz + " " ) < 0 ) {
7384
+							cur += clazz + " ";
7385
+						}
7386
+					}
7387
+
7388
+					// Only assign if different to avoid unneeded rendering.
7389
+					finalValue = jQuery.trim( cur );
7390
+					if ( curValue !== finalValue ) {
7391
+						elem.setAttribute( "class", finalValue );
7392
+					}
7393
+				}
7394
+			}
7395
+		}
7396
+
7397
+		return this;
7398
+	},
7399
+
7400
+	removeClass: function( value ) {
7401
+		var classes, elem, cur, curValue, clazz, j, finalValue,
7402
+			i = 0;
7403
+
7404
+		if ( jQuery.isFunction( value ) ) {
7405
+			return this.each( function( j ) {
7406
+				jQuery( this ).removeClass( value.call( this, j, getClass( this ) ) );
7407
+			} );
7408
+		}
7409
+
7410
+		if ( !arguments.length ) {
7411
+			return this.attr( "class", "" );
7412
+		}
7413
+
7414
+		if ( typeof value === "string" && value ) {
7415
+			classes = value.match( rnotwhite ) || [];
7416
+
7417
+			while ( ( elem = this[ i++ ] ) ) {
7418
+				curValue = getClass( elem );
7419
+
7420
+				// This expression is here for better compressibility (see addClass)
7421
+				cur = elem.nodeType === 1 &&
7422
+					( " " + curValue + " " ).replace( rclass, " " );
7423
+
7424
+				if ( cur ) {
7425
+					j = 0;
7426
+					while ( ( clazz = classes[ j++ ] ) ) {
7427
+
7428
+						// Remove *all* instances
7429
+						while ( cur.indexOf( " " + clazz + " " ) > -1 ) {
7430
+							cur = cur.replace( " " + clazz + " ", " " );
7431
+						}
7432
+					}
7433
+
7434
+					// Only assign if different to avoid unneeded rendering.
7435
+					finalValue = jQuery.trim( cur );
7436
+					if ( curValue !== finalValue ) {
7437
+						elem.setAttribute( "class", finalValue );
7438
+					}
7439
+				}
7440
+			}
7441
+		}
7442
+
7443
+		return this;
7444
+	},
7445
+
7446
+	toggleClass: function( value, stateVal ) {
7447
+		var type = typeof value;
7448
+
7449
+		if ( typeof stateVal === "boolean" && type === "string" ) {
7450
+			return stateVal ? this.addClass( value ) : this.removeClass( value );
7451
+		}
7452
+
7453
+		if ( jQuery.isFunction( value ) ) {
7454
+			return this.each( function( i ) {
7455
+				jQuery( this ).toggleClass(
7456
+					value.call( this, i, getClass( this ), stateVal ),
7457
+					stateVal
7458
+				);
7459
+			} );
7460
+		}
7461
+
7462
+		return this.each( function() {
7463
+			var className, i, self, classNames;
7464
+
7465
+			if ( type === "string" ) {
7466
+
7467
+				// Toggle individual class names
7468
+				i = 0;
7469
+				self = jQuery( this );
7470
+				classNames = value.match( rnotwhite ) || [];
7471
+
7472
+				while ( ( className = classNames[ i++ ] ) ) {
7473
+
7474
+					// Check each className given, space separated list
7475
+					if ( self.hasClass( className ) ) {
7476
+						self.removeClass( className );
7477
+					} else {
7478
+						self.addClass( className );
7479
+					}
7480
+				}
7481
+
7482
+			// Toggle whole class name
7483
+			} else if ( value === undefined || type === "boolean" ) {
7484
+				className = getClass( this );
7485
+				if ( className ) {
7486
+
7487
+					// Store className if set
7488
+					dataPriv.set( this, "__className__", className );
7489
+				}
7490
+
7491
+				// If the element has a class name or if we're passed `false`,
7492
+				// then remove the whole classname (if there was one, the above saved it).
7493
+				// Otherwise bring back whatever was previously saved (if anything),
7494
+				// falling back to the empty string if nothing was stored.
7495
+				if ( this.setAttribute ) {
7496
+					this.setAttribute( "class",
7497
+						className || value === false ?
7498
+						"" :
7499
+						dataPriv.get( this, "__className__" ) || ""
7500
+					);
7501
+				}
7502
+			}
7503
+		} );
7504
+	},
7505
+
7506
+	hasClass: function( selector ) {
7507
+		var className, elem,
7508
+			i = 0;
7509
+
7510
+		className = " " + selector + " ";
7511
+		while ( ( elem = this[ i++ ] ) ) {
7512
+			if ( elem.nodeType === 1 &&
7513
+				( " " + getClass( elem ) + " " ).replace( rclass, " " )
7514
+					.indexOf( className ) > -1
7515
+			) {
7516
+				return true;
7517
+			}
7518
+		}
7519
+
7520
+		return false;
7521
+	}
7522
+} );
7523
+
7524
+
7525
+
7526
+
7527
+var rreturn = /\r/g;
7528
+
7529
+jQuery.fn.extend( {
7530
+	val: function( value ) {
7531
+		var hooks, ret, isFunction,
7532
+			elem = this[ 0 ];
7533
+
7534
+		if ( !arguments.length ) {
7535
+			if ( elem ) {
7536
+				hooks = jQuery.valHooks[ elem.type ] ||
7537
+					jQuery.valHooks[ elem.nodeName.toLowerCase() ];
7538
+
7539
+				if ( hooks &&
7540
+					"get" in hooks &&
7541
+					( ret = hooks.get( elem, "value" ) ) !== undefined
7542
+				) {
7543
+					return ret;
7544
+				}
7545
+
7546
+				ret = elem.value;
7547
+
7548
+				return typeof ret === "string" ?
7549
+
7550
+					// Handle most common string cases
7551
+					ret.replace( rreturn, "" ) :
7552
+
7553
+					// Handle cases where value is null/undef or number
7554
+					ret == null ? "" : ret;
7555
+			}
7556
+
7557
+			return;
7558
+		}
7559
+
7560
+		isFunction = jQuery.isFunction( value );
7561
+
7562
+		return this.each( function( i ) {
7563
+			var val;
7564
+
7565
+			if ( this.nodeType !== 1 ) {
7566
+				return;
7567
+			}
7568
+
7569
+			if ( isFunction ) {
7570
+				val = value.call( this, i, jQuery( this ).val() );
7571
+			} else {
7572
+				val = value;
7573
+			}
7574
+
7575
+			// Treat null/undefined as ""; convert numbers to string
7576
+			if ( val == null ) {
7577
+				val = "";
7578
+
7579
+			} else if ( typeof val === "number" ) {
7580
+				val += "";
7581
+
7582
+			} else if ( jQuery.isArray( val ) ) {
7583
+				val = jQuery.map( val, function( value ) {
7584
+					return value == null ? "" : value + "";
7585
+				} );
7586
+			}
7587
+
7588
+			hooks = jQuery.valHooks[ this.type ] || jQuery.valHooks[ this.nodeName.toLowerCase() ];
7589
+
7590
+			// If set returns undefined, fall back to normal setting
7591
+			if ( !hooks || !( "set" in hooks ) || hooks.set( this, val, "value" ) === undefined ) {
7592
+				this.value = val;
7593
+			}
7594
+		} );
7595
+	}
7596
+} );
7597
+
7598
+jQuery.extend( {
7599
+	valHooks: {
7600
+		option: {
7601
+			get: function( elem ) {
7602
+
7603
+				// Support: IE<11
7604
+				// option.value not trimmed (#14858)
7605
+				return jQuery.trim( elem.value );
7606
+			}
7607
+		},
7608
+		select: {
7609
+			get: function( elem ) {
7610
+				var value, option,
7611
+					options = elem.options,
7612
+					index = elem.selectedIndex,
7613
+					one = elem.type === "select-one" || index < 0,
7614
+					values = one ? null : [],
7615
+					max = one ? index + 1 : options.length,
7616
+					i = index < 0 ?
7617
+						max :
7618
+						one ? index : 0;
7619
+
7620
+				// Loop through all the selected options
7621
+				for ( ; i < max; i++ ) {
7622
+					option = options[ i ];
7623
+
7624
+					// IE8-9 doesn't update selected after form reset (#2551)
7625
+					if ( ( option.selected || i === index ) &&
7626
+
7627
+							// Don't return options that are disabled or in a disabled optgroup
7628
+							( support.optDisabled ?
7629
+								!option.disabled : option.getAttribute( "disabled" ) === null ) &&
7630
+							( !option.parentNode.disabled ||
7631
+								!jQuery.nodeName( option.parentNode, "optgroup" ) ) ) {
7632
+
7633
+						// Get the specific value for the option
7634
+						value = jQuery( option ).val();
7635
+
7636
+						// We don't need an array for one selects
7637
+						if ( one ) {
7638
+							return value;
7639
+						}
7640
+
7641
+						// Multi-Selects return an array
7642
+						values.push( value );
7643
+					}
7644
+				}
7645
+
7646
+				return values;
7647
+			},
7648
+
7649
+			set: function( elem, value ) {
7650
+				var optionSet, option,
7651
+					options = elem.options,
7652
+					values = jQuery.makeArray( value ),
7653
+					i = options.length;
7654
+
7655
+				while ( i-- ) {
7656
+					option = options[ i ];
7657
+					if ( option.selected =
7658
+							jQuery.inArray( jQuery.valHooks.option.get( option ), values ) > -1
7659
+					) {
7660
+						optionSet = true;
7661
+					}
7662
+				}
7663
+
7664
+				// Force browsers to behave consistently when non-matching value is set
7665
+				if ( !optionSet ) {
7666
+					elem.selectedIndex = -1;
7667
+				}
7668
+				return values;
7669
+			}
7670
+		}
7671
+	}
7672
+} );
7673
+
7674
+// Radios and checkboxes getter/setter
7675
+jQuery.each( [ "radio", "checkbox" ], function() {
7676
+	jQuery.valHooks[ this ] = {
7677
+		set: function( elem, value ) {
7678
+			if ( jQuery.isArray( value ) ) {
7679
+				return ( elem.checked = jQuery.inArray( jQuery( elem ).val(), value ) > -1 );
7680
+			}
7681
+		}
7682
+	};
7683
+	if ( !support.checkOn ) {
7684
+		jQuery.valHooks[ this ].get = function( elem ) {
7685
+			return elem.getAttribute( "value" ) === null ? "on" : elem.value;
7686
+		};
7687
+	}
7688
+} );
7689
+
7690
+
7691
+
7692
+
7693
+// Return jQuery for attributes-only inclusion
7694
+
7695
+
7696
+var rfocusMorph = /^(?:focusinfocus|focusoutblur)$/;
7697
+
7698
+jQuery.extend( jQuery.event, {
7699
+
7700
+	trigger: function( event, data, elem, onlyHandlers ) {
7701
+
7702
+		var i, cur, tmp, bubbleType, ontype, handle, special,
7703
+			eventPath = [ elem || document ],
7704
+			type = hasOwn.call( event, "type" ) ? event.type : event,
7705
+			namespaces = hasOwn.call( event, "namespace" ) ? event.namespace.split( "." ) : [];
7706
+
7707
+		cur = tmp = elem = elem || document;
7708
+
7709
+		// Don't do events on text and comment nodes
7710
+		if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
7711
+			return;
7712
+		}
7713
+
7714
+		// focus/blur morphs to focusin/out; ensure we're not firing them right now
7715
+		if ( rfocusMorph.test( type + jQuery.event.triggered ) ) {
7716
+			return;
7717
+		}
7718
+
7719
+		if ( type.indexOf( "." ) > -1 ) {
7720
+
7721
+			// Namespaced trigger; create a regexp to match event type in handle()
7722
+			namespaces = type.split( "." );
7723
+			type = namespaces.shift();
7724
+			namespaces.sort();
7725
+		}
7726
+		ontype = type.indexOf( ":" ) < 0 && "on" + type;
7727
+
7728
+		// Caller can pass in a jQuery.Event object, Object, or just an event type string
7729
+		event = event[ jQuery.expando ] ?
7730
+			event :
7731
+			new jQuery.Event( type, typeof event === "object" && event );
7732
+
7733
+		// Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true)
7734
+		event.isTrigger = onlyHandlers ? 2 : 3;
7735
+		event.namespace = namespaces.join( "." );
7736
+		event.rnamespace = event.namespace ?
7737
+			new RegExp( "(^|\\.)" + namespaces.join( "\\.(?:.*\\.|)" ) + "(\\.|$)" ) :
7738
+			null;
7739
+
7740
+		// Clean up the event in case it is being reused
7741
+		event.result = undefined;
7742
+		if ( !event.target ) {
7743
+			event.target = elem;
7744
+		}
7745
+
7746
+		// Clone any incoming data and prepend the event, creating the handler arg list
7747
+		data = data == null ?
7748
+			[ event ] :
7749
+			jQuery.makeArray( data, [ event ] );
7750
+
7751
+		// Allow special events to draw outside the lines
7752
+		special = jQuery.event.special[ type ] || {};
7753
+		if ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) {
7754
+			return;
7755
+		}
7756
+
7757
+		// Determine event propagation path in advance, per W3C events spec (#9951)
7758
+		// Bubble up to document, then to window; watch for a global ownerDocument var (#9724)
7759
+		if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) {
7760
+
7761
+			bubbleType = special.delegateType || type;
7762
+			if ( !rfocusMorph.test( bubbleType + type ) ) {
7763
+				cur = cur.parentNode;
7764
+			}
7765
+			for ( ; cur; cur = cur.parentNode ) {
7766
+				eventPath.push( cur );
7767
+				tmp = cur;
7768
+			}
7769
+
7770
+			// Only add window if we got to document (e.g., not plain obj or detached DOM)
7771
+			if ( tmp === ( elem.ownerDocument || document ) ) {
7772
+				eventPath.push( tmp.defaultView || tmp.parentWindow || window );
7773
+			}
7774
+		}
7775
+
7776
+		// Fire handlers on the event path
7777
+		i = 0;
7778
+		while ( ( cur = eventPath[ i++ ] ) && !event.isPropagationStopped() ) {
7779
+
7780
+			event.type = i > 1 ?
7781
+				bubbleType :
7782
+				special.bindType || type;
7783
+
7784
+			// jQuery handler
7785
+			handle = ( dataPriv.get( cur, "events" ) || {} )[ event.type ] &&
7786
+				dataPriv.get( cur, "handle" );
7787
+			if ( handle ) {
7788
+				handle.apply( cur, data );
7789
+			}
7790
+
7791
+			// Native handler
7792
+			handle = ontype && cur[ ontype ];
7793
+			if ( handle && handle.apply && acceptData( cur ) ) {
7794
+				event.result = handle.apply( cur, data );
7795
+				if ( event.result === false ) {
7796
+					event.preventDefault();
7797
+				}
7798
+			}
7799
+		}
7800
+		event.type = type;
7801
+
7802
+		// If nobody prevented the default action, do it now
7803
+		if ( !onlyHandlers && !event.isDefaultPrevented() ) {
7804
+
7805
+			if ( ( !special._default ||
7806
+				special._default.apply( eventPath.pop(), data ) === false ) &&
7807
+				acceptData( elem ) ) {
7808
+
7809
+				// Call a native DOM method on the target with the same name name as the event.
7810
+				// Don't do default actions on window, that's where global variables be (#6170)
7811
+				if ( ontype && jQuery.isFunction( elem[ type ] ) && !jQuery.isWindow( elem ) ) {
7812
+
7813
+					// Don't re-trigger an onFOO event when we call its FOO() method
7814
+					tmp = elem[ ontype ];
7815
+
7816
+					if ( tmp ) {
7817
+						elem[ ontype ] = null;
7818
+					}
7819
+
7820
+					// Prevent re-triggering of the same event, since we already bubbled it above
7821
+					jQuery.event.triggered = type;
7822
+					elem[ type ]();
7823
+					jQuery.event.triggered = undefined;
7824
+
7825
+					if ( tmp ) {
7826
+						elem[ ontype ] = tmp;
7827
+					}
7828
+				}
7829
+			}
7830
+		}
7831
+
7832
+		return event.result;
7833
+	},
7834
+
7835
+	// Piggyback on a donor event to simulate a different one
7836
+	simulate: function( type, elem, event ) {
7837
+		var e = jQuery.extend(
7838
+			new jQuery.Event(),
7839
+			event,
7840
+			{
7841
+				type: type,
7842
+				isSimulated: true
7843
+
7844
+				// Previously, `originalEvent: {}` was set here, so stopPropagation call
7845
+				// would not be triggered on donor event, since in our own
7846
+				// jQuery.event.stopPropagation function we had a check for existence of
7847
+				// originalEvent.stopPropagation method, so, consequently it would be a noop.
7848
+				//
7849
+				// But now, this "simulate" function is used only for events
7850
+				// for which stopPropagation() is noop, so there is no need for that anymore.
7851
+				//
7852
+				// For the compat branch though, guard for "click" and "submit"
7853
+				// events is still used, but was moved to jQuery.event.stopPropagation function
7854
+				// because `originalEvent` should point to the original event for the constancy
7855
+				// with other events and for more focused logic
7856
+			}
7857
+		);
7858
+
7859
+		jQuery.event.trigger( e, null, elem );
7860
+
7861
+		if ( e.isDefaultPrevented() ) {
7862
+			event.preventDefault();
7863
+		}
7864
+	}
7865
+
7866
+} );
7867
+
7868
+jQuery.fn.extend( {
7869
+
7870
+	trigger: function( type, data ) {
7871
+		return this.each( function() {
7872
+			jQuery.event.trigger( type, data, this );
7873
+		} );
7874
+	},
7875
+	triggerHandler: function( type, data ) {
7876
+		var elem = this[ 0 ];
7877
+		if ( elem ) {
7878
+			return jQuery.event.trigger( type, data, elem, true );
7879
+		}
7880
+	}
7881
+} );
7882
+
7883
+
7884
+jQuery.each( ( "blur focus focusin focusout load resize scroll unload click dblclick " +
7885
+	"mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
7886
+	"change select submit keydown keypress keyup error contextmenu" ).split( " " ),
7887
+	function( i, name ) {
7888
+
7889
+	// Handle event binding
7890
+	jQuery.fn[ name ] = function( data, fn ) {
7891
+		return arguments.length > 0 ?
7892
+			this.on( name, null, data, fn ) :
7893
+			this.trigger( name );
7894
+	};
7895
+} );
7896
+
7897
+jQuery.fn.extend( {
7898
+	hover: function( fnOver, fnOut ) {
7899
+		return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
7900
+	}
7901
+} );
7902
+
7903
+
7904
+
7905
+
7906
+support.focusin = "onfocusin" in window;
7907
+
7908
+
7909
+// Support: Firefox
7910
+// Firefox doesn't have focus(in | out) events
7911
+// Related ticket - https://bugzilla.mozilla.org/show_bug.cgi?id=687787
7912
+//
7913
+// Support: Chrome, Safari
7914
+// focus(in | out) events fire after focus & blur events,
7915
+// which is spec violation - http://www.w3.org/TR/DOM-Level-3-Events/#events-focusevent-event-order
7916
+// Related ticket - https://code.google.com/p/chromium/issues/detail?id=449857
7917
+if ( !support.focusin ) {
7918
+	jQuery.each( { focus: "focusin", blur: "focusout" }, function( orig, fix ) {
7919
+
7920
+		// Attach a single capturing handler on the document while someone wants focusin/focusout
7921
+		var handler = function( event ) {
7922
+			jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ) );
7923
+		};
7924
+
7925
+		jQuery.event.special[ fix ] = {
7926
+			setup: function() {
7927
+				var doc = this.ownerDocument || this,
7928
+					attaches = dataPriv.access( doc, fix );
7929
+
7930
+				if ( !attaches ) {
7931
+					doc.addEventListener( orig, handler, true );
7932
+				}
7933
+				dataPriv.access( doc, fix, ( attaches || 0 ) + 1 );
7934
+			},
7935
+			teardown: function() {
7936
+				var doc = this.ownerDocument || this,
7937
+					attaches = dataPriv.access( doc, fix ) - 1;
7938
+
7939
+				if ( !attaches ) {
7940
+					doc.removeEventListener( orig, handler, true );
7941
+					dataPriv.remove( doc, fix );
7942
+
7943
+				} else {
7944
+					dataPriv.access( doc, fix, attaches );
7945
+				}
7946
+			}
7947
+		};
7948
+	} );
7949
+}
7950
+var location = window.location;
7951
+
7952
+var nonce = jQuery.now();
7953
+
7954
+var rquery = ( /\?/ );
7955
+
7956
+
7957
+
7958
+// Support: Android 2.3
7959
+// Workaround failure to string-cast null input
7960
+jQuery.parseJSON = function( data ) {
7961
+	return JSON.parse( data + "" );
7962
+};
7963
+
7964
+
7965
+// Cross-browser xml parsing
7966
+jQuery.parseXML = function( data ) {
7967
+	var xml;
7968
+	if ( !data || typeof data !== "string" ) {
7969
+		return null;
7970
+	}
7971
+
7972
+	// Support: IE9
7973
+	try {
7974
+		xml = ( new window.DOMParser() ).parseFromString( data, "text/xml" );
7975
+	} catch ( e ) {
7976
+		xml = undefined;
7977
+	}
7978
+
7979
+	if ( !xml || xml.getElementsByTagName( "parsererror" ).length ) {
7980
+		jQuery.error( "Invalid XML: " + data );
7981
+	}
7982
+	return xml;
7983
+};
7984
+
7985
+
7986
+var
7987
+	rhash = /#.*$/,
7988
+	rts = /([?&])_=[^&]*/,
7989
+	rheaders = /^(.*?):[ \t]*([^\r\n]*)$/mg,
7990
+
7991
+	// #7653, #8125, #8152: local protocol detection
7992
+	rlocalProtocol = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/,
7993
+	rnoContent = /^(?:GET|HEAD)$/,
7994
+	rprotocol = /^\/\//,
7995
+
7996
+	/* Prefilters
7997
+	 * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)
7998
+	 * 2) These are called:
7999
+	 *    - BEFORE asking for a transport
8000
+	 *    - AFTER param serialization (s.data is a string if s.processData is true)
8001
+	 * 3) key is the dataType
8002
+	 * 4) the catchall symbol "*" can be used
8003
+	 * 5) execution will start with transport dataType and THEN continue down to "*" if needed
8004
+	 */
8005
+	prefilters = {},
8006
+
8007
+	/* Transports bindings
8008
+	 * 1) key is the dataType
8009
+	 * 2) the catchall symbol "*" can be used
8010
+	 * 3) selection will start with transport dataType and THEN go to "*" if needed
8011
+	 */
8012
+	transports = {},
8013
+
8014
+	// Avoid comment-prolog char sequence (#10098); must appease lint and evade compression
8015
+	allTypes = "*/".concat( "*" ),
8016
+
8017
+	// Anchor tag for parsing the document origin
8018
+	originAnchor = document.createElement( "a" );
8019
+	originAnchor.href = location.href;
8020
+
8021
+// Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport
8022
+function addToPrefiltersOrTransports( structure ) {
8023
+
8024
+	// dataTypeExpression is optional and defaults to "*"
8025
+	return function( dataTypeExpression, func ) {
8026
+
8027
+		if ( typeof dataTypeExpression !== "string" ) {
8028
+			func = dataTypeExpression;
8029
+			dataTypeExpression = "*";
8030
+		}
8031
+
8032
+		var dataType,
8033
+			i = 0,
8034
+			dataTypes = dataTypeExpression.toLowerCase().match( rnotwhite ) || [];
8035
+
8036
+		if ( jQuery.isFunction( func ) ) {
8037
+
8038
+			// For each dataType in the dataTypeExpression
8039
+			while ( ( dataType = dataTypes[ i++ ] ) ) {
8040
+
8041
+				// Prepend if requested
8042
+				if ( dataType[ 0 ] === "+" ) {
8043
+					dataType = dataType.slice( 1 ) || "*";
8044
+					( structure[ dataType ] = structure[ dataType ] || [] ).unshift( func );
8045
+
8046
+				// Otherwise append
8047
+				} else {
8048
+					( structure[ dataType ] = structure[ dataType ] || [] ).push( func );
8049
+				}
8050
+			}
8051
+		}
8052
+	};
8053
+}
8054
+
8055
+// Base inspection function for prefilters and transports
8056
+function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR ) {
8057
+
8058
+	var inspected = {},
8059
+		seekingTransport = ( structure === transports );
8060
+
8061
+	function inspect( dataType ) {
8062
+		var selected;
8063
+		inspected[ dataType ] = true;
8064
+		jQuery.each( structure[ dataType ] || [], function( _, prefilterOrFactory ) {
8065
+			var dataTypeOrTransport = prefilterOrFactory( options, originalOptions, jqXHR );
8066
+			if ( typeof dataTypeOrTransport === "string" &&
8067
+				!seekingTransport && !inspected[ dataTypeOrTransport ] ) {
8068
+
8069
+				options.dataTypes.unshift( dataTypeOrTransport );
8070
+				inspect( dataTypeOrTransport );
8071
+				return false;
8072
+			} else if ( seekingTransport ) {
8073
+				return !( selected = dataTypeOrTransport );
8074
+			}
8075
+		} );
8076
+		return selected;
8077
+	}
8078
+
8079
+	return inspect( options.dataTypes[ 0 ] ) || !inspected[ "*" ] && inspect( "*" );
8080
+}
8081
+
8082
+// A special extend for ajax options
8083
+// that takes "flat" options (not to be deep extended)
8084
+// Fixes #9887
8085
+function ajaxExtend( target, src ) {
8086
+	var key, deep,
8087
+		flatOptions = jQuery.ajaxSettings.flatOptions || {};
8088
+
8089
+	for ( key in src ) {
8090
+		if ( src[ key ] !== undefined ) {
8091
+			( flatOptions[ key ] ? target : ( deep || ( deep = {} ) ) )[ key ] = src[ key ];
8092
+		}
8093
+	}
8094
+	if ( deep ) {
8095
+		jQuery.extend( true, target, deep );
8096
+	}
8097
+
8098
+	return target;
8099
+}
8100
+
8101
+/* Handles responses to an ajax request:
8102
+ * - finds the right dataType (mediates between content-type and expected dataType)
8103
+ * - returns the corresponding response
8104
+ */
8105
+function ajaxHandleResponses( s, jqXHR, responses ) {
8106
+
8107
+	var ct, type, finalDataType, firstDataType,
8108
+		contents = s.contents,
8109
+		dataTypes = s.dataTypes;
8110
+
8111
+	// Remove auto dataType and get content-type in the process
8112
+	while ( dataTypes[ 0 ] === "*" ) {
8113
+		dataTypes.shift();
8114
+		if ( ct === undefined ) {
8115
+			ct = s.mimeType || jqXHR.getResponseHeader( "Content-Type" );
8116
+		}
8117
+	}
8118
+
8119
+	// Check if we're dealing with a known content-type
8120
+	if ( ct ) {
8121
+		for ( type in contents ) {
8122
+			if ( contents[ type ] && contents[ type ].test( ct ) ) {
8123
+				dataTypes.unshift( type );
8124
+				break;
8125
+			}
8126
+		}
8127
+	}
8128
+
8129
+	// Check to see if we have a response for the expected dataType
8130
+	if ( dataTypes[ 0 ] in responses ) {
8131
+		finalDataType = dataTypes[ 0 ];
8132
+	} else {
8133
+
8134
+		// Try convertible dataTypes
8135
+		for ( type in responses ) {
8136
+			if ( !dataTypes[ 0 ] || s.converters[ type + " " + dataTypes[ 0 ] ] ) {
8137
+				finalDataType = type;
8138
+				break;
8139
+			}
8140
+			if ( !firstDataType ) {
8141
+				firstDataType = type;
8142
+			}
8143
+		}
8144
+
8145
+		// Or just use first one
8146
+		finalDataType = finalDataType || firstDataType;
8147
+	}
8148
+
8149
+	// If we found a dataType
8150
+	// We add the dataType to the list if needed
8151
+	// and return the corresponding response
8152
+	if ( finalDataType ) {
8153
+		if ( finalDataType !== dataTypes[ 0 ] ) {
8154
+			dataTypes.unshift( finalDataType );
8155
+		}
8156
+		return responses[ finalDataType ];
8157
+	}
8158
+}
8159
+
8160
+/* Chain conversions given the request and the original response
8161
+ * Also sets the responseXXX fields on the jqXHR instance
8162
+ */
8163
+function ajaxConvert( s, response, jqXHR, isSuccess ) {
8164
+	var conv2, current, conv, tmp, prev,
8165
+		converters = {},
8166
+
8167
+		// Work with a copy of dataTypes in case we need to modify it for conversion
8168
+		dataTypes = s.dataTypes.slice();
8169
+
8170
+	// Create converters map with lowercased keys
8171
+	if ( dataTypes[ 1 ] ) {
8172
+		for ( conv in s.converters ) {
8173
+			converters[ conv.toLowerCase() ] = s.converters[ conv ];
8174
+		}
8175
+	}
8176
+
8177
+	current = dataTypes.shift();
8178
+
8179
+	// Convert to each sequential dataType
8180
+	while ( current ) {
8181
+
8182
+		if ( s.responseFields[ current ] ) {
8183
+			jqXHR[ s.responseFields[ current ] ] = response;
8184
+		}
8185
+
8186
+		// Apply the dataFilter if provided
8187
+		if ( !prev && isSuccess && s.dataFilter ) {
8188
+			response = s.dataFilter( response, s.dataType );
8189
+		}
8190
+
8191
+		prev = current;
8192
+		current = dataTypes.shift();
8193
+
8194
+		if ( current ) {
8195
+
8196
+		// There's only work to do if current dataType is non-auto
8197
+			if ( current === "*" ) {
8198
+
8199
+				current = prev;
8200
+
8201
+			// Convert response if prev dataType is non-auto and differs from current
8202
+			} else if ( prev !== "*" && prev !== current ) {
8203
+
8204
+				// Seek a direct converter
8205
+				conv = converters[ prev + " " + current ] || converters[ "* " + current ];
8206
+
8207
+				// If none found, seek a pair
8208
+				if ( !conv ) {
8209
+					for ( conv2 in converters ) {
8210
+
8211
+						// If conv2 outputs current
8212
+						tmp = conv2.split( " " );
8213
+						if ( tmp[ 1 ] === current ) {
8214
+
8215
+							// If prev can be converted to accepted input
8216
+							conv = converters[ prev + " " + tmp[ 0 ] ] ||
8217
+								converters[ "* " + tmp[ 0 ] ];
8218
+							if ( conv ) {
8219
+
8220
+								// Condense equivalence converters
8221
+								if ( conv === true ) {
8222
+									conv = converters[ conv2 ];
8223
+
8224
+								// Otherwise, insert the intermediate dataType
8225
+								} else if ( converters[ conv2 ] !== true ) {
8226
+									current = tmp[ 0 ];
8227
+									dataTypes.unshift( tmp[ 1 ] );
8228
+								}
8229
+								break;
8230
+							}
8231
+						}
8232
+					}
8233
+				}
8234
+
8235
+				// Apply converter (if not an equivalence)
8236
+				if ( conv !== true ) {
8237
+
8238
+					// Unless errors are allowed to bubble, catch and return them
8239
+					if ( conv && s.throws ) {
8240
+						response = conv( response );
8241
+					} else {
8242
+						try {
8243
+							response = conv( response );
8244
+						} catch ( e ) {
8245
+							return {
8246
+								state: "parsererror",
8247
+								error: conv ? e : "No conversion from " + prev + " to " + current
8248
+							};
8249
+						}
8250
+					}
8251
+				}
8252
+			}
8253
+		}
8254
+	}
8255
+
8256
+	return { state: "success", data: response };
8257
+}
8258
+
8259
+jQuery.extend( {
8260
+
8261
+	// Counter for holding the number of active queries
8262
+	active: 0,
8263
+
8264
+	// Last-Modified header cache for next request
8265
+	lastModified: {},
8266
+	etag: {},
8267
+
8268
+	ajaxSettings: {
8269
+		url: location.href,
8270
+		type: "GET",
8271
+		isLocal: rlocalProtocol.test( location.protocol ),
8272
+		global: true,
8273
+		processData: true,
8274
+		async: true,
8275
+		contentType: "application/x-www-form-urlencoded; charset=UTF-8",
8276
+		/*
8277
+		timeout: 0,
8278
+		data: null,
8279
+		dataType: null,
8280
+		username: null,
8281
+		password: null,
8282
+		cache: null,
8283
+		throws: false,
8284
+		traditional: false,
8285
+		headers: {},
8286
+		*/
8287
+
8288
+		accepts: {
8289
+			"*": allTypes,
8290
+			text: "text/plain",
8291
+			html: "text/html",
8292
+			xml: "application/xml, text/xml",
8293
+			json: "application/json, text/javascript"
8294
+		},
8295
+
8296
+		contents: {
8297
+			xml: /\bxml\b/,
8298
+			html: /\bhtml/,
8299
+			json: /\bjson\b/
8300
+		},
8301
+
8302
+		responseFields: {
8303
+			xml: "responseXML",
8304
+			text: "responseText",
8305
+			json: "responseJSON"
8306
+		},
8307
+
8308
+		// Data converters
8309
+		// Keys separate source (or catchall "*") and destination types with a single space
8310
+		converters: {
8311
+
8312
+			// Convert anything to text
8313
+			"* text": String,
8314
+
8315
+			// Text to html (true = no transformation)
8316
+			"text html": true,
8317
+
8318
+			// Evaluate text as a json expression
8319
+			"text json": jQuery.parseJSON,
8320
+
8321
+			// Parse text as xml
8322
+			"text xml": jQuery.parseXML
8323
+		},
8324
+
8325
+		// For options that shouldn't be deep extended:
8326
+		// you can add your own custom options here if
8327
+		// and when you create one that shouldn't be
8328
+		// deep extended (see ajaxExtend)
8329
+		flatOptions: {
8330
+			url: true,
8331
+			context: true
8332
+		}
8333
+	},
8334
+
8335
+	// Creates a full fledged settings object into target
8336
+	// with both ajaxSettings and settings fields.
8337
+	// If target is omitted, writes into ajaxSettings.
8338
+	ajaxSetup: function( target, settings ) {
8339
+		return settings ?
8340
+
8341
+			// Building a settings object
8342
+			ajaxExtend( ajaxExtend( target, jQuery.ajaxSettings ), settings ) :
8343
+
8344
+			// Extending ajaxSettings
8345
+			ajaxExtend( jQuery.ajaxSettings, target );
8346
+	},
8347
+
8348
+	ajaxPrefilter: addToPrefiltersOrTransports( prefilters ),
8349
+	ajaxTransport: addToPrefiltersOrTransports( transports ),
8350
+
8351
+	// Main method
8352
+	ajax: function( url, options ) {
8353
+
8354
+		// If url is an object, simulate pre-1.5 signature
8355
+		if ( typeof url === "object" ) {
8356
+			options = url;
8357
+			url = undefined;
8358
+		}
8359
+
8360
+		// Force options to be an object
8361
+		options = options || {};
8362
+
8363
+		var transport,
8364
+
8365
+			// URL without anti-cache param
8366
+			cacheURL,
8367
+
8368
+			// Response headers
8369
+			responseHeadersString,
8370
+			responseHeaders,
8371
+
8372
+			// timeout handle
8373
+			timeoutTimer,
8374
+
8375
+			// Url cleanup var
8376
+			urlAnchor,
8377
+
8378
+			// To know if global events are to be dispatched
8379
+			fireGlobals,
8380
+
8381
+			// Loop variable
8382
+			i,
8383
+
8384
+			// Create the final options object
8385
+			s = jQuery.ajaxSetup( {}, options ),
8386
+
8387
+			// Callbacks context
8388
+			callbackContext = s.context || s,
8389
+
8390
+			// Context for global events is callbackContext if it is a DOM node or jQuery collection
8391
+			globalEventContext = s.context &&
8392
+				( callbackContext.nodeType || callbackContext.jquery ) ?
8393
+					jQuery( callbackContext ) :
8394
+					jQuery.event,
8395
+
8396
+			// Deferreds
8397
+			deferred = jQuery.Deferred(),
8398
+			completeDeferred = jQuery.Callbacks( "once memory" ),
8399
+
8400
+			// Status-dependent callbacks
8401
+			statusCode = s.statusCode || {},
8402
+
8403
+			// Headers (they are sent all at once)
8404
+			requestHeaders = {},
8405
+			requestHeadersNames = {},
8406
+
8407
+			// The jqXHR state
8408
+			state = 0,
8409
+
8410
+			// Default abort message
8411
+			strAbort = "canceled",
8412
+
8413
+			// Fake xhr
8414
+			jqXHR = {
8415
+				readyState: 0,
8416
+
8417
+				// Builds headers hashtable if needed
8418
+				getResponseHeader: function( key ) {
8419
+					var match;
8420
+					if ( state === 2 ) {
8421
+						if ( !responseHeaders ) {
8422
+							responseHeaders = {};
8423
+							while ( ( match = rheaders.exec( responseHeadersString ) ) ) {
8424
+								responseHeaders[ match[ 1 ].toLowerCase() ] = match[ 2 ];
8425
+							}
8426
+						}
8427
+						match = responseHeaders[ key.toLowerCase() ];
8428
+					}
8429
+					return match == null ? null : match;
8430
+				},
8431
+
8432
+				// Raw string
8433
+				getAllResponseHeaders: function() {
8434
+					return state === 2 ? responseHeadersString : null;
8435
+				},
8436
+
8437
+				// Caches the header
8438
+				setRequestHeader: function( name, value ) {
8439
+					var lname = name.toLowerCase();
8440
+					if ( !state ) {
8441
+						name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name;
8442
+						requestHeaders[ name ] = value;
8443
+					}
8444
+					return this;
8445
+				},
8446
+
8447
+				// Overrides response content-type header
8448
+				overrideMimeType: function( type ) {
8449
+					if ( !state ) {
8450
+						s.mimeType = type;
8451
+					}
8452
+					return this;
8453
+				},
8454
+
8455
+				// Status-dependent callbacks
8456
+				statusCode: function( map ) {
8457
+					var code;
8458
+					if ( map ) {
8459
+						if ( state < 2 ) {
8460
+							for ( code in map ) {
8461
+
8462
+								// Lazy-add the new callback in a way that preserves old ones
8463
+								statusCode[ code ] = [ statusCode[ code ], map[ code ] ];
8464
+							}
8465
+						} else {
8466
+
8467
+							// Execute the appropriate callbacks
8468
+							jqXHR.always( map[ jqXHR.status ] );
8469
+						}
8470
+					}
8471
+					return this;
8472
+				},
8473
+
8474
+				// Cancel the request
8475
+				abort: function( statusText ) {
8476
+					var finalText = statusText || strAbort;
8477
+					if ( transport ) {
8478
+						transport.abort( finalText );
8479
+					}
8480
+					done( 0, finalText );
8481
+					return this;
8482
+				}
8483
+			};
8484
+
8485
+		// Attach deferreds
8486
+		deferred.promise( jqXHR ).complete = completeDeferred.add;
8487
+		jqXHR.success = jqXHR.done;
8488
+		jqXHR.error = jqXHR.fail;
8489
+
8490
+		// Remove hash character (#7531: and string promotion)
8491
+		// Add protocol if not provided (prefilters might expect it)
8492
+		// Handle falsy url in the settings object (#10093: consistency with old signature)
8493
+		// We also use the url parameter if available
8494
+		s.url = ( ( url || s.url || location.href ) + "" ).replace( rhash, "" )
8495
+			.replace( rprotocol, location.protocol + "//" );
8496
+
8497
+		// Alias method option to type as per ticket #12004
8498
+		s.type = options.method || options.type || s.method || s.type;
8499
+
8500
+		// Extract dataTypes list
8501
+		s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().match( rnotwhite ) || [ "" ];
8502
+
8503
+		// A cross-domain request is in order when the origin doesn't match the current origin.
8504
+		if ( s.crossDomain == null ) {
8505
+			urlAnchor = document.createElement( "a" );
8506
+
8507
+			// Support: IE8-11+
8508
+			// IE throws exception if url is malformed, e.g. http://example.com:80x/
8509
+			try {
8510
+				urlAnchor.href = s.url;
8511
+
8512
+				// Support: IE8-11+
8513
+				// Anchor's host property isn't correctly set when s.url is relative
8514
+				urlAnchor.href = urlAnchor.href;
8515
+				s.crossDomain = originAnchor.protocol + "//" + originAnchor.host !==
8516
+					urlAnchor.protocol + "//" + urlAnchor.host;
8517
+			} catch ( e ) {
8518
+
8519
+				// If there is an error parsing the URL, assume it is crossDomain,
8520
+				// it can be rejected by the transport if it is invalid
8521
+				s.crossDomain = true;
8522
+			}
8523
+		}
8524
+
8525
+		// Convert data if not already a string
8526
+		if ( s.data && s.processData && typeof s.data !== "string" ) {
8527
+			s.data = jQuery.param( s.data, s.traditional );
8528
+		}
8529
+
8530
+		// Apply prefilters
8531
+		inspectPrefiltersOrTransports( prefilters, s, options, jqXHR );
8532
+
8533
+		// If request was aborted inside a prefilter, stop there
8534
+		if ( state === 2 ) {
8535
+			return jqXHR;
8536
+		}
8537
+
8538
+		// We can fire global events as of now if asked to
8539
+		// Don't fire events if jQuery.event is undefined in an AMD-usage scenario (#15118)
8540
+		fireGlobals = jQuery.event && s.global;
8541
+
8542
+		// Watch for a new set of requests
8543
+		if ( fireGlobals && jQuery.active++ === 0 ) {
8544
+			jQuery.event.trigger( "ajaxStart" );
8545
+		}
8546
+
8547
+		// Uppercase the type
8548
+		s.type = s.type.toUpperCase();
8549
+
8550
+		// Determine if request has content
8551
+		s.hasContent = !rnoContent.test( s.type );
8552
+
8553
+		// Save the URL in case we're toying with the If-Modified-Since
8554
+		// and/or If-None-Match header later on
8555
+		cacheURL = s.url;
8556
+
8557
+		// More options handling for requests with no content
8558
+		if ( !s.hasContent ) {
8559
+
8560
+			// If data is available, append data to url
8561
+			if ( s.data ) {
8562
+				cacheURL = ( s.url += ( rquery.test( cacheURL ) ? "&" : "?" ) + s.data );
8563
+
8564
+				// #9682: remove data so that it's not used in an eventual retry
8565
+				delete s.data;
8566
+			}
8567
+
8568
+			// Add anti-cache in url if needed
8569
+			if ( s.cache === false ) {
8570
+				s.url = rts.test( cacheURL ) ?
8571
+
8572
+					// If there is already a '_' parameter, set its value
8573
+					cacheURL.replace( rts, "$1_=" + nonce++ ) :
8574
+
8575
+					// Otherwise add one to the end
8576
+					cacheURL + ( rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + nonce++;
8577
+			}
8578
+		}
8579
+
8580
+		// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
8581
+		if ( s.ifModified ) {
8582
+			if ( jQuery.lastModified[ cacheURL ] ) {
8583
+				jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ cacheURL ] );
8584
+			}
8585
+			if ( jQuery.etag[ cacheURL ] ) {
8586
+				jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ cacheURL ] );
8587
+			}
8588
+		}
8589
+
8590
+		// Set the correct header, if data is being sent
8591
+		if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {
8592
+			jqXHR.setRequestHeader( "Content-Type", s.contentType );
8593
+		}
8594
+
8595
+		// Set the Accepts header for the server, depending on the dataType
8596
+		jqXHR.setRequestHeader(
8597
+			"Accept",
8598
+			s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[ 0 ] ] ?
8599
+				s.accepts[ s.dataTypes[ 0 ] ] +
8600
+					( s.dataTypes[ 0 ] !== "*" ? ", " + allTypes + "; q=0.01" : "" ) :
8601
+				s.accepts[ "*" ]
8602
+		);
8603
+
8604
+		// Check for headers option
8605
+		for ( i in s.headers ) {
8606
+			jqXHR.setRequestHeader( i, s.headers[ i ] );
8607
+		}
8608
+
8609
+		// Allow custom headers/mimetypes and early abort
8610
+		if ( s.beforeSend &&
8611
+			( s.beforeSend.call( callbackContext, jqXHR, s ) === false || state === 2 ) ) {
8612
+
8613
+			// Abort if not done already and return
8614
+			return jqXHR.abort();
8615
+		}
8616
+
8617
+		// Aborting is no longer a cancellation
8618
+		strAbort = "abort";
8619
+
8620
+		// Install callbacks on deferreds
8621
+		for ( i in { success: 1, error: 1, complete: 1 } ) {
8622
+			jqXHR[ i ]( s[ i ] );
8623
+		}
8624
+
8625
+		// Get transport
8626
+		transport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );
8627
+
8628
+		// If no transport, we auto-abort
8629
+		if ( !transport ) {
8630
+			done( -1, "No Transport" );
8631
+		} else {
8632
+			jqXHR.readyState = 1;
8633
+
8634
+			// Send global event
8635
+			if ( fireGlobals ) {
8636
+				globalEventContext.trigger( "ajaxSend", [ jqXHR, s ] );
8637
+			}
8638
+
8639
+			// If request was aborted inside ajaxSend, stop there
8640
+			if ( state === 2 ) {
8641
+				return jqXHR;
8642
+			}
8643
+
8644
+			// Timeout
8645
+			if ( s.async && s.timeout > 0 ) {
8646
+				timeoutTimer = window.setTimeout( function() {
8647
+					jqXHR.abort( "timeout" );
8648
+				}, s.timeout );
8649
+			}
8650
+
8651
+			try {
8652
+				state = 1;
8653
+				transport.send( requestHeaders, done );
8654
+			} catch ( e ) {
8655
+
8656
+				// Propagate exception as error if not done
8657
+				if ( state < 2 ) {
8658
+					done( -1, e );
8659
+
8660
+				// Simply rethrow otherwise
8661
+				} else {
8662
+					throw e;
8663
+				}
8664
+			}
8665
+		}
8666
+
8667
+		// Callback for when everything is done
8668
+		function done( status, nativeStatusText, responses, headers ) {
8669
+			var isSuccess, success, error, response, modified,
8670
+				statusText = nativeStatusText;
8671
+
8672
+			// Called once
8673
+			if ( state === 2 ) {
8674
+				return;
8675
+			}
8676
+
8677
+			// State is "done" now
8678
+			state = 2;
8679
+
8680
+			// Clear timeout if it exists
8681
+			if ( timeoutTimer ) {
8682
+				window.clearTimeout( timeoutTimer );
8683
+			}
8684
+
8685
+			// Dereference transport for early garbage collection
8686
+			// (no matter how long the jqXHR object will be used)
8687
+			transport = undefined;
8688
+
8689
+			// Cache response headers
8690
+			responseHeadersString = headers || "";
8691
+
8692
+			// Set readyState
8693
+			jqXHR.readyState = status > 0 ? 4 : 0;
8694
+
8695
+			// Determine if successful
8696
+			isSuccess = status >= 200 && status < 300 || status === 304;
8697
+
8698
+			// Get response data
8699
+			if ( responses ) {
8700
+				response = ajaxHandleResponses( s, jqXHR, responses );
8701
+			}
8702
+
8703
+			// Convert no matter what (that way responseXXX fields are always set)
8704
+			response = ajaxConvert( s, response, jqXHR, isSuccess );
8705
+
8706
+			// If successful, handle type chaining
8707
+			if ( isSuccess ) {
8708
+
8709
+				// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
8710
+				if ( s.ifModified ) {
8711
+					modified = jqXHR.getResponseHeader( "Last-Modified" );
8712
+					if ( modified ) {
8713
+						jQuery.lastModified[ cacheURL ] = modified;
8714
+					}
8715
+					modified = jqXHR.getResponseHeader( "etag" );
8716
+					if ( modified ) {
8717
+						jQuery.etag[ cacheURL ] = modified;
8718
+					}
8719
+				}
8720
+
8721
+				// if no content
8722
+				if ( status === 204 || s.type === "HEAD" ) {
8723
+					statusText = "nocontent";
8724
+
8725
+				// if not modified
8726
+				} else if ( status === 304 ) {
8727
+					statusText = "notmodified";
8728
+
8729
+				// If we have data, let's convert it
8730
+				} else {
8731
+					statusText = response.state;
8732
+					success = response.data;
8733
+					error = response.error;
8734
+					isSuccess = !error;
8735
+				}
8736
+			} else {
8737
+
8738
+				// Extract error from statusText and normalize for non-aborts
8739
+				error = statusText;
8740
+				if ( status || !statusText ) {
8741
+					statusText = "error";
8742
+					if ( status < 0 ) {
8743
+						status = 0;
8744
+					}
8745
+				}
8746
+			}
8747
+
8748
+			// Set data for the fake xhr object
8749
+			jqXHR.status = status;
8750
+			jqXHR.statusText = ( nativeStatusText || statusText ) + "";
8751
+
8752
+			// Success/Error
8753
+			if ( isSuccess ) {
8754
+				deferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );
8755
+			} else {
8756
+				deferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );
8757
+			}
8758
+
8759
+			// Status-dependent callbacks
8760
+			jqXHR.statusCode( statusCode );
8761
+			statusCode = undefined;
8762
+
8763
+			if ( fireGlobals ) {
8764
+				globalEventContext.trigger( isSuccess ? "ajaxSuccess" : "ajaxError",
8765
+					[ jqXHR, s, isSuccess ? success : error ] );
8766
+			}
8767
+
8768
+			// Complete
8769
+			completeDeferred.fireWith( callbackContext, [ jqXHR, statusText ] );
8770
+
8771
+			if ( fireGlobals ) {
8772
+				globalEventContext.trigger( "ajaxComplete", [ jqXHR, s ] );
8773
+
8774
+				// Handle the global AJAX counter
8775
+				if ( !( --jQuery.active ) ) {
8776
+					jQuery.event.trigger( "ajaxStop" );
8777
+				}
8778
+			}
8779
+		}
8780
+
8781
+		return jqXHR;
8782
+	},
8783
+
8784
+	getJSON: function( url, data, callback ) {
8785
+		return jQuery.get( url, data, callback, "json" );
8786
+	},
8787
+
8788
+	getScript: function( url, callback ) {
8789
+		return jQuery.get( url, undefined, callback, "script" );
8790
+	}
8791
+} );
8792
+
8793
+jQuery.each( [ "get", "post" ], function( i, method ) {
8794
+	jQuery[ method ] = function( url, data, callback, type ) {
8795
+
8796
+		// Shift arguments if data argument was omitted
8797
+		if ( jQuery.isFunction( data ) ) {
8798
+			type = type || callback;
8799
+			callback = data;
8800
+			data = undefined;
8801
+		}
8802
+
8803
+		// The url can be an options object (which then must have .url)
8804
+		return jQuery.ajax( jQuery.extend( {
8805
+			url: url,
8806
+			type: method,
8807
+			dataType: type,
8808
+			data: data,
8809
+			success: callback
8810
+		}, jQuery.isPlainObject( url ) && url ) );
8811
+	};
8812
+} );
8813
+
8814
+
8815
+jQuery._evalUrl = function( url ) {
8816
+	return jQuery.ajax( {
8817
+		url: url,
8818
+
8819
+		// Make this explicit, since user can override this through ajaxSetup (#11264)
8820
+		type: "GET",
8821
+		dataType: "script",
8822
+		async: false,
8823
+		global: false,
8824
+		"throws": true
8825
+	} );
8826
+};
8827
+
8828
+
8829
+jQuery.fn.extend( {
8830
+	wrapAll: function( html ) {
8831
+		var wrap;
8832
+
8833
+		if ( jQuery.isFunction( html ) ) {
8834
+			return this.each( function( i ) {
8835
+				jQuery( this ).wrapAll( html.call( this, i ) );
8836
+			} );
8837
+		}
8838
+
8839
+		if ( this[ 0 ] ) {
8840
+
8841
+			// The elements to wrap the target around
8842
+			wrap = jQuery( html, this[ 0 ].ownerDocument ).eq( 0 ).clone( true );
8843
+
8844
+			if ( this[ 0 ].parentNode ) {
8845
+				wrap.insertBefore( this[ 0 ] );
8846
+			}
8847
+
8848
+			wrap.map( function() {
8849
+				var elem = this;
8850
+
8851
+				while ( elem.firstElementChild ) {
8852
+					elem = elem.firstElementChild;
8853
+				}
8854
+
8855
+				return elem;
8856
+			} ).append( this );
8857
+		}
8858
+
8859
+		return this;
8860
+	},
8861
+
8862
+	wrapInner: function( html ) {
8863
+		if ( jQuery.isFunction( html ) ) {
8864
+			return this.each( function( i ) {
8865
+				jQuery( this ).wrapInner( html.call( this, i ) );
8866
+			} );
8867
+		}
8868
+
8869
+		return this.each( function() {
8870
+			var self = jQuery( this ),
8871
+				contents = self.contents();
8872
+
8873
+			if ( contents.length ) {
8874
+				contents.wrapAll( html );
8875
+
8876
+			} else {
8877
+				self.append( html );
8878
+			}
8879
+		} );
8880
+	},
8881
+
8882
+	wrap: function( html ) {
8883
+		var isFunction = jQuery.isFunction( html );
8884
+
8885
+		return this.each( function( i ) {
8886
+			jQuery( this ).wrapAll( isFunction ? html.call( this, i ) : html );
8887
+		} );
8888
+	},
8889
+
8890
+	unwrap: function() {
8891
+		return this.parent().each( function() {
8892
+			if ( !jQuery.nodeName( this, "body" ) ) {
8893
+				jQuery( this ).replaceWith( this.childNodes );
8894
+			}
8895
+		} ).end();
8896
+	}
8897
+} );
8898
+
8899
+
8900
+jQuery.expr.filters.hidden = function( elem ) {
8901
+	return !jQuery.expr.filters.visible( elem );
8902
+};
8903
+jQuery.expr.filters.visible = function( elem ) {
8904
+
8905
+	// Support: Opera <= 12.12
8906
+	// Opera reports offsetWidths and offsetHeights less than zero on some elements
8907
+	// Use OR instead of AND as the element is not visible if either is true
8908
+	// See tickets #10406 and #13132
8909
+	return elem.offsetWidth > 0 || elem.offsetHeight > 0 || elem.getClientRects().length > 0;
8910
+};
8911
+
8912
+
8913
+
8914
+
8915
+var r20 = /%20/g,
8916
+	rbracket = /\[\]$/,
8917
+	rCRLF = /\r?\n/g,
8918
+	rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,
8919
+	rsubmittable = /^(?:input|select|textarea|keygen)/i;
8920
+
8921
+function buildParams( prefix, obj, traditional, add ) {
8922
+	var name;
8923
+
8924
+	if ( jQuery.isArray( obj ) ) {
8925
+
8926
+		// Serialize array item.
8927
+		jQuery.each( obj, function( i, v ) {
8928
+			if ( traditional || rbracket.test( prefix ) ) {
8929
+
8930
+				// Treat each array item as a scalar.
8931
+				add( prefix, v );
8932
+
8933
+			} else {
8934
+
8935
+				// Item is non-scalar (array or object), encode its numeric index.
8936
+				buildParams(
8937
+					prefix + "[" + ( typeof v === "object" && v != null ? i : "" ) + "]",
8938
+					v,
8939
+					traditional,
8940
+					add
8941
+				);
8942
+			}
8943
+		} );
8944
+
8945
+	} else if ( !traditional && jQuery.type( obj ) === "object" ) {
8946
+
8947
+		// Serialize object item.
8948
+		for ( name in obj ) {
8949
+			buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add );
8950
+		}
8951
+
8952
+	} else {
8953
+
8954
+		// Serialize scalar item.
8955
+		add( prefix, obj );
8956
+	}
8957
+}
8958
+
8959
+// Serialize an array of form elements or a set of
8960
+// key/values into a query string
8961
+jQuery.param = function( a, traditional ) {
8962
+	var prefix,
8963
+		s = [],
8964
+		add = function( key, value ) {
8965
+
8966
+			// If value is a function, invoke it and return its value
8967
+			value = jQuery.isFunction( value ) ? value() : ( value == null ? "" : value );
8968
+			s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );
8969
+		};
8970
+
8971
+	// Set traditional to true for jQuery <= 1.3.2 behavior.
8972
+	if ( traditional === undefined ) {
8973
+		traditional = jQuery.ajaxSettings && jQuery.ajaxSettings.traditional;
8974
+	}
8975
+
8976
+	// If an array was passed in, assume that it is an array of form elements.
8977
+	if ( jQuery.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {
8978
+
8979
+		// Serialize the form elements
8980
+		jQuery.each( a, function() {
8981
+			add( this.name, this.value );
8982
+		} );
8983
+
8984
+	} else {
8985
+
8986
+		// If traditional, encode the "old" way (the way 1.3.2 or older
8987
+		// did it), otherwise encode params recursively.
8988
+		for ( prefix in a ) {
8989
+			buildParams( prefix, a[ prefix ], traditional, add );
8990
+		}
8991
+	}
8992
+
8993
+	// Return the resulting serialization
8994
+	return s.join( "&" ).replace( r20, "+" );
8995
+};
8996
+
8997
+jQuery.fn.extend( {
8998
+	serialize: function() {
8999
+		return jQuery.param( this.serializeArray() );
9000
+	},
9001
+	serializeArray: function() {
9002
+		return this.map( function() {
9003
+
9004
+			// Can add propHook for "elements" to filter or add form elements
9005
+			var elements = jQuery.prop( this, "elements" );
9006
+			return elements ? jQuery.makeArray( elements ) : this;
9007
+		} )
9008
+		.filter( function() {
9009
+			var type = this.type;
9010
+
9011
+			// Use .is( ":disabled" ) so that fieldset[disabled] works
9012
+			return this.name && !jQuery( this ).is( ":disabled" ) &&
9013
+				rsubmittable.test( this.nodeName ) && !rsubmitterTypes.test( type ) &&
9014
+				( this.checked || !rcheckableType.test( type ) );
9015
+		} )
9016
+		.map( function( i, elem ) {
9017
+			var val = jQuery( this ).val();
9018
+
9019
+			return val == null ?
9020
+				null :
9021
+				jQuery.isArray( val ) ?
9022
+					jQuery.map( val, function( val ) {
9023
+						return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
9024
+					} ) :
9025
+					{ name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
9026
+		} ).get();
9027
+	}
9028
+} );
9029
+
9030
+
9031
+jQuery.ajaxSettings.xhr = function() {
9032
+	try {
9033
+		return new window.XMLHttpRequest();
9034
+	} catch ( e ) {}
9035
+};
9036
+
9037
+var xhrSuccessStatus = {
9038
+
9039
+		// File protocol always yields status code 0, assume 200
9040
+		0: 200,
9041
+
9042
+		// Support: IE9
9043
+		// #1450: sometimes IE returns 1223 when it should be 204
9044
+		1223: 204
9045
+	},
9046
+	xhrSupported = jQuery.ajaxSettings.xhr();
9047
+
9048
+support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported );
9049
+support.ajax = xhrSupported = !!xhrSupported;
9050
+
9051
+jQuery.ajaxTransport( function( options ) {
9052
+	var callback, errorCallback;
9053
+
9054
+	// Cross domain only allowed if supported through XMLHttpRequest
9055
+	if ( support.cors || xhrSupported && !options.crossDomain ) {
9056
+		return {
9057
+			send: function( headers, complete ) {
9058
+				var i,
9059
+					xhr = options.xhr();
9060
+
9061
+				xhr.open(
9062
+					options.type,
9063
+					options.url,
9064
+					options.async,
9065
+					options.username,
9066
+					options.password
9067
+				);
9068
+
9069
+				// Apply custom fields if provided
9070
+				if ( options.xhrFields ) {
9071
+					for ( i in options.xhrFields ) {
9072
+						xhr[ i ] = options.xhrFields[ i ];
9073
+					}
9074
+				}
9075
+
9076
+				// Override mime type if needed
9077
+				if ( options.mimeType && xhr.overrideMimeType ) {
9078
+					xhr.overrideMimeType( options.mimeType );
9079
+				}
9080
+
9081
+				// X-Requested-With header
9082
+				// For cross-domain requests, seeing as conditions for a preflight are
9083
+				// akin to a jigsaw puzzle, we simply never set it to be sure.
9084
+				// (it can always be set on a per-request basis or even using ajaxSetup)
9085
+				// For same-domain requests, won't change header if already provided.
9086
+				if ( !options.crossDomain && !headers[ "X-Requested-With" ] ) {
9087
+					headers[ "X-Requested-With" ] = "XMLHttpRequest";
9088
+				}
9089
+
9090
+				// Set headers
9091
+				for ( i in headers ) {
9092
+					xhr.setRequestHeader( i, headers[ i ] );
9093
+				}
9094
+
9095
+				// Callback
9096
+				callback = function( type ) {
9097
+					return function() {
9098
+						if ( callback ) {
9099
+							callback = errorCallback = xhr.onload =
9100
+								xhr.onerror = xhr.onabort = xhr.onreadystatechange = null;
9101
+
9102
+							if ( type === "abort" ) {
9103
+								xhr.abort();
9104
+							} else if ( type === "error" ) {
9105
+
9106
+								// Support: IE9
9107
+								// On a manual native abort, IE9 throws
9108
+								// errors on any property access that is not readyState
9109
+								if ( typeof xhr.status !== "number" ) {
9110
+									complete( 0, "error" );
9111
+								} else {
9112
+									complete(
9113
+
9114
+										// File: protocol always yields status 0; see #8605, #14207
9115
+										xhr.status,
9116
+										xhr.statusText
9117
+									);
9118
+								}
9119
+							} else {
9120
+								complete(
9121
+									xhrSuccessStatus[ xhr.status ] || xhr.status,
9122
+									xhr.statusText,
9123
+
9124
+									// Support: IE9 only
9125
+									// IE9 has no XHR2 but throws on binary (trac-11426)
9126
+									// For XHR2 non-text, let the caller handle it (gh-2498)
9127
+									( xhr.responseType || "text" ) !== "text"  ||
9128
+									typeof xhr.responseText !== "string" ?
9129
+										{ binary: xhr.response } :
9130
+										{ text: xhr.responseText },
9131
+									xhr.getAllResponseHeaders()
9132
+								);
9133
+							}
9134
+						}
9135
+					};
9136
+				};
9137
+
9138
+				// Listen to events
9139
+				xhr.onload = callback();
9140
+				errorCallback = xhr.onerror = callback( "error" );
9141
+
9142
+				// Support: IE9
9143
+				// Use onreadystatechange to replace onabort
9144
+				// to handle uncaught aborts
9145
+				if ( xhr.onabort !== undefined ) {
9146
+					xhr.onabort = errorCallback;
9147
+				} else {
9148
+					xhr.onreadystatechange = function() {
9149
+
9150
+						// Check readyState before timeout as it changes
9151
+						if ( xhr.readyState === 4 ) {
9152
+
9153
+							// Allow onerror to be called first,
9154
+							// but that will not handle a native abort
9155
+							// Also, save errorCallback to a variable
9156
+							// as xhr.onerror cannot be accessed
9157
+							window.setTimeout( function() {
9158
+								if ( callback ) {
9159
+									errorCallback();
9160
+								}
9161
+							} );
9162
+						}
9163
+					};
9164
+				}
9165
+
9166
+				// Create the abort callback
9167
+				callback = callback( "abort" );
9168
+
9169
+				try {
9170
+
9171
+					// Do send the request (this may raise an exception)
9172
+					xhr.send( options.hasContent && options.data || null );
9173
+				} catch ( e ) {
9174
+
9175
+					// #14683: Only rethrow if this hasn't been notified as an error yet
9176
+					if ( callback ) {
9177
+						throw e;
9178
+					}
9179
+				}
9180
+			},
9181
+
9182
+			abort: function() {
9183
+				if ( callback ) {
9184
+					callback();
9185
+				}
9186
+			}
9187
+		};
9188
+	}
9189
+} );
9190
+
9191
+
9192
+
9193
+
9194
+// Install script dataType
9195
+jQuery.ajaxSetup( {
9196
+	accepts: {
9197
+		script: "text/javascript, application/javascript, " +
9198
+			"application/ecmascript, application/x-ecmascript"
9199
+	},
9200
+	contents: {
9201
+		script: /\b(?:java|ecma)script\b/
9202
+	},
9203
+	converters: {
9204
+		"text script": function( text ) {
9205
+			jQuery.globalEval( text );
9206
+			return text;
9207
+		}
9208
+	}
9209
+} );
9210
+
9211
+// Handle cache's special case and crossDomain
9212
+jQuery.ajaxPrefilter( "script", function( s ) {
9213
+	if ( s.cache === undefined ) {
9214
+		s.cache = false;
9215
+	}
9216
+	if ( s.crossDomain ) {
9217
+		s.type = "GET";
9218
+	}
9219
+} );
9220
+
9221
+// Bind script tag hack transport
9222
+jQuery.ajaxTransport( "script", function( s ) {
9223
+
9224
+	// This transport only deals with cross domain requests
9225
+	if ( s.crossDomain ) {
9226
+		var script, callback;
9227
+		return {
9228
+			send: function( _, complete ) {
9229
+				script = jQuery( "<script>" ).prop( {
9230
+					charset: s.scriptCharset,
9231
+					src: s.url
9232
+				} ).on(
9233
+					"load error",
9234
+					callback = function( evt ) {
9235
+						script.remove();
9236
+						callback = null;
9237
+						if ( evt ) {
9238
+							complete( evt.type === "error" ? 404 : 200, evt.type );
9239
+						}
9240
+					}
9241
+				);
9242
+
9243
+				// Use native DOM manipulation to avoid our domManip AJAX trickery
9244
+				document.head.appendChild( script[ 0 ] );
9245
+			},
9246
+			abort: function() {
9247
+				if ( callback ) {
9248
+					callback();
9249
+				}
9250
+			}
9251
+		};
9252
+	}
9253
+} );
9254
+
9255
+
9256
+
9257
+
9258
+var oldCallbacks = [],
9259
+	rjsonp = /(=)\?(?=&|$)|\?\?/;
9260
+
9261
+// Default jsonp settings
9262
+jQuery.ajaxSetup( {
9263
+	jsonp: "callback",
9264
+	jsonpCallback: function() {
9265
+		var callback = oldCallbacks.pop() || ( jQuery.expando + "_" + ( nonce++ ) );
9266
+		this[ callback ] = true;
9267
+		return callback;
9268
+	}
9269
+} );
9270
+
9271
+// Detect, normalize options and install callbacks for jsonp requests
9272
+jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {
9273
+
9274
+	var callbackName, overwritten, responseContainer,
9275
+		jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?
9276
+			"url" :
9277
+			typeof s.data === "string" &&
9278
+				( s.contentType || "" )
9279
+					.indexOf( "application/x-www-form-urlencoded" ) === 0 &&
9280
+				rjsonp.test( s.data ) && "data"
9281
+		);
9282
+
9283
+	// Handle iff the expected data type is "jsonp" or we have a parameter to set
9284
+	if ( jsonProp || s.dataTypes[ 0 ] === "jsonp" ) {
9285
+
9286
+		// Get callback name, remembering preexisting value associated with it
9287
+		callbackName = s.jsonpCallback = jQuery.isFunction( s.jsonpCallback ) ?
9288
+			s.jsonpCallback() :
9289
+			s.jsonpCallback;
9290
+
9291
+		// Insert callback into url or form data
9292
+		if ( jsonProp ) {
9293
+			s[ jsonProp ] = s[ jsonProp ].replace( rjsonp, "$1" + callbackName );
9294
+		} else if ( s.jsonp !== false ) {
9295
+			s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.jsonp + "=" + callbackName;
9296
+		}
9297
+
9298
+		// Use data converter to retrieve json after script execution
9299
+		s.converters[ "script json" ] = function() {
9300
+			if ( !responseContainer ) {
9301
+				jQuery.error( callbackName + " was not called" );
9302
+			}
9303
+			return responseContainer[ 0 ];
9304
+		};
9305
+
9306
+		// Force json dataType
9307
+		s.dataTypes[ 0 ] = "json";
9308
+
9309
+		// Install callback
9310
+		overwritten = window[ callbackName ];
9311
+		window[ callbackName ] = function() {
9312
+			responseContainer = arguments;
9313
+		};
9314
+
9315
+		// Clean-up function (fires after converters)
9316
+		jqXHR.always( function() {
9317
+
9318
+			// If previous value didn't exist - remove it
9319
+			if ( overwritten === undefined ) {
9320
+				jQuery( window ).removeProp( callbackName );
9321
+
9322
+			// Otherwise restore preexisting value
9323
+			} else {
9324
+				window[ callbackName ] = overwritten;
9325
+			}
9326
+
9327
+			// Save back as free
9328
+			if ( s[ callbackName ] ) {
9329
+
9330
+				// Make sure that re-using the options doesn't screw things around
9331
+				s.jsonpCallback = originalSettings.jsonpCallback;
9332
+
9333
+				// Save the callback name for future use
9334
+				oldCallbacks.push( callbackName );
9335
+			}
9336
+
9337
+			// Call if it was a function and we have a response
9338
+			if ( responseContainer && jQuery.isFunction( overwritten ) ) {
9339
+				overwritten( responseContainer[ 0 ] );
9340
+			}
9341
+
9342
+			responseContainer = overwritten = undefined;
9343
+		} );
9344
+
9345
+		// Delegate to script
9346
+		return "script";
9347
+	}
9348
+} );
9349
+
9350
+
9351
+
9352
+
9353
+// Support: Safari 8+
9354
+// In Safari 8 documents created via document.implementation.createHTMLDocument
9355
+// collapse sibling forms: the second one becomes a child of the first one.
9356
+// Because of that, this security measure has to be disabled in Safari 8.
9357
+// https://bugs.webkit.org/show_bug.cgi?id=137337
9358
+support.createHTMLDocument = ( function() {
9359
+	var body = document.implementation.createHTMLDocument( "" ).body;
9360
+	body.innerHTML = "<form></form><form></form>";
9361
+	return body.childNodes.length === 2;
9362
+} )();
9363
+
9364
+
9365
+// Argument "data" should be string of html
9366
+// context (optional): If specified, the fragment will be created in this context,
9367
+// defaults to document
9368
+// keepScripts (optional): If true, will include scripts passed in the html string
9369
+jQuery.parseHTML = function( data, context, keepScripts ) {
9370
+	if ( !data || typeof data !== "string" ) {
9371
+		return null;
9372
+	}
9373
+	if ( typeof context === "boolean" ) {
9374
+		keepScripts = context;
9375
+		context = false;
9376
+	}
9377
+
9378
+	// Stop scripts or inline event handlers from being executed immediately
9379
+	// by using document.implementation
9380
+	context = context || ( support.createHTMLDocument ?
9381
+		document.implementation.createHTMLDocument( "" ) :
9382
+		document );
9383
+
9384
+	var parsed = rsingleTag.exec( data ),
9385
+		scripts = !keepScripts && [];
9386
+
9387
+	// Single tag
9388
+	if ( parsed ) {
9389
+		return [ context.createElement( parsed[ 1 ] ) ];
9390
+	}
9391
+
9392
+	parsed = buildFragment( [ data ], context, scripts );
9393
+
9394
+	if ( scripts && scripts.length ) {
9395
+		jQuery( scripts ).remove();
9396
+	}
9397
+
9398
+	return jQuery.merge( [], parsed.childNodes );
9399
+};
9400
+
9401
+
9402
+// Keep a copy of the old load method
9403
+var _load = jQuery.fn.load;
9404
+
9405
+/**
9406
+ * Load a url into a page
9407
+ */
9408
+jQuery.fn.load = function( url, params, callback ) {
9409
+	if ( typeof url !== "string" && _load ) {
9410
+		return _load.apply( this, arguments );
9411
+	}
9412
+
9413
+	var selector, type, response,
9414
+		self = this,
9415
+		off = url.indexOf( " " );
9416
+
9417
+	if ( off > -1 ) {
9418
+		selector = jQuery.trim( url.slice( off ) );
9419
+		url = url.slice( 0, off );
9420
+	}
9421
+
9422
+	// If it's a function
9423
+	if ( jQuery.isFunction( params ) ) {
9424
+
9425
+		// We assume that it's the callback
9426
+		callback = params;
9427
+		params = undefined;
9428
+
9429
+	// Otherwise, build a param string
9430
+	} else if ( params && typeof params === "object" ) {
9431
+		type = "POST";
9432
+	}
9433
+
9434
+	// If we have elements to modify, make the request
9435
+	if ( self.length > 0 ) {
9436
+		jQuery.ajax( {
9437
+			url: url,
9438
+
9439
+			// If "type" variable is undefined, then "GET" method will be used.
9440
+			// Make value of this field explicit since
9441
+			// user can override it through ajaxSetup method
9442
+			type: type || "GET",
9443
+			dataType: "html",
9444
+			data: params
9445
+		} ).done( function( responseText ) {
9446
+
9447
+			// Save response for use in complete callback
9448
+			response = arguments;
9449
+
9450
+			self.html( selector ?
9451
+
9452
+				// If a selector was specified, locate the right elements in a dummy div
9453
+				// Exclude scripts to avoid IE 'Permission Denied' errors
9454
+				jQuery( "<div>" ).append( jQuery.parseHTML( responseText ) ).find( selector ) :
9455
+
9456
+				// Otherwise use the full result
9457
+				responseText );
9458
+
9459
+		// If the request succeeds, this function gets "data", "status", "jqXHR"
9460
+		// but they are ignored because response was set above.
9461
+		// If it fails, this function gets "jqXHR", "status", "error"
9462
+		} ).always( callback && function( jqXHR, status ) {
9463
+			self.each( function() {
9464
+				callback.apply( self, response || [ jqXHR.responseText, status, jqXHR ] );
9465
+			} );
9466
+		} );
9467
+	}
9468
+
9469
+	return this;
9470
+};
9471
+
9472
+
9473
+
9474
+
9475
+// Attach a bunch of functions for handling common AJAX events
9476
+jQuery.each( [
9477
+	"ajaxStart",
9478
+	"ajaxStop",
9479
+	"ajaxComplete",
9480
+	"ajaxError",
9481
+	"ajaxSuccess",
9482
+	"ajaxSend"
9483
+], function( i, type ) {
9484
+	jQuery.fn[ type ] = function( fn ) {
9485
+		return this.on( type, fn );
9486
+	};
9487
+} );
9488
+
9489
+
9490
+
9491
+
9492
+jQuery.expr.filters.animated = function( elem ) {
9493
+	return jQuery.grep( jQuery.timers, function( fn ) {
9494
+		return elem === fn.elem;
9495
+	} ).length;
9496
+};
9497
+
9498
+
9499
+
9500
+
9501
+/**
9502
+ * Gets a window from an element
9503
+ */
9504
+function getWindow( elem ) {
9505
+	return jQuery.isWindow( elem ) ? elem : elem.nodeType === 9 && elem.defaultView;
9506
+}
9507
+
9508
+jQuery.offset = {
9509
+	setOffset: function( elem, options, i ) {
9510
+		var curPosition, curLeft, curCSSTop, curTop, curOffset, curCSSLeft, calculatePosition,
9511
+			position = jQuery.css( elem, "position" ),
9512
+			curElem = jQuery( elem ),
9513
+			props = {};
9514
+
9515
+		// Set position first, in-case top/left are set even on static elem
9516
+		if ( position === "static" ) {
9517
+			elem.style.position = "relative";
9518
+		}
9519
+
9520
+		curOffset = curElem.offset();
9521
+		curCSSTop = jQuery.css( elem, "top" );
9522
+		curCSSLeft = jQuery.css( elem, "left" );
9523
+		calculatePosition = ( position === "absolute" || position === "fixed" ) &&
9524
+			( curCSSTop + curCSSLeft ).indexOf( "auto" ) > -1;
9525
+
9526
+		// Need to be able to calculate position if either
9527
+		// top or left is auto and position is either absolute or fixed
9528
+		if ( calculatePosition ) {
9529
+			curPosition = curElem.position();
9530
+			curTop = curPosition.top;
9531
+			curLeft = curPosition.left;
9532
+
9533
+		} else {
9534
+			curTop = parseFloat( curCSSTop ) || 0;
9535
+			curLeft = parseFloat( curCSSLeft ) || 0;
9536
+		}
9537
+
9538
+		if ( jQuery.isFunction( options ) ) {
9539
+
9540
+			// Use jQuery.extend here to allow modification of coordinates argument (gh-1848)
9541
+			options = options.call( elem, i, jQuery.extend( {}, curOffset ) );
9542
+		}
9543
+
9544
+		if ( options.top != null ) {
9545
+			props.top = ( options.top - curOffset.top ) + curTop;
9546
+		}
9547
+		if ( options.left != null ) {
9548
+			props.left = ( options.left - curOffset.left ) + curLeft;
9549
+		}
9550
+
9551
+		if ( "using" in options ) {
9552
+			options.using.call( elem, props );
9553
+
9554
+		} else {
9555
+			curElem.css( props );
9556
+		}
9557
+	}
9558
+};
9559
+
9560
+jQuery.fn.extend( {
9561
+	offset: function( options ) {
9562
+		if ( arguments.length ) {
9563
+			return options === undefined ?
9564
+				this :
9565
+				this.each( function( i ) {
9566
+					jQuery.offset.setOffset( this, options, i );
9567
+				} );
9568
+		}
9569
+
9570
+		var docElem, win,
9571
+			elem = this[ 0 ],
9572
+			box = { top: 0, left: 0 },
9573
+			doc = elem && elem.ownerDocument;
9574
+
9575
+		if ( !doc ) {
9576
+			return;
9577
+		}
9578
+
9579
+		docElem = doc.documentElement;
9580
+
9581
+		// Make sure it's not a disconnected DOM node
9582
+		if ( !jQuery.contains( docElem, elem ) ) {
9583
+			return box;
9584
+		}
9585
+
9586
+		box = elem.getBoundingClientRect();
9587
+		win = getWindow( doc );
9588
+		return {
9589
+			top: box.top + win.pageYOffset - docElem.clientTop,
9590
+			left: box.left + win.pageXOffset - docElem.clientLeft
9591
+		};
9592
+	},
9593
+
9594
+	position: function() {
9595
+		if ( !this[ 0 ] ) {
9596
+			return;
9597
+		}
9598
+
9599
+		var offsetParent, offset,
9600
+			elem = this[ 0 ],
9601
+			parentOffset = { top: 0, left: 0 };
9602
+
9603
+		// Fixed elements are offset from window (parentOffset = {top:0, left: 0},
9604
+		// because it is its only offset parent
9605
+		if ( jQuery.css( elem, "position" ) === "fixed" ) {
9606
+
9607
+			// Assume getBoundingClientRect is there when computed position is fixed
9608
+			offset = elem.getBoundingClientRect();
9609
+
9610
+		} else {
9611
+
9612
+			// Get *real* offsetParent
9613
+			offsetParent = this.offsetParent();
9614
+
9615
+			// Get correct offsets
9616
+			offset = this.offset();
9617
+			if ( !jQuery.nodeName( offsetParent[ 0 ], "html" ) ) {
9618
+				parentOffset = offsetParent.offset();
9619
+			}
9620
+
9621
+			// Add offsetParent borders
9622
+			// Subtract offsetParent scroll positions
9623
+			parentOffset.top += jQuery.css( offsetParent[ 0 ], "borderTopWidth", true ) -
9624
+				offsetParent.scrollTop();
9625
+			parentOffset.left += jQuery.css( offsetParent[ 0 ], "borderLeftWidth", true ) -
9626
+				offsetParent.scrollLeft();
9627
+		}
9628
+
9629
+		// Subtract parent offsets and element margins
9630
+		return {
9631
+			top: offset.top - parentOffset.top - jQuery.css( elem, "marginTop", true ),
9632
+			left: offset.left - parentOffset.left - jQuery.css( elem, "marginLeft", true )
9633
+		};
9634
+	},
9635
+
9636
+	// This method will return documentElement in the following cases:
9637
+	// 1) For the element inside the iframe without offsetParent, this method will return
9638
+	//    documentElement of the parent window
9639
+	// 2) For the hidden or detached element
9640
+	// 3) For body or html element, i.e. in case of the html node - it will return itself
9641
+	//
9642
+	// but those exceptions were never presented as a real life use-cases
9643
+	// and might be considered as more preferable results.
9644
+	//
9645
+	// This logic, however, is not guaranteed and can change at any point in the future
9646
+	offsetParent: function() {
9647
+		return this.map( function() {
9648
+			var offsetParent = this.offsetParent;
9649
+
9650
+			while ( offsetParent && jQuery.css( offsetParent, "position" ) === "static" ) {
9651
+				offsetParent = offsetParent.offsetParent;
9652
+			}
9653
+
9654
+			return offsetParent || documentElement;
9655
+		} );
9656
+	}
9657
+} );
9658
+
9659
+// Create scrollLeft and scrollTop methods
9660
+jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function( method, prop ) {
9661
+	var top = "pageYOffset" === prop;
9662
+
9663
+	jQuery.fn[ method ] = function( val ) {
9664
+		return access( this, function( elem, method, val ) {
9665
+			var win = getWindow( elem );
9666
+
9667
+			if ( val === undefined ) {
9668
+				return win ? win[ prop ] : elem[ method ];
9669
+			}
9670
+
9671
+			if ( win ) {
9672
+				win.scrollTo(
9673
+					!top ? val : win.pageXOffset,
9674
+					top ? val : win.pageYOffset
9675
+				);
9676
+
9677
+			} else {
9678
+				elem[ method ] = val;
9679
+			}
9680
+		}, method, val, arguments.length );
9681
+	};
9682
+} );
9683
+
9684
+// Support: Safari<7-8+, Chrome<37-44+
9685
+// Add the top/left cssHooks using jQuery.fn.position
9686
+// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084
9687
+// Blink bug: https://code.google.com/p/chromium/issues/detail?id=229280
9688
+// getComputedStyle returns percent when specified for top/left/bottom/right;
9689
+// rather than make the css module depend on the offset module, just check for it here
9690
+jQuery.each( [ "top", "left" ], function( i, prop ) {
9691
+	jQuery.cssHooks[ prop ] = addGetHookIf( support.pixelPosition,
9692
+		function( elem, computed ) {
9693
+			if ( computed ) {
9694
+				computed = curCSS( elem, prop );
9695
+
9696
+				// If curCSS returns percentage, fallback to offset
9697
+				return rnumnonpx.test( computed ) ?
9698
+					jQuery( elem ).position()[ prop ] + "px" :
9699
+					computed;
9700
+			}
9701
+		}
9702
+	);
9703
+} );
9704
+
9705
+
9706
+// Create innerHeight, innerWidth, height, width, outerHeight and outerWidth methods
9707
+jQuery.each( { Height: "height", Width: "width" }, function( name, type ) {
9708
+	jQuery.each( { padding: "inner" + name, content: type, "": "outer" + name },
9709
+		function( defaultExtra, funcName ) {
9710
+
9711
+		// Margin is only for outerHeight, outerWidth
9712
+		jQuery.fn[ funcName ] = function( margin, value ) {
9713
+			var chainable = arguments.length && ( defaultExtra || typeof margin !== "boolean" ),
9714
+				extra = defaultExtra || ( margin === true || value === true ? "margin" : "border" );
9715
+
9716
+			return access( this, function( elem, type, value ) {
9717
+				var doc;
9718
+
9719
+				if ( jQuery.isWindow( elem ) ) {
9720
+
9721
+					// As of 5/8/2012 this will yield incorrect results for Mobile Safari, but there
9722
+					// isn't a whole lot we can do. See pull request at this URL for discussion:
9723
+					// https://github.com/jquery/jquery/pull/764
9724
+					return elem.document.documentElement[ "client" + name ];
9725
+				}
9726
+
9727
+				// Get document width or height
9728
+				if ( elem.nodeType === 9 ) {
9729
+					doc = elem.documentElement;
9730
+
9731
+					// Either scroll[Width/Height] or offset[Width/Height] or client[Width/Height],
9732
+					// whichever is greatest
9733
+					return Math.max(
9734
+						elem.body[ "scroll" + name ], doc[ "scroll" + name ],
9735
+						elem.body[ "offset" + name ], doc[ "offset" + name ],
9736
+						doc[ "client" + name ]
9737
+					);
9738
+				}
9739
+
9740
+				return value === undefined ?
9741
+
9742
+					// Get width or height on the element, requesting but not forcing parseFloat
9743
+					jQuery.css( elem, type, extra ) :
9744
+
9745
+					// Set width or height on the element
9746
+					jQuery.style( elem, type, value, extra );
9747
+			}, type, chainable ? margin : undefined, chainable, null );
9748
+		};
9749
+	} );
9750
+} );
9751
+
9752
+
9753
+jQuery.fn.extend( {
9754
+
9755
+	bind: function( types, data, fn ) {
9756
+		return this.on( types, null, data, fn );
9757
+	},
9758
+	unbind: function( types, fn ) {
9759
+		return this.off( types, null, fn );
9760
+	},
9761
+
9762
+	delegate: function( selector, types, data, fn ) {
9763
+		return this.on( types, selector, data, fn );
9764
+	},
9765
+	undelegate: function( selector, types, fn ) {
9766
+
9767
+		// ( namespace ) or ( selector, types [, fn] )
9768
+		return arguments.length === 1 ?
9769
+			this.off( selector, "**" ) :
9770
+			this.off( types, selector || "**", fn );
9771
+	},
9772
+	size: function() {
9773
+		return this.length;
9774
+	}
9775
+} );
9776
+
9777
+jQuery.fn.andSelf = jQuery.fn.addBack;
9778
+
9779
+
9780
+
9781
+
9782
+// Register as a named AMD module, since jQuery can be concatenated with other
9783
+// files that may use define, but not via a proper concatenation script that
9784
+// understands anonymous AMD modules. A named AMD is safest and most robust
9785
+// way to register. Lowercase jquery is used because AMD module names are
9786
+// derived from file names, and jQuery is normally delivered in a lowercase
9787
+// file name. Do this after creating the global so that if an AMD module wants
9788
+// to call noConflict to hide this version of jQuery, it will work.
9789
+
9790
+// Note that for maximum portability, libraries that are not jQuery should
9791
+// declare themselves as anonymous modules, and avoid setting a global if an
9792
+// AMD loader is present. jQuery is a special case. For more information, see
9793
+// https://github.com/jrburke/requirejs/wiki/Updating-existing-libraries#wiki-anon
9794
+
9795
+if ( typeof define === "function" && define.amd ) {
9796
+	define( "jquery", [], function() {
9797
+		return jQuery;
9798
+	} );
9799
+}
9800
+
9801
+
9802
+
9803
+var
9804
+
9805
+	// Map over jQuery in case of overwrite
9806
+	_jQuery = window.jQuery,
9807
+
9808
+	// Map over the $ in case of overwrite
9809
+	_$ = window.$;
9810
+
9811
+jQuery.noConflict = function( deep ) {
9812
+	if ( window.$ === jQuery ) {
9813
+		window.$ = _$;
9814
+	}
9815
+
9816
+	if ( deep && window.jQuery === jQuery ) {
9817
+		window.jQuery = _jQuery;
9818
+	}
9819
+
9820
+	return jQuery;
9821
+};
9822
+
9823
+// Expose jQuery and $ identifiers, even in AMD
9824
+// (#7102#comment:10, https://github.com/jquery/jquery/pull/557)
9825
+// and CommonJS for browser emulators (#13566)
9826
+if ( !noGlobal ) {
9827
+	window.jQuery = window.$ = jQuery;
9828
+}
9829
+
9830
+return jQuery;
9831
+}));
0 9832
new file mode 100644
... ...
@@ -0,0 +1,9530 @@
1
+/*!
2
+ * Vue.js v1.0.15
3
+ * (c) 2016 Evan You
4
+ * Released under the MIT License.
5
+ */
6
+(function (global, factory) {
7
+  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
8
+  typeof define === 'function' && define.amd ? define(factory) :
9
+  global.Vue = factory();
10
+}(this, function () { 'use strict';
11
+
12
+  function set(obj, key, val) {
13
+    if (hasOwn(obj, key)) {
14
+      obj[key] = val;
15
+      return;
16
+    }
17
+    if (obj._isVue) {
18
+      set(obj._data, key, val);
19
+      return;
20
+    }
21
+    var ob = obj.__ob__;
22
+    if (!ob) {
23
+      obj[key] = val;
24
+      return;
25
+    }
26
+    ob.convert(key, val);
27
+    ob.dep.notify();
28
+    if (ob.vms) {
29
+      var i = ob.vms.length;
30
+      while (i--) {
31
+        var vm = ob.vms[i];
32
+        vm._proxy(key);
33
+        vm._digest();
34
+      }
35
+    }
36
+    return val;
37
+  }
38
+
39
+  /**
40
+   * Delete a property and trigger change if necessary.
41
+   *
42
+   * @param {Object} obj
43
+   * @param {String} key
44
+   */
45
+
46
+  function del(obj, key) {
47
+    if (!hasOwn(obj, key)) {
48
+      return;
49
+    }
50
+    delete obj[key];
51
+    var ob = obj.__ob__;
52
+    if (!ob) {
53
+      return;
54
+    }
55
+    ob.dep.notify();
56
+    if (ob.vms) {
57
+      var i = ob.vms.length;
58
+      while (i--) {
59
+        var vm = ob.vms[i];
60
+        vm._unproxy(key);
61
+        vm._digest();
62
+      }
63
+    }
64
+  }
65
+
66
+  var hasOwnProperty = Object.prototype.hasOwnProperty;
67
+  /**
68
+   * Check whether the object has the property.
69
+   *
70
+   * @param {Object} obj
71
+   * @param {String} key
72
+   * @return {Boolean}
73
+   */
74
+
75
+  function hasOwn(obj, key) {
76
+    return hasOwnProperty.call(obj, key);
77
+  }
78
+
79
+  /**
80
+   * Check if an expression is a literal value.
81
+   *
82
+   * @param {String} exp
83
+   * @return {Boolean}
84
+   */
85
+
86
+  var literalValueRE = /^\s?(true|false|[\d\.]+|'[^']*'|"[^"]*")\s?$/;
87
+
88
+  function isLiteral(exp) {
89
+    return literalValueRE.test(exp);
90
+  }
91
+
92
+  /**
93
+   * Check if a string starts with $ or _
94
+   *
95
+   * @param {String} str
96
+   * @return {Boolean}
97
+   */
98
+
99
+  function isReserved(str) {
100
+    var c = (str + '').charCodeAt(0);
101
+    return c === 0x24 || c === 0x5F;
102
+  }
103
+
104
+  /**
105
+   * Guard text output, make sure undefined outputs
106
+   * empty string
107
+   *
108
+   * @param {*} value
109
+   * @return {String}
110
+   */
111
+
112
+  function _toString(value) {
113
+    return value == null ? '' : value.toString();
114
+  }
115
+
116
+  /**
117
+   * Check and convert possible numeric strings to numbers
118
+   * before setting back to data
119
+   *
120
+   * @param {*} value
121
+   * @return {*|Number}
122
+   */
123
+
124
+  function toNumber(value) {
125
+    if (typeof value !== 'string') {
126
+      return value;
127
+    } else {
128
+      var parsed = Number(value);
129
+      return isNaN(parsed) ? value : parsed;
130
+    }
131
+  }
132
+
133
+  /**
134
+   * Convert string boolean literals into real booleans.
135
+   *
136
+   * @param {*} value
137
+   * @return {*|Boolean}
138
+   */
139
+
140
+  function toBoolean(value) {
141
+    return value === 'true' ? true : value === 'false' ? false : value;
142
+  }
143
+
144
+  /**
145
+   * Strip quotes from a string
146
+   *
147
+   * @param {String} str
148
+   * @return {String | false}
149
+   */
150
+
151
+  function stripQuotes(str) {
152
+    var a = str.charCodeAt(0);
153
+    var b = str.charCodeAt(str.length - 1);
154
+    return a === b && (a === 0x22 || a === 0x27) ? str.slice(1, -1) : str;
155
+  }
156
+
157
+  /**
158
+   * Camelize a hyphen-delmited string.
159
+   *
160
+   * @param {String} str
161
+   * @return {String}
162
+   */
163
+
164
+  var camelizeRE = /-(\w)/g;
165
+
166
+  function camelize(str) {
167
+    return str.replace(camelizeRE, toUpper);
168
+  }
169
+
170
+  function toUpper(_, c) {
171
+    return c ? c.toUpperCase() : '';
172
+  }
173
+
174
+  /**
175
+   * Hyphenate a camelCase string.
176
+   *
177
+   * @param {String} str
178
+   * @return {String}
179
+   */
180
+
181
+  var hyphenateRE = /([a-z\d])([A-Z])/g;
182
+
183
+  function hyphenate(str) {
184
+    return str.replace(hyphenateRE, '$1-$2').toLowerCase();
185
+  }
186
+
187
+  /**
188
+   * Converts hyphen/underscore/slash delimitered names into
189
+   * camelized classNames.
190
+   *
191
+   * e.g. my-component => MyComponent
192
+   *      some_else    => SomeElse
193
+   *      some/comp    => SomeComp
194
+   *
195
+   * @param {String} str
196
+   * @return {String}
197
+   */
198
+
199
+  var classifyRE = /(?:^|[-_\/])(\w)/g;
200
+
201
+  function classify(str) {
202
+    return str.replace(classifyRE, toUpper);
203
+  }
204
+
205
+  /**
206
+   * Simple bind, faster than native
207
+   *
208
+   * @param {Function} fn
209
+   * @param {Object} ctx
210
+   * @return {Function}
211
+   */
212
+
213
+  function bind$1(fn, ctx) {
214
+    return function (a) {
215
+      var l = arguments.length;
216
+      return l ? l > 1 ? fn.apply(ctx, arguments) : fn.call(ctx, a) : fn.call(ctx);
217
+    };
218
+  }
219
+
220
+  /**
221
+   * Convert an Array-like object to a real Array.
222
+   *
223
+   * @param {Array-like} list
224
+   * @param {Number} [start] - start index
225
+   * @return {Array}
226
+   */
227
+
228
+  function toArray(list, start) {
229
+    start = start || 0;
230
+    var i = list.length - start;
231
+    var ret = new Array(i);
232
+    while (i--) {
233
+      ret[i] = list[i + start];
234
+    }
235
+    return ret;
236
+  }
237
+
238
+  /**
239
+   * Mix properties into target object.
240
+   *
241
+   * @param {Object} to
242
+   * @param {Object} from
243
+   */
244
+
245
+  function extend(to, from) {
246
+    var keys = Object.keys(from);
247
+    var i = keys.length;
248
+    while (i--) {
249
+      to[keys[i]] = from[keys[i]];
250
+    }
251
+    return to;
252
+  }
253
+
254
+  /**
255
+   * Quick object check - this is primarily used to tell
256
+   * Objects from primitive values when we know the value
257
+   * is a JSON-compliant type.
258
+   *
259
+   * @param {*} obj
260
+   * @return {Boolean}
261
+   */
262
+
263
+  function isObject(obj) {
264
+    return obj !== null && typeof obj === 'object';
265
+  }
266
+
267
+  /**
268
+   * Strict object type check. Only returns true
269
+   * for plain JavaScript objects.
270
+   *
271
+   * @param {*} obj
272
+   * @return {Boolean}
273
+   */
274
+
275
+  var toString = Object.prototype.toString;
276
+  var OBJECT_STRING = '[object Object]';
277
+
278
+  function isPlainObject(obj) {
279
+    return toString.call(obj) === OBJECT_STRING;
280
+  }
281
+
282
+  /**
283
+   * Array type check.
284
+   *
285
+   * @param {*} obj
286
+   * @return {Boolean}
287
+   */
288
+
289
+  var isArray = Array.isArray;
290
+
291
+  /**
292
+   * Define a non-enumerable property
293
+   *
294
+   * @param {Object} obj
295
+   * @param {String} key
296
+   * @param {*} val
297
+   * @param {Boolean} [enumerable]
298
+   */
299
+
300
+  function def(obj, key, val, enumerable) {
301
+    Object.defineProperty(obj, key, {
302
+      value: val,
303
+      enumerable: !!enumerable,
304
+      writable: true,
305
+      configurable: true
306
+    });
307
+  }
308
+
309
+  /**
310
+   * Debounce a function so it only gets called after the
311
+   * input stops arriving after the given wait period.
312
+   *
313
+   * @param {Function} func
314
+   * @param {Number} wait
315
+   * @return {Function} - the debounced function
316
+   */
317
+
318
+  function _debounce(func, wait) {
319
+    var timeout, args, context, timestamp, result;
320
+    var later = function later() {
321
+      var last = Date.now() - timestamp;
322
+      if (last < wait && last >= 0) {
323
+        timeout = setTimeout(later, wait - last);
324
+      } else {
325
+        timeout = null;
326
+        result = func.apply(context, args);
327
+        if (!timeout) context = args = null;
328
+      }
329
+    };
330
+    return function () {
331
+      context = this;
332
+      args = arguments;
333
+      timestamp = Date.now();
334
+      if (!timeout) {
335
+        timeout = setTimeout(later, wait);
336
+      }
337
+      return result;
338
+    };
339
+  }
340
+
341
+  /**
342
+   * Manual indexOf because it's slightly faster than
343
+   * native.
344
+   *
345
+   * @param {Array} arr
346
+   * @param {*} obj
347
+   */
348
+
349
+  function indexOf(arr, obj) {
350
+    var i = arr.length;
351
+    while (i--) {
352
+      if (arr[i] === obj) return i;
353
+    }
354
+    return -1;
355
+  }
356
+
357
+  /**
358
+   * Make a cancellable version of an async callback.
359
+   *
360
+   * @param {Function} fn
361
+   * @return {Function}
362
+   */
363
+
364
+  function cancellable(fn) {
365
+    var cb = function cb() {
366
+      if (!cb.cancelled) {
367
+        return fn.apply(this, arguments);
368
+      }
369
+    };
370
+    cb.cancel = function () {
371
+      cb.cancelled = true;
372
+    };
373
+    return cb;
374
+  }
375
+
376
+  /**
377
+   * Check if two values are loosely equal - that is,
378
+   * if they are plain objects, do they have the same shape?
379
+   *
380
+   * @param {*} a
381
+   * @param {*} b
382
+   * @return {Boolean}
383
+   */
384
+
385
+  function looseEqual(a, b) {
386
+    /* eslint-disable eqeqeq */
387
+    return a == b || (isObject(a) && isObject(b) ? JSON.stringify(a) === JSON.stringify(b) : false);
388
+    /* eslint-enable eqeqeq */
389
+  }
390
+
391
+  var hasProto = ('__proto__' in {});
392
+
393
+  // Browser environment sniffing
394
+  var inBrowser = typeof window !== 'undefined' && Object.prototype.toString.call(window) !== '[object Object]';
395
+
396
+  var isIE9 = inBrowser && navigator.userAgent.toLowerCase().indexOf('msie 9.0') > 0;
397
+
398
+  var isAndroid = inBrowser && navigator.userAgent.toLowerCase().indexOf('android') > 0;
399
+
400
+  var transitionProp = undefined;
401
+  var transitionEndEvent = undefined;
402
+  var animationProp = undefined;
403
+  var animationEndEvent = undefined;
404
+
405
+  // Transition property/event sniffing
406
+  if (inBrowser && !isIE9) {
407
+    var isWebkitTrans = window.ontransitionend === undefined && window.onwebkittransitionend !== undefined;
408
+    var isWebkitAnim = window.onanimationend === undefined && window.onwebkitanimationend !== undefined;
409
+    transitionProp = isWebkitTrans ? 'WebkitTransition' : 'transition';
410
+    transitionEndEvent = isWebkitTrans ? 'webkitTransitionEnd' : 'transitionend';
411
+    animationProp = isWebkitAnim ? 'WebkitAnimation' : 'animation';
412
+    animationEndEvent = isWebkitAnim ? 'webkitAnimationEnd' : 'animationend';
413
+  }
414
+
415
+  /**
416
+   * Defer a task to execute it asynchronously. Ideally this
417
+   * should be executed as a microtask, so we leverage
418
+   * MutationObserver if it's available, and fallback to
419
+   * setTimeout(0).
420
+   *
421
+   * @param {Function} cb
422
+   * @param {Object} ctx
423
+   */
424
+
425
+  var nextTick = (function () {
426
+    var callbacks = [];
427
+    var pending = false;
428
+    var timerFunc;
429
+    function nextTickHandler() {
430
+      pending = false;
431
+      var copies = callbacks.slice(0);
432
+      callbacks = [];
433
+      for (var i = 0; i < copies.length; i++) {
434
+        copies[i]();
435
+      }
436
+    }
437
+    /* istanbul ignore if */
438
+    if (typeof MutationObserver !== 'undefined') {
439
+      var counter = 1;
440
+      var observer = new MutationObserver(nextTickHandler);
441
+      var textNode = document.createTextNode(counter);
442
+      observer.observe(textNode, {
443
+        characterData: true
444
+      });
445
+      timerFunc = function () {
446
+        counter = (counter + 1) % 2;
447
+        textNode.data = counter;
448
+      };
449
+    } else {
450
+      timerFunc = setTimeout;
451
+    }
452
+    return function (cb, ctx) {
453
+      var func = ctx ? function () {
454
+        cb.call(ctx);
455
+      } : cb;
456
+      callbacks.push(func);
457
+      if (pending) return;
458
+      pending = true;
459
+      timerFunc(nextTickHandler, 0);
460
+    };
461
+  })();
462
+
463
+  function Cache(limit) {
464
+    this.size = 0;
465
+    this.limit = limit;
466
+    this.head = this.tail = undefined;
467
+    this._keymap = Object.create(null);
468
+  }
469
+
470
+  var p = Cache.prototype;
471
+
472
+  /**
473
+   * Put <value> into the cache associated with <key>.
474
+   * Returns the entry which was removed to make room for
475
+   * the new entry. Otherwise undefined is returned.
476
+   * (i.e. if there was enough room already).
477
+   *
478
+   * @param {String} key
479
+   * @param {*} value
480
+   * @return {Entry|undefined}
481
+   */
482
+
483
+  p.put = function (key, value) {
484
+    var removed;
485
+    if (this.size === this.limit) {
486
+      removed = this.shift();
487
+    }
488
+
489
+    var entry = this.get(key, true);
490
+    if (!entry) {
491
+      entry = {
492
+        key: key
493
+      };
494
+      this._keymap[key] = entry;
495
+      if (this.tail) {
496
+        this.tail.newer = entry;
497
+        entry.older = this.tail;
498
+      } else {
499
+        this.head = entry;
500
+      }
501
+      this.tail = entry;
502
+      this.size++;
503
+    }
504
+    entry.value = value;
505
+
506
+    return removed;
507
+  };
508
+
509
+  /**
510
+   * Purge the least recently used (oldest) entry from the
511
+   * cache. Returns the removed entry or undefined if the
512
+   * cache was empty.
513
+   */
514
+
515
+  p.shift = function () {
516
+    var entry = this.head;
517
+    if (entry) {
518
+      this.head = this.head.newer;
519
+      this.head.older = undefined;
520
+      entry.newer = entry.older = undefined;
521
+      this._keymap[entry.key] = undefined;
522
+      this.size--;
523
+    }
524
+    return entry;
525
+  };
526
+
527
+  /**
528
+   * Get and register recent use of <key>. Returns the value
529
+   * associated with <key> or undefined if not in cache.
530
+   *
531
+   * @param {String} key
532
+   * @param {Boolean} returnEntry
533
+   * @return {Entry|*}
534
+   */
535
+
536
+  p.get = function (key, returnEntry) {
537
+    var entry = this._keymap[key];
538
+    if (entry === undefined) return;
539
+    if (entry === this.tail) {
540
+      return returnEntry ? entry : entry.value;
541
+    }
542
+    // HEAD--------------TAIL
543
+    //   <.older   .newer>
544
+    //  <--- add direction --
545
+    //   A  B  C  <D>  E
546
+    if (entry.newer) {
547
+      if (entry === this.head) {
548
+        this.head = entry.newer;
549
+      }
550
+      entry.newer.older = entry.older; // C <-- E.
551
+    }
552
+    if (entry.older) {
553
+      entry.older.newer = entry.newer; // C. --> E
554
+    }
555
+    entry.newer = undefined; // D --x
556
+    entry.older = this.tail; // D. --> E
557
+    if (this.tail) {
558
+      this.tail.newer = entry; // E. <-- D
559
+    }
560
+    this.tail = entry;
561
+    return returnEntry ? entry : entry.value;
562
+  };
563
+
564
+  var cache$1 = new Cache(1000);
565
+  var filterTokenRE = /[^\s'"]+|'[^']*'|"[^"]*"/g;
566
+  var reservedArgRE = /^in$|^-?\d+/;
567
+
568
+  /**
569
+   * Parser state
570
+   */
571
+
572
+  var str;
573
+  var dir;
574
+  var c;
575
+  var prev;
576
+  var i;
577
+  var l;
578
+  var lastFilterIndex;
579
+  var inSingle;
580
+  var inDouble;
581
+  var curly;
582
+  var square;
583
+  var paren;
584
+  /**
585
+   * Push a filter to the current directive object
586
+   */
587
+
588
+  function pushFilter() {
589
+    var exp = str.slice(lastFilterIndex, i).trim();
590
+    var filter;
591
+    if (exp) {
592
+      filter = {};
593
+      var tokens = exp.match(filterTokenRE);
594
+      filter.name = tokens[0];
595
+      if (tokens.length > 1) {
596
+        filter.args = tokens.slice(1).map(processFilterArg);
597
+      }
598
+    }
599
+    if (filter) {
600
+      (dir.filters = dir.filters || []).push(filter);
601
+    }
602
+    lastFilterIndex = i + 1;
603
+  }
604
+
605
+  /**
606
+   * Check if an argument is dynamic and strip quotes.
607
+   *
608
+   * @param {String} arg
609
+   * @return {Object}
610
+   */
611
+
612
+  function processFilterArg(arg) {
613
+    if (reservedArgRE.test(arg)) {
614
+      return {
615
+        value: toNumber(arg),
616
+        dynamic: false
617
+      };
618
+    } else {
619
+      var stripped = stripQuotes(arg);
620
+      var dynamic = stripped === arg;
621
+      return {
622
+        value: dynamic ? arg : stripped,
623
+        dynamic: dynamic
624
+      };
625
+    }
626
+  }
627
+
628
+  /**
629
+   * Parse a directive value and extract the expression
630
+   * and its filters into a descriptor.
631
+   *
632
+   * Example:
633
+   *
634
+   * "a + 1 | uppercase" will yield:
635
+   * {
636
+   *   expression: 'a + 1',
637
+   *   filters: [
638
+   *     { name: 'uppercase', args: null }
639
+   *   ]
640
+   * }
641
+   *
642
+   * @param {String} str
643
+   * @return {Object}
644
+   */
645
+
646
+  function parseDirective(s) {
647
+
648
+    var hit = cache$1.get(s);
649
+    if (hit) {
650
+      return hit;
651
+    }
652
+
653
+    // reset parser state
654
+    str = s;
655
+    inSingle = inDouble = false;
656
+    curly = square = paren = 0;
657
+    lastFilterIndex = 0;
658
+    dir = {};
659
+
660
+    for (i = 0, l = str.length; i < l; i++) {
661
+      prev = c;
662
+      c = str.charCodeAt(i);
663
+      if (inSingle) {
664
+        // check single quote
665
+        if (c === 0x27 && prev !== 0x5C) inSingle = !inSingle;
666
+      } else if (inDouble) {
667
+        // check double quote
668
+        if (c === 0x22 && prev !== 0x5C) inDouble = !inDouble;
669
+      } else if (c === 0x7C && // pipe
670
+      str.charCodeAt(i + 1) !== 0x7C && str.charCodeAt(i - 1) !== 0x7C) {
671
+        if (dir.expression == null) {
672
+          // first filter, end of expression
673
+          lastFilterIndex = i + 1;
674
+          dir.expression = str.slice(0, i).trim();
675
+        } else {
676
+          // already has filter
677
+          pushFilter();
678
+        }
679
+      } else {
680
+        switch (c) {
681
+          case 0x22:
682
+            inDouble = true;break; // "
683
+          case 0x27:
684
+            inSingle = true;break; // '
685
+          case 0x28:
686
+            paren++;break; // (
687
+          case 0x29:
688
+            paren--;break; // )
689
+          case 0x5B:
690
+            square++;break; // [
691
+          case 0x5D:
692
+            square--;break; // ]
693
+          case 0x7B:
694
+            curly++;break; // {
695
+          case 0x7D:
696
+            curly--;break; // }
697
+        }
698
+      }
699
+    }
700
+
701
+    if (dir.expression == null) {
702
+      dir.expression = str.slice(0, i).trim();
703
+    } else if (lastFilterIndex !== 0) {
704
+      pushFilter();
705
+    }
706
+
707
+    cache$1.put(s, dir);
708
+    return dir;
709
+  }
710
+
711
+  var directive = Object.freeze({
712
+    parseDirective: parseDirective
713
+  });
714
+
715
+  var regexEscapeRE = /[-.*+?^${}()|[\]\/\\]/g;
716
+  var cache = undefined;
717
+  var tagRE = undefined;
718
+  var htmlRE = undefined;
719
+  /**
720
+   * Escape a string so it can be used in a RegExp
721
+   * constructor.
722
+   *
723
+   * @param {String} str
724
+   */
725
+
726
+  function escapeRegex(str) {
727
+    return str.replace(regexEscapeRE, '\\$&');
728
+  }
729
+
730
+  function compileRegex() {
731
+    var open = escapeRegex(config.delimiters[0]);
732
+    var close = escapeRegex(config.delimiters[1]);
733
+    var unsafeOpen = escapeRegex(config.unsafeDelimiters[0]);
734
+    var unsafeClose = escapeRegex(config.unsafeDelimiters[1]);
735
+    tagRE = new RegExp(unsafeOpen + '(.+?)' + unsafeClose + '|' + open + '(.+?)' + close, 'g');
736
+    htmlRE = new RegExp('^' + unsafeOpen + '.*' + unsafeClose + '$');
737
+    // reset cache
738
+    cache = new Cache(1000);
739
+  }
740
+
741
+  /**
742
+   * Parse a template text string into an array of tokens.
743
+   *
744
+   * @param {String} text
745
+   * @return {Array<Object> | null}
746
+   *               - {String} type
747
+   *               - {String} value
748
+   *               - {Boolean} [html]
749
+   *               - {Boolean} [oneTime]
750
+   */
751
+
752
+  function parseText(text) {
753
+    if (!cache) {
754
+      compileRegex();
755
+    }
756
+    var hit = cache.get(text);
757
+    if (hit) {
758
+      return hit;
759
+    }
760
+    text = text.replace(/\n/g, '');
761
+    if (!tagRE.test(text)) {
762
+      return null;
763
+    }
764
+    var tokens = [];
765
+    var lastIndex = tagRE.lastIndex = 0;
766
+    var match, index, html, value, first, oneTime;
767
+    /* eslint-disable no-cond-assign */
768
+    while (match = tagRE.exec(text)) {
769
+      /* eslint-enable no-cond-assign */
770
+      index = match.index;
771
+      // push text token
772
+      if (index > lastIndex) {
773
+        tokens.push({
774
+          value: text.slice(lastIndex, index)
775
+        });
776
+      }
777
+      // tag token
778
+      html = htmlRE.test(match[0]);
779
+      value = html ? match[1] : match[2];
780
+      first = value.charCodeAt(0);
781
+      oneTime = first === 42; // *
782
+      value = oneTime ? value.slice(1) : value;
783
+      tokens.push({
784
+        tag: true,
785
+        value: value.trim(),
786
+        html: html,
787
+        oneTime: oneTime
788
+      });
789
+      lastIndex = index + match[0].length;
790
+    }
791
+    if (lastIndex < text.length) {
792
+      tokens.push({
793
+        value: text.slice(lastIndex)
794
+      });
795
+    }
796
+    cache.put(text, tokens);
797
+    return tokens;
798
+  }
799
+
800
+  /**
801
+   * Format a list of tokens into an expression.
802
+   * e.g. tokens parsed from 'a {{b}} c' can be serialized
803
+   * into one single expression as '"a " + b + " c"'.
804
+   *
805
+   * @param {Array} tokens
806
+   * @param {Vue} [vm]
807
+   * @return {String}
808
+   */
809
+
810
+  function tokensToExp(tokens, vm) {
811
+    if (tokens.length > 1) {
812
+      return tokens.map(function (token) {
813
+        return formatToken(token, vm);
814
+      }).join('+');
815
+    } else {
816
+      return formatToken(tokens[0], vm, true);
817
+    }
818
+  }
819
+
820
+  /**
821
+   * Format a single token.
822
+   *
823
+   * @param {Object} token
824
+   * @param {Vue} [vm]
825
+   * @param {Boolean} [single]
826
+   * @return {String}
827
+   */
828
+
829
+  function formatToken(token, vm, single) {
830
+    return token.tag ? token.oneTime && vm ? '"' + vm.$eval(token.value) + '"' : inlineFilters(token.value, single) : '"' + token.value + '"';
831
+  }
832
+
833
+  /**
834
+   * For an attribute with multiple interpolation tags,
835
+   * e.g. attr="some-{{thing | filter}}", in order to combine
836
+   * the whole thing into a single watchable expression, we
837
+   * have to inline those filters. This function does exactly
838
+   * that. This is a bit hacky but it avoids heavy changes
839
+   * to directive parser and watcher mechanism.
840
+   *
841
+   * @param {String} exp
842
+   * @param {Boolean} single
843
+   * @return {String}
844
+   */
845
+
846
+  var filterRE$1 = /[^|]\|[^|]/;
847
+  function inlineFilters(exp, single) {
848
+    if (!filterRE$1.test(exp)) {
849
+      return single ? exp : '(' + exp + ')';
850
+    } else {
851
+      var dir = parseDirective(exp);
852
+      if (!dir.filters) {
853
+        return '(' + exp + ')';
854
+      } else {
855
+        return 'this._applyFilters(' + dir.expression + // value
856
+        ',null,' + // oldValue (null for read)
857
+        JSON.stringify(dir.filters) + // filter descriptors
858
+        ',false)'; // write?
859
+      }
860
+    }
861
+  }
862
+
863
+  var text$1 = Object.freeze({
864
+    compileRegex: compileRegex,
865
+    parseText: parseText,
866
+    tokensToExp: tokensToExp
867
+  });
868
+
869
+  var delimiters = ['{{', '}}'];
870
+  var unsafeDelimiters = ['{{{', '}}}'];
871
+
872
+  var config = Object.defineProperties({
873
+
874
+    /**
875
+     * Whether to print debug messages.
876
+     * Also enables stack trace for warnings.
877
+     *
878
+     * @type {Boolean}
879
+     */
880
+
881
+    debug: false,
882
+
883
+    /**
884
+     * Whether to suppress warnings.
885
+     *
886
+     * @type {Boolean}
887
+     */
888
+
889
+    silent: false,
890
+
891
+    /**
892
+     * Whether to use async rendering.
893
+     */
894
+
895
+    async: true,
896
+
897
+    /**
898
+     * Whether to warn against errors caught when evaluating
899
+     * expressions.
900
+     */
901
+
902
+    warnExpressionErrors: true,
903
+
904
+    /**
905
+     * Whether or not to handle fully object properties which
906
+     * are already backed by getters and seters. Depending on
907
+     * use case and environment, this might introduce non-neglible
908
+     * performance penalties.
909
+     */
910
+    convertAllProperties: false,
911
+
912
+    /**
913
+     * Internal flag to indicate the delimiters have been
914
+     * changed.
915
+     *
916
+     * @type {Boolean}
917
+     */
918
+
919
+    _delimitersChanged: true,
920
+
921
+    /**
922
+     * List of asset types that a component can own.
923
+     *
924
+     * @type {Array}
925
+     */
926
+
927
+    _assetTypes: ['component', 'directive', 'elementDirective', 'filter', 'transition', 'partial'],
928
+
929
+    /**
930
+     * prop binding modes
931
+     */
932
+
933
+    _propBindingModes: {
934
+      ONE_WAY: 0,
935
+      TWO_WAY: 1,
936
+      ONE_TIME: 2
937
+    },
938
+
939
+    /**
940
+     * Max circular updates allowed in a batcher flush cycle.
941
+     */
942
+
943
+    _maxUpdateCount: 100
944
+
945
+  }, {
946
+    delimiters: { /**
947
+                   * Interpolation delimiters. Changing these would trigger
948
+                   * the text parser to re-compile the regular expressions.
949
+                   *
950
+                   * @type {Array<String>}
951
+                   */
952
+
953
+      get: function get() {
954
+        return delimiters;
955
+      },
956
+      set: function set(val) {
957
+        delimiters = val;
958
+        compileRegex();
959
+      },
960
+      configurable: true,
961
+      enumerable: true
962
+    },
963
+    unsafeDelimiters: {
964
+      get: function get() {
965
+        return unsafeDelimiters;
966
+      },
967
+      set: function set(val) {
968
+        unsafeDelimiters = val;
969
+        compileRegex();
970
+      },
971
+      configurable: true,
972
+      enumerable: true
973
+    }
974
+  });
975
+
976
+  var warn = undefined;
977
+
978
+  if ('development' !== 'production') {
979
+    (function () {
980
+      var hasConsole = typeof console !== 'undefined';
981
+      warn = function (msg, e) {
982
+        if (hasConsole && (!config.silent || config.debug)) {
983
+          console.warn('[Vue warn]: ' + msg);
984
+          /* istanbul ignore if */
985
+          if (config.debug) {
986
+            if (e) {
987
+              throw e;
988
+            } else {
989
+              console.warn(new Error('Warning Stack Trace').stack);
990
+            }
991
+          }
992
+        }
993
+      };
994
+    })();
995
+  }
996
+
997
+  /**
998
+   * Append with transition.
999
+   *
1000
+   * @param {Element} el
1001
+   * @param {Element} target
1002
+   * @param {Vue} vm
1003
+   * @param {Function} [cb]
1004
+   */
1005
+
1006
+  function appendWithTransition(el, target, vm, cb) {
1007
+    applyTransition(el, 1, function () {
1008
+      target.appendChild(el);
1009
+    }, vm, cb);
1010
+  }
1011
+
1012
+  /**
1013
+   * InsertBefore with transition.
1014
+   *
1015
+   * @param {Element} el
1016
+   * @param {Element} target
1017
+   * @param {Vue} vm
1018
+   * @param {Function} [cb]
1019
+   */
1020
+
1021
+  function beforeWithTransition(el, target, vm, cb) {
1022
+    applyTransition(el, 1, function () {
1023
+      before(el, target);
1024
+    }, vm, cb);
1025
+  }
1026
+
1027
+  /**
1028
+   * Remove with transition.
1029
+   *
1030
+   * @param {Element} el
1031
+   * @param {Vue} vm
1032
+   * @param {Function} [cb]
1033
+   */
1034
+
1035
+  function removeWithTransition(el, vm, cb) {
1036
+    applyTransition(el, -1, function () {
1037
+      remove(el);
1038
+    }, vm, cb);
1039
+  }
1040
+
1041
+  /**
1042
+   * Apply transitions with an operation callback.
1043
+   *
1044
+   * @param {Element} el
1045
+   * @param {Number} direction
1046
+   *                  1: enter
1047
+   *                 -1: leave
1048
+   * @param {Function} op - the actual DOM operation
1049
+   * @param {Vue} vm
1050
+   * @param {Function} [cb]
1051
+   */
1052
+
1053
+  function applyTransition(el, direction, op, vm, cb) {
1054
+    var transition = el.__v_trans;
1055
+    if (!transition ||
1056
+    // skip if there are no js hooks and CSS transition is
1057
+    // not supported
1058
+    !transition.hooks && !transitionEndEvent ||
1059
+    // skip transitions for initial compile
1060
+    !vm._isCompiled ||
1061
+    // if the vm is being manipulated by a parent directive
1062
+    // during the parent's compilation phase, skip the
1063
+    // animation.
1064
+    vm.$parent && !vm.$parent._isCompiled) {
1065
+      op();
1066
+      if (cb) cb();
1067
+      return;
1068
+    }
1069
+    var action = direction > 0 ? 'enter' : 'leave';
1070
+    transition[action](op, cb);
1071
+  }
1072
+
1073
+  /**
1074
+   * Query an element selector if it's not an element already.
1075
+   *
1076
+   * @param {String|Element} el
1077
+   * @return {Element}
1078
+   */
1079
+
1080
+  function query(el) {
1081
+    if (typeof el === 'string') {
1082
+      var selector = el;
1083
+      el = document.querySelector(el);
1084
+      if (!el) {
1085
+        'development' !== 'production' && warn('Cannot find element: ' + selector);
1086
+      }
1087
+    }
1088
+    return el;
1089
+  }
1090
+
1091
+  /**
1092
+   * Check if a node is in the document.
1093
+   * Note: document.documentElement.contains should work here
1094
+   * but always returns false for comment nodes in phantomjs,
1095
+   * making unit tests difficult. This is fixed by doing the
1096
+   * contains() check on the node's parentNode instead of
1097
+   * the node itself.
1098
+   *
1099
+   * @param {Node} node
1100
+   * @return {Boolean}
1101
+   */
1102
+
1103
+  function inDoc(node) {
1104
+    var doc = document.documentElement;
1105
+    var parent = node && node.parentNode;
1106
+    return doc === node || doc === parent || !!(parent && parent.nodeType === 1 && doc.contains(parent));
1107
+  }
1108
+
1109
+  /**
1110
+   * Get and remove an attribute from a node.
1111
+   *
1112
+   * @param {Node} node
1113
+   * @param {String} _attr
1114
+   */
1115
+
1116
+  function getAttr(node, _attr) {
1117
+    var val = node.getAttribute(_attr);
1118
+    if (val !== null) {
1119
+      node.removeAttribute(_attr);
1120
+    }
1121
+    return val;
1122
+  }
1123
+
1124
+  /**
1125
+   * Get an attribute with colon or v-bind: prefix.
1126
+   *
1127
+   * @param {Node} node
1128
+   * @param {String} name
1129
+   * @return {String|null}
1130
+   */
1131
+
1132
+  function getBindAttr(node, name) {
1133
+    var val = getAttr(node, ':' + name);
1134
+    if (val === null) {
1135
+      val = getAttr(node, 'v-bind:' + name);
1136
+    }
1137
+    return val;
1138
+  }
1139
+
1140
+  /**
1141
+   * Check the presence of a bind attribute.
1142
+   *
1143
+   * @param {Node} node
1144
+   * @param {String} name
1145
+   * @return {Boolean}
1146
+   */
1147
+
1148
+  function hasBindAttr(node, name) {
1149
+    return node.hasAttribute(name) || node.hasAttribute(':' + name) || node.hasAttribute('v-bind:' + name);
1150
+  }
1151
+
1152
+  /**
1153
+   * Insert el before target
1154
+   *
1155
+   * @param {Element} el
1156
+   * @param {Element} target
1157
+   */
1158
+
1159
+  function before(el, target) {
1160
+    target.parentNode.insertBefore(el, target);
1161
+  }
1162
+
1163
+  /**
1164
+   * Insert el after target
1165
+   *
1166
+   * @param {Element} el
1167
+   * @param {Element} target
1168
+   */
1169
+
1170
+  function after(el, target) {
1171
+    if (target.nextSibling) {
1172
+      before(el, target.nextSibling);
1173
+    } else {
1174
+      target.parentNode.appendChild(el);
1175
+    }
1176
+  }
1177
+
1178
+  /**
1179
+   * Remove el from DOM
1180
+   *
1181
+   * @param {Element} el
1182
+   */
1183
+
1184
+  function remove(el) {
1185
+    el.parentNode.removeChild(el);
1186
+  }
1187
+
1188
+  /**
1189
+   * Prepend el to target
1190
+   *
1191
+   * @param {Element} el
1192
+   * @param {Element} target
1193
+   */
1194
+
1195
+  function prepend(el, target) {
1196
+    if (target.firstChild) {
1197
+      before(el, target.firstChild);
1198
+    } else {
1199
+      target.appendChild(el);
1200
+    }
1201
+  }
1202
+
1203
+  /**
1204
+   * Replace target with el
1205
+   *
1206
+   * @param {Element} target
1207
+   * @param {Element} el
1208
+   */
1209
+
1210
+  function replace(target, el) {
1211
+    var parent = target.parentNode;
1212
+    if (parent) {
1213
+      parent.replaceChild(el, target);
1214
+    }
1215
+  }
1216
+
1217
+  /**
1218
+   * Add event listener shorthand.
1219
+   *
1220
+   * @param {Element} el
1221
+   * @param {String} event
1222
+   * @param {Function} cb
1223
+   */
1224
+
1225
+  function on$1(el, event, cb) {
1226
+    el.addEventListener(event, cb);
1227
+  }
1228
+
1229
+  /**
1230
+   * Remove event listener shorthand.
1231
+   *
1232
+   * @param {Element} el
1233
+   * @param {String} event
1234
+   * @param {Function} cb
1235
+   */
1236
+
1237
+  function off(el, event, cb) {
1238
+    el.removeEventListener(event, cb);
1239
+  }
1240
+
1241
+  /**
1242
+   * In IE9, setAttribute('class') will result in empty class
1243
+   * if the element also has the :class attribute; However in
1244
+   * PhantomJS, setting `className` does not work on SVG elements...
1245
+   * So we have to do a conditional check here.
1246
+   *
1247
+   * @param {Element} el
1248
+   * @param {String} cls
1249
+   */
1250
+
1251
+  function setClass(el, cls) {
1252
+    /* istanbul ignore if */
1253
+    if (isIE9 && !(el instanceof SVGElement)) {
1254
+      el.className = cls;
1255
+    } else {
1256
+      el.setAttribute('class', cls);
1257
+    }
1258
+  }
1259
+
1260
+  /**
1261
+   * Add class with compatibility for IE & SVG
1262
+   *
1263
+   * @param {Element} el
1264
+   * @param {String} cls
1265
+   */
1266
+
1267
+  function addClass(el, cls) {
1268
+    if (el.classList) {
1269
+      el.classList.add(cls);
1270
+    } else {
1271
+      var cur = ' ' + (el.getAttribute('class') || '') + ' ';
1272
+      if (cur.indexOf(' ' + cls + ' ') < 0) {
1273
+        setClass(el, (cur + cls).trim());
1274
+      }
1275
+    }
1276
+  }
1277
+
1278
+  /**
1279
+   * Remove class with compatibility for IE & SVG
1280
+   *
1281
+   * @param {Element} el
1282
+   * @param {String} cls
1283
+   */
1284
+
1285
+  function removeClass(el, cls) {
1286
+    if (el.classList) {
1287
+      el.classList.remove(cls);
1288
+    } else {
1289
+      var cur = ' ' + (el.getAttribute('class') || '') + ' ';
1290
+      var tar = ' ' + cls + ' ';
1291
+      while (cur.indexOf(tar) >= 0) {
1292
+        cur = cur.replace(tar, ' ');
1293
+      }
1294
+      setClass(el, cur.trim());
1295
+    }
1296
+    if (!el.className) {
1297
+      el.removeAttribute('class');
1298
+    }
1299
+  }
1300
+
1301
+  /**
1302
+   * Extract raw content inside an element into a temporary
1303
+   * container div
1304
+   *
1305
+   * @param {Element} el
1306
+   * @param {Boolean} asFragment
1307
+   * @return {Element}
1308
+   */
1309
+
1310
+  function extractContent(el, asFragment) {
1311
+    var child;
1312
+    var rawContent;
1313
+    /* istanbul ignore if */
1314
+    if (isTemplate(el) && el.content instanceof DocumentFragment) {
1315
+      el = el.content;
1316
+    }
1317
+    if (el.hasChildNodes()) {
1318
+      trimNode(el);
1319
+      rawContent = asFragment ? document.createDocumentFragment() : document.createElement('div');
1320
+      /* eslint-disable no-cond-assign */
1321
+      while (child = el.firstChild) {
1322
+        /* eslint-enable no-cond-assign */
1323
+        rawContent.appendChild(child);
1324
+      }
1325
+    }
1326
+    return rawContent;
1327
+  }
1328
+
1329
+  /**
1330
+   * Trim possible empty head/tail textNodes inside a parent.
1331
+   *
1332
+   * @param {Node} node
1333
+   */
1334
+
1335
+  function trimNode(node) {
1336
+    trim(node, node.firstChild);
1337
+    trim(node, node.lastChild);
1338
+  }
1339
+
1340
+  function trim(parent, node) {
1341
+    if (node && node.nodeType === 3 && !node.data.trim()) {
1342
+      parent.removeChild(node);
1343
+    }
1344
+  }
1345
+
1346
+  /**
1347
+   * Check if an element is a template tag.
1348
+   * Note if the template appears inside an SVG its tagName
1349
+   * will be in lowercase.
1350
+   *
1351
+   * @param {Element} el
1352
+   */
1353
+
1354
+  function isTemplate(el) {
1355
+    return el.tagName && el.tagName.toLowerCase() === 'template';
1356
+  }
1357
+
1358
+  /**
1359
+   * Create an "anchor" for performing dom insertion/removals.
1360
+   * This is used in a number of scenarios:
1361
+   * - fragment instance
1362
+   * - v-html
1363
+   * - v-if
1364
+   * - v-for
1365
+   * - component
1366
+   *
1367
+   * @param {String} content
1368
+   * @param {Boolean} persist - IE trashes empty textNodes on
1369
+   *                            cloneNode(true), so in certain
1370
+   *                            cases the anchor needs to be
1371
+   *                            non-empty to be persisted in
1372
+   *                            templates.
1373
+   * @return {Comment|Text}
1374
+   */
1375
+
1376
+  function createAnchor(content, persist) {
1377
+    var anchor = config.debug ? document.createComment(content) : document.createTextNode(persist ? ' ' : '');
1378
+    anchor.__vue_anchor = true;
1379
+    return anchor;
1380
+  }
1381
+
1382
+  /**
1383
+   * Find a component ref attribute that starts with $.
1384
+   *
1385
+   * @param {Element} node
1386
+   * @return {String|undefined}
1387
+   */
1388
+
1389
+  var refRE = /^v-ref:/;
1390
+
1391
+  function findRef(node) {
1392
+    if (node.hasAttributes()) {
1393
+      var attrs = node.attributes;
1394
+      for (var i = 0, l = attrs.length; i < l; i++) {
1395
+        var name = attrs[i].name;
1396
+        if (refRE.test(name)) {
1397
+          return camelize(name.replace(refRE, ''));
1398
+        }
1399
+      }
1400
+    }
1401
+  }
1402
+
1403
+  /**
1404
+   * Map a function to a range of nodes .
1405
+   *
1406
+   * @param {Node} node
1407
+   * @param {Node} end
1408
+   * @param {Function} op
1409
+   */
1410
+
1411
+  function mapNodeRange(node, end, op) {
1412
+    var next;
1413
+    while (node !== end) {
1414
+      next = node.nextSibling;
1415
+      op(node);
1416
+      node = next;
1417
+    }
1418
+    op(end);
1419
+  }
1420
+
1421
+  /**
1422
+   * Remove a range of nodes with transition, store
1423
+   * the nodes in a fragment with correct ordering,
1424
+   * and call callback when done.
1425
+   *
1426
+   * @param {Node} start
1427
+   * @param {Node} end
1428
+   * @param {Vue} vm
1429
+   * @param {DocumentFragment} frag
1430
+   * @param {Function} cb
1431
+   */
1432
+
1433
+  function removeNodeRange(start, end, vm, frag, cb) {
1434
+    var done = false;
1435
+    var removed = 0;
1436
+    var nodes = [];
1437
+    mapNodeRange(start, end, function (node) {
1438
+      if (node === end) done = true;
1439
+      nodes.push(node);
1440
+      removeWithTransition(node, vm, onRemoved);
1441
+    });
1442
+    function onRemoved() {
1443
+      removed++;
1444
+      if (done && removed >= nodes.length) {
1445
+        for (var i = 0; i < nodes.length; i++) {
1446
+          frag.appendChild(nodes[i]);
1447
+        }
1448
+        cb && cb();
1449
+      }
1450
+    }
1451
+  }
1452
+
1453
+  var commonTagRE = /^(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)$/;
1454
+  var reservedTagRE = /^(slot|partial|component)$/;
1455
+
1456
+  /**
1457
+   * Check if an element is a component, if yes return its
1458
+   * component id.
1459
+   *
1460
+   * @param {Element} el
1461
+   * @param {Object} options
1462
+   * @return {Object|undefined}
1463
+   */
1464
+
1465
+  function checkComponentAttr(el, options) {
1466
+    var tag = el.tagName.toLowerCase();
1467
+    var hasAttrs = el.hasAttributes();
1468
+    if (!commonTagRE.test(tag) && !reservedTagRE.test(tag)) {
1469
+      if (resolveAsset(options, 'components', tag)) {
1470
+        return { id: tag };
1471
+      } else {
1472
+        var is = hasAttrs && getIsBinding(el);
1473
+        if (is) {
1474
+          return is;
1475
+        } else if ('development' !== 'production') {
1476
+          if (tag.indexOf('-') > -1 || /HTMLUnknownElement/.test(el.toString()) &&
1477
+          // Chrome returns unknown for several HTML5 elements.
1478
+          // https://code.google.com/p/chromium/issues/detail?id=540526
1479
+          !/^(data|time|rtc|rb)$/.test(tag)) {
1480
+            warn('Unknown custom element: <' + tag + '> - did you ' + 'register the component correctly?');
1481
+          }
1482
+        }
1483
+      }
1484
+    } else if (hasAttrs) {
1485
+      return getIsBinding(el);
1486
+    }
1487
+  }
1488
+
1489
+  /**
1490
+   * Get "is" binding from an element.
1491
+   *
1492
+   * @param {Element} el
1493
+   * @return {Object|undefined}
1494
+   */
1495
+
1496
+  function getIsBinding(el) {
1497
+    // dynamic syntax
1498
+    var exp = getAttr(el, 'is');
1499
+    if (exp != null) {
1500
+      return { id: exp };
1501
+    } else {
1502
+      exp = getBindAttr(el, 'is');
1503
+      if (exp != null) {
1504
+        return { id: exp, dynamic: true };
1505
+      }
1506
+    }
1507
+  }
1508
+
1509
+  /**
1510
+   * Set a prop's initial value on a vm and its data object.
1511
+   *
1512
+   * @param {Vue} vm
1513
+   * @param {Object} prop
1514
+   * @param {*} value
1515
+   */
1516
+
1517
+  function initProp(vm, prop, value) {
1518
+    var key = prop.path;
1519
+    value = coerceProp(prop, value);
1520
+    vm[key] = vm._data[key] = assertProp(prop, value) ? value : undefined;
1521
+  }
1522
+
1523
+  /**
1524
+   * Assert whether a prop is valid.
1525
+   *
1526
+   * @param {Object} prop
1527
+   * @param {*} value
1528
+   */
1529
+
1530
+  function assertProp(prop, value) {
1531
+    // if a prop is not provided and is not required,
1532
+    // skip the check.
1533
+    if (prop.raw === null && !prop.required) {
1534
+      return true;
1535
+    }
1536
+    var options = prop.options;
1537
+    var type = options.type;
1538
+    var valid = true;
1539
+    var expectedType;
1540
+    if (type) {
1541
+      if (type === String) {
1542
+        expectedType = 'string';
1543
+        valid = typeof value === expectedType;
1544
+      } else if (type === Number) {
1545
+        expectedType = 'number';
1546
+        valid = typeof value === 'number';
1547
+      } else if (type === Boolean) {
1548
+        expectedType = 'boolean';
1549
+        valid = typeof value === 'boolean';
1550
+      } else if (type === Function) {
1551
+        expectedType = 'function';
1552
+        valid = typeof value === 'function';
1553
+      } else if (type === Object) {
1554
+        expectedType = 'object';
1555
+        valid = isPlainObject(value);
1556
+      } else if (type === Array) {
1557
+        expectedType = 'array';
1558
+        valid = isArray(value);
1559
+      } else {
1560
+        valid = value instanceof type;
1561
+      }
1562
+    }
1563
+    if (!valid) {
1564
+      'development' !== 'production' && warn('Invalid prop: type check failed for ' + prop.path + '="' + prop.raw + '".' + ' Expected ' + formatType(expectedType) + ', got ' + formatValue(value) + '.');
1565
+      return false;
1566
+    }
1567
+    var validator = options.validator;
1568
+    if (validator) {
1569
+      if (!validator.call(null, value)) {
1570
+        'development' !== 'production' && warn('Invalid prop: custom validator check failed for ' + prop.path + '="' + prop.raw + '"');
1571
+        return false;
1572
+      }
1573
+    }
1574
+    return true;
1575
+  }
1576
+
1577
+  /**
1578
+   * Force parsing value with coerce option.
1579
+   *
1580
+   * @param {*} value
1581
+   * @param {Object} options
1582
+   * @return {*}
1583
+   */
1584
+
1585
+  function coerceProp(prop, value) {
1586
+    var coerce = prop.options.coerce;
1587
+    if (!coerce) {
1588
+      return value;
1589
+    }
1590
+    // coerce is a function
1591
+    return coerce(value);
1592
+  }
1593
+
1594
+  function formatType(val) {
1595
+    return val ? val.charAt(0).toUpperCase() + val.slice(1) : 'custom type';
1596
+  }
1597
+
1598
+  function formatValue(val) {
1599
+    return Object.prototype.toString.call(val).slice(8, -1);
1600
+  }
1601
+
1602
+  /**
1603
+   * Option overwriting strategies are functions that handle
1604
+   * how to merge a parent option value and a child option
1605
+   * value into the final value.
1606
+   *
1607
+   * All strategy functions follow the same signature:
1608
+   *
1609
+   * @param {*} parentVal
1610
+   * @param {*} childVal
1611
+   * @param {Vue} [vm]
1612
+   */
1613
+
1614
+  var strats = config.optionMergeStrategies = Object.create(null);
1615
+
1616
+  /**
1617
+   * Helper that recursively merges two data objects together.
1618
+   */
1619
+
1620
+  function mergeData(to, from) {
1621
+    var key, toVal, fromVal;
1622
+    for (key in from) {
1623
+      toVal = to[key];
1624
+      fromVal = from[key];
1625
+      if (!hasOwn(to, key)) {
1626
+        set(to, key, fromVal);
1627
+      } else if (isObject(toVal) && isObject(fromVal)) {
1628
+        mergeData(toVal, fromVal);
1629
+      }
1630
+    }
1631
+    return to;
1632
+  }
1633
+
1634
+  /**
1635
+   * Data
1636
+   */
1637
+
1638
+  strats.data = function (parentVal, childVal, vm) {
1639
+    if (!vm) {
1640
+      // in a Vue.extend merge, both should be functions
1641
+      if (!childVal) {
1642
+        return parentVal;
1643
+      }
1644
+      if (typeof childVal !== 'function') {
1645
+        'development' !== 'production' && warn('The "data" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.');
1646
+        return parentVal;
1647
+      }
1648
+      if (!parentVal) {
1649
+        return childVal;
1650
+      }
1651
+      // when parentVal & childVal are both present,
1652
+      // we need to return a function that returns the
1653
+      // merged result of both functions... no need to
1654
+      // check if parentVal is a function here because
1655
+      // it has to be a function to pass previous merges.
1656
+      return function mergedDataFn() {
1657
+        return mergeData(childVal.call(this), parentVal.call(this));
1658
+      };
1659
+    } else if (parentVal || childVal) {
1660
+      return function mergedInstanceDataFn() {
1661
+        // instance merge
1662
+        var instanceData = typeof childVal === 'function' ? childVal.call(vm) : childVal;
1663
+        var defaultData = typeof parentVal === 'function' ? parentVal.call(vm) : undefined;
1664
+        if (instanceData) {
1665
+          return mergeData(instanceData, defaultData);
1666
+        } else {
1667
+          return defaultData;
1668
+        }
1669
+      };
1670
+    }
1671
+  };
1672
+
1673
+  /**
1674
+   * El
1675
+   */
1676
+
1677
+  strats.el = function (parentVal, childVal, vm) {
1678
+    if (!vm && childVal && typeof childVal !== 'function') {
1679
+      'development' !== 'production' && warn('The "el" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.');
1680
+      return;
1681
+    }
1682
+    var ret = childVal || parentVal;
1683
+    // invoke the element factory if this is instance merge
1684
+    return vm && typeof ret === 'function' ? ret.call(vm) : ret;
1685
+  };
1686
+
1687
+  /**
1688
+   * Hooks and param attributes are merged as arrays.
1689
+   */
1690
+
1691
+  strats.init = strats.created = strats.ready = strats.attached = strats.detached = strats.beforeCompile = strats.compiled = strats.beforeDestroy = strats.destroyed = function (parentVal, childVal) {
1692
+    return childVal ? parentVal ? parentVal.concat(childVal) : isArray(childVal) ? childVal : [childVal] : parentVal;
1693
+  };
1694
+
1695
+  /**
1696
+   * 0.11 deprecation warning
1697
+   */
1698
+
1699
+  strats.paramAttributes = function () {
1700
+    /* istanbul ignore next */
1701
+    'development' !== 'production' && warn('"paramAttributes" option has been deprecated in 0.12. ' + 'Use "props" instead.');
1702
+  };
1703
+
1704
+  /**
1705
+   * Assets
1706
+   *
1707
+   * When a vm is present (instance creation), we need to do
1708
+   * a three-way merge between constructor options, instance
1709
+   * options and parent options.
1710
+   */
1711
+
1712
+  function mergeAssets(parentVal, childVal) {
1713
+    var res = Object.create(parentVal);
1714
+    return childVal ? extend(res, guardArrayAssets(childVal)) : res;
1715
+  }
1716
+
1717
+  config._assetTypes.forEach(function (type) {
1718
+    strats[type + 's'] = mergeAssets;
1719
+  });
1720
+
1721
+  /**
1722
+   * Events & Watchers.
1723
+   *
1724
+   * Events & watchers hashes should not overwrite one
1725
+   * another, so we merge them as arrays.
1726
+   */
1727
+
1728
+  strats.watch = strats.events = function (parentVal, childVal) {
1729
+    if (!childVal) return parentVal;
1730
+    if (!parentVal) return childVal;
1731
+    var ret = {};
1732
+    extend(ret, parentVal);
1733
+    for (var key in childVal) {
1734
+      var parent = ret[key];
1735
+      var child = childVal[key];
1736
+      if (parent && !isArray(parent)) {
1737
+        parent = [parent];
1738
+      }
1739
+      ret[key] = parent ? parent.concat(child) : [child];
1740
+    }
1741
+    return ret;
1742
+  };
1743
+
1744
+  /**
1745
+   * Other object hashes.
1746
+   */
1747
+
1748
+  strats.props = strats.methods = strats.computed = function (parentVal, childVal) {
1749
+    if (!childVal) return parentVal;
1750
+    if (!parentVal) return childVal;
1751
+    var ret = Object.create(null);
1752
+    extend(ret, parentVal);
1753
+    extend(ret, childVal);
1754
+    return ret;
1755
+  };
1756
+
1757
+  /**
1758
+   * Default strategy.
1759
+   */
1760
+
1761
+  var defaultStrat = function defaultStrat(parentVal, childVal) {
1762
+    return childVal === undefined ? parentVal : childVal;
1763
+  };
1764
+
1765
+  /**
1766
+   * Make sure component options get converted to actual
1767
+   * constructors.
1768
+   *
1769
+   * @param {Object} options
1770
+   */
1771
+
1772
+  function guardComponents(options) {
1773
+    if (options.components) {
1774
+      var components = options.components = guardArrayAssets(options.components);
1775
+      var def;
1776
+      var ids = Object.keys(components);
1777
+      for (var i = 0, l = ids.length; i < l; i++) {
1778
+        var key = ids[i];
1779
+        if (commonTagRE.test(key) || reservedTagRE.test(key)) {
1780
+          'development' !== 'production' && warn('Do not use built-in or reserved HTML elements as component ' + 'id: ' + key);
1781
+          continue;
1782
+        }
1783
+        def = components[key];
1784
+        if (isPlainObject(def)) {
1785
+          components[key] = Vue.extend(def);
1786
+        }
1787
+      }
1788
+    }
1789
+  }
1790
+
1791
+  /**
1792
+   * Ensure all props option syntax are normalized into the
1793
+   * Object-based format.
1794
+   *
1795
+   * @param {Object} options
1796
+   */
1797
+
1798
+  function guardProps(options) {
1799
+    var props = options.props;
1800
+    var i, val;
1801
+    if (isArray(props)) {
1802
+      options.props = {};
1803
+      i = props.length;
1804
+      while (i--) {
1805
+        val = props[i];
1806
+        if (typeof val === 'string') {
1807
+          options.props[val] = null;
1808
+        } else if (val.name) {
1809
+          options.props[val.name] = val;
1810
+        }
1811
+      }
1812
+    } else if (isPlainObject(props)) {
1813
+      var keys = Object.keys(props);
1814
+      i = keys.length;
1815
+      while (i--) {
1816
+        val = props[keys[i]];
1817
+        if (typeof val === 'function') {
1818
+          props[keys[i]] = { type: val };
1819
+        }
1820
+      }
1821
+    }
1822
+  }
1823
+
1824
+  /**
1825
+   * Guard an Array-format assets option and converted it
1826
+   * into the key-value Object format.
1827
+   *
1828
+   * @param {Object|Array} assets
1829
+   * @return {Object}
1830
+   */
1831
+
1832
+  function guardArrayAssets(assets) {
1833
+    if (isArray(assets)) {
1834
+      var res = {};
1835
+      var i = assets.length;
1836
+      var asset;
1837
+      while (i--) {
1838
+        asset = assets[i];
1839
+        var id = typeof asset === 'function' ? asset.options && asset.options.name || asset.id : asset.name || asset.id;
1840
+        if (!id) {
1841
+          'development' !== 'production' && warn('Array-syntax assets must provide a "name" or "id" field.');
1842
+        } else {
1843
+          res[id] = asset;
1844
+        }
1845
+      }
1846
+      return res;
1847
+    }
1848
+    return assets;
1849
+  }
1850
+
1851
+  /**
1852
+   * Merge two option objects into a new one.
1853
+   * Core utility used in both instantiation and inheritance.
1854
+   *
1855
+   * @param {Object} parent
1856
+   * @param {Object} child
1857
+   * @param {Vue} [vm] - if vm is present, indicates this is
1858
+   *                     an instantiation merge.
1859
+   */
1860
+
1861
+  function mergeOptions(parent, child, vm) {
1862
+    guardComponents(child);
1863
+    guardProps(child);
1864
+    var options = {};
1865
+    var key;
1866
+    if (child.mixins) {
1867
+      for (var i = 0, l = child.mixins.length; i < l; i++) {
1868
+        parent = mergeOptions(parent, child.mixins[i], vm);
1869
+      }
1870
+    }
1871
+    for (key in parent) {
1872
+      mergeField(key);
1873
+    }
1874
+    for (key in child) {
1875
+      if (!hasOwn(parent, key)) {
1876
+        mergeField(key);
1877
+      }
1878
+    }
1879
+    function mergeField(key) {
1880
+      var strat = strats[key] || defaultStrat;
1881
+      options[key] = strat(parent[key], child[key], vm, key);
1882
+    }
1883
+    return options;
1884
+  }
1885
+
1886
+  /**
1887
+   * Resolve an asset.
1888
+   * This function is used because child instances need access
1889
+   * to assets defined in its ancestor chain.
1890
+   *
1891
+   * @param {Object} options
1892
+   * @param {String} type
1893
+   * @param {String} id
1894
+   * @return {Object|Function}
1895
+   */
1896
+
1897
+  function resolveAsset(options, type, id) {
1898
+    var assets = options[type];
1899
+    var camelizedId;
1900
+    return assets[id] ||
1901
+    // camelCase ID
1902
+    assets[camelizedId = camelize(id)] ||
1903
+    // Pascal Case ID
1904
+    assets[camelizedId.charAt(0).toUpperCase() + camelizedId.slice(1)];
1905
+  }
1906
+
1907
+  /**
1908
+   * Assert asset exists
1909
+   */
1910
+
1911
+  function assertAsset(val, type, id) {
1912
+    if (!val) {
1913
+      'development' !== 'production' && warn('Failed to resolve ' + type + ': ' + id);
1914
+    }
1915
+  }
1916
+
1917
+  var arrayProto = Array.prototype;
1918
+  var arrayMethods = Object.create(arrayProto)
1919
+
1920
+  /**
1921
+   * Intercept mutating methods and emit events
1922
+   */
1923
+
1924
+  ;['push', 'pop', 'shift', 'unshift', 'splice', 'sort', 'reverse'].forEach(function (method) {
1925
+    // cache original method
1926
+    var original = arrayProto[method];
1927
+    def(arrayMethods, method, function mutator() {
1928
+      // avoid leaking arguments:
1929
+      // http://jsperf.com/closure-with-arguments
1930
+      var i = arguments.length;
1931
+      var args = new Array(i);
1932
+      while (i--) {
1933
+        args[i] = arguments[i];
1934
+      }
1935
+      var result = original.apply(this, args);
1936
+      var ob = this.__ob__;
1937
+      var inserted;
1938
+      switch (method) {
1939
+        case 'push':
1940
+          inserted = args;
1941
+          break;
1942
+        case 'unshift':
1943
+          inserted = args;
1944
+          break;
1945
+        case 'splice':
1946
+          inserted = args.slice(2);
1947
+          break;
1948
+      }
1949
+      if (inserted) ob.observeArray(inserted);
1950
+      // notify change
1951
+      ob.dep.notify();
1952
+      return result;
1953
+    });
1954
+  });
1955
+
1956
+  /**
1957
+   * Swap the element at the given index with a new value
1958
+   * and emits corresponding event.
1959
+   *
1960
+   * @param {Number} index
1961
+   * @param {*} val
1962
+   * @return {*} - replaced element
1963
+   */
1964
+
1965
+  def(arrayProto, '$set', function $set(index, val) {
1966
+    if (index >= this.length) {
1967
+      this.length = Number(index) + 1;
1968
+    }
1969
+    return this.splice(index, 1, val)[0];
1970
+  });
1971
+
1972
+  /**
1973
+   * Convenience method to remove the element at given index.
1974
+   *
1975
+   * @param {Number} index
1976
+   * @param {*} val
1977
+   */
1978
+
1979
+  def(arrayProto, '$remove', function $remove(item) {
1980
+    /* istanbul ignore if */
1981
+    if (!this.length) return;
1982
+    var index = indexOf(this, item);
1983
+    if (index > -1) {
1984
+      return this.splice(index, 1);
1985
+    }
1986
+  });
1987
+
1988
+  var uid$3 = 0;
1989
+
1990
+  /**
1991
+   * A dep is an observable that can have multiple
1992
+   * directives subscribing to it.
1993
+   *
1994
+   * @constructor
1995
+   */
1996
+  function Dep() {
1997
+    this.id = uid$3++;
1998
+    this.subs = [];
1999
+  }
2000
+
2001
+  // the current target watcher being evaluated.
2002
+  // this is globally unique because there could be only one
2003
+  // watcher being evaluated at any time.
2004
+  Dep.target = null;
2005
+
2006
+  /**
2007
+   * Add a directive subscriber.
2008
+   *
2009
+   * @param {Directive} sub
2010
+   */
2011
+
2012
+  Dep.prototype.addSub = function (sub) {
2013
+    this.subs.push(sub);
2014
+  };
2015
+
2016
+  /**
2017
+   * Remove a directive subscriber.
2018
+   *
2019
+   * @param {Directive} sub
2020
+   */
2021
+
2022
+  Dep.prototype.removeSub = function (sub) {
2023
+    this.subs.$remove(sub);
2024
+  };
2025
+
2026
+  /**
2027
+   * Add self as a dependency to the target watcher.
2028
+   */
2029
+
2030
+  Dep.prototype.depend = function () {
2031
+    Dep.target.addDep(this);
2032
+  };
2033
+
2034
+  /**
2035
+   * Notify all subscribers of a new value.
2036
+   */
2037
+
2038
+  Dep.prototype.notify = function () {
2039
+    // stablize the subscriber list first
2040
+    var subs = toArray(this.subs);
2041
+    for (var i = 0, l = subs.length; i < l; i++) {
2042
+      subs[i].update();
2043
+    }
2044
+  };
2045
+
2046
+  var arrayKeys = Object.getOwnPropertyNames(arrayMethods);
2047
+
2048
+  /**
2049
+   * Observer class that are attached to each observed
2050
+   * object. Once attached, the observer converts target
2051
+   * object's property keys into getter/setters that
2052
+   * collect dependencies and dispatches updates.
2053
+   *
2054
+   * @param {Array|Object} value
2055
+   * @constructor
2056
+   */
2057
+
2058
+  function Observer(value) {
2059
+    this.value = value;
2060
+    this.dep = new Dep();
2061
+    def(value, '__ob__', this);
2062
+    if (isArray(value)) {
2063
+      var augment = hasProto ? protoAugment : copyAugment;
2064
+      augment(value, arrayMethods, arrayKeys);
2065
+      this.observeArray(value);
2066
+    } else {
2067
+      this.walk(value);
2068
+    }
2069
+  }
2070
+
2071
+  // Instance methods
2072
+
2073
+  /**
2074
+   * Walk through each property and convert them into
2075
+   * getter/setters. This method should only be called when
2076
+   * value type is Object.
2077
+   *
2078
+   * @param {Object} obj
2079
+   */
2080
+
2081
+  Observer.prototype.walk = function (obj) {
2082
+    var keys = Object.keys(obj);
2083
+    for (var i = 0, l = keys.length; i < l; i++) {
2084
+      this.convert(keys[i], obj[keys[i]]);
2085
+    }
2086
+  };
2087
+
2088
+  /**
2089
+   * Observe a list of Array items.
2090
+   *
2091
+   * @param {Array} items
2092
+   */
2093
+
2094
+  Observer.prototype.observeArray = function (items) {
2095
+    for (var i = 0, l = items.length; i < l; i++) {
2096
+      observe(items[i]);
2097
+    }
2098
+  };
2099
+
2100
+  /**
2101
+   * Convert a property into getter/setter so we can emit
2102
+   * the events when the property is accessed/changed.
2103
+   *
2104
+   * @param {String} key
2105
+   * @param {*} val
2106
+   */
2107
+
2108
+  Observer.prototype.convert = function (key, val) {
2109
+    defineReactive(this.value, key, val);
2110
+  };
2111
+
2112
+  /**
2113
+   * Add an owner vm, so that when $set/$delete mutations
2114
+   * happen we can notify owner vms to proxy the keys and
2115
+   * digest the watchers. This is only called when the object
2116
+   * is observed as an instance's root $data.
2117
+   *
2118
+   * @param {Vue} vm
2119
+   */
2120
+
2121
+  Observer.prototype.addVm = function (vm) {
2122
+    (this.vms || (this.vms = [])).push(vm);
2123
+  };
2124
+
2125
+  /**
2126
+   * Remove an owner vm. This is called when the object is
2127
+   * swapped out as an instance's $data object.
2128
+   *
2129
+   * @param {Vue} vm
2130
+   */
2131
+
2132
+  Observer.prototype.removeVm = function (vm) {
2133
+    this.vms.$remove(vm);
2134
+  };
2135
+
2136
+  // helpers
2137
+
2138
+  /**
2139
+   * Augment an target Object or Array by intercepting
2140
+   * the prototype chain using __proto__
2141
+   *
2142
+   * @param {Object|Array} target
2143
+   * @param {Object} proto
2144
+   */
2145
+
2146
+  function protoAugment(target, src) {
2147
+    target.__proto__ = src;
2148
+  }
2149
+
2150
+  /**
2151
+   * Augment an target Object or Array by defining
2152
+   * hidden properties.
2153
+   *
2154
+   * @param {Object|Array} target
2155
+   * @param {Object} proto
2156
+   */
2157
+
2158
+  function copyAugment(target, src, keys) {
2159
+    for (var i = 0, l = keys.length; i < l; i++) {
2160
+      var key = keys[i];
2161
+      def(target, key, src[key]);
2162
+    }
2163
+  }
2164
+
2165
+  /**
2166
+   * Attempt to create an observer instance for a value,
2167
+   * returns the new observer if successfully observed,
2168
+   * or the existing observer if the value already has one.
2169
+   *
2170
+   * @param {*} value
2171
+   * @param {Vue} [vm]
2172
+   * @return {Observer|undefined}
2173
+   * @static
2174
+   */
2175
+
2176
+  function observe(value, vm) {
2177
+    if (!value || typeof value !== 'object') {
2178
+      return;
2179
+    }
2180
+    var ob;
2181
+    if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
2182
+      ob = value.__ob__;
2183
+    } else if ((isArray(value) || isPlainObject(value)) && Object.isExtensible(value) && !value._isVue) {
2184
+      ob = new Observer(value);
2185
+    }
2186
+    if (ob && vm) {
2187
+      ob.addVm(vm);
2188
+    }
2189
+    return ob;
2190
+  }
2191
+
2192
+  /**
2193
+   * Define a reactive property on an Object.
2194
+   *
2195
+   * @param {Object} obj
2196
+   * @param {String} key
2197
+   * @param {*} val
2198
+   */
2199
+
2200
+  function defineReactive(obj, key, val) {
2201
+    var dep = new Dep();
2202
+
2203
+    // cater for pre-defined getter/setters
2204
+    var getter, setter;
2205
+    if (config.convertAllProperties) {
2206
+      var property = Object.getOwnPropertyDescriptor(obj, key);
2207
+      if (property && property.configurable === false) {
2208
+        return;
2209
+      }
2210
+      getter = property && property.get;
2211
+      setter = property && property.set;
2212
+    }
2213
+
2214
+    var childOb = observe(val);
2215
+    Object.defineProperty(obj, key, {
2216
+      enumerable: true,
2217
+      configurable: true,
2218
+      get: function reactiveGetter() {
2219
+        var value = getter ? getter.call(obj) : val;
2220
+        if (Dep.target) {
2221
+          dep.depend();
2222
+          if (childOb) {
2223
+            childOb.dep.depend();
2224
+          }
2225
+          if (isArray(value)) {
2226
+            for (var e, i = 0, l = value.length; i < l; i++) {
2227
+              e = value[i];
2228
+              e && e.__ob__ && e.__ob__.dep.depend();
2229
+            }
2230
+          }
2231
+        }
2232
+        return value;
2233
+      },
2234
+      set: function reactiveSetter(newVal) {
2235
+        var value = getter ? getter.call(obj) : val;
2236
+        if (newVal === value) {
2237
+          return;
2238
+        }
2239
+        if (setter) {
2240
+          setter.call(obj, newVal);
2241
+        } else {
2242
+          val = newVal;
2243
+        }
2244
+        childOb = observe(newVal);
2245
+        dep.notify();
2246
+      }
2247
+    });
2248
+  }
2249
+
2250
+  var util = Object.freeze({
2251
+  	defineReactive: defineReactive,
2252
+  	set: set,
2253
+  	del: del,
2254
+  	hasOwn: hasOwn,
2255
+  	isLiteral: isLiteral,
2256
+  	isReserved: isReserved,
2257
+  	_toString: _toString,
2258
+  	toNumber: toNumber,
2259
+  	toBoolean: toBoolean,
2260
+  	stripQuotes: stripQuotes,
2261
+  	camelize: camelize,
2262
+  	hyphenate: hyphenate,
2263
+  	classify: classify,
2264
+  	bind: bind$1,
2265
+  	toArray: toArray,
2266
+  	extend: extend,
2267
+  	isObject: isObject,
2268
+  	isPlainObject: isPlainObject,
2269
+  	def: def,
2270
+  	debounce: _debounce,
2271
+  	indexOf: indexOf,
2272
+  	cancellable: cancellable,
2273
+  	looseEqual: looseEqual,
2274
+  	isArray: isArray,
2275
+  	hasProto: hasProto,
2276
+  	inBrowser: inBrowser,
2277
+  	isIE9: isIE9,
2278
+  	isAndroid: isAndroid,
2279
+  	get transitionProp () { return transitionProp; },
2280
+  	get transitionEndEvent () { return transitionEndEvent; },
2281
+  	get animationProp () { return animationProp; },
2282
+  	get animationEndEvent () { return animationEndEvent; },
2283
+  	nextTick: nextTick,
2284
+  	query: query,
2285
+  	inDoc: inDoc,
2286
+  	getAttr: getAttr,
2287
+  	getBindAttr: getBindAttr,
2288
+  	hasBindAttr: hasBindAttr,
2289
+  	before: before,
2290
+  	after: after,
2291
+  	remove: remove,
2292
+  	prepend: prepend,
2293
+  	replace: replace,
2294
+  	on: on$1,
2295
+  	off: off,
2296
+  	setClass: setClass,
2297
+  	addClass: addClass,
2298
+  	removeClass: removeClass,
2299
+  	extractContent: extractContent,
2300
+  	trimNode: trimNode,
2301
+  	isTemplate: isTemplate,
2302
+  	createAnchor: createAnchor,
2303
+  	findRef: findRef,
2304
+  	mapNodeRange: mapNodeRange,
2305
+  	removeNodeRange: removeNodeRange,
2306
+  	mergeOptions: mergeOptions,
2307
+  	resolveAsset: resolveAsset,
2308
+  	assertAsset: assertAsset,
2309
+  	checkComponentAttr: checkComponentAttr,
2310
+  	initProp: initProp,
2311
+  	assertProp: assertProp,
2312
+  	coerceProp: coerceProp,
2313
+  	commonTagRE: commonTagRE,
2314
+  	reservedTagRE: reservedTagRE,
2315
+  	get warn () { return warn; }
2316
+  });
2317
+
2318
+  var uid = 0;
2319
+
2320
+  function initMixin (Vue) {
2321
+
2322
+    /**
2323
+     * The main init sequence. This is called for every
2324
+     * instance, including ones that are created from extended
2325
+     * constructors.
2326
+     *
2327
+     * @param {Object} options - this options object should be
2328
+     *                           the result of merging class
2329
+     *                           options and the options passed
2330
+     *                           in to the constructor.
2331
+     */
2332
+
2333
+    Vue.prototype._init = function (options) {
2334
+
2335
+      options = options || {};
2336
+
2337
+      this.$el = null;
2338
+      this.$parent = options.parent;
2339
+      this.$root = this.$parent ? this.$parent.$root : this;
2340
+      this.$children = [];
2341
+      this.$refs = {}; // child vm references
2342
+      this.$els = {}; // element references
2343
+      this._watchers = []; // all watchers as an array
2344
+      this._directives = []; // all directives
2345
+
2346
+      // a uid
2347
+      this._uid = uid++;
2348
+
2349
+      // a flag to avoid this being observed
2350
+      this._isVue = true;
2351
+
2352
+      // events bookkeeping
2353
+      this._events = {}; // registered callbacks
2354
+      this._eventsCount = {}; // for $broadcast optimization
2355
+
2356
+      // fragment instance properties
2357
+      this._isFragment = false;
2358
+      this._fragment = // @type {DocumentFragment}
2359
+      this._fragmentStart = // @type {Text|Comment}
2360
+      this._fragmentEnd = null; // @type {Text|Comment}
2361
+
2362
+      // lifecycle state
2363
+      this._isCompiled = this._isDestroyed = this._isReady = this._isAttached = this._isBeingDestroyed = false;
2364
+      this._unlinkFn = null;
2365
+
2366
+      // context:
2367
+      // if this is a transcluded component, context
2368
+      // will be the common parent vm of this instance
2369
+      // and its host.
2370
+      this._context = options._context || this.$parent;
2371
+
2372
+      // scope:
2373
+      // if this is inside an inline v-for, the scope
2374
+      // will be the intermediate scope created for this
2375
+      // repeat fragment. this is used for linking props
2376
+      // and container directives.
2377
+      this._scope = options._scope;
2378
+
2379
+      // fragment:
2380
+      // if this instance is compiled inside a Fragment, it
2381
+      // needs to reigster itself as a child of that fragment
2382
+      // for attach/detach to work properly.
2383
+      this._frag = options._frag;
2384
+      if (this._frag) {
2385
+        this._frag.children.push(this);
2386
+      }
2387
+
2388
+      // push self into parent / transclusion host
2389
+      if (this.$parent) {
2390
+        this.$parent.$children.push(this);
2391
+      }
2392
+
2393
+      // merge options.
2394
+      options = this.$options = mergeOptions(this.constructor.options, options, this);
2395
+
2396
+      // set ref
2397
+      this._updateRef();
2398
+
2399
+      // initialize data as empty object.
2400
+      // it will be filled up in _initScope().
2401
+      this._data = {};
2402
+
2403
+      // call init hook
2404
+      this._callHook('init');
2405
+
2406
+      // initialize data observation and scope inheritance.
2407
+      this._initState();
2408
+
2409
+      // setup event system and option events.
2410
+      this._initEvents();
2411
+
2412
+      // call created hook
2413
+      this._callHook('created');
2414
+
2415
+      // if `el` option is passed, start compilation.
2416
+      if (options.el) {
2417
+        this.$mount(options.el);
2418
+      }
2419
+    };
2420
+  }
2421
+
2422
+  var pathCache = new Cache(1000);
2423
+
2424
+  // actions
2425
+  var APPEND = 0;
2426
+  var PUSH = 1;
2427
+  var INC_SUB_PATH_DEPTH = 2;
2428
+  var PUSH_SUB_PATH = 3;
2429
+
2430
+  // states
2431
+  var BEFORE_PATH = 0;
2432
+  var IN_PATH = 1;
2433
+  var BEFORE_IDENT = 2;
2434
+  var IN_IDENT = 3;
2435
+  var IN_SUB_PATH = 4;
2436
+  var IN_SINGLE_QUOTE = 5;
2437
+  var IN_DOUBLE_QUOTE = 6;
2438
+  var AFTER_PATH = 7;
2439
+  var ERROR = 8;
2440
+
2441
+  var pathStateMachine = [];
2442
+
2443
+  pathStateMachine[BEFORE_PATH] = {
2444
+    'ws': [BEFORE_PATH],
2445
+    'ident': [IN_IDENT, APPEND],
2446
+    '[': [IN_SUB_PATH],
2447
+    'eof': [AFTER_PATH]
2448
+  };
2449
+
2450
+  pathStateMachine[IN_PATH] = {
2451
+    'ws': [IN_PATH],
2452
+    '.': [BEFORE_IDENT],
2453
+    '[': [IN_SUB_PATH],
2454
+    'eof': [AFTER_PATH]
2455
+  };
2456
+
2457
+  pathStateMachine[BEFORE_IDENT] = {
2458
+    'ws': [BEFORE_IDENT],
2459
+    'ident': [IN_IDENT, APPEND]
2460
+  };
2461
+
2462
+  pathStateMachine[IN_IDENT] = {
2463
+    'ident': [IN_IDENT, APPEND],
2464
+    '0': [IN_IDENT, APPEND],
2465
+    'number': [IN_IDENT, APPEND],
2466
+    'ws': [IN_PATH, PUSH],
2467
+    '.': [BEFORE_IDENT, PUSH],
2468
+    '[': [IN_SUB_PATH, PUSH],
2469
+    'eof': [AFTER_PATH, PUSH]
2470
+  };
2471
+
2472
+  pathStateMachine[IN_SUB_PATH] = {
2473
+    "'": [IN_SINGLE_QUOTE, APPEND],
2474
+    '"': [IN_DOUBLE_QUOTE, APPEND],
2475
+    '[': [IN_SUB_PATH, INC_SUB_PATH_DEPTH],
2476
+    ']': [IN_PATH, PUSH_SUB_PATH],
2477
+    'eof': ERROR,
2478
+    'else': [IN_SUB_PATH, APPEND]
2479
+  };
2480
+
2481
+  pathStateMachine[IN_SINGLE_QUOTE] = {
2482
+    "'": [IN_SUB_PATH, APPEND],
2483
+    'eof': ERROR,
2484
+    'else': [IN_SINGLE_QUOTE, APPEND]
2485
+  };
2486
+
2487
+  pathStateMachine[IN_DOUBLE_QUOTE] = {
2488
+    '"': [IN_SUB_PATH, APPEND],
2489
+    'eof': ERROR,
2490
+    'else': [IN_DOUBLE_QUOTE, APPEND]
2491
+  };
2492
+
2493
+  /**
2494
+   * Determine the type of a character in a keypath.
2495
+   *
2496
+   * @param {Char} ch
2497
+   * @return {String} type
2498
+   */
2499
+
2500
+  function getPathCharType(ch) {
2501
+    if (ch === undefined) {
2502
+      return 'eof';
2503
+    }
2504
+
2505
+    var code = ch.charCodeAt(0);
2506
+
2507
+    switch (code) {
2508
+      case 0x5B: // [
2509
+      case 0x5D: // ]
2510
+      case 0x2E: // .
2511
+      case 0x22: // "
2512
+      case 0x27: // '
2513
+      case 0x30:
2514
+        // 0
2515
+        return ch;
2516
+
2517
+      case 0x5F: // _
2518
+      case 0x24:
2519
+        // $
2520
+        return 'ident';
2521
+
2522
+      case 0x20: // Space
2523
+      case 0x09: // Tab
2524
+      case 0x0A: // Newline
2525
+      case 0x0D: // Return
2526
+      case 0xA0: // No-break space
2527
+      case 0xFEFF: // Byte Order Mark
2528
+      case 0x2028: // Line Separator
2529
+      case 0x2029:
2530
+        // Paragraph Separator
2531
+        return 'ws';
2532
+    }
2533
+
2534
+    // a-z, A-Z
2535
+    if (code >= 0x61 && code <= 0x7A || code >= 0x41 && code <= 0x5A) {
2536
+      return 'ident';
2537
+    }
2538
+
2539
+    // 1-9
2540
+    if (code >= 0x31 && code <= 0x39) {
2541
+      return 'number';
2542
+    }
2543
+
2544
+    return 'else';
2545
+  }
2546
+
2547
+  /**
2548
+   * Format a subPath, return its plain form if it is
2549
+   * a literal string or number. Otherwise prepend the
2550
+   * dynamic indicator (*).
2551
+   *
2552
+   * @param {String} path
2553
+   * @return {String}
2554
+   */
2555
+
2556
+  function formatSubPath(path) {
2557
+    var trimmed = path.trim();
2558
+    // invalid leading 0
2559
+    if (path.charAt(0) === '0' && isNaN(path)) {
2560
+      return false;
2561
+    }
2562
+    return isLiteral(trimmed) ? stripQuotes(trimmed) : '*' + trimmed;
2563
+  }
2564
+
2565
+  /**
2566
+   * Parse a string path into an array of segments
2567
+   *
2568
+   * @param {String} path
2569
+   * @return {Array|undefined}
2570
+   */
2571
+
2572
+  function parse(path) {
2573
+    var keys = [];
2574
+    var index = -1;
2575
+    var mode = BEFORE_PATH;
2576
+    var subPathDepth = 0;
2577
+    var c, newChar, key, type, transition, action, typeMap;
2578
+
2579
+    var actions = [];
2580
+
2581
+    actions[PUSH] = function () {
2582
+      if (key !== undefined) {
2583
+        keys.push(key);
2584
+        key = undefined;
2585
+      }
2586
+    };
2587
+
2588
+    actions[APPEND] = function () {
2589
+      if (key === undefined) {
2590
+        key = newChar;
2591
+      } else {
2592
+        key += newChar;
2593
+      }
2594
+    };
2595
+
2596
+    actions[INC_SUB_PATH_DEPTH] = function () {
2597
+      actions[APPEND]();
2598
+      subPathDepth++;
2599
+    };
2600
+
2601
+    actions[PUSH_SUB_PATH] = function () {
2602
+      if (subPathDepth > 0) {
2603
+        subPathDepth--;
2604
+        mode = IN_SUB_PATH;
2605
+        actions[APPEND]();
2606
+      } else {
2607
+        subPathDepth = 0;
2608
+        key = formatSubPath(key);
2609
+        if (key === false) {
2610
+          return false;
2611
+        } else {
2612
+          actions[PUSH]();
2613
+        }
2614
+      }
2615
+    };
2616
+
2617
+    function maybeUnescapeQuote() {
2618
+      var nextChar = path[index + 1];
2619
+      if (mode === IN_SINGLE_QUOTE && nextChar === "'" || mode === IN_DOUBLE_QUOTE && nextChar === '"') {
2620
+        index++;
2621
+        newChar = '\\' + nextChar;
2622
+        actions[APPEND]();
2623
+        return true;
2624
+      }
2625
+    }
2626
+
2627
+    while (mode != null) {
2628
+      index++;
2629
+      c = path[index];
2630
+
2631
+      if (c === '\\' && maybeUnescapeQuote()) {
2632
+        continue;
2633
+      }
2634
+
2635
+      type = getPathCharType(c);
2636
+      typeMap = pathStateMachine[mode];
2637
+      transition = typeMap[type] || typeMap['else'] || ERROR;
2638
+
2639
+      if (transition === ERROR) {
2640
+        return; // parse error
2641
+      }
2642
+
2643
+      mode = transition[0];
2644
+      action = actions[transition[1]];
2645
+      if (action) {
2646
+        newChar = transition[2];
2647
+        newChar = newChar === undefined ? c : newChar;
2648
+        if (action() === false) {
2649
+          return;
2650
+        }
2651
+      }
2652
+
2653
+      if (mode === AFTER_PATH) {
2654
+        keys.raw = path;
2655
+        return keys;
2656
+      }
2657
+    }
2658
+  }
2659
+
2660
+  /**
2661
+   * External parse that check for a cache hit first
2662
+   *
2663
+   * @param {String} path
2664
+   * @return {Array|undefined}
2665
+   */
2666
+
2667
+  function parsePath(path) {
2668
+    var hit = pathCache.get(path);
2669
+    if (!hit) {
2670
+      hit = parse(path);
2671
+      if (hit) {
2672
+        pathCache.put(path, hit);
2673
+      }
2674
+    }
2675
+    return hit;
2676
+  }
2677
+
2678
+  /**
2679
+   * Get from an object from a path string
2680
+   *
2681
+   * @param {Object} obj
2682
+   * @param {String} path
2683
+   */
2684
+
2685
+  function getPath(obj, path) {
2686
+    return parseExpression(path).get(obj);
2687
+  }
2688
+
2689
+  /**
2690
+   * Warn against setting non-existent root path on a vm.
2691
+   */
2692
+
2693
+  var warnNonExistent;
2694
+  if ('development' !== 'production') {
2695
+    warnNonExistent = function (path) {
2696
+      warn('You are setting a non-existent path "' + path.raw + '" ' + 'on a vm instance. Consider pre-initializing the property ' + 'with the "data" option for more reliable reactivity ' + 'and better performance.');
2697
+    };
2698
+  }
2699
+
2700
+  /**
2701
+   * Set on an object from a path
2702
+   *
2703
+   * @param {Object} obj
2704
+   * @param {String | Array} path
2705
+   * @param {*} val
2706
+   */
2707
+
2708
+  function setPath(obj, path, val) {
2709
+    var original = obj;
2710
+    if (typeof path === 'string') {
2711
+      path = parse(path);
2712
+    }
2713
+    if (!path || !isObject(obj)) {
2714
+      return false;
2715
+    }
2716
+    var last, key;
2717
+    for (var i = 0, l = path.length; i < l; i++) {
2718
+      last = obj;
2719
+      key = path[i];
2720
+      if (key.charAt(0) === '*') {
2721
+        key = parseExpression(key.slice(1)).get.call(original, original);
2722
+      }
2723
+      if (i < l - 1) {
2724
+        obj = obj[key];
2725
+        if (!isObject(obj)) {
2726
+          obj = {};
2727
+          if ('development' !== 'production' && last._isVue) {
2728
+            warnNonExistent(path);
2729
+          }
2730
+          set(last, key, obj);
2731
+        }
2732
+      } else {
2733
+        if (isArray(obj)) {
2734
+          obj.$set(key, val);
2735
+        } else if (key in obj) {
2736
+          obj[key] = val;
2737
+        } else {
2738
+          if ('development' !== 'production' && obj._isVue) {
2739
+            warnNonExistent(path);
2740
+          }
2741
+          set(obj, key, val);
2742
+        }
2743
+      }
2744
+    }
2745
+    return true;
2746
+  }
2747
+
2748
+  var path = Object.freeze({
2749
+    parsePath: parsePath,
2750
+    getPath: getPath,
2751
+    setPath: setPath
2752
+  });
2753
+
2754
+  var expressionCache = new Cache(1000);
2755
+
2756
+  var allowedKeywords = 'Math,Date,this,true,false,null,undefined,Infinity,NaN,' + 'isNaN,isFinite,decodeURI,decodeURIComponent,encodeURI,' + 'encodeURIComponent,parseInt,parseFloat';
2757
+  var allowedKeywordsRE = new RegExp('^(' + allowedKeywords.replace(/,/g, '\\b|') + '\\b)');
2758
+
2759
+  // keywords that don't make sense inside expressions
2760
+  var improperKeywords = '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';
2761
+  var improperKeywordsRE = new RegExp('^(' + improperKeywords.replace(/,/g, '\\b|') + '\\b)');
2762
+
2763
+  var wsRE = /\s/g;
2764
+  var newlineRE = /\n/g;
2765
+  var saveRE = /[\{,]\s*[\w\$_]+\s*:|('(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*")|new |typeof |void /g;
2766
+  var restoreRE = /"(\d+)"/g;
2767
+  var pathTestRE = /^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['.*?'\]|\[".*?"\]|\[\d+\]|\[[A-Za-z_$][\w$]*\])*$/;
2768
+  var identRE = /[^\w$\.](?:[A-Za-z_$][\w$]*)/g;
2769
+  var booleanLiteralRE = /^(?:true|false)$/;
2770
+
2771
+  /**
2772
+   * Save / Rewrite / Restore
2773
+   *
2774
+   * When rewriting paths found in an expression, it is
2775
+   * possible for the same letter sequences to be found in
2776
+   * strings and Object literal property keys. Therefore we
2777
+   * remove and store these parts in a temporary array, and
2778
+   * restore them after the path rewrite.
2779
+   */
2780
+
2781
+  var saved = [];
2782
+
2783
+  /**
2784
+   * Save replacer
2785
+   *
2786
+   * The save regex can match two possible cases:
2787
+   * 1. An opening object literal
2788
+   * 2. A string
2789
+   * If matched as a plain string, we need to escape its
2790
+   * newlines, since the string needs to be preserved when
2791
+   * generating the function body.
2792
+   *
2793
+   * @param {String} str
2794
+   * @param {String} isString - str if matched as a string
2795
+   * @return {String} - placeholder with index
2796
+   */
2797
+
2798
+  function save(str, isString) {
2799
+    var i = saved.length;
2800
+    saved[i] = isString ? str.replace(newlineRE, '\\n') : str;
2801
+    return '"' + i + '"';
2802
+  }
2803
+
2804
+  /**
2805
+   * Path rewrite replacer
2806
+   *
2807
+   * @param {String} raw
2808
+   * @return {String}
2809
+   */
2810
+
2811
+  function rewrite(raw) {
2812
+    var c = raw.charAt(0);
2813
+    var path = raw.slice(1);
2814
+    if (allowedKeywordsRE.test(path)) {
2815
+      return raw;
2816
+    } else {
2817
+      path = path.indexOf('"') > -1 ? path.replace(restoreRE, restore) : path;
2818
+      return c + 'scope.' + path;
2819
+    }
2820
+  }
2821
+
2822
+  /**
2823
+   * Restore replacer
2824
+   *
2825
+   * @param {String} str
2826
+   * @param {String} i - matched save index
2827
+   * @return {String}
2828
+   */
2829
+
2830
+  function restore(str, i) {
2831
+    return saved[i];
2832
+  }
2833
+
2834
+  /**
2835
+   * Rewrite an expression, prefixing all path accessors with
2836
+   * `scope.` and generate getter/setter functions.
2837
+   *
2838
+   * @param {String} exp
2839
+   * @return {Function}
2840
+   */
2841
+
2842
+  function compileGetter(exp) {
2843
+    if (improperKeywordsRE.test(exp)) {
2844
+      'development' !== 'production' && warn('Avoid using reserved keywords in expression: ' + exp);
2845
+    }
2846
+    // reset state
2847
+    saved.length = 0;
2848
+    // save strings and object literal keys
2849
+    var body = exp.replace(saveRE, save).replace(wsRE, '');
2850
+    // rewrite all paths
2851
+    // pad 1 space here becaue the regex matches 1 extra char
2852
+    body = (' ' + body).replace(identRE, rewrite).replace(restoreRE, restore);
2853
+    return makeGetterFn(body);
2854
+  }
2855
+
2856
+  /**
2857
+   * Build a getter function. Requires eval.
2858
+   *
2859
+   * We isolate the try/catch so it doesn't affect the
2860
+   * optimization of the parse function when it is not called.
2861
+   *
2862
+   * @param {String} body
2863
+   * @return {Function|undefined}
2864
+   */
2865
+
2866
+  function makeGetterFn(body) {
2867
+    try {
2868
+      return new Function('scope', 'return ' + body + ';');
2869
+    } catch (e) {
2870
+      'development' !== 'production' && warn('Invalid expression. ' + 'Generated function body: ' + body);
2871
+    }
2872
+  }
2873
+
2874
+  /**
2875
+   * Compile a setter function for the expression.
2876
+   *
2877
+   * @param {String} exp
2878
+   * @return {Function|undefined}
2879
+   */
2880
+
2881
+  function compileSetter(exp) {
2882
+    var path = parsePath(exp);
2883
+    if (path) {
2884
+      return function (scope, val) {
2885
+        setPath(scope, path, val);
2886
+      };
2887
+    } else {
2888
+      'development' !== 'production' && warn('Invalid setter expression: ' + exp);
2889
+    }
2890
+  }
2891
+
2892
+  /**
2893
+   * Parse an expression into re-written getter/setters.
2894
+   *
2895
+   * @param {String} exp
2896
+   * @param {Boolean} needSet
2897
+   * @return {Function}
2898
+   */
2899
+
2900
+  function parseExpression(exp, needSet) {
2901
+    exp = exp.trim();
2902
+    // try cache
2903
+    var hit = expressionCache.get(exp);
2904
+    if (hit) {
2905
+      if (needSet && !hit.set) {
2906
+        hit.set = compileSetter(hit.exp);
2907
+      }
2908
+      return hit;
2909
+    }
2910
+    var res = { exp: exp };
2911
+    res.get = isSimplePath(exp) && exp.indexOf('[') < 0
2912
+    // optimized super simple getter
2913
+    ? makeGetterFn('scope.' + exp)
2914
+    // dynamic getter
2915
+    : compileGetter(exp);
2916
+    if (needSet) {
2917
+      res.set = compileSetter(exp);
2918
+    }
2919
+    expressionCache.put(exp, res);
2920
+    return res;
2921
+  }
2922
+
2923
+  /**
2924
+   * Check if an expression is a simple path.
2925
+   *
2926
+   * @param {String} exp
2927
+   * @return {Boolean}
2928
+   */
2929
+
2930
+  function isSimplePath(exp) {
2931
+    return pathTestRE.test(exp) &&
2932
+    // don't treat true/false as paths
2933
+    !booleanLiteralRE.test(exp) &&
2934
+    // Math constants e.g. Math.PI, Math.E etc.
2935
+    exp.slice(0, 5) !== 'Math.';
2936
+  }
2937
+
2938
+  var expression = Object.freeze({
2939
+    parseExpression: parseExpression,
2940
+    isSimplePath: isSimplePath
2941
+  });
2942
+
2943
+  // we have two separate queues: one for directive updates
2944
+  // and one for user watcher registered via $watch().
2945
+  // we want to guarantee directive updates to be called
2946
+  // before user watchers so that when user watchers are
2947
+  // triggered, the DOM would have already been in updated
2948
+  // state.
2949
+  var queue = [];
2950
+  var userQueue = [];
2951
+  var has = {};
2952
+  var circular = {};
2953
+  var waiting = false;
2954
+  var internalQueueDepleted = false;
2955
+
2956
+  /**
2957
+   * Reset the batcher's state.
2958
+   */
2959
+
2960
+  function resetBatcherState() {
2961
+    queue = [];
2962
+    userQueue = [];
2963
+    has = {};
2964
+    circular = {};
2965
+    waiting = internalQueueDepleted = false;
2966
+  }
2967
+
2968
+  /**
2969
+   * Flush both queues and run the watchers.
2970
+   */
2971
+
2972
+  function flushBatcherQueue() {
2973
+    runBatcherQueue(queue);
2974
+    internalQueueDepleted = true;
2975
+    runBatcherQueue(userQueue);
2976
+    // dev tool hook
2977
+    /* istanbul ignore if */
2978
+    if ('development' !== 'production') {
2979
+      if (inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__) {
2980
+        window.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit('flush');
2981
+      }
2982
+    }
2983
+    resetBatcherState();
2984
+  }
2985
+
2986
+  /**
2987
+   * Run the watchers in a single queue.
2988
+   *
2989
+   * @param {Array} queue
2990
+   */
2991
+
2992
+  function runBatcherQueue(queue) {
2993
+    // do not cache length because more watchers might be pushed
2994
+    // as we run existing watchers
2995
+    for (var i = 0; i < queue.length; i++) {
2996
+      var watcher = queue[i];
2997
+      var id = watcher.id;
2998
+      has[id] = null;
2999
+      watcher.run();
3000
+      // in dev build, check and stop circular updates.
3001
+      if ('development' !== 'production' && has[id] != null) {
3002
+        circular[id] = (circular[id] || 0) + 1;
3003
+        if (circular[id] > config._maxUpdateCount) {
3004
+          queue.splice(has[id], 1);
3005
+          warn('You may have an infinite update loop for watcher ' + 'with expression: ' + watcher.expression);
3006
+        }
3007
+      }
3008
+    }
3009
+  }
3010
+
3011
+  /**
3012
+   * Push a watcher into the watcher queue.
3013
+   * Jobs with duplicate IDs will be skipped unless it's
3014
+   * pushed when the queue is being flushed.
3015
+   *
3016
+   * @param {Watcher} watcher
3017
+   *   properties:
3018
+   *   - {Number} id
3019
+   *   - {Function} run
3020
+   */
3021
+
3022
+  function pushWatcher(watcher) {
3023
+    var id = watcher.id;
3024
+    if (has[id] == null) {
3025
+      // if an internal watcher is pushed, but the internal
3026
+      // queue is already depleted, we run it immediately.
3027
+      if (internalQueueDepleted && !watcher.user) {
3028
+        watcher.run();
3029
+        return;
3030
+      }
3031
+      // push watcher into appropriate queue
3032
+      var q = watcher.user ? userQueue : queue;
3033
+      has[id] = q.length;
3034
+      q.push(watcher);
3035
+      // queue the flush
3036
+      if (!waiting) {
3037
+        waiting = true;
3038
+        nextTick(flushBatcherQueue);
3039
+      }
3040
+    }
3041
+  }
3042
+
3043
+  var uid$2 = 0;
3044
+
3045
+  /**
3046
+   * A watcher parses an expression, collects dependencies,
3047
+   * and fires callback when the expression value changes.
3048
+   * This is used for both the $watch() api and directives.
3049
+   *
3050
+   * @param {Vue} vm
3051
+   * @param {String} expression
3052
+   * @param {Function} cb
3053
+   * @param {Object} options
3054
+   *                 - {Array} filters
3055
+   *                 - {Boolean} twoWay
3056
+   *                 - {Boolean} deep
3057
+   *                 - {Boolean} user
3058
+   *                 - {Boolean} sync
3059
+   *                 - {Boolean} lazy
3060
+   *                 - {Function} [preProcess]
3061
+   *                 - {Function} [postProcess]
3062
+   * @constructor
3063
+   */
3064
+  function Watcher(vm, expOrFn, cb, options) {
3065
+    // mix in options
3066
+    if (options) {
3067
+      extend(this, options);
3068
+    }
3069
+    var isFn = typeof expOrFn === 'function';
3070
+    this.vm = vm;
3071
+    vm._watchers.push(this);
3072
+    this.expression = isFn ? expOrFn.toString() : expOrFn;
3073
+    this.cb = cb;
3074
+    this.id = ++uid$2; // uid for batching
3075
+    this.active = true;
3076
+    this.dirty = this.lazy; // for lazy watchers
3077
+    this.deps = Object.create(null);
3078
+    this.newDeps = null;
3079
+    this.prevError = null; // for async error stacks
3080
+    // parse expression for getter/setter
3081
+    if (isFn) {
3082
+      this.getter = expOrFn;
3083
+      this.setter = undefined;
3084
+    } else {
3085
+      var res = parseExpression(expOrFn, this.twoWay);
3086
+      this.getter = res.get;
3087
+      this.setter = res.set;
3088
+    }
3089
+    this.value = this.lazy ? undefined : this.get();
3090
+    // state for avoiding false triggers for deep and Array
3091
+    // watchers during vm._digest()
3092
+    this.queued = this.shallow = false;
3093
+  }
3094
+
3095
+  /**
3096
+   * Add a dependency to this directive.
3097
+   *
3098
+   * @param {Dep} dep
3099
+   */
3100
+
3101
+  Watcher.prototype.addDep = function (dep) {
3102
+    var id = dep.id;
3103
+    if (!this.newDeps[id]) {
3104
+      this.newDeps[id] = dep;
3105
+      if (!this.deps[id]) {
3106
+        this.deps[id] = dep;
3107
+        dep.addSub(this);
3108
+      }
3109
+    }
3110
+  };
3111
+
3112
+  /**
3113
+   * Evaluate the getter, and re-collect dependencies.
3114
+   */
3115
+
3116
+  Watcher.prototype.get = function () {
3117
+    this.beforeGet();
3118
+    var scope = this.scope || this.vm;
3119
+    var value;
3120
+    try {
3121
+      value = this.getter.call(scope, scope);
3122
+    } catch (e) {
3123
+      if ('development' !== 'production' && config.warnExpressionErrors) {
3124
+        warn('Error when evaluating expression "' + this.expression + '". ' + (config.debug ? '' : 'Turn on debug mode to see stack trace.'), e);
3125
+      }
3126
+    }
3127
+    // "touch" every property so they are all tracked as
3128
+    // dependencies for deep watching
3129
+    if (this.deep) {
3130
+      traverse(value);
3131
+    }
3132
+    if (this.preProcess) {
3133
+      value = this.preProcess(value);
3134
+    }
3135
+    if (this.filters) {
3136
+      value = scope._applyFilters(value, null, this.filters, false);
3137
+    }
3138
+    if (this.postProcess) {
3139
+      value = this.postProcess(value);
3140
+    }
3141
+    this.afterGet();
3142
+    return value;
3143
+  };
3144
+
3145
+  /**
3146
+   * Set the corresponding value with the setter.
3147
+   *
3148
+   * @param {*} value
3149
+   */
3150
+
3151
+  Watcher.prototype.set = function (value) {
3152
+    var scope = this.scope || this.vm;
3153
+    if (this.filters) {
3154
+      value = scope._applyFilters(value, this.value, this.filters, true);
3155
+    }
3156
+    try {
3157
+      this.setter.call(scope, scope, value);
3158
+    } catch (e) {
3159
+      if ('development' !== 'production' && config.warnExpressionErrors) {
3160
+        warn('Error when evaluating setter "' + this.expression + '"', e);
3161
+      }
3162
+    }
3163
+    // two-way sync for v-for alias
3164
+    var forContext = scope.$forContext;
3165
+    if (forContext && forContext.alias === this.expression) {
3166
+      if (forContext.filters) {
3167
+        'development' !== 'production' && warn('It seems you are using two-way binding on ' + 'a v-for alias (' + this.expression + '), and the ' + 'v-for has filters. This will not work properly. ' + 'Either remove the filters or use an array of ' + 'objects and bind to object properties instead.');
3168
+        return;
3169
+      }
3170
+      forContext._withLock(function () {
3171
+        if (scope.$key) {
3172
+          // original is an object
3173
+          forContext.rawValue[scope.$key] = value;
3174
+        } else {
3175
+          forContext.rawValue.$set(scope.$index, value);
3176
+        }
3177
+      });
3178
+    }
3179
+  };
3180
+
3181
+  /**
3182
+   * Prepare for dependency collection.
3183
+   */
3184
+
3185
+  Watcher.prototype.beforeGet = function () {
3186
+    Dep.target = this;
3187
+    this.newDeps = Object.create(null);
3188
+  };
3189
+
3190
+  /**
3191
+   * Clean up for dependency collection.
3192
+   */
3193
+
3194
+  Watcher.prototype.afterGet = function () {
3195
+    Dep.target = null;
3196
+    var ids = Object.keys(this.deps);
3197
+    var i = ids.length;
3198
+    while (i--) {
3199
+      var id = ids[i];
3200
+      if (!this.newDeps[id]) {
3201
+        this.deps[id].removeSub(this);
3202
+      }
3203
+    }
3204
+    this.deps = this.newDeps;
3205
+  };
3206
+
3207
+  /**
3208
+   * Subscriber interface.
3209
+   * Will be called when a dependency changes.
3210
+   *
3211
+   * @param {Boolean} shallow
3212
+   */
3213
+
3214
+  Watcher.prototype.update = function (shallow) {
3215
+    if (this.lazy) {
3216
+      this.dirty = true;
3217
+    } else if (this.sync || !config.async) {
3218
+      this.run();
3219
+    } else {
3220
+      // if queued, only overwrite shallow with non-shallow,
3221
+      // but not the other way around.
3222
+      this.shallow = this.queued ? shallow ? this.shallow : false : !!shallow;
3223
+      this.queued = true;
3224
+      // record before-push error stack in debug mode
3225
+      /* istanbul ignore if */
3226
+      if ('development' !== 'production' && config.debug) {
3227
+        this.prevError = new Error('[vue] async stack trace');
3228
+      }
3229
+      pushWatcher(this);
3230
+    }
3231
+  };
3232
+
3233
+  /**
3234
+   * Batcher job interface.
3235
+   * Will be called by the batcher.
3236
+   */
3237
+
3238
+  Watcher.prototype.run = function () {
3239
+    if (this.active) {
3240
+      var value = this.get();
3241
+      if (value !== this.value ||
3242
+      // Deep watchers and watchers on Object/Arrays should fire even
3243
+      // when the value is the same, because the value may
3244
+      // have mutated; but only do so if this is a
3245
+      // non-shallow update (caused by a vm digest).
3246
+      (isObject(value) || this.deep) && !this.shallow) {
3247
+        // set new value
3248
+        var oldValue = this.value;
3249
+        this.value = value;
3250
+        // in debug + async mode, when a watcher callbacks
3251
+        // throws, we also throw the saved before-push error
3252
+        // so the full cross-tick stack trace is available.
3253
+        var prevError = this.prevError;
3254
+        /* istanbul ignore if */
3255
+        if ('development' !== 'production' && config.debug && prevError) {
3256
+          this.prevError = null;
3257
+          try {
3258
+            this.cb.call(this.vm, value, oldValue);
3259
+          } catch (e) {
3260
+            nextTick(function () {
3261
+              throw prevError;
3262
+            }, 0);
3263
+            throw e;
3264
+          }
3265
+        } else {
3266
+          this.cb.call(this.vm, value, oldValue);
3267
+        }
3268
+      }
3269
+      this.queued = this.shallow = false;
3270
+    }
3271
+  };
3272
+
3273
+  /**
3274
+   * Evaluate the value of the watcher.
3275
+   * This only gets called for lazy watchers.
3276
+   */
3277
+
3278
+  Watcher.prototype.evaluate = function () {
3279
+    // avoid overwriting another watcher that is being
3280
+    // collected.
3281
+    var current = Dep.target;
3282
+    this.value = this.get();
3283
+    this.dirty = false;
3284
+    Dep.target = current;
3285
+  };
3286
+
3287
+  /**
3288
+   * Depend on all deps collected by this watcher.
3289
+   */
3290
+
3291
+  Watcher.prototype.depend = function () {
3292
+    var depIds = Object.keys(this.deps);
3293
+    var i = depIds.length;
3294
+    while (i--) {
3295
+      this.deps[depIds[i]].depend();
3296
+    }
3297
+  };
3298
+
3299
+  /**
3300
+   * Remove self from all dependencies' subcriber list.
3301
+   */
3302
+
3303
+  Watcher.prototype.teardown = function () {
3304
+    if (this.active) {
3305
+      // remove self from vm's watcher list
3306
+      // we can skip this if the vm if being destroyed
3307
+      // which can improve teardown performance.
3308
+      if (!this.vm._isBeingDestroyed) {
3309
+        this.vm._watchers.$remove(this);
3310
+      }
3311
+      var depIds = Object.keys(this.deps);
3312
+      var i = depIds.length;
3313
+      while (i--) {
3314
+        this.deps[depIds[i]].removeSub(this);
3315
+      }
3316
+      this.active = false;
3317
+      this.vm = this.cb = this.value = null;
3318
+    }
3319
+  };
3320
+
3321
+  /**
3322
+   * Recrusively traverse an object to evoke all converted
3323
+   * getters, so that every nested property inside the object
3324
+   * is collected as a "deep" dependency.
3325
+   *
3326
+   * @param {*} val
3327
+   */
3328
+
3329
+  function traverse(val) {
3330
+    var i, keys;
3331
+    if (isArray(val)) {
3332
+      i = val.length;
3333
+      while (i--) traverse(val[i]);
3334
+    } else if (isObject(val)) {
3335
+      keys = Object.keys(val);
3336
+      i = keys.length;
3337
+      while (i--) traverse(val[keys[i]]);
3338
+    }
3339
+  }
3340
+
3341
+  var cloak = {
3342
+    bind: function bind() {
3343
+      var el = this.el;
3344
+      this.vm.$once('pre-hook:compiled', function () {
3345
+        el.removeAttribute('v-cloak');
3346
+      });
3347
+    }
3348
+  };
3349
+
3350
+  var ref = {
3351
+    bind: function bind() {
3352
+      'development' !== 'production' && warn('v-ref:' + this.arg + ' must be used on a child ' + 'component. Found on <' + this.el.tagName.toLowerCase() + '>.');
3353
+    }
3354
+  };
3355
+
3356
+  var ON = 700;
3357
+  var MODEL = 800;
3358
+  var BIND = 850;
3359
+  var TRANSITION = 1100;
3360
+  var EL = 1500;
3361
+  var COMPONENT = 1500;
3362
+  var PARTIAL = 1750;
3363
+  var FOR = 2000;
3364
+  var IF = 2000;
3365
+  var SLOT = 2100;
3366
+
3367
+  var el = {
3368
+
3369
+    priority: EL,
3370
+
3371
+    bind: function bind() {
3372
+      /* istanbul ignore if */
3373
+      if (!this.arg) {
3374
+        return;
3375
+      }
3376
+      var id = this.id = camelize(this.arg);
3377
+      var refs = (this._scope || this.vm).$els;
3378
+      if (hasOwn(refs, id)) {
3379
+        refs[id] = this.el;
3380
+      } else {
3381
+        defineReactive(refs, id, this.el);
3382
+      }
3383
+    },
3384
+
3385
+    unbind: function unbind() {
3386
+      var refs = (this._scope || this.vm).$els;
3387
+      if (refs[this.id] === this.el) {
3388
+        refs[this.id] = null;
3389
+      }
3390
+    }
3391
+  };
3392
+
3393
+  var prefixes = ['-webkit-', '-moz-', '-ms-'];
3394
+  var camelPrefixes = ['Webkit', 'Moz', 'ms'];
3395
+  var importantRE = /!important;?$/;
3396
+  var propCache = Object.create(null);
3397
+
3398
+  var testEl = null;
3399
+
3400
+  var style = {
3401
+
3402
+    deep: true,
3403
+
3404
+    update: function update(value) {
3405
+      if (typeof value === 'string') {
3406
+        this.el.style.cssText = value;
3407
+      } else if (isArray(value)) {
3408
+        this.handleObject(value.reduce(extend, {}));
3409
+      } else {
3410
+        this.handleObject(value || {});
3411
+      }
3412
+    },
3413
+
3414
+    handleObject: function handleObject(value) {
3415
+      // cache object styles so that only changed props
3416
+      // are actually updated.
3417
+      var cache = this.cache || (this.cache = {});
3418
+      var name, val;
3419
+      for (name in cache) {
3420
+        if (!(name in value)) {
3421
+          this.handleSingle(name, null);
3422
+          delete cache[name];
3423
+        }
3424
+      }
3425
+      for (name in value) {
3426
+        val = value[name];
3427
+        if (val !== cache[name]) {
3428
+          cache[name] = val;
3429
+          this.handleSingle(name, val);
3430
+        }
3431
+      }
3432
+    },
3433
+
3434
+    handleSingle: function handleSingle(prop, value) {
3435
+      prop = normalize(prop);
3436
+      if (!prop) return; // unsupported prop
3437
+      // cast possible numbers/booleans into strings
3438
+      if (value != null) value += '';
3439
+      if (value) {
3440
+        var isImportant = importantRE.test(value) ? 'important' : '';
3441
+        if (isImportant) {
3442
+          value = value.replace(importantRE, '').trim();
3443
+        }
3444
+        this.el.style.setProperty(prop, value, isImportant);
3445
+      } else {
3446
+        this.el.style.removeProperty(prop);
3447
+      }
3448
+    }
3449
+
3450
+  };
3451
+
3452
+  /**
3453
+   * Normalize a CSS property name.
3454
+   * - cache result
3455
+   * - auto prefix
3456
+   * - camelCase -> dash-case
3457
+   *
3458
+   * @param {String} prop
3459
+   * @return {String}
3460
+   */
3461
+
3462
+  function normalize(prop) {
3463
+    if (propCache[prop]) {
3464
+      return propCache[prop];
3465
+    }
3466
+    var res = prefix(prop);
3467
+    propCache[prop] = propCache[res] = res;
3468
+    return res;
3469
+  }
3470
+
3471
+  /**
3472
+   * Auto detect the appropriate prefix for a CSS property.
3473
+   * https://gist.github.com/paulirish/523692
3474
+   *
3475
+   * @param {String} prop
3476
+   * @return {String}
3477
+   */
3478
+
3479
+  function prefix(prop) {
3480
+    prop = hyphenate(prop);
3481
+    var camel = camelize(prop);
3482
+    var upper = camel.charAt(0).toUpperCase() + camel.slice(1);
3483
+    if (!testEl) {
3484
+      testEl = document.createElement('div');
3485
+    }
3486
+    if (camel in testEl.style) {
3487
+      return prop;
3488
+    }
3489
+    var i = prefixes.length;
3490
+    var prefixed;
3491
+    while (i--) {
3492
+      prefixed = camelPrefixes[i] + upper;
3493
+      if (prefixed in testEl.style) {
3494
+        return prefixes[i] + prop;
3495
+      }
3496
+    }
3497
+  }
3498
+
3499
+  // xlink
3500
+  var xlinkNS = 'http://www.w3.org/1999/xlink';
3501
+  var xlinkRE = /^xlink:/;
3502
+
3503
+  // check for attributes that prohibit interpolations
3504
+  var disallowedInterpAttrRE = /^v-|^:|^@|^(?:is|transition|transition-mode|debounce|track-by|stagger|enter-stagger|leave-stagger)$/;
3505
+  // these attributes should also set their corresponding properties
3506
+  // because they only affect the initial state of the element
3507
+  var attrWithPropsRE = /^(?:value|checked|selected|muted)$/;
3508
+
3509
+  // these attributes should set a hidden property for
3510
+  // binding v-model to object values
3511
+  var modelProps = {
3512
+    value: '_value',
3513
+    'true-value': '_trueValue',
3514
+    'false-value': '_falseValue'
3515
+  };
3516
+
3517
+  var bind = {
3518
+
3519
+    priority: BIND,
3520
+
3521
+    bind: function bind() {
3522
+      var attr = this.arg;
3523
+      var tag = this.el.tagName;
3524
+      // should be deep watch on object mode
3525
+      if (!attr) {
3526
+        this.deep = true;
3527
+      }
3528
+      // handle interpolation bindings
3529
+      var descriptor = this.descriptor;
3530
+      var tokens = descriptor.interp;
3531
+      if (tokens) {
3532
+        // handle interpolations with one-time tokens
3533
+        if (descriptor.hasOneTime) {
3534
+          this.expression = tokensToExp(tokens, this._scope || this.vm);
3535
+        }
3536
+
3537
+        // only allow binding on native attributes
3538
+        if (disallowedInterpAttrRE.test(attr) || attr === 'name' && (tag === 'PARTIAL' || tag === 'SLOT')) {
3539
+          'development' !== 'production' && warn(attr + '="' + descriptor.raw + '": ' + 'attribute interpolation is not allowed in Vue.js ' + 'directives and special attributes.');
3540
+          this.el.removeAttribute(attr);
3541
+          this.invalid = true;
3542
+        }
3543
+
3544
+        /* istanbul ignore if */
3545
+        if ('development' !== 'production') {
3546
+          var raw = attr + '="' + descriptor.raw + '": ';
3547
+          // warn src
3548
+          if (attr === 'src') {
3549
+            warn(raw + 'interpolation in "src" attribute will cause ' + 'a 404 request. Use v-bind:src instead.');
3550
+          }
3551
+
3552
+          // warn style
3553
+          if (attr === 'style') {
3554
+            warn(raw + 'interpolation in "style" attribute will cause ' + 'the attribute to be discarded in Internet Explorer. ' + 'Use v-bind:style instead.');
3555
+          }
3556
+        }
3557
+      }
3558
+    },
3559
+
3560
+    update: function update(value) {
3561
+      if (this.invalid) {
3562
+        return;
3563
+      }
3564
+      var attr = this.arg;
3565
+      if (this.arg) {
3566
+        this.handleSingle(attr, value);
3567
+      } else {
3568
+        this.handleObject(value || {});
3569
+      }
3570
+    },
3571
+
3572
+    // share object handler with v-bind:class
3573
+    handleObject: style.handleObject,
3574
+
3575
+    handleSingle: function handleSingle(attr, value) {
3576
+      var el = this.el;
3577
+      var interp = this.descriptor.interp;
3578
+      if (!interp && attrWithPropsRE.test(attr) && attr in el) {
3579
+        el[attr] = attr === 'value' ? value == null // IE9 will set input.value to "null" for null...
3580
+        ? '' : value : value;
3581
+      }
3582
+      // set model props
3583
+      var modelProp = modelProps[attr];
3584
+      if (!interp && modelProp) {
3585
+        el[modelProp] = value;
3586
+        // update v-model if present
3587
+        var model = el.__v_model;
3588
+        if (model) {
3589
+          model.listener();
3590
+        }
3591
+      }
3592
+      // do not set value attribute for textarea
3593
+      if (attr === 'value' && el.tagName === 'TEXTAREA') {
3594
+        el.removeAttribute(attr);
3595
+        return;
3596
+      }
3597
+      // update attribute
3598
+      if (value != null && value !== false) {
3599
+        if (attr === 'class') {
3600
+          // handle edge case #1960:
3601
+          // class interpolation should not overwrite Vue transition class
3602
+          if (el.__v_trans) {
3603
+            value += ' ' + el.__v_trans.id + '-transition';
3604
+          }
3605
+          setClass(el, value);
3606
+        } else if (xlinkRE.test(attr)) {
3607
+          el.setAttributeNS(xlinkNS, attr, value);
3608
+        } else {
3609
+          el.setAttribute(attr, value);
3610
+        }
3611
+      } else {
3612
+        el.removeAttribute(attr);
3613
+      }
3614
+    }
3615
+  };
3616
+
3617
+  // keyCode aliases
3618
+  var keyCodes = {
3619
+    esc: 27,
3620
+    tab: 9,
3621
+    enter: 13,
3622
+    space: 32,
3623
+    'delete': 46,
3624
+    up: 38,
3625
+    left: 37,
3626
+    right: 39,
3627
+    down: 40
3628
+  };
3629
+
3630
+  function keyFilter(handler, keys) {
3631
+    var codes = keys.map(function (key) {
3632
+      var charCode = key.charCodeAt(0);
3633
+      if (charCode > 47 && charCode < 58) {
3634
+        return parseInt(key, 10);
3635
+      }
3636
+      if (key.length === 1) {
3637
+        charCode = key.toUpperCase().charCodeAt(0);
3638
+        if (charCode > 64 && charCode < 91) {
3639
+          return charCode;
3640
+        }
3641
+      }
3642
+      return keyCodes[key];
3643
+    });
3644
+    return function keyHandler(e) {
3645
+      if (codes.indexOf(e.keyCode) > -1) {
3646
+        return handler.call(this, e);
3647
+      }
3648
+    };
3649
+  }
3650
+
3651
+  function stopFilter(handler) {
3652
+    return function stopHandler(e) {
3653
+      e.stopPropagation();
3654
+      return handler.call(this, e);
3655
+    };
3656
+  }
3657
+
3658
+  function preventFilter(handler) {
3659
+    return function preventHandler(e) {
3660
+      e.preventDefault();
3661
+      return handler.call(this, e);
3662
+    };
3663
+  }
3664
+
3665
+  var on = {
3666
+
3667
+    acceptStatement: true,
3668
+    priority: ON,
3669
+
3670
+    bind: function bind() {
3671
+      // deal with iframes
3672
+      if (this.el.tagName === 'IFRAME' && this.arg !== 'load') {
3673
+        var self = this;
3674
+        this.iframeBind = function () {
3675
+          on$1(self.el.contentWindow, self.arg, self.handler);
3676
+        };
3677
+        this.on('load', this.iframeBind);
3678
+      }
3679
+    },
3680
+
3681
+    update: function update(handler) {
3682
+      // stub a noop for v-on with no value,
3683
+      // e.g. @mousedown.prevent
3684
+      if (!this.descriptor.raw) {
3685
+        handler = function () {};
3686
+      }
3687
+
3688
+      if (typeof handler !== 'function') {
3689
+        'development' !== 'production' && warn('v-on:' + this.arg + '="' + this.expression + '" expects a function value, ' + 'got ' + handler);
3690
+        return;
3691
+      }
3692
+
3693
+      // apply modifiers
3694
+      if (this.modifiers.stop) {
3695
+        handler = stopFilter(handler);
3696
+      }
3697
+      if (this.modifiers.prevent) {
3698
+        handler = preventFilter(handler);
3699
+      }
3700
+      // key filter
3701
+      var keys = Object.keys(this.modifiers).filter(function (key) {
3702
+        return key !== 'stop' && key !== 'prevent';
3703
+      });
3704
+      if (keys.length) {
3705
+        handler = keyFilter(handler, keys);
3706
+      }
3707
+
3708
+      this.reset();
3709
+      this.handler = handler;
3710
+
3711
+      if (this.iframeBind) {
3712
+        this.iframeBind();
3713
+      } else {
3714
+        on$1(this.el, this.arg, this.handler);
3715
+      }
3716
+    },
3717
+
3718
+    reset: function reset() {
3719
+      var el = this.iframeBind ? this.el.contentWindow : this.el;
3720
+      if (this.handler) {
3721
+        off(el, this.arg, this.handler);
3722
+      }
3723
+    },
3724
+
3725
+    unbind: function unbind() {
3726
+      this.reset();
3727
+    }
3728
+  };
3729
+
3730
+  var checkbox = {
3731
+
3732
+    bind: function bind() {
3733
+      var self = this;
3734
+      var el = this.el;
3735
+
3736
+      this.getValue = function () {
3737
+        return el.hasOwnProperty('_value') ? el._value : self.params.number ? toNumber(el.value) : el.value;
3738
+      };
3739
+
3740
+      function getBooleanValue() {
3741
+        var val = el.checked;
3742
+        if (val && el.hasOwnProperty('_trueValue')) {
3743
+          return el._trueValue;
3744
+        }
3745
+        if (!val && el.hasOwnProperty('_falseValue')) {
3746
+          return el._falseValue;
3747
+        }
3748
+        return val;
3749
+      }
3750
+
3751
+      this.listener = function () {
3752
+        var model = self._watcher.value;
3753
+        if (isArray(model)) {
3754
+          var val = self.getValue();
3755
+          if (el.checked) {
3756
+            if (indexOf(model, val) < 0) {
3757
+              model.push(val);
3758
+            }
3759
+          } else {
3760
+            model.$remove(val);
3761
+          }
3762
+        } else {
3763
+          self.set(getBooleanValue());
3764
+        }
3765
+      };
3766
+
3767
+      this.on('change', this.listener);
3768
+      if (el.hasAttribute('checked')) {
3769
+        this.afterBind = this.listener;
3770
+      }
3771
+    },
3772
+
3773
+    update: function update(value) {
3774
+      var el = this.el;
3775
+      if (isArray(value)) {
3776
+        el.checked = indexOf(value, this.getValue()) > -1;
3777
+      } else {
3778
+        if (el.hasOwnProperty('_trueValue')) {
3779
+          el.checked = looseEqual(value, el._trueValue);
3780
+        } else {
3781
+          el.checked = !!value;
3782
+        }
3783
+      }
3784
+    }
3785
+  };
3786
+
3787
+  var select = {
3788
+
3789
+    bind: function bind() {
3790
+      var self = this;
3791
+      var el = this.el;
3792
+
3793
+      // method to force update DOM using latest value.
3794
+      this.forceUpdate = function () {
3795
+        if (self._watcher) {
3796
+          self.update(self._watcher.get());
3797
+        }
3798
+      };
3799
+
3800
+      // check if this is a multiple select
3801
+      var multiple = this.multiple = el.hasAttribute('multiple');
3802
+
3803
+      // attach listener
3804
+      this.listener = function () {
3805
+        var value = getValue(el, multiple);
3806
+        value = self.params.number ? isArray(value) ? value.map(toNumber) : toNumber(value) : value;
3807
+        self.set(value);
3808
+      };
3809
+      this.on('change', this.listener);
3810
+
3811
+      // if has initial value, set afterBind
3812
+      var initValue = getValue(el, multiple, true);
3813
+      if (multiple && initValue.length || !multiple && initValue !== null) {
3814
+        this.afterBind = this.listener;
3815
+      }
3816
+
3817
+      // All major browsers except Firefox resets
3818
+      // selectedIndex with value -1 to 0 when the element
3819
+      // is appended to a new parent, therefore we have to
3820
+      // force a DOM update whenever that happens...
3821
+      this.vm.$on('hook:attached', this.forceUpdate);
3822
+    },
3823
+
3824
+    update: function update(value) {
3825
+      var el = this.el;
3826
+      el.selectedIndex = -1;
3827
+      var multi = this.multiple && isArray(value);
3828
+      var options = el.options;
3829
+      var i = options.length;
3830
+      var op, val;
3831
+      while (i--) {
3832
+        op = options[i];
3833
+        val = op.hasOwnProperty('_value') ? op._value : op.value;
3834
+        /* eslint-disable eqeqeq */
3835
+        op.selected = multi ? indexOf$1(value, val) > -1 : looseEqual(value, val);
3836
+        /* eslint-enable eqeqeq */
3837
+      }
3838
+    },
3839
+
3840
+    unbind: function unbind() {
3841
+      /* istanbul ignore next */
3842
+      this.vm.$off('hook:attached', this.forceUpdate);
3843
+    }
3844
+  };
3845
+
3846
+  /**
3847
+   * Get select value
3848
+   *
3849
+   * @param {SelectElement} el
3850
+   * @param {Boolean} multi
3851
+   * @param {Boolean} init
3852
+   * @return {Array|*}
3853
+   */
3854
+
3855
+  function getValue(el, multi, init) {
3856
+    var res = multi ? [] : null;
3857
+    var op, val, selected;
3858
+    for (var i = 0, l = el.options.length; i < l; i++) {
3859
+      op = el.options[i];
3860
+      selected = init ? op.hasAttribute('selected') : op.selected;
3861
+      if (selected) {
3862
+        val = op.hasOwnProperty('_value') ? op._value : op.value;
3863
+        if (multi) {
3864
+          res.push(val);
3865
+        } else {
3866
+          return val;
3867
+        }
3868
+      }
3869
+    }
3870
+    return res;
3871
+  }
3872
+
3873
+  /**
3874
+   * Native Array.indexOf uses strict equal, but in this
3875
+   * case we need to match string/numbers with custom equal.
3876
+   *
3877
+   * @param {Array} arr
3878
+   * @param {*} val
3879
+   */
3880
+
3881
+  function indexOf$1(arr, val) {
3882
+    var i = arr.length;
3883
+    while (i--) {
3884
+      if (looseEqual(arr[i], val)) {
3885
+        return i;
3886
+      }
3887
+    }
3888
+    return -1;
3889
+  }
3890
+
3891
+  var radio = {
3892
+
3893
+    bind: function bind() {
3894
+      var self = this;
3895
+      var el = this.el;
3896
+
3897
+      this.getValue = function () {
3898
+        // value overwrite via v-bind:value
3899
+        if (el.hasOwnProperty('_value')) {
3900
+          return el._value;
3901
+        }
3902
+        var val = el.value;
3903
+        if (self.params.number) {
3904
+          val = toNumber(val);
3905
+        }
3906
+        return val;
3907
+      };
3908
+
3909
+      this.listener = function () {
3910
+        self.set(self.getValue());
3911
+      };
3912
+      this.on('change', this.listener);
3913
+
3914
+      if (el.hasAttribute('checked')) {
3915
+        this.afterBind = this.listener;
3916
+      }
3917
+    },
3918
+
3919
+    update: function update(value) {
3920
+      this.el.checked = looseEqual(value, this.getValue());
3921
+    }
3922
+  };
3923
+
3924
+  var text$2 = {
3925
+
3926
+    bind: function bind() {
3927
+      var self = this;
3928
+      var el = this.el;
3929
+      var isRange = el.type === 'range';
3930
+      var lazy = this.params.lazy;
3931
+      var number = this.params.number;
3932
+      var debounce = this.params.debounce;
3933
+
3934
+      // handle composition events.
3935
+      //   http://blog.evanyou.me/2014/01/03/composition-event/
3936
+      // skip this for Android because it handles composition
3937
+      // events quite differently. Android doesn't trigger
3938
+      // composition events for language input methods e.g.
3939
+      // Chinese, but instead triggers them for spelling
3940
+      // suggestions... (see Discussion/#162)
3941
+      var composing = false;
3942
+      if (!isAndroid && !isRange) {
3943
+        this.on('compositionstart', function () {
3944
+          composing = true;
3945
+        });
3946
+        this.on('compositionend', function () {
3947
+          composing = false;
3948
+          // in IE11 the "compositionend" event fires AFTER
3949
+          // the "input" event, so the input handler is blocked
3950
+          // at the end... have to call it here.
3951
+          //
3952
+          // #1327: in lazy mode this is unecessary.
3953
+          if (!lazy) {
3954
+            self.listener();
3955
+          }
3956
+        });
3957
+      }
3958
+
3959
+      // prevent messing with the input when user is typing,
3960
+      // and force update on blur.
3961
+      this.focused = false;
3962
+      if (!isRange && !lazy) {
3963
+        this.on('focus', function () {
3964
+          self.focused = true;
3965
+        });
3966
+        this.on('blur', function () {
3967
+          self.focused = false;
3968
+          // do not sync value after fragment removal (#2017)
3969
+          if (!self._frag || self._frag.inserted) {
3970
+            self.rawListener();
3971
+          }
3972
+        });
3973
+      }
3974
+
3975
+      // Now attach the main listener
3976
+      this.listener = this.rawListener = function () {
3977
+        if (composing || !self._bound) {
3978
+          return;
3979
+        }
3980
+        var val = number || isRange ? toNumber(el.value) : el.value;
3981
+        self.set(val);
3982
+        // force update on next tick to avoid lock & same value
3983
+        // also only update when user is not typing
3984
+        nextTick(function () {
3985
+          if (self._bound && !self.focused) {
3986
+            self.update(self._watcher.value);
3987
+          }
3988
+        });
3989
+      };
3990
+
3991
+      // apply debounce
3992
+      if (debounce) {
3993
+        this.listener = _debounce(this.listener, debounce);
3994
+      }
3995
+
3996
+      // Support jQuery events, since jQuery.trigger() doesn't
3997
+      // trigger native events in some cases and some plugins
3998
+      // rely on $.trigger()
3999
+      //
4000
+      // We want to make sure if a listener is attached using
4001
+      // jQuery, it is also removed with jQuery, that's why
4002
+      // we do the check for each directive instance and
4003
+      // store that check result on itself. This also allows
4004
+      // easier test coverage control by unsetting the global
4005
+      // jQuery variable in tests.
4006
+      this.hasjQuery = typeof jQuery === 'function';
4007
+      if (this.hasjQuery) {
4008
+        jQuery(el).on('change', this.listener);
4009
+        if (!lazy) {
4010
+          jQuery(el).on('input', this.listener);
4011
+        }
4012
+      } else {
4013
+        this.on('change', this.listener);
4014
+        if (!lazy) {
4015
+          this.on('input', this.listener);
4016
+        }
4017
+      }
4018
+
4019
+      // IE9 doesn't fire input event on backspace/del/cut
4020
+      if (!lazy && isIE9) {
4021
+        this.on('cut', function () {
4022
+          nextTick(self.listener);
4023
+        });
4024
+        this.on('keyup', function (e) {
4025
+          if (e.keyCode === 46 || e.keyCode === 8) {
4026
+            self.listener();
4027
+          }
4028
+        });
4029
+      }
4030
+
4031
+      // set initial value if present
4032
+      if (el.hasAttribute('value') || el.tagName === 'TEXTAREA' && el.value.trim()) {
4033
+        this.afterBind = this.listener;
4034
+      }
4035
+    },
4036
+
4037
+    update: function update(value) {
4038
+      this.el.value = _toString(value);
4039
+    },
4040
+
4041
+    unbind: function unbind() {
4042
+      var el = this.el;
4043
+      if (this.hasjQuery) {
4044
+        jQuery(el).off('change', this.listener);
4045
+        jQuery(el).off('input', this.listener);
4046
+      }
4047
+    }
4048
+  };
4049
+
4050
+  var handlers = {
4051
+    text: text$2,
4052
+    radio: radio,
4053
+    select: select,
4054
+    checkbox: checkbox
4055
+  };
4056
+
4057
+  var model = {
4058
+
4059
+    priority: MODEL,
4060
+    twoWay: true,
4061
+    handlers: handlers,
4062
+    params: ['lazy', 'number', 'debounce'],
4063
+
4064
+    /**
4065
+     * Possible elements:
4066
+     *   <select>
4067
+     *   <textarea>
4068
+     *   <input type="*">
4069
+     *     - text
4070
+     *     - checkbox
4071
+     *     - radio
4072
+     *     - number
4073
+     */
4074
+
4075
+    bind: function bind() {
4076
+      // friendly warning...
4077
+      this.checkFilters();
4078
+      if (this.hasRead && !this.hasWrite) {
4079
+        'development' !== 'production' && warn('It seems you are using a read-only filter with ' + 'v-model. You might want to use a two-way filter ' + 'to ensure correct behavior.');
4080
+      }
4081
+      var el = this.el;
4082
+      var tag = el.tagName;
4083
+      var handler;
4084
+      if (tag === 'INPUT') {
4085
+        handler = handlers[el.type] || handlers.text;
4086
+      } else if (tag === 'SELECT') {
4087
+        handler = handlers.select;
4088
+      } else if (tag === 'TEXTAREA') {
4089
+        handler = handlers.text;
4090
+      } else {
4091
+        'development' !== 'production' && warn('v-model does not support element type: ' + tag);
4092
+        return;
4093
+      }
4094
+      el.__v_model = this;
4095
+      handler.bind.call(this);
4096
+      this.update = handler.update;
4097
+      this._unbind = handler.unbind;
4098
+    },
4099
+
4100
+    /**
4101
+     * Check read/write filter stats.
4102
+     */
4103
+
4104
+    checkFilters: function checkFilters() {
4105
+      var filters = this.filters;
4106
+      if (!filters) return;
4107
+      var i = filters.length;
4108
+      while (i--) {
4109
+        var filter = resolveAsset(this.vm.$options, 'filters', filters[i].name);
4110
+        if (typeof filter === 'function' || filter.read) {
4111
+          this.hasRead = true;
4112
+        }
4113
+        if (filter.write) {
4114
+          this.hasWrite = true;
4115
+        }
4116
+      }
4117
+    },
4118
+
4119
+    unbind: function unbind() {
4120
+      this.el.__v_model = null;
4121
+      this._unbind && this._unbind();
4122
+    }
4123
+  };
4124
+
4125
+  var show = {
4126
+
4127
+    bind: function bind() {
4128
+      // check else block
4129
+      var next = this.el.nextElementSibling;
4130
+      if (next && getAttr(next, 'v-else') !== null) {
4131
+        this.elseEl = next;
4132
+      }
4133
+    },
4134
+
4135
+    update: function update(value) {
4136
+      this.apply(this.el, value);
4137
+      if (this.elseEl) {
4138
+        this.apply(this.elseEl, !value);
4139
+      }
4140
+    },
4141
+
4142
+    apply: function apply(el, value) {
4143
+      if (inDoc(el)) {
4144
+        applyTransition(el, value ? 1 : -1, toggle, this.vm);
4145
+      } else {
4146
+        toggle();
4147
+      }
4148
+      function toggle() {
4149
+        el.style.display = value ? '' : 'none';
4150
+      }
4151
+    }
4152
+  };
4153
+
4154
+  var templateCache = new Cache(1000);
4155
+  var idSelectorCache = new Cache(1000);
4156
+
4157
+  var map = {
4158
+    efault: [0, '', ''],
4159
+    legend: [1, '<fieldset>', '</fieldset>'],
4160
+    tr: [2, '<table><tbody>', '</tbody></table>'],
4161
+    col: [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>']
4162
+  };
4163
+
4164
+  map.td = map.th = [3, '<table><tbody><tr>', '</tr></tbody></table>'];
4165
+
4166
+  map.option = map.optgroup = [1, '<select multiple="multiple">', '</select>'];
4167
+
4168
+  map.thead = map.tbody = map.colgroup = map.caption = map.tfoot = [1, '<table>', '</table>'];
4169
+
4170
+  map.g = map.defs = map.symbol = map.use = map.image = map.text = map.circle = map.ellipse = map.line = map.path = map.polygon = map.polyline = map.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>'];
4171
+
4172
+  /**
4173
+   * Check if a node is a supported template node with a
4174
+   * DocumentFragment content.
4175
+   *
4176
+   * @param {Node} node
4177
+   * @return {Boolean}
4178
+   */
4179
+
4180
+  function isRealTemplate(node) {
4181
+    return isTemplate(node) && node.content instanceof DocumentFragment;
4182
+  }
4183
+
4184
+  var tagRE$1 = /<([\w:]+)/;
4185
+  var entityRE = /&#?\w+?;/;
4186
+
4187
+  /**
4188
+   * Convert a string template to a DocumentFragment.
4189
+   * Determines correct wrapping by tag types. Wrapping
4190
+   * strategy found in jQuery & component/domify.
4191
+   *
4192
+   * @param {String} templateString
4193
+   * @param {Boolean} raw
4194
+   * @return {DocumentFragment}
4195
+   */
4196
+
4197
+  function stringToFragment(templateString, raw) {
4198
+    // try a cache hit first
4199
+    var hit = templateCache.get(templateString);
4200
+    if (hit) {
4201
+      return hit;
4202
+    }
4203
+
4204
+    var frag = document.createDocumentFragment();
4205
+    var tagMatch = templateString.match(tagRE$1);
4206
+    var entityMatch = entityRE.test(templateString);
4207
+
4208
+    if (!tagMatch && !entityMatch) {
4209
+      // text only, return a single text node.
4210
+      frag.appendChild(document.createTextNode(templateString));
4211
+    } else {
4212
+
4213
+      var tag = tagMatch && tagMatch[1];
4214
+      var wrap = map[tag] || map.efault;
4215
+      var depth = wrap[0];
4216
+      var prefix = wrap[1];
4217
+      var suffix = wrap[2];
4218
+      var node = document.createElement('div');
4219
+
4220
+      var templateStringToUse = raw ? templateString : templateString.trim();
4221
+      node.innerHTML = prefix + templateStringToUse + suffix;
4222
+      while (depth--) {
4223
+        node = node.lastChild;
4224
+      }
4225
+
4226
+      var child;
4227
+      /* eslint-disable no-cond-assign */
4228
+      while (child = node.firstChild) {
4229
+        /* eslint-enable no-cond-assign */
4230
+        frag.appendChild(child);
4231
+      }
4232
+    }
4233
+
4234
+    templateCache.put(templateString, frag);
4235
+    return frag;
4236
+  }
4237
+
4238
+  /**
4239
+   * Convert a template node to a DocumentFragment.
4240
+   *
4241
+   * @param {Node} node
4242
+   * @return {DocumentFragment}
4243
+   */
4244
+
4245
+  function nodeToFragment(node) {
4246
+    // if its a template tag and the browser supports it,
4247
+    // its content is already a document fragment.
4248
+    if (isRealTemplate(node)) {
4249
+      trimNode(node.content);
4250
+      return node.content;
4251
+    }
4252
+    // script template
4253
+    if (node.tagName === 'SCRIPT') {
4254
+      return stringToFragment(node.textContent);
4255
+    }
4256
+    // normal node, clone it to avoid mutating the original
4257
+    var clonedNode = cloneNode(node);
4258
+    var frag = document.createDocumentFragment();
4259
+    var child;
4260
+    /* eslint-disable no-cond-assign */
4261
+    while (child = clonedNode.firstChild) {
4262
+      /* eslint-enable no-cond-assign */
4263
+      frag.appendChild(child);
4264
+    }
4265
+    trimNode(frag);
4266
+    return frag;
4267
+  }
4268
+
4269
+  // Test for the presence of the Safari template cloning bug
4270
+  // https://bugs.webkit.org/showug.cgi?id=137755
4271
+  var hasBrokenTemplate = (function () {
4272
+    /* istanbul ignore else */
4273
+    if (inBrowser) {
4274
+      var a = document.createElement('div');
4275
+      a.innerHTML = '<template>1</template>';
4276
+      return !a.cloneNode(true).firstChild.innerHTML;
4277
+    } else {
4278
+      return false;
4279
+    }
4280
+  })();
4281
+
4282
+  // Test for IE10/11 textarea placeholder clone bug
4283
+  var hasTextareaCloneBug = (function () {
4284
+    /* istanbul ignore else */
4285
+    if (inBrowser) {
4286
+      var t = document.createElement('textarea');
4287
+      t.placeholder = 't';
4288
+      return t.cloneNode(true).value === 't';
4289
+    } else {
4290
+      return false;
4291
+    }
4292
+  })();
4293
+
4294
+  /**
4295
+   * 1. Deal with Safari cloning nested <template> bug by
4296
+   *    manually cloning all template instances.
4297
+   * 2. Deal with IE10/11 textarea placeholder bug by setting
4298
+   *    the correct value after cloning.
4299
+   *
4300
+   * @param {Element|DocumentFragment} node
4301
+   * @return {Element|DocumentFragment}
4302
+   */
4303
+
4304
+  function cloneNode(node) {
4305
+    if (!node.querySelectorAll) {
4306
+      return node.cloneNode();
4307
+    }
4308
+    var res = node.cloneNode(true);
4309
+    var i, original, cloned;
4310
+    /* istanbul ignore if */
4311
+    if (hasBrokenTemplate) {
4312
+      var tempClone = res;
4313
+      if (isRealTemplate(node)) {
4314
+        node = node.content;
4315
+        tempClone = res.content;
4316
+      }
4317
+      original = node.querySelectorAll('template');
4318
+      if (original.length) {
4319
+        cloned = tempClone.querySelectorAll('template');
4320
+        i = cloned.length;
4321
+        while (i--) {
4322
+          cloned[i].parentNode.replaceChild(cloneNode(original[i]), cloned[i]);
4323
+        }
4324
+      }
4325
+    }
4326
+    /* istanbul ignore if */
4327
+    if (hasTextareaCloneBug) {
4328
+      if (node.tagName === 'TEXTAREA') {
4329
+        res.value = node.value;
4330
+      } else {
4331
+        original = node.querySelectorAll('textarea');
4332
+        if (original.length) {
4333
+          cloned = res.querySelectorAll('textarea');
4334
+          i = cloned.length;
4335
+          while (i--) {
4336
+            cloned[i].value = original[i].value;
4337
+          }
4338
+        }
4339
+      }
4340
+    }
4341
+    return res;
4342
+  }
4343
+
4344
+  /**
4345
+   * Process the template option and normalizes it into a
4346
+   * a DocumentFragment that can be used as a partial or a
4347
+   * instance template.
4348
+   *
4349
+   * @param {*} template
4350
+   *        Possible values include:
4351
+   *        - DocumentFragment object
4352
+   *        - Node object of type Template
4353
+   *        - id selector: '#some-template-id'
4354
+   *        - template string: '<div><span>{{msg}}</span></div>'
4355
+   * @param {Boolean} shouldClone
4356
+   * @param {Boolean} raw
4357
+   *        inline HTML interpolation. Do not check for id
4358
+   *        selector and keep whitespace in the string.
4359
+   * @return {DocumentFragment|undefined}
4360
+   */
4361
+
4362
+  function parseTemplate(template, shouldClone, raw) {
4363
+    var node, frag;
4364
+
4365
+    // if the template is already a document fragment,
4366
+    // do nothing
4367
+    if (template instanceof DocumentFragment) {
4368
+      trimNode(template);
4369
+      return shouldClone ? cloneNode(template) : template;
4370
+    }
4371
+
4372
+    if (typeof template === 'string') {
4373
+      // id selector
4374
+      if (!raw && template.charAt(0) === '#') {
4375
+        // id selector can be cached too
4376
+        frag = idSelectorCache.get(template);
4377
+        if (!frag) {
4378
+          node = document.getElementById(template.slice(1));
4379
+          if (node) {
4380
+            frag = nodeToFragment(node);
4381
+            // save selector to cache
4382
+            idSelectorCache.put(template, frag);
4383
+          }
4384
+        }
4385
+      } else {
4386
+        // normal string template
4387
+        frag = stringToFragment(template, raw);
4388
+      }
4389
+    } else if (template.nodeType) {
4390
+      // a direct node
4391
+      frag = nodeToFragment(template);
4392
+    }
4393
+
4394
+    return frag && shouldClone ? cloneNode(frag) : frag;
4395
+  }
4396
+
4397
+  var template = Object.freeze({
4398
+    cloneNode: cloneNode,
4399
+    parseTemplate: parseTemplate
4400
+  });
4401
+
4402
+  /**
4403
+   * Abstraction for a partially-compiled fragment.
4404
+   * Can optionally compile content with a child scope.
4405
+   *
4406
+   * @param {Function} linker
4407
+   * @param {Vue} vm
4408
+   * @param {DocumentFragment} frag
4409
+   * @param {Vue} [host]
4410
+   * @param {Object} [scope]
4411
+   */
4412
+  function Fragment(linker, vm, frag, host, scope, parentFrag) {
4413
+    this.children = [];
4414
+    this.childFrags = [];
4415
+    this.vm = vm;
4416
+    this.scope = scope;
4417
+    this.inserted = false;
4418
+    this.parentFrag = parentFrag;
4419
+    if (parentFrag) {
4420
+      parentFrag.childFrags.push(this);
4421
+    }
4422
+    this.unlink = linker(vm, frag, host, scope, this);
4423
+    var single = this.single = frag.childNodes.length === 1 &&
4424
+    // do not go single mode if the only node is an anchor
4425
+    !frag.childNodes[0].__vue_anchor;
4426
+    if (single) {
4427
+      this.node = frag.childNodes[0];
4428
+      this.before = singleBefore;
4429
+      this.remove = singleRemove;
4430
+    } else {
4431
+      this.node = createAnchor('fragment-start');
4432
+      this.end = createAnchor('fragment-end');
4433
+      this.frag = frag;
4434
+      prepend(this.node, frag);
4435
+      frag.appendChild(this.end);
4436
+      this.before = multiBefore;
4437
+      this.remove = multiRemove;
4438
+    }
4439
+    this.node.__vfrag__ = this;
4440
+  }
4441
+
4442
+  /**
4443
+   * Call attach/detach for all components contained within
4444
+   * this fragment. Also do so recursively for all child
4445
+   * fragments.
4446
+   *
4447
+   * @param {Function} hook
4448
+   */
4449
+
4450
+  Fragment.prototype.callHook = function (hook) {
4451
+    var i, l;
4452
+    for (i = 0, l = this.childFrags.length; i < l; i++) {
4453
+      this.childFrags[i].callHook(hook);
4454
+    }
4455
+    for (i = 0, l = this.children.length; i < l; i++) {
4456
+      hook(this.children[i]);
4457
+    }
4458
+  };
4459
+
4460
+  /**
4461
+   * Insert fragment before target, single node version
4462
+   *
4463
+   * @param {Node} target
4464
+   * @param {Boolean} withTransition
4465
+   */
4466
+
4467
+  function singleBefore(target, withTransition) {
4468
+    this.inserted = true;
4469
+    var method = withTransition !== false ? beforeWithTransition : before;
4470
+    method(this.node, target, this.vm);
4471
+    if (inDoc(this.node)) {
4472
+      this.callHook(attach);
4473
+    }
4474
+  }
4475
+
4476
+  /**
4477
+   * Remove fragment, single node version
4478
+   */
4479
+
4480
+  function singleRemove() {
4481
+    this.inserted = false;
4482
+    var shouldCallRemove = inDoc(this.node);
4483
+    var self = this;
4484
+    this.beforeRemove();
4485
+    removeWithTransition(this.node, this.vm, function () {
4486
+      if (shouldCallRemove) {
4487
+        self.callHook(detach);
4488
+      }
4489
+      self.destroy();
4490
+    });
4491
+  }
4492
+
4493
+  /**
4494
+   * Insert fragment before target, multi-nodes version
4495
+   *
4496
+   * @param {Node} target
4497
+   * @param {Boolean} withTransition
4498
+   */
4499
+
4500
+  function multiBefore(target, withTransition) {
4501
+    this.inserted = true;
4502
+    var vm = this.vm;
4503
+    var method = withTransition !== false ? beforeWithTransition : before;
4504
+    mapNodeRange(this.node, this.end, function (node) {
4505
+      method(node, target, vm);
4506
+    });
4507
+    if (inDoc(this.node)) {
4508
+      this.callHook(attach);
4509
+    }
4510
+  }
4511
+
4512
+  /**
4513
+   * Remove fragment, multi-nodes version
4514
+   */
4515
+
4516
+  function multiRemove() {
4517
+    this.inserted = false;
4518
+    var self = this;
4519
+    var shouldCallRemove = inDoc(this.node);
4520
+    this.beforeRemove();
4521
+    removeNodeRange(this.node, this.end, this.vm, this.frag, function () {
4522
+      if (shouldCallRemove) {
4523
+        self.callHook(detach);
4524
+      }
4525
+      self.destroy();
4526
+    });
4527
+  }
4528
+
4529
+  /**
4530
+   * Prepare the fragment for removal.
4531
+   */
4532
+
4533
+  Fragment.prototype.beforeRemove = function () {
4534
+    var i, l;
4535
+    for (i = 0, l = this.childFrags.length; i < l; i++) {
4536
+      // call the same method recursively on child
4537
+      // fragments, depth-first
4538
+      this.childFrags[i].beforeRemove(false);
4539
+    }
4540
+    for (i = 0, l = this.children.length; i < l; i++) {
4541
+      // Call destroy for all contained instances,
4542
+      // with remove:false and defer:true.
4543
+      // Defer is necessary because we need to
4544
+      // keep the children to call detach hooks
4545
+      // on them.
4546
+      this.children[i].$destroy(false, true);
4547
+    }
4548
+    var dirs = this.unlink.dirs;
4549
+    for (i = 0, l = dirs.length; i < l; i++) {
4550
+      // disable the watchers on all the directives
4551
+      // so that the rendered content stays the same
4552
+      // during removal.
4553
+      dirs[i]._watcher && dirs[i]._watcher.teardown();
4554
+    }
4555
+  };
4556
+
4557
+  /**
4558
+   * Destroy the fragment.
4559
+   */
4560
+
4561
+  Fragment.prototype.destroy = function () {
4562
+    if (this.parentFrag) {
4563
+      this.parentFrag.childFrags.$remove(this);
4564
+    }
4565
+    this.node.__vfrag__ = null;
4566
+    this.unlink();
4567
+  };
4568
+
4569
+  /**
4570
+   * Call attach hook for a Vue instance.
4571
+   *
4572
+   * @param {Vue} child
4573
+   */
4574
+
4575
+  function attach(child) {
4576
+    if (!child._isAttached) {
4577
+      child._callHook('attached');
4578
+    }
4579
+  }
4580
+
4581
+  /**
4582
+   * Call detach hook for a Vue instance.
4583
+   *
4584
+   * @param {Vue} child
4585
+   */
4586
+
4587
+  function detach(child) {
4588
+    if (child._isAttached) {
4589
+      child._callHook('detached');
4590
+    }
4591
+  }
4592
+
4593
+  var linkerCache = new Cache(5000);
4594
+
4595
+  /**
4596
+   * A factory that can be used to create instances of a
4597
+   * fragment. Caches the compiled linker if possible.
4598
+   *
4599
+   * @param {Vue} vm
4600
+   * @param {Element|String} el
4601
+   */
4602
+  function FragmentFactory(vm, el) {
4603
+    this.vm = vm;
4604
+    var template;
4605
+    var isString = typeof el === 'string';
4606
+    if (isString || isTemplate(el)) {
4607
+      template = parseTemplate(el, true);
4608
+    } else {
4609
+      template = document.createDocumentFragment();
4610
+      template.appendChild(el);
4611
+    }
4612
+    this.template = template;
4613
+    // linker can be cached, but only for components
4614
+    var linker;
4615
+    var cid = vm.constructor.cid;
4616
+    if (cid > 0) {
4617
+      var cacheId = cid + (isString ? el : el.outerHTML);
4618
+      linker = linkerCache.get(cacheId);
4619
+      if (!linker) {
4620
+        linker = compile(template, vm.$options, true);
4621
+        linkerCache.put(cacheId, linker);
4622
+      }
4623
+    } else {
4624
+      linker = compile(template, vm.$options, true);
4625
+    }
4626
+    this.linker = linker;
4627
+  }
4628
+
4629
+  /**
4630
+   * Create a fragment instance with given host and scope.
4631
+   *
4632
+   * @param {Vue} host
4633
+   * @param {Object} scope
4634
+   * @param {Fragment} parentFrag
4635
+   */
4636
+
4637
+  FragmentFactory.prototype.create = function (host, scope, parentFrag) {
4638
+    var frag = cloneNode(this.template);
4639
+    return new Fragment(this.linker, this.vm, frag, host, scope, parentFrag);
4640
+  };
4641
+
4642
+  var vIf = {
4643
+
4644
+    priority: IF,
4645
+
4646
+    bind: function bind() {
4647
+      var el = this.el;
4648
+      if (!el.__vue__) {
4649
+        // check else block
4650
+        var next = el.nextElementSibling;
4651
+        if (next && getAttr(next, 'v-else') !== null) {
4652
+          remove(next);
4653
+          this.elseFactory = new FragmentFactory(this.vm, next);
4654
+        }
4655
+        // check main block
4656
+        this.anchor = createAnchor('v-if');
4657
+        replace(el, this.anchor);
4658
+        this.factory = new FragmentFactory(this.vm, el);
4659
+      } else {
4660
+        'development' !== 'production' && warn('v-if="' + this.expression + '" cannot be ' + 'used on an instance root element.');
4661
+        this.invalid = true;
4662
+      }
4663
+    },
4664
+
4665
+    update: function update(value) {
4666
+      if (this.invalid) return;
4667
+      if (value) {
4668
+        if (!this.frag) {
4669
+          this.insert();
4670
+        }
4671
+      } else {
4672
+        this.remove();
4673
+      }
4674
+    },
4675
+
4676
+    insert: function insert() {
4677
+      if (this.elseFrag) {
4678
+        this.elseFrag.remove();
4679
+        this.elseFrag = null;
4680
+      }
4681
+      this.frag = this.factory.create(this._host, this._scope, this._frag);
4682
+      this.frag.before(this.anchor);
4683
+    },
4684
+
4685
+    remove: function remove() {
4686
+      if (this.frag) {
4687
+        this.frag.remove();
4688
+        this.frag = null;
4689
+      }
4690
+      if (this.elseFactory && !this.elseFrag) {
4691
+        this.elseFrag = this.elseFactory.create(this._host, this._scope, this._frag);
4692
+        this.elseFrag.before(this.anchor);
4693
+      }
4694
+    },
4695
+
4696
+    unbind: function unbind() {
4697
+      if (this.frag) {
4698
+        this.frag.destroy();
4699
+      }
4700
+    }
4701
+  };
4702
+
4703
+  var uid$1 = 0;
4704
+
4705
+  var vFor = {
4706
+
4707
+    priority: FOR,
4708
+
4709
+    params: ['track-by', 'stagger', 'enter-stagger', 'leave-stagger'],
4710
+
4711
+    bind: function bind() {
4712
+      // support "item in items" syntax
4713
+      var inMatch = this.expression.match(/(.*) in (.*)/);
4714
+      if (inMatch) {
4715
+        var itMatch = inMatch[1].match(/\((.*),(.*)\)/);
4716
+        if (itMatch) {
4717
+          this.iterator = itMatch[1].trim();
4718
+          this.alias = itMatch[2].trim();
4719
+        } else {
4720
+          this.alias = inMatch[1].trim();
4721
+        }
4722
+        this.expression = inMatch[2];
4723
+      }
4724
+
4725
+      if (!this.alias) {
4726
+        'development' !== 'production' && warn('Alias is required in v-for.');
4727
+        return;
4728
+      }
4729
+
4730
+      // uid as a cache identifier
4731
+      this.id = '__v-for__' + ++uid$1;
4732
+
4733
+      // check if this is an option list,
4734
+      // so that we know if we need to update the <select>'s
4735
+      // v-model when the option list has changed.
4736
+      // because v-model has a lower priority than v-for,
4737
+      // the v-model is not bound here yet, so we have to
4738
+      // retrive it in the actual updateModel() function.
4739
+      var tag = this.el.tagName;
4740
+      this.isOption = (tag === 'OPTION' || tag === 'OPTGROUP') && this.el.parentNode.tagName === 'SELECT';
4741
+
4742
+      // setup anchor nodes
4743
+      this.start = createAnchor('v-for-start');
4744
+      this.end = createAnchor('v-for-end');
4745
+      replace(this.el, this.end);
4746
+      before(this.start, this.end);
4747
+
4748
+      // cache
4749
+      this.cache = Object.create(null);
4750
+
4751
+      // fragment factory
4752
+      this.factory = new FragmentFactory(this.vm, this.el);
4753
+    },
4754
+
4755
+    update: function update(data) {
4756
+      this.diff(data);
4757
+      this.updateRef();
4758
+      this.updateModel();
4759
+    },
4760
+
4761
+    /**
4762
+     * Diff, based on new data and old data, determine the
4763
+     * minimum amount of DOM manipulations needed to make the
4764
+     * DOM reflect the new data Array.
4765
+     *
4766
+     * The algorithm diffs the new data Array by storing a
4767
+     * hidden reference to an owner vm instance on previously
4768
+     * seen data. This allows us to achieve O(n) which is
4769
+     * better than a levenshtein distance based algorithm,
4770
+     * which is O(m * n).
4771
+     *
4772
+     * @param {Array} data
4773
+     */
4774
+
4775
+    diff: function diff(data) {
4776
+      // check if the Array was converted from an Object
4777
+      var item = data[0];
4778
+      var convertedFromObject = this.fromObject = isObject(item) && hasOwn(item, '$key') && hasOwn(item, '$value');
4779
+
4780
+      var trackByKey = this.params.trackBy;
4781
+      var oldFrags = this.frags;
4782
+      var frags = this.frags = new Array(data.length);
4783
+      var alias = this.alias;
4784
+      var iterator = this.iterator;
4785
+      var start = this.start;
4786
+      var end = this.end;
4787
+      var inDocument = inDoc(start);
4788
+      var init = !oldFrags;
4789
+      var i, l, frag, key, value, primitive;
4790
+
4791
+      // First pass, go through the new Array and fill up
4792
+      // the new frags array. If a piece of data has a cached
4793
+      // instance for it, we reuse it. Otherwise build a new
4794
+      // instance.
4795
+      for (i = 0, l = data.length; i < l; i++) {
4796
+        item = data[i];
4797
+        key = convertedFromObject ? item.$key : null;
4798
+        value = convertedFromObject ? item.$value : item;
4799
+        primitive = !isObject(value);
4800
+        frag = !init && this.getCachedFrag(value, i, key);
4801
+        if (frag) {
4802
+          // reusable fragment
4803
+          frag.reused = true;
4804
+          // update $index
4805
+          frag.scope.$index = i;
4806
+          // update $key
4807
+          if (key) {
4808
+            frag.scope.$key = key;
4809
+          }
4810
+          // update iterator
4811
+          if (iterator) {
4812
+            frag.scope[iterator] = key !== null ? key : i;
4813
+          }
4814
+          // update data for track-by, object repeat &
4815
+          // primitive values.
4816
+          if (trackByKey || convertedFromObject || primitive) {
4817
+            frag.scope[alias] = value;
4818
+          }
4819
+        } else {
4820
+          // new isntance
4821
+          frag = this.create(value, alias, i, key);
4822
+          frag.fresh = !init;
4823
+        }
4824
+        frags[i] = frag;
4825
+        if (init) {
4826
+          frag.before(end);
4827
+        }
4828
+      }
4829
+
4830
+      // we're done for the initial render.
4831
+      if (init) {
4832
+        return;
4833
+      }
4834
+
4835
+      // Second pass, go through the old fragments and
4836
+      // destroy those who are not reused (and remove them
4837
+      // from cache)
4838
+      var removalIndex = 0;
4839
+      var totalRemoved = oldFrags.length - frags.length;
4840
+      for (i = 0, l = oldFrags.length; i < l; i++) {
4841
+        frag = oldFrags[i];
4842
+        if (!frag.reused) {
4843
+          this.deleteCachedFrag(frag);
4844
+          this.remove(frag, removalIndex++, totalRemoved, inDocument);
4845
+        }
4846
+      }
4847
+
4848
+      // Final pass, move/insert new fragments into the
4849
+      // right place.
4850
+      var targetPrev, prevEl, currentPrev;
4851
+      var insertionIndex = 0;
4852
+      for (i = 0, l = frags.length; i < l; i++) {
4853
+        frag = frags[i];
4854
+        // this is the frag that we should be after
4855
+        targetPrev = frags[i - 1];
4856
+        prevEl = targetPrev ? targetPrev.staggerCb ? targetPrev.staggerAnchor : targetPrev.end || targetPrev.node : start;
4857
+        if (frag.reused && !frag.staggerCb) {
4858
+          currentPrev = findPrevFrag(frag, start, this.id);
4859
+          if (currentPrev !== targetPrev && (!currentPrev ||
4860
+          // optimization for moving a single item.
4861
+          // thanks to suggestions by @livoras in #1807
4862
+          findPrevFrag(currentPrev, start, this.id) !== targetPrev)) {
4863
+            this.move(frag, prevEl);
4864
+          }
4865
+        } else {
4866
+          // new instance, or still in stagger.
4867
+          // insert with updated stagger index.
4868
+          this.insert(frag, insertionIndex++, prevEl, inDocument);
4869
+        }
4870
+        frag.reused = frag.fresh = false;
4871
+      }
4872
+    },
4873
+
4874
+    /**
4875
+     * Create a new fragment instance.
4876
+     *
4877
+     * @param {*} value
4878
+     * @param {String} alias
4879
+     * @param {Number} index
4880
+     * @param {String} [key]
4881
+     * @return {Fragment}
4882
+     */
4883
+
4884
+    create: function create(value, alias, index, key) {
4885
+      var host = this._host;
4886
+      // create iteration scope
4887
+      var parentScope = this._scope || this.vm;
4888
+      var scope = Object.create(parentScope);
4889
+      // ref holder for the scope
4890
+      scope.$refs = Object.create(parentScope.$refs);
4891
+      scope.$els = Object.create(parentScope.$els);
4892
+      // make sure point $parent to parent scope
4893
+      scope.$parent = parentScope;
4894
+      // for two-way binding on alias
4895
+      scope.$forContext = this;
4896
+      // define scope properties
4897
+      defineReactive(scope, alias, value);
4898
+      defineReactive(scope, '$index', index);
4899
+      if (key) {
4900
+        defineReactive(scope, '$key', key);
4901
+      } else if (scope.$key) {
4902
+        // avoid accidental fallback
4903
+        def(scope, '$key', null);
4904
+      }
4905
+      if (this.iterator) {
4906
+        defineReactive(scope, this.iterator, key !== null ? key : index);
4907
+      }
4908
+      var frag = this.factory.create(host, scope, this._frag);
4909
+      frag.forId = this.id;
4910
+      this.cacheFrag(value, frag, index, key);
4911
+      return frag;
4912
+    },
4913
+
4914
+    /**
4915
+     * Update the v-ref on owner vm.
4916
+     */
4917
+
4918
+    updateRef: function updateRef() {
4919
+      var ref = this.descriptor.ref;
4920
+      if (!ref) return;
4921
+      var hash = (this._scope || this.vm).$refs;
4922
+      var refs;
4923
+      if (!this.fromObject) {
4924
+        refs = this.frags.map(findVmFromFrag);
4925
+      } else {
4926
+        refs = {};
4927
+        this.frags.forEach(function (frag) {
4928
+          refs[frag.scope.$key] = findVmFromFrag(frag);
4929
+        });
4930
+      }
4931
+      hash[ref] = refs;
4932
+    },
4933
+
4934
+    /**
4935
+     * For option lists, update the containing v-model on
4936
+     * parent <select>.
4937
+     */
4938
+
4939
+    updateModel: function updateModel() {
4940
+      if (this.isOption) {
4941
+        var parent = this.start.parentNode;
4942
+        var model = parent && parent.__v_model;
4943
+        if (model) {
4944
+          model.forceUpdate();
4945
+        }
4946
+      }
4947
+    },
4948
+
4949
+    /**
4950
+     * Insert a fragment. Handles staggering.
4951
+     *
4952
+     * @param {Fragment} frag
4953
+     * @param {Number} index
4954
+     * @param {Node} prevEl
4955
+     * @param {Boolean} inDocument
4956
+     */
4957
+
4958
+    insert: function insert(frag, index, prevEl, inDocument) {
4959
+      if (frag.staggerCb) {
4960
+        frag.staggerCb.cancel();
4961
+        frag.staggerCb = null;
4962
+      }
4963
+      var staggerAmount = this.getStagger(frag, index, null, 'enter');
4964
+      if (inDocument && staggerAmount) {
4965
+        // create an anchor and insert it synchronously,
4966
+        // so that we can resolve the correct order without
4967
+        // worrying about some elements not inserted yet
4968
+        var anchor = frag.staggerAnchor;
4969
+        if (!anchor) {
4970
+          anchor = frag.staggerAnchor = createAnchor('stagger-anchor');
4971
+          anchor.__vfrag__ = frag;
4972
+        }
4973
+        after(anchor, prevEl);
4974
+        var op = frag.staggerCb = cancellable(function () {
4975
+          frag.staggerCb = null;
4976
+          frag.before(anchor);
4977
+          remove(anchor);
4978
+        });
4979
+        setTimeout(op, staggerAmount);
4980
+      } else {
4981
+        frag.before(prevEl.nextSibling);
4982
+      }
4983
+    },
4984
+
4985
+    /**
4986
+     * Remove a fragment. Handles staggering.
4987
+     *
4988
+     * @param {Fragment} frag
4989
+     * @param {Number} index
4990
+     * @param {Number} total
4991
+     * @param {Boolean} inDocument
4992
+     */
4993
+
4994
+    remove: function remove(frag, index, total, inDocument) {
4995
+      if (frag.staggerCb) {
4996
+        frag.staggerCb.cancel();
4997
+        frag.staggerCb = null;
4998
+        // it's not possible for the same frag to be removed
4999
+        // twice, so if we have a pending stagger callback,
5000
+        // it means this frag is queued for enter but removed
5001
+        // before its transition started. Since it is already
5002
+        // destroyed, we can just leave it in detached state.
5003
+        return;
5004
+      }
5005
+      var staggerAmount = this.getStagger(frag, index, total, 'leave');
5006
+      if (inDocument && staggerAmount) {
5007
+        var op = frag.staggerCb = cancellable(function () {
5008
+          frag.staggerCb = null;
5009
+          frag.remove();
5010
+        });
5011
+        setTimeout(op, staggerAmount);
5012
+      } else {
5013
+        frag.remove();
5014
+      }
5015
+    },
5016
+
5017
+    /**
5018
+     * Move a fragment to a new position.
5019
+     * Force no transition.
5020
+     *
5021
+     * @param {Fragment} frag
5022
+     * @param {Node} prevEl
5023
+     */
5024
+
5025
+    move: function move(frag, prevEl) {
5026
+      // fix a common issue with Sortable:
5027
+      // if prevEl doesn't have nextSibling, this means it's
5028
+      // been dragged after the end anchor. Just re-position
5029
+      // the end anchor to the end of the container.
5030
+      /* istanbul ignore if */
5031
+      if (!prevEl.nextSibling) {
5032
+        this.end.parentNode.appendChild(this.end);
5033
+      }
5034
+      frag.before(prevEl.nextSibling, false);
5035
+    },
5036
+
5037
+    /**
5038
+     * Cache a fragment using track-by or the object key.
5039
+     *
5040
+     * @param {*} value
5041
+     * @param {Fragment} frag
5042
+     * @param {Number} index
5043
+     * @param {String} [key]
5044
+     */
5045
+
5046
+    cacheFrag: function cacheFrag(value, frag, index, key) {
5047
+      var trackByKey = this.params.trackBy;
5048
+      var cache = this.cache;
5049
+      var primitive = !isObject(value);
5050
+      var id;
5051
+      if (key || trackByKey || primitive) {
5052
+        id = trackByKey ? trackByKey === '$index' ? index : value[trackByKey] : key || value;
5053
+        if (!cache[id]) {
5054
+          cache[id] = frag;
5055
+        } else if (trackByKey !== '$index') {
5056
+          'development' !== 'production' && this.warnDuplicate(value);
5057
+        }
5058
+      } else {
5059
+        id = this.id;
5060
+        if (hasOwn(value, id)) {
5061
+          if (value[id] === null) {
5062
+            value[id] = frag;
5063
+          } else {
5064
+            'development' !== 'production' && this.warnDuplicate(value);
5065
+          }
5066
+        } else {
5067
+          def(value, id, frag);
5068
+        }
5069
+      }
5070
+      frag.raw = value;
5071
+    },
5072
+
5073
+    /**
5074
+     * Get a cached fragment from the value/index/key
5075
+     *
5076
+     * @param {*} value
5077
+     * @param {Number} index
5078
+     * @param {String} key
5079
+     * @return {Fragment}
5080
+     */
5081
+
5082
+    getCachedFrag: function getCachedFrag(value, index, key) {
5083
+      var trackByKey = this.params.trackBy;
5084
+      var primitive = !isObject(value);
5085
+      var frag;
5086
+      if (key || trackByKey || primitive) {
5087
+        var id = trackByKey ? trackByKey === '$index' ? index : value[trackByKey] : key || value;
5088
+        frag = this.cache[id];
5089
+      } else {
5090
+        frag = value[this.id];
5091
+      }
5092
+      if (frag && (frag.reused || frag.fresh)) {
5093
+        'development' !== 'production' && this.warnDuplicate(value);
5094
+      }
5095
+      return frag;
5096
+    },
5097
+
5098
+    /**
5099
+     * Delete a fragment from cache.
5100
+     *
5101
+     * @param {Fragment} frag
5102
+     */
5103
+
5104
+    deleteCachedFrag: function deleteCachedFrag(frag) {
5105
+      var value = frag.raw;
5106
+      var trackByKey = this.params.trackBy;
5107
+      var scope = frag.scope;
5108
+      var index = scope.$index;
5109
+      // fix #948: avoid accidentally fall through to
5110
+      // a parent repeater which happens to have $key.
5111
+      var key = hasOwn(scope, '$key') && scope.$key;
5112
+      var primitive = !isObject(value);
5113
+      if (trackByKey || key || primitive) {
5114
+        var id = trackByKey ? trackByKey === '$index' ? index : value[trackByKey] : key || value;
5115
+        this.cache[id] = null;
5116
+      } else {
5117
+        value[this.id] = null;
5118
+        frag.raw = null;
5119
+      }
5120
+    },
5121
+
5122
+    /**
5123
+     * Get the stagger amount for an insertion/removal.
5124
+     *
5125
+     * @param {Fragment} frag
5126
+     * @param {Number} index
5127
+     * @param {Number} total
5128
+     * @param {String} type
5129
+     */
5130
+
5131
+    getStagger: function getStagger(frag, index, total, type) {
5132
+      type = type + 'Stagger';
5133
+      var trans = frag.node.__v_trans;
5134
+      var hooks = trans && trans.hooks;
5135
+      var hook = hooks && (hooks[type] || hooks.stagger);
5136
+      return hook ? hook.call(frag, index, total) : index * parseInt(this.params[type] || this.params.stagger, 10);
5137
+    },
5138
+
5139
+    /**
5140
+     * Pre-process the value before piping it through the
5141
+     * filters. This is passed to and called by the watcher.
5142
+     */
5143
+
5144
+    _preProcess: function _preProcess(value) {
5145
+      // regardless of type, store the un-filtered raw value.
5146
+      this.rawValue = value;
5147
+      return value;
5148
+    },
5149
+
5150
+    /**
5151
+     * Post-process the value after it has been piped through
5152
+     * the filters. This is passed to and called by the watcher.
5153
+     *
5154
+     * It is necessary for this to be called during the
5155
+     * wathcer's dependency collection phase because we want
5156
+     * the v-for to update when the source Object is mutated.
5157
+     */
5158
+
5159
+    _postProcess: function _postProcess(value) {
5160
+      if (isArray(value)) {
5161
+        return value;
5162
+      } else if (isPlainObject(value)) {
5163
+        // convert plain object to array.
5164
+        var keys = Object.keys(value);
5165
+        var i = keys.length;
5166
+        var res = new Array(i);
5167
+        var key;
5168
+        while (i--) {
5169
+          key = keys[i];
5170
+          res[i] = {
5171
+            $key: key,
5172
+            $value: value[key]
5173
+          };
5174
+        }
5175
+        return res;
5176
+      } else {
5177
+        if (typeof value === 'number') {
5178
+          value = range(value);
5179
+        }
5180
+        return value || [];
5181
+      }
5182
+    },
5183
+
5184
+    unbind: function unbind() {
5185
+      if (this.descriptor.ref) {
5186
+        (this._scope || this.vm).$refs[this.descriptor.ref] = null;
5187
+      }
5188
+      if (this.frags) {
5189
+        var i = this.frags.length;
5190
+        var frag;
5191
+        while (i--) {
5192
+          frag = this.frags[i];
5193
+          this.deleteCachedFrag(frag);
5194
+          frag.destroy();
5195
+        }
5196
+      }
5197
+    }
5198
+  };
5199
+
5200
+  /**
5201
+   * Helper to find the previous element that is a fragment
5202
+   * anchor. This is necessary because a destroyed frag's
5203
+   * element could still be lingering in the DOM before its
5204
+   * leaving transition finishes, but its inserted flag
5205
+   * should have been set to false so we can skip them.
5206
+   *
5207
+   * If this is a block repeat, we want to make sure we only
5208
+   * return frag that is bound to this v-for. (see #929)
5209
+   *
5210
+   * @param {Fragment} frag
5211
+   * @param {Comment|Text} anchor
5212
+   * @param {String} id
5213
+   * @return {Fragment}
5214
+   */
5215
+
5216
+  function findPrevFrag(frag, anchor, id) {
5217
+    var el = frag.node.previousSibling;
5218
+    /* istanbul ignore if */
5219
+    if (!el) return;
5220
+    frag = el.__vfrag__;
5221
+    while ((!frag || frag.forId !== id || !frag.inserted) && el !== anchor) {
5222
+      el = el.previousSibling;
5223
+      /* istanbul ignore if */
5224
+      if (!el) return;
5225
+      frag = el.__vfrag__;
5226
+    }
5227
+    return frag;
5228
+  }
5229
+
5230
+  /**
5231
+   * Find a vm from a fragment.
5232
+   *
5233
+   * @param {Fragment} frag
5234
+   * @return {Vue|undefined}
5235
+   */
5236
+
5237
+  function findVmFromFrag(frag) {
5238
+    var node = frag.node;
5239
+    // handle multi-node frag
5240
+    if (frag.end) {
5241
+      while (!node.__vue__ && node !== frag.end && node.nextSibling) {
5242
+        node = node.nextSibling;
5243
+      }
5244
+    }
5245
+    return node.__vue__;
5246
+  }
5247
+
5248
+  /**
5249
+   * Create a range array from given number.
5250
+   *
5251
+   * @param {Number} n
5252
+   * @return {Array}
5253
+   */
5254
+
5255
+  function range(n) {
5256
+    var i = -1;
5257
+    var ret = new Array(n);
5258
+    while (++i < n) {
5259
+      ret[i] = i;
5260
+    }
5261
+    return ret;
5262
+  }
5263
+
5264
+  if ('development' !== 'production') {
5265
+    vFor.warnDuplicate = function (value) {
5266
+      warn('Duplicate value found in v-for="' + this.descriptor.raw + '": ' + JSON.stringify(value) + '. Use track-by="$index" if ' + 'you are expecting duplicate values.');
5267
+    };
5268
+  }
5269
+
5270
+  var html = {
5271
+
5272
+    bind: function bind() {
5273
+      // a comment node means this is a binding for
5274
+      // {{{ inline unescaped html }}}
5275
+      if (this.el.nodeType === 8) {
5276
+        // hold nodes
5277
+        this.nodes = [];
5278
+        // replace the placeholder with proper anchor
5279
+        this.anchor = createAnchor('v-html');
5280
+        replace(this.el, this.anchor);
5281
+      }
5282
+    },
5283
+
5284
+    update: function update(value) {
5285
+      value = _toString(value);
5286
+      if (this.nodes) {
5287
+        this.swap(value);
5288
+      } else {
5289
+        this.el.innerHTML = value;
5290
+      }
5291
+    },
5292
+
5293
+    swap: function swap(value) {
5294
+      // remove old nodes
5295
+      var i = this.nodes.length;
5296
+      while (i--) {
5297
+        remove(this.nodes[i]);
5298
+      }
5299
+      // convert new value to a fragment
5300
+      // do not attempt to retrieve from id selector
5301
+      var frag = parseTemplate(value, true, true);
5302
+      // save a reference to these nodes so we can remove later
5303
+      this.nodes = toArray(frag.childNodes);
5304
+      before(frag, this.anchor);
5305
+    }
5306
+  };
5307
+
5308
+  var text = {
5309
+
5310
+    bind: function bind() {
5311
+      this.attr = this.el.nodeType === 3 ? 'data' : 'textContent';
5312
+    },
5313
+
5314
+    update: function update(value) {
5315
+      this.el[this.attr] = _toString(value);
5316
+    }
5317
+  };
5318
+
5319
+  // must export plain object
5320
+  var publicDirectives = {
5321
+    text: text,
5322
+    html: html,
5323
+    'for': vFor,
5324
+    'if': vIf,
5325
+    show: show,
5326
+    model: model,
5327
+    on: on,
5328
+    bind: bind,
5329
+    el: el,
5330
+    ref: ref,
5331
+    cloak: cloak
5332
+  };
5333
+
5334
+  var queue$1 = [];
5335
+  var queued = false;
5336
+
5337
+  /**
5338
+   * Push a job into the queue.
5339
+   *
5340
+   * @param {Function} job
5341
+   */
5342
+
5343
+  function pushJob(job) {
5344
+    queue$1.push(job);
5345
+    if (!queued) {
5346
+      queued = true;
5347
+      nextTick(flush);
5348
+    }
5349
+  }
5350
+
5351
+  /**
5352
+   * Flush the queue, and do one forced reflow before
5353
+   * triggering transitions.
5354
+   */
5355
+
5356
+  function flush() {
5357
+    // Force layout
5358
+    var f = document.documentElement.offsetHeight;
5359
+    for (var i = 0; i < queue$1.length; i++) {
5360
+      queue$1[i]();
5361
+    }
5362
+    queue$1 = [];
5363
+    queued = false;
5364
+    // dummy return, so js linters don't complain about
5365
+    // unused variable f
5366
+    return f;
5367
+  }
5368
+
5369
+  var TYPE_TRANSITION = 'transition';
5370
+  var TYPE_ANIMATION = 'animation';
5371
+  var transDurationProp = transitionProp + 'Duration';
5372
+  var animDurationProp = animationProp + 'Duration';
5373
+
5374
+  /**
5375
+   * A Transition object that encapsulates the state and logic
5376
+   * of the transition.
5377
+   *
5378
+   * @param {Element} el
5379
+   * @param {String} id
5380
+   * @param {Object} hooks
5381
+   * @param {Vue} vm
5382
+   */
5383
+  function Transition(el, id, hooks, vm) {
5384
+    this.id = id;
5385
+    this.el = el;
5386
+    this.enterClass = hooks && hooks.enterClass || id + '-enter';
5387
+    this.leaveClass = hooks && hooks.leaveClass || id + '-leave';
5388
+    this.hooks = hooks;
5389
+    this.vm = vm;
5390
+    // async state
5391
+    this.pendingCssEvent = this.pendingCssCb = this.cancel = this.pendingJsCb = this.op = this.cb = null;
5392
+    this.justEntered = false;
5393
+    this.entered = this.left = false;
5394
+    this.typeCache = {};
5395
+    // check css transition type
5396
+    this.type = hooks && hooks.type;
5397
+    /* istanbul ignore if */
5398
+    if ('development' !== 'production') {
5399
+      if (this.type && this.type !== TYPE_TRANSITION && this.type !== TYPE_ANIMATION) {
5400
+        warn('invalid CSS transition type for transition="' + this.id + '": ' + this.type);
5401
+      }
5402
+    }
5403
+    // bind
5404
+    var self = this;['enterNextTick', 'enterDone', 'leaveNextTick', 'leaveDone'].forEach(function (m) {
5405
+      self[m] = bind$1(self[m], self);
5406
+    });
5407
+  }
5408
+
5409
+  var p$1 = Transition.prototype;
5410
+
5411
+  /**
5412
+   * Start an entering transition.
5413
+   *
5414
+   * 1. enter transition triggered
5415
+   * 2. call beforeEnter hook
5416
+   * 3. add enter class
5417
+   * 4. insert/show element
5418
+   * 5. call enter hook (with possible explicit js callback)
5419
+   * 6. reflow
5420
+   * 7. based on transition type:
5421
+   *    - transition:
5422
+   *        remove class now, wait for transitionend,
5423
+   *        then done if there's no explicit js callback.
5424
+   *    - animation:
5425
+   *        wait for animationend, remove class,
5426
+   *        then done if there's no explicit js callback.
5427
+   *    - no css transition:
5428
+   *        done now if there's no explicit js callback.
5429
+   * 8. wait for either done or js callback, then call
5430
+   *    afterEnter hook.
5431
+   *
5432
+   * @param {Function} op - insert/show the element
5433
+   * @param {Function} [cb]
5434
+   */
5435
+
5436
+  p$1.enter = function (op, cb) {
5437
+    this.cancelPending();
5438
+    this.callHook('beforeEnter');
5439
+    this.cb = cb;
5440
+    addClass(this.el, this.enterClass);
5441
+    op();
5442
+    this.entered = false;
5443
+    this.callHookWithCb('enter');
5444
+    if (this.entered) {
5445
+      return; // user called done synchronously.
5446
+    }
5447
+    this.cancel = this.hooks && this.hooks.enterCancelled;
5448
+    pushJob(this.enterNextTick);
5449
+  };
5450
+
5451
+  /**
5452
+   * The "nextTick" phase of an entering transition, which is
5453
+   * to be pushed into a queue and executed after a reflow so
5454
+   * that removing the class can trigger a CSS transition.
5455
+   */
5456
+
5457
+  p$1.enterNextTick = function () {
5458
+
5459
+    // Important hack:
5460
+    // in Chrome, if a just-entered element is applied the
5461
+    // leave class while its interpolated property still has
5462
+    // a very small value (within one frame), Chrome will
5463
+    // skip the leave transition entirely and not firing the
5464
+    // transtionend event. Therefore we need to protected
5465
+    // against such cases using a one-frame timeout.
5466
+    this.justEntered = true;
5467
+    var self = this;
5468
+    setTimeout(function () {
5469
+      self.justEntered = false;
5470
+    }, 17);
5471
+
5472
+    var enterDone = this.enterDone;
5473
+    var type = this.getCssTransitionType(this.enterClass);
5474
+    if (!this.pendingJsCb) {
5475
+      if (type === TYPE_TRANSITION) {
5476
+        // trigger transition by removing enter class now
5477
+        removeClass(this.el, this.enterClass);
5478
+        this.setupCssCb(transitionEndEvent, enterDone);
5479
+      } else if (type === TYPE_ANIMATION) {
5480
+        this.setupCssCb(animationEndEvent, enterDone);
5481
+      } else {
5482
+        enterDone();
5483
+      }
5484
+    } else if (type === TYPE_TRANSITION) {
5485
+      removeClass(this.el, this.enterClass);
5486
+    }
5487
+  };
5488
+
5489
+  /**
5490
+   * The "cleanup" phase of an entering transition.
5491
+   */
5492
+
5493
+  p$1.enterDone = function () {
5494
+    this.entered = true;
5495
+    this.cancel = this.pendingJsCb = null;
5496
+    removeClass(this.el, this.enterClass);
5497
+    this.callHook('afterEnter');
5498
+    if (this.cb) this.cb();
5499
+  };
5500
+
5501
+  /**
5502
+   * Start a leaving transition.
5503
+   *
5504
+   * 1. leave transition triggered.
5505
+   * 2. call beforeLeave hook
5506
+   * 3. add leave class (trigger css transition)
5507
+   * 4. call leave hook (with possible explicit js callback)
5508
+   * 5. reflow if no explicit js callback is provided
5509
+   * 6. based on transition type:
5510
+   *    - transition or animation:
5511
+   *        wait for end event, remove class, then done if
5512
+   *        there's no explicit js callback.
5513
+   *    - no css transition:
5514
+   *        done if there's no explicit js callback.
5515
+   * 7. wait for either done or js callback, then call
5516
+   *    afterLeave hook.
5517
+   *
5518
+   * @param {Function} op - remove/hide the element
5519
+   * @param {Function} [cb]
5520
+   */
5521
+
5522
+  p$1.leave = function (op, cb) {
5523
+    this.cancelPending();
5524
+    this.callHook('beforeLeave');
5525
+    this.op = op;
5526
+    this.cb = cb;
5527
+    addClass(this.el, this.leaveClass);
5528
+    this.left = false;
5529
+    this.callHookWithCb('leave');
5530
+    if (this.left) {
5531
+      return; // user called done synchronously.
5532
+    }
5533
+    this.cancel = this.hooks && this.hooks.leaveCancelled;
5534
+    // only need to handle leaveDone if
5535
+    // 1. the transition is already done (synchronously called
5536
+    //    by the user, which causes this.op set to null)
5537
+    // 2. there's no explicit js callback
5538
+    if (this.op && !this.pendingJsCb) {
5539
+      // if a CSS transition leaves immediately after enter,
5540
+      // the transitionend event never fires. therefore we
5541
+      // detect such cases and end the leave immediately.
5542
+      if (this.justEntered) {
5543
+        this.leaveDone();
5544
+      } else {
5545
+        pushJob(this.leaveNextTick);
5546
+      }
5547
+    }
5548
+  };
5549
+
5550
+  /**
5551
+   * The "nextTick" phase of a leaving transition.
5552
+   */
5553
+
5554
+  p$1.leaveNextTick = function () {
5555
+    var type = this.getCssTransitionType(this.leaveClass);
5556
+    if (type) {
5557
+      var event = type === TYPE_TRANSITION ? transitionEndEvent : animationEndEvent;
5558
+      this.setupCssCb(event, this.leaveDone);
5559
+    } else {
5560
+      this.leaveDone();
5561
+    }
5562
+  };
5563
+
5564
+  /**
5565
+   * The "cleanup" phase of a leaving transition.
5566
+   */
5567
+
5568
+  p$1.leaveDone = function () {
5569
+    this.left = true;
5570
+    this.cancel = this.pendingJsCb = null;
5571
+    this.op();
5572
+    removeClass(this.el, this.leaveClass);
5573
+    this.callHook('afterLeave');
5574
+    if (this.cb) this.cb();
5575
+    this.op = null;
5576
+  };
5577
+
5578
+  /**
5579
+   * Cancel any pending callbacks from a previously running
5580
+   * but not finished transition.
5581
+   */
5582
+
5583
+  p$1.cancelPending = function () {
5584
+    this.op = this.cb = null;
5585
+    var hasPending = false;
5586
+    if (this.pendingCssCb) {
5587
+      hasPending = true;
5588
+      off(this.el, this.pendingCssEvent, this.pendingCssCb);
5589
+      this.pendingCssEvent = this.pendingCssCb = null;
5590
+    }
5591
+    if (this.pendingJsCb) {
5592
+      hasPending = true;
5593
+      this.pendingJsCb.cancel();
5594
+      this.pendingJsCb = null;
5595
+    }
5596
+    if (hasPending) {
5597
+      removeClass(this.el, this.enterClass);
5598
+      removeClass(this.el, this.leaveClass);
5599
+    }
5600
+    if (this.cancel) {
5601
+      this.cancel.call(this.vm, this.el);
5602
+      this.cancel = null;
5603
+    }
5604
+  };
5605
+
5606
+  /**
5607
+   * Call a user-provided synchronous hook function.
5608
+   *
5609
+   * @param {String} type
5610
+   */
5611
+
5612
+  p$1.callHook = function (type) {
5613
+    if (this.hooks && this.hooks[type]) {
5614
+      this.hooks[type].call(this.vm, this.el);
5615
+    }
5616
+  };
5617
+
5618
+  /**
5619
+   * Call a user-provided, potentially-async hook function.
5620
+   * We check for the length of arguments to see if the hook
5621
+   * expects a `done` callback. If true, the transition's end
5622
+   * will be determined by when the user calls that callback;
5623
+   * otherwise, the end is determined by the CSS transition or
5624
+   * animation.
5625
+   *
5626
+   * @param {String} type
5627
+   */
5628
+
5629
+  p$1.callHookWithCb = function (type) {
5630
+    var hook = this.hooks && this.hooks[type];
5631
+    if (hook) {
5632
+      if (hook.length > 1) {
5633
+        this.pendingJsCb = cancellable(this[type + 'Done']);
5634
+      }
5635
+      hook.call(this.vm, this.el, this.pendingJsCb);
5636
+    }
5637
+  };
5638
+
5639
+  /**
5640
+   * Get an element's transition type based on the
5641
+   * calculated styles.
5642
+   *
5643
+   * @param {String} className
5644
+   * @return {Number}
5645
+   */
5646
+
5647
+  p$1.getCssTransitionType = function (className) {
5648
+    /* istanbul ignore if */
5649
+    if (!transitionEndEvent ||
5650
+    // skip CSS transitions if page is not visible -
5651
+    // this solves the issue of transitionend events not
5652
+    // firing until the page is visible again.
5653
+    // pageVisibility API is supported in IE10+, same as
5654
+    // CSS transitions.
5655
+    document.hidden ||
5656
+    // explicit js-only transition
5657
+    this.hooks && this.hooks.css === false ||
5658
+    // element is hidden
5659
+    isHidden(this.el)) {
5660
+      return;
5661
+    }
5662
+    var type = this.type || this.typeCache[className];
5663
+    if (type) return type;
5664
+    var inlineStyles = this.el.style;
5665
+    var computedStyles = window.getComputedStyle(this.el);
5666
+    var transDuration = inlineStyles[transDurationProp] || computedStyles[transDurationProp];
5667
+    if (transDuration && transDuration !== '0s') {
5668
+      type = TYPE_TRANSITION;
5669
+    } else {
5670
+      var animDuration = inlineStyles[animDurationProp] || computedStyles[animDurationProp];
5671
+      if (animDuration && animDuration !== '0s') {
5672
+        type = TYPE_ANIMATION;
5673
+      }
5674
+    }
5675
+    if (type) {
5676
+      this.typeCache[className] = type;
5677
+    }
5678
+    return type;
5679
+  };
5680
+
5681
+  /**
5682
+   * Setup a CSS transitionend/animationend callback.
5683
+   *
5684
+   * @param {String} event
5685
+   * @param {Function} cb
5686
+   */
5687
+
5688
+  p$1.setupCssCb = function (event, cb) {
5689
+    this.pendingCssEvent = event;
5690
+    var self = this;
5691
+    var el = this.el;
5692
+    var onEnd = this.pendingCssCb = function (e) {
5693
+      if (e.target === el) {
5694
+        off(el, event, onEnd);
5695
+        self.pendingCssEvent = self.pendingCssCb = null;
5696
+        if (!self.pendingJsCb && cb) {
5697
+          cb();
5698
+        }
5699
+      }
5700
+    };
5701
+    on$1(el, event, onEnd);
5702
+  };
5703
+
5704
+  /**
5705
+   * Check if an element is hidden - in that case we can just
5706
+   * skip the transition alltogether.
5707
+   *
5708
+   * @param {Element} el
5709
+   * @return {Boolean}
5710
+   */
5711
+
5712
+  function isHidden(el) {
5713
+    return !(el.offsetWidth || el.offsetHeight || el.getClientRects().length);
5714
+  }
5715
+
5716
+  var transition = {
5717
+
5718
+    priority: TRANSITION,
5719
+
5720
+    update: function update(id, oldId) {
5721
+      var el = this.el;
5722
+      // resolve on owner vm
5723
+      var hooks = resolveAsset(this.vm.$options, 'transitions', id);
5724
+      id = id || 'v';
5725
+      // apply on closest vm
5726
+      el.__v_trans = new Transition(el, id, hooks, this.el.__vue__ || this.vm);
5727
+      if (oldId) {
5728
+        removeClass(el, oldId + '-transition');
5729
+      }
5730
+      addClass(el, id + '-transition');
5731
+    }
5732
+  };
5733
+
5734
+  var bindingModes = config._propBindingModes;
5735
+
5736
+  var propDef = {
5737
+
5738
+    bind: function bind() {
5739
+
5740
+      var child = this.vm;
5741
+      var parent = child._context;
5742
+      // passed in from compiler directly
5743
+      var prop = this.descriptor.prop;
5744
+      var childKey = prop.path;
5745
+      var parentKey = prop.parentPath;
5746
+      var twoWay = prop.mode === bindingModes.TWO_WAY;
5747
+
5748
+      var parentWatcher = this.parentWatcher = new Watcher(parent, parentKey, function (val) {
5749
+        val = coerceProp(prop, val);
5750
+        if (assertProp(prop, val)) {
5751
+          child[childKey] = val;
5752
+        }
5753
+      }, {
5754
+        twoWay: twoWay,
5755
+        filters: prop.filters,
5756
+        // important: props need to be observed on the
5757
+        // v-for scope if present
5758
+        scope: this._scope
5759
+      });
5760
+
5761
+      // set the child initial value.
5762
+      initProp(child, prop, parentWatcher.value);
5763
+
5764
+      // setup two-way binding
5765
+      if (twoWay) {
5766
+        // important: defer the child watcher creation until
5767
+        // the created hook (after data observation)
5768
+        var self = this;
5769
+        child.$once('pre-hook:created', function () {
5770
+          self.childWatcher = new Watcher(child, childKey, function (val) {
5771
+            parentWatcher.set(val);
5772
+          }, {
5773
+            // ensure sync upward before parent sync down.
5774
+            // this is necessary in cases e.g. the child
5775
+            // mutates a prop array, then replaces it. (#1683)
5776
+            sync: true
5777
+          });
5778
+        });
5779
+      }
5780
+    },
5781
+
5782
+    unbind: function unbind() {
5783
+      this.parentWatcher.teardown();
5784
+      if (this.childWatcher) {
5785
+        this.childWatcher.teardown();
5786
+      }
5787
+    }
5788
+  };
5789
+
5790
+  var component = {
5791
+
5792
+    priority: COMPONENT,
5793
+
5794
+    params: ['keep-alive', 'transition-mode', 'inline-template'],
5795
+
5796
+    /**
5797
+     * Setup. Two possible usages:
5798
+     *
5799
+     * - static:
5800
+     *   <comp> or <div v-component="comp">
5801
+     *
5802
+     * - dynamic:
5803
+     *   <component :is="view">
5804
+     */
5805
+
5806
+    bind: function bind() {
5807
+      if (!this.el.__vue__) {
5808
+        // keep-alive cache
5809
+        this.keepAlive = this.params.keepAlive;
5810
+        if (this.keepAlive) {
5811
+          this.cache = {};
5812
+        }
5813
+        // check inline-template
5814
+        if (this.params.inlineTemplate) {
5815
+          // extract inline template as a DocumentFragment
5816
+          this.inlineTemplate = extractContent(this.el, true);
5817
+        }
5818
+        // component resolution related state
5819
+        this.pendingComponentCb = this.Component = null;
5820
+        // transition related state
5821
+        this.pendingRemovals = 0;
5822
+        this.pendingRemovalCb = null;
5823
+        // create a ref anchor
5824
+        this.anchor = createAnchor('v-component');
5825
+        replace(this.el, this.anchor);
5826
+        // remove is attribute.
5827
+        // this is removed during compilation, but because compilation is
5828
+        // cached, when the component is used elsewhere this attribute
5829
+        // will remain at link time.
5830
+        this.el.removeAttribute('is');
5831
+        // remove ref, same as above
5832
+        if (this.descriptor.ref) {
5833
+          this.el.removeAttribute('v-ref:' + hyphenate(this.descriptor.ref));
5834
+        }
5835
+        // if static, build right now.
5836
+        if (this.literal) {
5837
+          this.setComponent(this.expression);
5838
+        }
5839
+      } else {
5840
+        'development' !== 'production' && warn('cannot mount component "' + this.expression + '" ' + 'on already mounted element: ' + this.el);
5841
+      }
5842
+    },
5843
+
5844
+    /**
5845
+     * Public update, called by the watcher in the dynamic
5846
+     * literal scenario, e.g. <component :is="view">
5847
+     */
5848
+
5849
+    update: function update(value) {
5850
+      if (!this.literal) {
5851
+        this.setComponent(value);
5852
+      }
5853
+    },
5854
+
5855
+    /**
5856
+     * Switch dynamic components. May resolve the component
5857
+     * asynchronously, and perform transition based on
5858
+     * specified transition mode. Accepts a few additional
5859
+     * arguments specifically for vue-router.
5860
+     *
5861
+     * The callback is called when the full transition is
5862
+     * finished.
5863
+     *
5864
+     * @param {String} value
5865
+     * @param {Function} [cb]
5866
+     */
5867
+
5868
+    setComponent: function setComponent(value, cb) {
5869
+      this.invalidatePending();
5870
+      if (!value) {
5871
+        // just remove current
5872
+        this.unbuild(true);
5873
+        this.remove(this.childVM, cb);
5874
+        this.childVM = null;
5875
+      } else {
5876
+        var self = this;
5877
+        this.resolveComponent(value, function () {
5878
+          self.mountComponent(cb);
5879
+        });
5880
+      }
5881
+    },
5882
+
5883
+    /**
5884
+     * Resolve the component constructor to use when creating
5885
+     * the child vm.
5886
+     */
5887
+
5888
+    resolveComponent: function resolveComponent(id, cb) {
5889
+      var self = this;
5890
+      this.pendingComponentCb = cancellable(function (Component) {
5891
+        self.ComponentName = Component.options.name || id;
5892
+        self.Component = Component;
5893
+        cb();
5894
+      });
5895
+      this.vm._resolveComponent(id, this.pendingComponentCb);
5896
+    },
5897
+
5898
+    /**
5899
+     * Create a new instance using the current constructor and
5900
+     * replace the existing instance. This method doesn't care
5901
+     * whether the new component and the old one are actually
5902
+     * the same.
5903
+     *
5904
+     * @param {Function} [cb]
5905
+     */
5906
+
5907
+    mountComponent: function mountComponent(cb) {
5908
+      // actual mount
5909
+      this.unbuild(true);
5910
+      var self = this;
5911
+      var activateHook = this.Component.options.activate;
5912
+      var cached = this.getCached();
5913
+      var newComponent = this.build();
5914
+      if (activateHook && !cached) {
5915
+        this.waitingFor = newComponent;
5916
+        activateHook.call(newComponent, function () {
5917
+          if (self.waitingFor !== newComponent) {
5918
+            return;
5919
+          }
5920
+          self.waitingFor = null;
5921
+          self.transition(newComponent, cb);
5922
+        });
5923
+      } else {
5924
+        // update ref for kept-alive component
5925
+        if (cached) {
5926
+          newComponent._updateRef();
5927
+        }
5928
+        this.transition(newComponent, cb);
5929
+      }
5930
+    },
5931
+
5932
+    /**
5933
+     * When the component changes or unbinds before an async
5934
+     * constructor is resolved, we need to invalidate its
5935
+     * pending callback.
5936
+     */
5937
+
5938
+    invalidatePending: function invalidatePending() {
5939
+      if (this.pendingComponentCb) {
5940
+        this.pendingComponentCb.cancel();
5941
+        this.pendingComponentCb = null;
5942
+      }
5943
+    },
5944
+
5945
+    /**
5946
+     * Instantiate/insert a new child vm.
5947
+     * If keep alive and has cached instance, insert that
5948
+     * instance; otherwise build a new one and cache it.
5949
+     *
5950
+     * @param {Object} [extraOptions]
5951
+     * @return {Vue} - the created instance
5952
+     */
5953
+
5954
+    build: function build(extraOptions) {
5955
+      var cached = this.getCached();
5956
+      if (cached) {
5957
+        return cached;
5958
+      }
5959
+      if (this.Component) {
5960
+        // default options
5961
+        var options = {
5962
+          name: this.ComponentName,
5963
+          el: cloneNode(this.el),
5964
+          template: this.inlineTemplate,
5965
+          // make sure to add the child with correct parent
5966
+          // if this is a transcluded component, its parent
5967
+          // should be the transclusion host.
5968
+          parent: this._host || this.vm,
5969
+          // if no inline-template, then the compiled
5970
+          // linker can be cached for better performance.
5971
+          _linkerCachable: !this.inlineTemplate,
5972
+          _ref: this.descriptor.ref,
5973
+          _asComponent: true,
5974
+          _isRouterView: this._isRouterView,
5975
+          // if this is a transcluded component, context
5976
+          // will be the common parent vm of this instance
5977
+          // and its host.
5978
+          _context: this.vm,
5979
+          // if this is inside an inline v-for, the scope
5980
+          // will be the intermediate scope created for this
5981
+          // repeat fragment. this is used for linking props
5982
+          // and container directives.
5983
+          _scope: this._scope,
5984
+          // pass in the owner fragment of this component.
5985
+          // this is necessary so that the fragment can keep
5986
+          // track of its contained components in order to
5987
+          // call attach/detach hooks for them.
5988
+          _frag: this._frag
5989
+        };
5990
+        // extra options
5991
+        // in 1.0.0 this is used by vue-router only
5992
+        /* istanbul ignore if */
5993
+        if (extraOptions) {
5994
+          extend(options, extraOptions);
5995
+        }
5996
+        var child = new this.Component(options);
5997
+        if (this.keepAlive) {
5998
+          this.cache[this.Component.cid] = child;
5999
+        }
6000
+        /* istanbul ignore if */
6001
+        if ('development' !== 'production' && this.el.hasAttribute('transition') && child._isFragment) {
6002
+          warn('Transitions will not work on a fragment instance. ' + 'Template: ' + child.$options.template);
6003
+        }
6004
+        return child;
6005
+      }
6006
+    },
6007
+
6008
+    /**
6009
+     * Try to get a cached instance of the current component.
6010
+     *
6011
+     * @return {Vue|undefined}
6012
+     */
6013
+
6014
+    getCached: function getCached() {
6015
+      return this.keepAlive && this.cache[this.Component.cid];
6016
+    },
6017
+
6018
+    /**
6019
+     * Teardown the current child, but defers cleanup so
6020
+     * that we can separate the destroy and removal steps.
6021
+     *
6022
+     * @param {Boolean} defer
6023
+     */
6024
+
6025
+    unbuild: function unbuild(defer) {
6026
+      if (this.waitingFor) {
6027
+        this.waitingFor.$destroy();
6028
+        this.waitingFor = null;
6029
+      }
6030
+      var child = this.childVM;
6031
+      if (!child || this.keepAlive) {
6032
+        if (child) {
6033
+          // remove ref
6034
+          child._updateRef(true);
6035
+        }
6036
+        return;
6037
+      }
6038
+      // the sole purpose of `deferCleanup` is so that we can
6039
+      // "deactivate" the vm right now and perform DOM removal
6040
+      // later.
6041
+      child.$destroy(false, defer);
6042
+    },
6043
+
6044
+    /**
6045
+     * Remove current destroyed child and manually do
6046
+     * the cleanup after removal.
6047
+     *
6048
+     * @param {Function} cb
6049
+     */
6050
+
6051
+    remove: function remove(child, cb) {
6052
+      var keepAlive = this.keepAlive;
6053
+      if (child) {
6054
+        // we may have a component switch when a previous
6055
+        // component is still being transitioned out.
6056
+        // we want to trigger only one lastest insertion cb
6057
+        // when the existing transition finishes. (#1119)
6058
+        this.pendingRemovals++;
6059
+        this.pendingRemovalCb = cb;
6060
+        var self = this;
6061
+        child.$remove(function () {
6062
+          self.pendingRemovals--;
6063
+          if (!keepAlive) child._cleanup();
6064
+          if (!self.pendingRemovals && self.pendingRemovalCb) {
6065
+            self.pendingRemovalCb();
6066
+            self.pendingRemovalCb = null;
6067
+          }
6068
+        });
6069
+      } else if (cb) {
6070
+        cb();
6071
+      }
6072
+    },
6073
+
6074
+    /**
6075
+     * Actually swap the components, depending on the
6076
+     * transition mode. Defaults to simultaneous.
6077
+     *
6078
+     * @param {Vue} target
6079
+     * @param {Function} [cb]
6080
+     */
6081
+
6082
+    transition: function transition(target, cb) {
6083
+      var self = this;
6084
+      var current = this.childVM;
6085
+      // for devtool inspection
6086
+      if ('development' !== 'production') {
6087
+        if (current) current._inactive = true;
6088
+        target._inactive = false;
6089
+      }
6090
+      this.childVM = target;
6091
+      switch (self.params.transitionMode) {
6092
+        case 'in-out':
6093
+          target.$before(self.anchor, function () {
6094
+            self.remove(current, cb);
6095
+          });
6096
+          break;
6097
+        case 'out-in':
6098
+          self.remove(current, function () {
6099
+            target.$before(self.anchor, cb);
6100
+          });
6101
+          break;
6102
+        default:
6103
+          self.remove(current);
6104
+          target.$before(self.anchor, cb);
6105
+      }
6106
+    },
6107
+
6108
+    /**
6109
+     * Unbind.
6110
+     */
6111
+
6112
+    unbind: function unbind() {
6113
+      this.invalidatePending();
6114
+      // Do not defer cleanup when unbinding
6115
+      this.unbuild();
6116
+      // destroy all keep-alive cached instances
6117
+      if (this.cache) {
6118
+        for (var key in this.cache) {
6119
+          this.cache[key].$destroy();
6120
+        }
6121
+        this.cache = null;
6122
+      }
6123
+    }
6124
+  };
6125
+
6126
+  var vClass = {
6127
+
6128
+    deep: true,
6129
+
6130
+    update: function update(value) {
6131
+      if (value && typeof value === 'string') {
6132
+        this.handleObject(stringToObject(value));
6133
+      } else if (isPlainObject(value)) {
6134
+        this.handleObject(value);
6135
+      } else if (isArray(value)) {
6136
+        this.handleArray(value);
6137
+      } else {
6138
+        this.cleanup();
6139
+      }
6140
+    },
6141
+
6142
+    handleObject: function handleObject(value) {
6143
+      this.cleanup(value);
6144
+      var keys = this.prevKeys = Object.keys(value);
6145
+      for (var i = 0, l = keys.length; i < l; i++) {
6146
+        var key = keys[i];
6147
+        if (value[key]) {
6148
+          addClass(this.el, key);
6149
+        } else {
6150
+          removeClass(this.el, key);
6151
+        }
6152
+      }
6153
+    },
6154
+
6155
+    handleArray: function handleArray(value) {
6156
+      this.cleanup(value);
6157
+      for (var i = 0, l = value.length; i < l; i++) {
6158
+        if (value[i]) {
6159
+          addClass(this.el, value[i]);
6160
+        }
6161
+      }
6162
+      this.prevKeys = value.slice();
6163
+    },
6164
+
6165
+    cleanup: function cleanup(value) {
6166
+      if (this.prevKeys) {
6167
+        var i = this.prevKeys.length;
6168
+        while (i--) {
6169
+          var key = this.prevKeys[i];
6170
+          if (key && (!value || !contains$1(value, key))) {
6171
+            removeClass(this.el, key);
6172
+          }
6173
+        }
6174
+      }
6175
+    }
6176
+  };
6177
+
6178
+  function stringToObject(value) {
6179
+    var res = {};
6180
+    var keys = value.trim().split(/\s+/);
6181
+    var i = keys.length;
6182
+    while (i--) {
6183
+      res[keys[i]] = true;
6184
+    }
6185
+    return res;
6186
+  }
6187
+
6188
+  function contains$1(value, key) {
6189
+    return isArray(value) ? value.indexOf(key) > -1 : hasOwn(value, key);
6190
+  }
6191
+
6192
+  var internalDirectives = {
6193
+    style: style,
6194
+    'class': vClass,
6195
+    component: component,
6196
+    prop: propDef,
6197
+    transition: transition
6198
+  };
6199
+
6200
+  var propBindingModes = config._propBindingModes;
6201
+  var empty = {};
6202
+
6203
+  // regexes
6204
+  var identRE$1 = /^[$_a-zA-Z]+[\w$]*$/;
6205
+  var settablePathRE = /^[A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*|\[[^\[\]]+\])*$/;
6206
+
6207
+  /**
6208
+   * Compile props on a root element and return
6209
+   * a props link function.
6210
+   *
6211
+   * @param {Element|DocumentFragment} el
6212
+   * @param {Array} propOptions
6213
+   * @return {Function} propsLinkFn
6214
+   */
6215
+
6216
+  function compileProps(el, propOptions) {
6217
+    var props = [];
6218
+    var names = Object.keys(propOptions);
6219
+    var i = names.length;
6220
+    var options, name, attr, value, path, parsed, prop;
6221
+    while (i--) {
6222
+      name = names[i];
6223
+      options = propOptions[name] || empty;
6224
+
6225
+      if ('development' !== 'production' && name === '$data') {
6226
+        warn('Do not use $data as prop.');
6227
+        continue;
6228
+      }
6229
+
6230
+      // props could contain dashes, which will be
6231
+      // interpreted as minus calculations by the parser
6232
+      // so we need to camelize the path here
6233
+      path = camelize(name);
6234
+      if (!identRE$1.test(path)) {
6235
+        'development' !== 'production' && warn('Invalid prop key: "' + name + '". Prop keys ' + 'must be valid identifiers.');
6236
+        continue;
6237
+      }
6238
+
6239
+      prop = {
6240
+        name: name,
6241
+        path: path,
6242
+        options: options,
6243
+        mode: propBindingModes.ONE_WAY,
6244
+        raw: null
6245
+      };
6246
+
6247
+      attr = hyphenate(name);
6248
+      // first check dynamic version
6249
+      if ((value = getBindAttr(el, attr)) === null) {
6250
+        if ((value = getBindAttr(el, attr + '.sync')) !== null) {
6251
+          prop.mode = propBindingModes.TWO_WAY;
6252
+        } else if ((value = getBindAttr(el, attr + '.once')) !== null) {
6253
+          prop.mode = propBindingModes.ONE_TIME;
6254
+        }
6255
+      }
6256
+      if (value !== null) {
6257
+        // has dynamic binding!
6258
+        prop.raw = value;
6259
+        parsed = parseDirective(value);
6260
+        value = parsed.expression;
6261
+        prop.filters = parsed.filters;
6262
+        // check binding type
6263
+        if (isLiteral(value) && !parsed.filters) {
6264
+          // for expressions containing literal numbers and
6265
+          // booleans, there's no need to setup a prop binding,
6266
+          // so we can optimize them as a one-time set.
6267
+          prop.optimizedLiteral = true;
6268
+        } else {
6269
+          prop.dynamic = true;
6270
+          // check non-settable path for two-way bindings
6271
+          if ('development' !== 'production' && prop.mode === propBindingModes.TWO_WAY && !settablePathRE.test(value)) {
6272
+            prop.mode = propBindingModes.ONE_WAY;
6273
+            warn('Cannot bind two-way prop with non-settable ' + 'parent path: ' + value);
6274
+          }
6275
+        }
6276
+        prop.parentPath = value;
6277
+
6278
+        // warn required two-way
6279
+        if ('development' !== 'production' && options.twoWay && prop.mode !== propBindingModes.TWO_WAY) {
6280
+          warn('Prop "' + name + '" expects a two-way binding type.');
6281
+        }
6282
+      } else if ((value = getAttr(el, attr)) !== null) {
6283
+        // has literal binding!
6284
+        prop.raw = value;
6285
+      } else if (options.required) {
6286
+        // warn missing required
6287
+        'development' !== 'production' && warn('Missing required prop: ' + name);
6288
+      }
6289
+      // push prop
6290
+      props.push(prop);
6291
+    }
6292
+    return makePropsLinkFn(props);
6293
+  }
6294
+
6295
+  /**
6296
+   * Build a function that applies props to a vm.
6297
+   *
6298
+   * @param {Array} props
6299
+   * @return {Function} propsLinkFn
6300
+   */
6301
+
6302
+  function makePropsLinkFn(props) {
6303
+    return function propsLinkFn(vm, scope) {
6304
+      // store resolved props info
6305
+      vm._props = {};
6306
+      var i = props.length;
6307
+      var prop, path, options, value, raw;
6308
+      while (i--) {
6309
+        prop = props[i];
6310
+        raw = prop.raw;
6311
+        path = prop.path;
6312
+        options = prop.options;
6313
+        vm._props[path] = prop;
6314
+        if (raw === null) {
6315
+          // initialize absent prop
6316
+          initProp(vm, prop, getDefault(vm, options));
6317
+        } else if (prop.dynamic) {
6318
+          // dynamic prop
6319
+          if (vm._context) {
6320
+            if (prop.mode === propBindingModes.ONE_TIME) {
6321
+              // one time binding
6322
+              value = (scope || vm._context).$get(prop.parentPath);
6323
+              initProp(vm, prop, value);
6324
+            } else {
6325
+              // dynamic binding
6326
+              vm._bindDir({
6327
+                name: 'prop',
6328
+                def: propDef,
6329
+                prop: prop
6330
+              }, null, null, scope); // el, host, scope
6331
+            }
6332
+          } else {
6333
+              'development' !== 'production' && warn('Cannot bind dynamic prop on a root instance' + ' with no parent: ' + prop.name + '="' + raw + '"');
6334
+            }
6335
+        } else if (prop.optimizedLiteral) {
6336
+          // optimized literal, cast it and just set once
6337
+          var stripped = stripQuotes(raw);
6338
+          value = stripped === raw ? toBoolean(toNumber(raw)) : stripped;
6339
+          initProp(vm, prop, value);
6340
+        } else {
6341
+          // string literal, but we need to cater for
6342
+          // Boolean props with no value
6343
+          value = options.type === Boolean && raw === '' ? true : raw;
6344
+          initProp(vm, prop, value);
6345
+        }
6346
+      }
6347
+    };
6348
+  }
6349
+
6350
+  /**
6351
+   * Get the default value of a prop.
6352
+   *
6353
+   * @param {Vue} vm
6354
+   * @param {Object} options
6355
+   * @return {*}
6356
+   */
6357
+
6358
+  function getDefault(vm, options) {
6359
+    // no default, return undefined
6360
+    if (!hasOwn(options, 'default')) {
6361
+      // absent boolean value defaults to false
6362
+      return options.type === Boolean ? false : undefined;
6363
+    }
6364
+    var def = options['default'];
6365
+    // warn against non-factory defaults for Object & Array
6366
+    if (isObject(def)) {
6367
+      'development' !== 'production' && warn('Object/Array as default prop values will be shared ' + 'across multiple instances. Use a factory function ' + 'to return the default value instead.');
6368
+    }
6369
+    // call factory function for non-Function types
6370
+    return typeof def === 'function' && options.type !== Function ? def.call(vm) : def;
6371
+  }
6372
+
6373
+  // special binding prefixes
6374
+  var bindRE = /^v-bind:|^:/;
6375
+  var onRE = /^v-on:|^@/;
6376
+  var argRE = /:(.*)$/;
6377
+  var modifierRE = /\.[^\.]+/g;
6378
+  var transitionRE = /^(v-bind:|:)?transition$/;
6379
+
6380
+  // terminal directives
6381
+  var terminalDirectives = ['for', 'if'];
6382
+
6383
+  // default directive priority
6384
+  var DEFAULT_PRIORITY = 1000;
6385
+
6386
+  /**
6387
+   * Compile a template and return a reusable composite link
6388
+   * function, which recursively contains more link functions
6389
+   * inside. This top level compile function would normally
6390
+   * be called on instance root nodes, but can also be used
6391
+   * for partial compilation if the partial argument is true.
6392
+   *
6393
+   * The returned composite link function, when called, will
6394
+   * return an unlink function that tearsdown all directives
6395
+   * created during the linking phase.
6396
+   *
6397
+   * @param {Element|DocumentFragment} el
6398
+   * @param {Object} options
6399
+   * @param {Boolean} partial
6400
+   * @return {Function}
6401
+   */
6402
+
6403
+  function compile(el, options, partial) {
6404
+    // link function for the node itself.
6405
+    var nodeLinkFn = partial || !options._asComponent ? compileNode(el, options) : null;
6406
+    // link function for the childNodes
6407
+    var childLinkFn = !(nodeLinkFn && nodeLinkFn.terminal) && el.tagName !== 'SCRIPT' && el.hasChildNodes() ? compileNodeList(el.childNodes, options) : null;
6408
+
6409
+    /**
6410
+     * A composite linker function to be called on a already
6411
+     * compiled piece of DOM, which instantiates all directive
6412
+     * instances.
6413
+     *
6414
+     * @param {Vue} vm
6415
+     * @param {Element|DocumentFragment} el
6416
+     * @param {Vue} [host] - host vm of transcluded content
6417
+     * @param {Object} [scope] - v-for scope
6418
+     * @param {Fragment} [frag] - link context fragment
6419
+     * @return {Function|undefined}
6420
+     */
6421
+
6422
+    return function compositeLinkFn(vm, el, host, scope, frag) {
6423
+      // cache childNodes before linking parent, fix #657
6424
+      var childNodes = toArray(el.childNodes);
6425
+      // link
6426
+      var dirs = linkAndCapture(function compositeLinkCapturer() {
6427
+        if (nodeLinkFn) nodeLinkFn(vm, el, host, scope, frag);
6428
+        if (childLinkFn) childLinkFn(vm, childNodes, host, scope, frag);
6429
+      }, vm);
6430
+      return makeUnlinkFn(vm, dirs);
6431
+    };
6432
+  }
6433
+
6434
+  /**
6435
+   * Apply a linker to a vm/element pair and capture the
6436
+   * directives created during the process.
6437
+   *
6438
+   * @param {Function} linker
6439
+   * @param {Vue} vm
6440
+   */
6441
+
6442
+  function linkAndCapture(linker, vm) {
6443
+    var originalDirCount = vm._directives.length;
6444
+    linker();
6445
+    var dirs = vm._directives.slice(originalDirCount);
6446
+    dirs.sort(directiveComparator);
6447
+    for (var i = 0, l = dirs.length; i < l; i++) {
6448
+      dirs[i]._bind();
6449
+    }
6450
+    return dirs;
6451
+  }
6452
+
6453
+  /**
6454
+   * Directive priority sort comparator
6455
+   *
6456
+   * @param {Object} a
6457
+   * @param {Object} b
6458
+   */
6459
+
6460
+  function directiveComparator(a, b) {
6461
+    a = a.descriptor.def.priority || DEFAULT_PRIORITY;
6462
+    b = b.descriptor.def.priority || DEFAULT_PRIORITY;
6463
+    return a > b ? -1 : a === b ? 0 : 1;
6464
+  }
6465
+
6466
+  /**
6467
+   * Linker functions return an unlink function that
6468
+   * tearsdown all directives instances generated during
6469
+   * the process.
6470
+   *
6471
+   * We create unlink functions with only the necessary
6472
+   * information to avoid retaining additional closures.
6473
+   *
6474
+   * @param {Vue} vm
6475
+   * @param {Array} dirs
6476
+   * @param {Vue} [context]
6477
+   * @param {Array} [contextDirs]
6478
+   * @return {Function}
6479
+   */
6480
+
6481
+  function makeUnlinkFn(vm, dirs, context, contextDirs) {
6482
+    function unlink(destroying) {
6483
+      teardownDirs(vm, dirs, destroying);
6484
+      if (context && contextDirs) {
6485
+        teardownDirs(context, contextDirs);
6486
+      }
6487
+    }
6488
+    // expose linked directives
6489
+    unlink.dirs = dirs;
6490
+    return unlink;
6491
+  }
6492
+
6493
+  /**
6494
+   * Teardown partial linked directives.
6495
+   *
6496
+   * @param {Vue} vm
6497
+   * @param {Array} dirs
6498
+   * @param {Boolean} destroying
6499
+   */
6500
+
6501
+  function teardownDirs(vm, dirs, destroying) {
6502
+    var i = dirs.length;
6503
+    while (i--) {
6504
+      dirs[i]._teardown();
6505
+      if (!destroying) {
6506
+        vm._directives.$remove(dirs[i]);
6507
+      }
6508
+    }
6509
+  }
6510
+
6511
+  /**
6512
+   * Compile link props on an instance.
6513
+   *
6514
+   * @param {Vue} vm
6515
+   * @param {Element} el
6516
+   * @param {Object} props
6517
+   * @param {Object} [scope]
6518
+   * @return {Function}
6519
+   */
6520
+
6521
+  function compileAndLinkProps(vm, el, props, scope) {
6522
+    var propsLinkFn = compileProps(el, props);
6523
+    var propDirs = linkAndCapture(function () {
6524
+      propsLinkFn(vm, scope);
6525
+    }, vm);
6526
+    return makeUnlinkFn(vm, propDirs);
6527
+  }
6528
+
6529
+  /**
6530
+   * Compile the root element of an instance.
6531
+   *
6532
+   * 1. attrs on context container (context scope)
6533
+   * 2. attrs on the component template root node, if
6534
+   *    replace:true (child scope)
6535
+   *
6536
+   * If this is a fragment instance, we only need to compile 1.
6537
+   *
6538
+   * @param {Vue} vm
6539
+   * @param {Element} el
6540
+   * @param {Object} options
6541
+   * @param {Object} contextOptions
6542
+   * @return {Function}
6543
+   */
6544
+
6545
+  function compileRoot(el, options, contextOptions) {
6546
+    var containerAttrs = options._containerAttrs;
6547
+    var replacerAttrs = options._replacerAttrs;
6548
+    var contextLinkFn, replacerLinkFn;
6549
+
6550
+    // only need to compile other attributes for
6551
+    // non-fragment instances
6552
+    if (el.nodeType !== 11) {
6553
+      // for components, container and replacer need to be
6554
+      // compiled separately and linked in different scopes.
6555
+      if (options._asComponent) {
6556
+        // 2. container attributes
6557
+        if (containerAttrs && contextOptions) {
6558
+          contextLinkFn = compileDirectives(containerAttrs, contextOptions);
6559
+        }
6560
+        if (replacerAttrs) {
6561
+          // 3. replacer attributes
6562
+          replacerLinkFn = compileDirectives(replacerAttrs, options);
6563
+        }
6564
+      } else {
6565
+        // non-component, just compile as a normal element.
6566
+        replacerLinkFn = compileDirectives(el.attributes, options);
6567
+      }
6568
+    } else if ('development' !== 'production' && containerAttrs) {
6569
+      // warn container directives for fragment instances
6570
+      var names = containerAttrs.filter(function (attr) {
6571
+        // allow vue-loader/vueify scoped css attributes
6572
+        return attr.name.indexOf('_v-') < 0 &&
6573
+        // allow event listeners
6574
+        !onRE.test(attr.name) &&
6575
+        // allow slots
6576
+        attr.name !== 'slot';
6577
+      }).map(function (attr) {
6578
+        return '"' + attr.name + '"';
6579
+      });
6580
+      if (names.length) {
6581
+        var plural = names.length > 1;
6582
+        warn('Attribute' + (plural ? 's ' : ' ') + names.join(', ') + (plural ? ' are' : ' is') + ' ignored on component ' + '<' + options.el.tagName.toLowerCase() + '> because ' + 'the component is a fragment instance: ' + 'http://vuejs.org/guide/components.html#Fragment_Instance');
6583
+      }
6584
+    }
6585
+
6586
+    options._containerAttrs = options._replacerAttrs = null;
6587
+    return function rootLinkFn(vm, el, scope) {
6588
+      // link context scope dirs
6589
+      var context = vm._context;
6590
+      var contextDirs;
6591
+      if (context && contextLinkFn) {
6592
+        contextDirs = linkAndCapture(function () {
6593
+          contextLinkFn(context, el, null, scope);
6594
+        }, context);
6595
+      }
6596
+
6597
+      // link self
6598
+      var selfDirs = linkAndCapture(function () {
6599
+        if (replacerLinkFn) replacerLinkFn(vm, el);
6600
+      }, vm);
6601
+
6602
+      // return the unlink function that tearsdown context
6603
+      // container directives.
6604
+      return makeUnlinkFn(vm, selfDirs, context, contextDirs);
6605
+    };
6606
+  }
6607
+
6608
+  /**
6609
+   * Compile a node and return a nodeLinkFn based on the
6610
+   * node type.
6611
+   *
6612
+   * @param {Node} node
6613
+   * @param {Object} options
6614
+   * @return {Function|null}
6615
+   */
6616
+
6617
+  function compileNode(node, options) {
6618
+    var type = node.nodeType;
6619
+    if (type === 1 && node.tagName !== 'SCRIPT') {
6620
+      return compileElement(node, options);
6621
+    } else if (type === 3 && node.data.trim()) {
6622
+      return compileTextNode(node, options);
6623
+    } else {
6624
+      return null;
6625
+    }
6626
+  }
6627
+
6628
+  /**
6629
+   * Compile an element and return a nodeLinkFn.
6630
+   *
6631
+   * @param {Element} el
6632
+   * @param {Object} options
6633
+   * @return {Function|null}
6634
+   */
6635
+
6636
+  function compileElement(el, options) {
6637
+    // preprocess textareas.
6638
+    // textarea treats its text content as the initial value.
6639
+    // just bind it as an attr directive for value.
6640
+    if (el.tagName === 'TEXTAREA') {
6641
+      var tokens = parseText(el.value);
6642
+      if (tokens) {
6643
+        el.setAttribute(':value', tokensToExp(tokens));
6644
+        el.value = '';
6645
+      }
6646
+    }
6647
+    var linkFn;
6648
+    var hasAttrs = el.hasAttributes();
6649
+    // check terminal directives (for & if)
6650
+    if (hasAttrs) {
6651
+      linkFn = checkTerminalDirectives(el, options);
6652
+    }
6653
+    // check element directives
6654
+    if (!linkFn) {
6655
+      linkFn = checkElementDirectives(el, options);
6656
+    }
6657
+    // check component
6658
+    if (!linkFn) {
6659
+      linkFn = checkComponent(el, options);
6660
+    }
6661
+    // normal directives
6662
+    if (!linkFn && hasAttrs) {
6663
+      linkFn = compileDirectives(el.attributes, options);
6664
+    }
6665
+    return linkFn;
6666
+  }
6667
+
6668
+  /**
6669
+   * Compile a textNode and return a nodeLinkFn.
6670
+   *
6671
+   * @param {TextNode} node
6672
+   * @param {Object} options
6673
+   * @return {Function|null} textNodeLinkFn
6674
+   */
6675
+
6676
+  function compileTextNode(node, options) {
6677
+    // skip marked text nodes
6678
+    if (node._skip) {
6679
+      return removeText;
6680
+    }
6681
+
6682
+    var tokens = parseText(node.wholeText);
6683
+    if (!tokens) {
6684
+      return null;
6685
+    }
6686
+
6687
+    // mark adjacent text nodes as skipped,
6688
+    // because we are using node.wholeText to compile
6689
+    // all adjacent text nodes together. This fixes
6690
+    // issues in IE where sometimes it splits up a single
6691
+    // text node into multiple ones.
6692
+    var next = node.nextSibling;
6693
+    while (next && next.nodeType === 3) {
6694
+      next._skip = true;
6695
+      next = next.nextSibling;
6696
+    }
6697
+
6698
+    var frag = document.createDocumentFragment();
6699
+    var el, token;
6700
+    for (var i = 0, l = tokens.length; i < l; i++) {
6701
+      token = tokens[i];
6702
+      el = token.tag ? processTextToken(token, options) : document.createTextNode(token.value);
6703
+      frag.appendChild(el);
6704
+    }
6705
+    return makeTextNodeLinkFn(tokens, frag, options);
6706
+  }
6707
+
6708
+  /**
6709
+   * Linker for an skipped text node.
6710
+   *
6711
+   * @param {Vue} vm
6712
+   * @param {Text} node
6713
+   */
6714
+
6715
+  function removeText(vm, node) {
6716
+    remove(node);
6717
+  }
6718
+
6719
+  /**
6720
+   * Process a single text token.
6721
+   *
6722
+   * @param {Object} token
6723
+   * @param {Object} options
6724
+   * @return {Node}
6725
+   */
6726
+
6727
+  function processTextToken(token, options) {
6728
+    var el;
6729
+    if (token.oneTime) {
6730
+      el = document.createTextNode(token.value);
6731
+    } else {
6732
+      if (token.html) {
6733
+        el = document.createComment('v-html');
6734
+        setTokenType('html');
6735
+      } else {
6736
+        // IE will clean up empty textNodes during
6737
+        // frag.cloneNode(true), so we have to give it
6738
+        // something here...
6739
+        el = document.createTextNode(' ');
6740
+        setTokenType('text');
6741
+      }
6742
+    }
6743
+    function setTokenType(type) {
6744
+      if (token.descriptor) return;
6745
+      var parsed = parseDirective(token.value);
6746
+      token.descriptor = {
6747
+        name: type,
6748
+        def: publicDirectives[type],
6749
+        expression: parsed.expression,
6750
+        filters: parsed.filters
6751
+      };
6752
+    }
6753
+    return el;
6754
+  }
6755
+
6756
+  /**
6757
+   * Build a function that processes a textNode.
6758
+   *
6759
+   * @param {Array<Object>} tokens
6760
+   * @param {DocumentFragment} frag
6761
+   */
6762
+
6763
+  function makeTextNodeLinkFn(tokens, frag) {
6764
+    return function textNodeLinkFn(vm, el, host, scope) {
6765
+      var fragClone = frag.cloneNode(true);
6766
+      var childNodes = toArray(fragClone.childNodes);
6767
+      var token, value, node;
6768
+      for (var i = 0, l = tokens.length; i < l; i++) {
6769
+        token = tokens[i];
6770
+        value = token.value;
6771
+        if (token.tag) {
6772
+          node = childNodes[i];
6773
+          if (token.oneTime) {
6774
+            value = (scope || vm).$eval(value);
6775
+            if (token.html) {
6776
+              replace(node, parseTemplate(value, true));
6777
+            } else {
6778
+              node.data = value;
6779
+            }
6780
+          } else {
6781
+            vm._bindDir(token.descriptor, node, host, scope);
6782
+          }
6783
+        }
6784
+      }
6785
+      replace(el, fragClone);
6786
+    };
6787
+  }
6788
+
6789
+  /**
6790
+   * Compile a node list and return a childLinkFn.
6791
+   *
6792
+   * @param {NodeList} nodeList
6793
+   * @param {Object} options
6794
+   * @return {Function|undefined}
6795
+   */
6796
+
6797
+  function compileNodeList(nodeList, options) {
6798
+    var linkFns = [];
6799
+    var nodeLinkFn, childLinkFn, node;
6800
+    for (var i = 0, l = nodeList.length; i < l; i++) {
6801
+      node = nodeList[i];
6802
+      nodeLinkFn = compileNode(node, options);
6803
+      childLinkFn = !(nodeLinkFn && nodeLinkFn.terminal) && node.tagName !== 'SCRIPT' && node.hasChildNodes() ? compileNodeList(node.childNodes, options) : null;
6804
+      linkFns.push(nodeLinkFn, childLinkFn);
6805
+    }
6806
+    return linkFns.length ? makeChildLinkFn(linkFns) : null;
6807
+  }
6808
+
6809
+  /**
6810
+   * Make a child link function for a node's childNodes.
6811
+   *
6812
+   * @param {Array<Function>} linkFns
6813
+   * @return {Function} childLinkFn
6814
+   */
6815
+
6816
+  function makeChildLinkFn(linkFns) {
6817
+    return function childLinkFn(vm, nodes, host, scope, frag) {
6818
+      var node, nodeLinkFn, childrenLinkFn;
6819
+      for (var i = 0, n = 0, l = linkFns.length; i < l; n++) {
6820
+        node = nodes[n];
6821
+        nodeLinkFn = linkFns[i++];
6822
+        childrenLinkFn = linkFns[i++];
6823
+        // cache childNodes before linking parent, fix #657
6824
+        var childNodes = toArray(node.childNodes);
6825
+        if (nodeLinkFn) {
6826
+          nodeLinkFn(vm, node, host, scope, frag);
6827
+        }
6828
+        if (childrenLinkFn) {
6829
+          childrenLinkFn(vm, childNodes, host, scope, frag);
6830
+        }
6831
+      }
6832
+    };
6833
+  }
6834
+
6835
+  /**
6836
+   * Check for element directives (custom elements that should
6837
+   * be resovled as terminal directives).
6838
+   *
6839
+   * @param {Element} el
6840
+   * @param {Object} options
6841
+   */
6842
+
6843
+  function checkElementDirectives(el, options) {
6844
+    var tag = el.tagName.toLowerCase();
6845
+    if (commonTagRE.test(tag)) return;
6846
+    // special case: give named slot a higher priority
6847
+    // than unnamed slots
6848
+    if (tag === 'slot' && hasBindAttr(el, 'name')) {
6849
+      tag = '_namedSlot';
6850
+    }
6851
+    var def = resolveAsset(options, 'elementDirectives', tag);
6852
+    if (def) {
6853
+      return makeTerminalNodeLinkFn(el, tag, '', options, def);
6854
+    }
6855
+  }
6856
+
6857
+  /**
6858
+   * Check if an element is a component. If yes, return
6859
+   * a component link function.
6860
+   *
6861
+   * @param {Element} el
6862
+   * @param {Object} options
6863
+   * @return {Function|undefined}
6864
+   */
6865
+
6866
+  function checkComponent(el, options) {
6867
+    var component = checkComponentAttr(el, options);
6868
+    if (component) {
6869
+      var ref = findRef(el);
6870
+      var descriptor = {
6871
+        name: 'component',
6872
+        ref: ref,
6873
+        expression: component.id,
6874
+        def: internalDirectives.component,
6875
+        modifiers: {
6876
+          literal: !component.dynamic
6877
+        }
6878
+      };
6879
+      var componentLinkFn = function componentLinkFn(vm, el, host, scope, frag) {
6880
+        if (ref) {
6881
+          defineReactive((scope || vm).$refs, ref, null);
6882
+        }
6883
+        vm._bindDir(descriptor, el, host, scope, frag);
6884
+      };
6885
+      componentLinkFn.terminal = true;
6886
+      return componentLinkFn;
6887
+    }
6888
+  }
6889
+
6890
+  /**
6891
+   * Check an element for terminal directives in fixed order.
6892
+   * If it finds one, return a terminal link function.
6893
+   *
6894
+   * @param {Element} el
6895
+   * @param {Object} options
6896
+   * @return {Function} terminalLinkFn
6897
+   */
6898
+
6899
+  function checkTerminalDirectives(el, options) {
6900
+    // skip v-pre
6901
+    if (getAttr(el, 'v-pre') !== null) {
6902
+      return skip;
6903
+    }
6904
+    // skip v-else block, but only if following v-if
6905
+    if (el.hasAttribute('v-else')) {
6906
+      var prev = el.previousElementSibling;
6907
+      if (prev && prev.hasAttribute('v-if')) {
6908
+        return skip;
6909
+      }
6910
+    }
6911
+    var value, dirName;
6912
+    for (var i = 0, l = terminalDirectives.length; i < l; i++) {
6913
+      dirName = terminalDirectives[i];
6914
+      value = el.getAttribute('v-' + dirName);
6915
+      if (value != null) {
6916
+        return makeTerminalNodeLinkFn(el, dirName, value, options);
6917
+      }
6918
+    }
6919
+  }
6920
+
6921
+  function skip() {}
6922
+  skip.terminal = true;
6923
+
6924
+  /**
6925
+   * Build a node link function for a terminal directive.
6926
+   * A terminal link function terminates the current
6927
+   * compilation recursion and handles compilation of the
6928
+   * subtree in the directive.
6929
+   *
6930
+   * @param {Element} el
6931
+   * @param {String} dirName
6932
+   * @param {String} value
6933
+   * @param {Object} options
6934
+   * @param {Object} [def]
6935
+   * @return {Function} terminalLinkFn
6936
+   */
6937
+
6938
+  function makeTerminalNodeLinkFn(el, dirName, value, options, def) {
6939
+    var parsed = parseDirective(value);
6940
+    var descriptor = {
6941
+      name: dirName,
6942
+      expression: parsed.expression,
6943
+      filters: parsed.filters,
6944
+      raw: value,
6945
+      // either an element directive, or if/for
6946
+      def: def || publicDirectives[dirName]
6947
+    };
6948
+    // check ref for v-for and router-view
6949
+    if (dirName === 'for' || dirName === 'router-view') {
6950
+      descriptor.ref = findRef(el);
6951
+    }
6952
+    var fn = function terminalNodeLinkFn(vm, el, host, scope, frag) {
6953
+      if (descriptor.ref) {
6954
+        defineReactive((scope || vm).$refs, descriptor.ref, null);
6955
+      }
6956
+      vm._bindDir(descriptor, el, host, scope, frag);
6957
+    };
6958
+    fn.terminal = true;
6959
+    return fn;
6960
+  }
6961
+
6962
+  /**
6963
+   * Compile the directives on an element and return a linker.
6964
+   *
6965
+   * @param {Array|NamedNodeMap} attrs
6966
+   * @param {Object} options
6967
+   * @return {Function}
6968
+   */
6969
+
6970
+  function compileDirectives(attrs, options) {
6971
+    var i = attrs.length;
6972
+    var dirs = [];
6973
+    var attr, name, value, rawName, rawValue, dirName, arg, modifiers, dirDef, tokens;
6974
+    while (i--) {
6975
+      attr = attrs[i];
6976
+      name = rawName = attr.name;
6977
+      value = rawValue = attr.value;
6978
+      tokens = parseText(value);
6979
+      // reset arg
6980
+      arg = null;
6981
+      // check modifiers
6982
+      modifiers = parseModifiers(name);
6983
+      name = name.replace(modifierRE, '');
6984
+
6985
+      // attribute interpolations
6986
+      if (tokens) {
6987
+        value = tokensToExp(tokens);
6988
+        arg = name;
6989
+        pushDir('bind', publicDirectives.bind, tokens);
6990
+        // warn against mixing mustaches with v-bind
6991
+        if ('development' !== 'production') {
6992
+          if (name === 'class' && Array.prototype.some.call(attrs, function (attr) {
6993
+            return attr.name === ':class' || attr.name === 'v-bind:class';
6994
+          })) {
6995
+            warn('class="' + rawValue + '": Do not mix mustache interpolation ' + 'and v-bind for "class" on the same element. Use one or the other.');
6996
+          }
6997
+        }
6998
+      } else
6999
+
7000
+        // special attribute: transition
7001
+        if (transitionRE.test(name)) {
7002
+          modifiers.literal = !bindRE.test(name);
7003
+          pushDir('transition', internalDirectives.transition);
7004
+        } else
7005
+
7006
+          // event handlers
7007
+          if (onRE.test(name)) {
7008
+            arg = name.replace(onRE, '');
7009
+            pushDir('on', publicDirectives.on);
7010
+          } else
7011
+
7012
+            // attribute bindings
7013
+            if (bindRE.test(name)) {
7014
+              dirName = name.replace(bindRE, '');
7015
+              if (dirName === 'style' || dirName === 'class') {
7016
+                pushDir(dirName, internalDirectives[dirName]);
7017
+              } else {
7018
+                arg = dirName;
7019
+                pushDir('bind', publicDirectives.bind);
7020
+              }
7021
+            } else
7022
+
7023
+              // normal directives
7024
+              if (name.indexOf('v-') === 0) {
7025
+                // check arg
7026
+                arg = (arg = name.match(argRE)) && arg[1];
7027
+                if (arg) {
7028
+                  name = name.replace(argRE, '');
7029
+                }
7030
+                // extract directive name
7031
+                dirName = name.slice(2);
7032
+
7033
+                // skip v-else (when used with v-show)
7034
+                if (dirName === 'else') {
7035
+                  continue;
7036
+                }
7037
+
7038
+                dirDef = resolveAsset(options, 'directives', dirName);
7039
+
7040
+                if ('development' !== 'production') {
7041
+                  assertAsset(dirDef, 'directive', dirName);
7042
+                }
7043
+
7044
+                if (dirDef) {
7045
+                  pushDir(dirName, dirDef);
7046
+                }
7047
+              }
7048
+    }
7049
+
7050
+    /**
7051
+     * Push a directive.
7052
+     *
7053
+     * @param {String} dirName
7054
+     * @param {Object|Function} def
7055
+     * @param {Array} [interpTokens]
7056
+     */
7057
+
7058
+    function pushDir(dirName, def, interpTokens) {
7059
+      var hasOneTimeToken = interpTokens && hasOneTime(interpTokens);
7060
+      var parsed = !hasOneTimeToken && parseDirective(value);
7061
+      dirs.push({
7062
+        name: dirName,
7063
+        attr: rawName,
7064
+        raw: rawValue,
7065
+        def: def,
7066
+        arg: arg,
7067
+        modifiers: modifiers,
7068
+        // conversion from interpolation strings with one-time token
7069
+        // to expression is differed until directive bind time so that we
7070
+        // have access to the actual vm context for one-time bindings.
7071
+        expression: parsed && parsed.expression,
7072
+        filters: parsed && parsed.filters,
7073
+        interp: interpTokens,
7074
+        hasOneTime: hasOneTimeToken
7075
+      });
7076
+    }
7077
+
7078
+    if (dirs.length) {
7079
+      return makeNodeLinkFn(dirs);
7080
+    }
7081
+  }
7082
+
7083
+  /**
7084
+   * Parse modifiers from directive attribute name.
7085
+   *
7086
+   * @param {String} name
7087
+   * @return {Object}
7088
+   */
7089
+
7090
+  function parseModifiers(name) {
7091
+    var res = Object.create(null);
7092
+    var match = name.match(modifierRE);
7093
+    if (match) {
7094
+      var i = match.length;
7095
+      while (i--) {
7096
+        res[match[i].slice(1)] = true;
7097
+      }
7098
+    }
7099
+    return res;
7100
+  }
7101
+
7102
+  /**
7103
+   * Build a link function for all directives on a single node.
7104
+   *
7105
+   * @param {Array} directives
7106
+   * @return {Function} directivesLinkFn
7107
+   */
7108
+
7109
+  function makeNodeLinkFn(directives) {
7110
+    return function nodeLinkFn(vm, el, host, scope, frag) {
7111
+      // reverse apply because it's sorted low to high
7112
+      var i = directives.length;
7113
+      while (i--) {
7114
+        vm._bindDir(directives[i], el, host, scope, frag);
7115
+      }
7116
+    };
7117
+  }
7118
+
7119
+  /**
7120
+   * Check if an interpolation string contains one-time tokens.
7121
+   *
7122
+   * @param {Array} tokens
7123
+   * @return {Boolean}
7124
+   */
7125
+
7126
+  function hasOneTime(tokens) {
7127
+    var i = tokens.length;
7128
+    while (i--) {
7129
+      if (tokens[i].oneTime) return true;
7130
+    }
7131
+  }
7132
+
7133
+  var specialCharRE = /[^\w\-:\.]/;
7134
+
7135
+  /**
7136
+   * Process an element or a DocumentFragment based on a
7137
+   * instance option object. This allows us to transclude
7138
+   * a template node/fragment before the instance is created,
7139
+   * so the processed fragment can then be cloned and reused
7140
+   * in v-for.
7141
+   *
7142
+   * @param {Element} el
7143
+   * @param {Object} options
7144
+   * @return {Element|DocumentFragment}
7145
+   */
7146
+
7147
+  function transclude(el, options) {
7148
+    // extract container attributes to pass them down
7149
+    // to compiler, because they need to be compiled in
7150
+    // parent scope. we are mutating the options object here
7151
+    // assuming the same object will be used for compile
7152
+    // right after this.
7153
+    if (options) {
7154
+      options._containerAttrs = extractAttrs(el);
7155
+    }
7156
+    // for template tags, what we want is its content as
7157
+    // a documentFragment (for fragment instances)
7158
+    if (isTemplate(el)) {
7159
+      el = parseTemplate(el);
7160
+    }
7161
+    if (options) {
7162
+      if (options._asComponent && !options.template) {
7163
+        options.template = '<slot></slot>';
7164
+      }
7165
+      if (options.template) {
7166
+        options._content = extractContent(el);
7167
+        el = transcludeTemplate(el, options);
7168
+      }
7169
+    }
7170
+    if (el instanceof DocumentFragment) {
7171
+      // anchors for fragment instance
7172
+      // passing in `persist: true` to avoid them being
7173
+      // discarded by IE during template cloning
7174
+      prepend(createAnchor('v-start', true), el);
7175
+      el.appendChild(createAnchor('v-end', true));
7176
+    }
7177
+    return el;
7178
+  }
7179
+
7180
+  /**
7181
+   * Process the template option.
7182
+   * If the replace option is true this will swap the $el.
7183
+   *
7184
+   * @param {Element} el
7185
+   * @param {Object} options
7186
+   * @return {Element|DocumentFragment}
7187
+   */
7188
+
7189
+  function transcludeTemplate(el, options) {
7190
+    var template = options.template;
7191
+    var frag = parseTemplate(template, true);
7192
+    if (frag) {
7193
+      var replacer = frag.firstChild;
7194
+      var tag = replacer.tagName && replacer.tagName.toLowerCase();
7195
+      if (options.replace) {
7196
+        /* istanbul ignore if */
7197
+        if (el === document.body) {
7198
+          'development' !== 'production' && warn('You are mounting an instance with a template to ' + '<body>. This will replace <body> entirely. You ' + 'should probably use `replace: false` here.');
7199
+        }
7200
+        // there are many cases where the instance must
7201
+        // become a fragment instance: basically anything that
7202
+        // can create more than 1 root nodes.
7203
+        if (
7204
+        // multi-children template
7205
+        frag.childNodes.length > 1 ||
7206
+        // non-element template
7207
+        replacer.nodeType !== 1 ||
7208
+        // single nested component
7209
+        tag === 'component' || resolveAsset(options, 'components', tag) || hasBindAttr(replacer, 'is') ||
7210
+        // element directive
7211
+        resolveAsset(options, 'elementDirectives', tag) ||
7212
+        // for block
7213
+        replacer.hasAttribute('v-for') ||
7214
+        // if block
7215
+        replacer.hasAttribute('v-if')) {
7216
+          return frag;
7217
+        } else {
7218
+          options._replacerAttrs = extractAttrs(replacer);
7219
+          mergeAttrs(el, replacer);
7220
+          return replacer;
7221
+        }
7222
+      } else {
7223
+        el.appendChild(frag);
7224
+        return el;
7225
+      }
7226
+    } else {
7227
+      'development' !== 'production' && warn('Invalid template option: ' + template);
7228
+    }
7229
+  }
7230
+
7231
+  /**
7232
+   * Helper to extract a component container's attributes
7233
+   * into a plain object array.
7234
+   *
7235
+   * @param {Element} el
7236
+   * @return {Array}
7237
+   */
7238
+
7239
+  function extractAttrs(el) {
7240
+    if (el.nodeType === 1 && el.hasAttributes()) {
7241
+      return toArray(el.attributes);
7242
+    }
7243
+  }
7244
+
7245
+  /**
7246
+   * Merge the attributes of two elements, and make sure
7247
+   * the class names are merged properly.
7248
+   *
7249
+   * @param {Element} from
7250
+   * @param {Element} to
7251
+   */
7252
+
7253
+  function mergeAttrs(from, to) {
7254
+    var attrs = from.attributes;
7255
+    var i = attrs.length;
7256
+    var name, value;
7257
+    while (i--) {
7258
+      name = attrs[i].name;
7259
+      value = attrs[i].value;
7260
+      if (!to.hasAttribute(name) && !specialCharRE.test(name)) {
7261
+        to.setAttribute(name, value);
7262
+      } else if (name === 'class' && !parseText(value)) {
7263
+        value.split(/\s+/).forEach(function (cls) {
7264
+          addClass(to, cls);
7265
+        });
7266
+      }
7267
+    }
7268
+  }
7269
+
7270
+  var compiler = Object.freeze({
7271
+  	compile: compile,
7272
+  	compileAndLinkProps: compileAndLinkProps,
7273
+  	compileRoot: compileRoot,
7274
+  	terminalDirectives: terminalDirectives,
7275
+  	transclude: transclude
7276
+  });
7277
+
7278
+  function stateMixin (Vue) {
7279
+
7280
+    /**
7281
+     * Accessor for `$data` property, since setting $data
7282
+     * requires observing the new object and updating
7283
+     * proxied properties.
7284
+     */
7285
+
7286
+    Object.defineProperty(Vue.prototype, '$data', {
7287
+      get: function get() {
7288
+        return this._data;
7289
+      },
7290
+      set: function set(newData) {
7291
+        if (newData !== this._data) {
7292
+          this._setData(newData);
7293
+        }
7294
+      }
7295
+    });
7296
+
7297
+    /**
7298
+     * Setup the scope of an instance, which contains:
7299
+     * - observed data
7300
+     * - computed properties
7301
+     * - user methods
7302
+     * - meta properties
7303
+     */
7304
+
7305
+    Vue.prototype._initState = function () {
7306
+      this._initProps();
7307
+      this._initMeta();
7308
+      this._initMethods();
7309
+      this._initData();
7310
+      this._initComputed();
7311
+    };
7312
+
7313
+    /**
7314
+     * Initialize props.
7315
+     */
7316
+
7317
+    Vue.prototype._initProps = function () {
7318
+      var options = this.$options;
7319
+      var el = options.el;
7320
+      var props = options.props;
7321
+      if (props && !el) {
7322
+        'development' !== 'production' && warn('Props will not be compiled if no `el` option is ' + 'provided at instantiation.');
7323
+      }
7324
+      // make sure to convert string selectors into element now
7325
+      el = options.el = query(el);
7326
+      this._propsUnlinkFn = el && el.nodeType === 1 && props
7327
+      // props must be linked in proper scope if inside v-for
7328
+      ? compileAndLinkProps(this, el, props, this._scope) : null;
7329
+    };
7330
+
7331
+    /**
7332
+     * Initialize the data.
7333
+     */
7334
+
7335
+    Vue.prototype._initData = function () {
7336
+      var propsData = this._data;
7337
+      var optionsDataFn = this.$options.data;
7338
+      var optionsData = optionsDataFn && optionsDataFn();
7339
+      if (optionsData) {
7340
+        this._data = optionsData;
7341
+        for (var prop in propsData) {
7342
+          if ('development' !== 'production' && hasOwn(optionsData, prop)) {
7343
+            warn('Data field "' + prop + '" is already defined ' + 'as a prop. Use prop default value instead.');
7344
+          }
7345
+          if (this._props[prop].raw !== null || !hasOwn(optionsData, prop)) {
7346
+            set(optionsData, prop, propsData[prop]);
7347
+          }
7348
+        }
7349
+      }
7350
+      var data = this._data;
7351
+      // proxy data on instance
7352
+      var keys = Object.keys(data);
7353
+      var i, key;
7354
+      i = keys.length;
7355
+      while (i--) {
7356
+        key = keys[i];
7357
+        this._proxy(key);
7358
+      }
7359
+      // observe data
7360
+      observe(data, this);
7361
+    };
7362
+
7363
+    /**
7364
+     * Swap the instance's $data. Called in $data's setter.
7365
+     *
7366
+     * @param {Object} newData
7367
+     */
7368
+
7369
+    Vue.prototype._setData = function (newData) {
7370
+      newData = newData || {};
7371
+      var oldData = this._data;
7372
+      this._data = newData;
7373
+      var keys, key, i;
7374
+      // unproxy keys not present in new data
7375
+      keys = Object.keys(oldData);
7376
+      i = keys.length;
7377
+      while (i--) {
7378
+        key = keys[i];
7379
+        if (!(key in newData)) {
7380
+          this._unproxy(key);
7381
+        }
7382
+      }
7383
+      // proxy keys not already proxied,
7384
+      // and trigger change for changed values
7385
+      keys = Object.keys(newData);
7386
+      i = keys.length;
7387
+      while (i--) {
7388
+        key = keys[i];
7389
+        if (!hasOwn(this, key)) {
7390
+          // new property
7391
+          this._proxy(key);
7392
+        }
7393
+      }
7394
+      oldData.__ob__.removeVm(this);
7395
+      observe(newData, this);
7396
+      this._digest();
7397
+    };
7398
+
7399
+    /**
7400
+     * Proxy a property, so that
7401
+     * vm.prop === vm._data.prop
7402
+     *
7403
+     * @param {String} key
7404
+     */
7405
+
7406
+    Vue.prototype._proxy = function (key) {
7407
+      if (!isReserved(key)) {
7408
+        // need to store ref to self here
7409
+        // because these getter/setters might
7410
+        // be called by child scopes via
7411
+        // prototype inheritance.
7412
+        var self = this;
7413
+        Object.defineProperty(self, key, {
7414
+          configurable: true,
7415
+          enumerable: true,
7416
+          get: function proxyGetter() {
7417
+            return self._data[key];
7418
+          },
7419
+          set: function proxySetter(val) {
7420
+            self._data[key] = val;
7421
+          }
7422
+        });
7423
+      }
7424
+    };
7425
+
7426
+    /**
7427
+     * Unproxy a property.
7428
+     *
7429
+     * @param {String} key
7430
+     */
7431
+
7432
+    Vue.prototype._unproxy = function (key) {
7433
+      if (!isReserved(key)) {
7434
+        delete this[key];
7435
+      }
7436
+    };
7437
+
7438
+    /**
7439
+     * Force update on every watcher in scope.
7440
+     */
7441
+
7442
+    Vue.prototype._digest = function () {
7443
+      for (var i = 0, l = this._watchers.length; i < l; i++) {
7444
+        this._watchers[i].update(true); // shallow updates
7445
+      }
7446
+    };
7447
+
7448
+    /**
7449
+     * Setup computed properties. They are essentially
7450
+     * special getter/setters
7451
+     */
7452
+
7453
+    function noop() {}
7454
+    Vue.prototype._initComputed = function () {
7455
+      var computed = this.$options.computed;
7456
+      if (computed) {
7457
+        for (var key in computed) {
7458
+          var userDef = computed[key];
7459
+          var def = {
7460
+            enumerable: true,
7461
+            configurable: true
7462
+          };
7463
+          if (typeof userDef === 'function') {
7464
+            def.get = makeComputedGetter(userDef, this);
7465
+            def.set = noop;
7466
+          } else {
7467
+            def.get = userDef.get ? userDef.cache !== false ? makeComputedGetter(userDef.get, this) : bind$1(userDef.get, this) : noop;
7468
+            def.set = userDef.set ? bind$1(userDef.set, this) : noop;
7469
+          }
7470
+          Object.defineProperty(this, key, def);
7471
+        }
7472
+      }
7473
+    };
7474
+
7475
+    function makeComputedGetter(getter, owner) {
7476
+      var watcher = new Watcher(owner, getter, null, {
7477
+        lazy: true
7478
+      });
7479
+      return function computedGetter() {
7480
+        if (watcher.dirty) {
7481
+          watcher.evaluate();
7482
+        }
7483
+        if (Dep.target) {
7484
+          watcher.depend();
7485
+        }
7486
+        return watcher.value;
7487
+      };
7488
+    }
7489
+
7490
+    /**
7491
+     * Setup instance methods. Methods must be bound to the
7492
+     * instance since they might be passed down as a prop to
7493
+     * child components.
7494
+     */
7495
+
7496
+    Vue.prototype._initMethods = function () {
7497
+      var methods = this.$options.methods;
7498
+      if (methods) {
7499
+        for (var key in methods) {
7500
+          this[key] = bind$1(methods[key], this);
7501
+        }
7502
+      }
7503
+    };
7504
+
7505
+    /**
7506
+     * Initialize meta information like $index, $key & $value.
7507
+     */
7508
+
7509
+    Vue.prototype._initMeta = function () {
7510
+      var metas = this.$options._meta;
7511
+      if (metas) {
7512
+        for (var key in metas) {
7513
+          defineReactive(this, key, metas[key]);
7514
+        }
7515
+      }
7516
+    };
7517
+  }
7518
+
7519
+  var eventRE = /^v-on:|^@/;
7520
+
7521
+  function eventsMixin (Vue) {
7522
+
7523
+    /**
7524
+     * Setup the instance's option events & watchers.
7525
+     * If the value is a string, we pull it from the
7526
+     * instance's methods by name.
7527
+     */
7528
+
7529
+    Vue.prototype._initEvents = function () {
7530
+      var options = this.$options;
7531
+      if (options._asComponent) {
7532
+        registerComponentEvents(this, options.el);
7533
+      }
7534
+      registerCallbacks(this, '$on', options.events);
7535
+      registerCallbacks(this, '$watch', options.watch);
7536
+    };
7537
+
7538
+    /**
7539
+     * Register v-on events on a child component
7540
+     *
7541
+     * @param {Vue} vm
7542
+     * @param {Element} el
7543
+     */
7544
+
7545
+    function registerComponentEvents(vm, el) {
7546
+      var attrs = el.attributes;
7547
+      var name, handler;
7548
+      for (var i = 0, l = attrs.length; i < l; i++) {
7549
+        name = attrs[i].name;
7550
+        if (eventRE.test(name)) {
7551
+          name = name.replace(eventRE, '');
7552
+          handler = (vm._scope || vm._context).$eval(attrs[i].value, true);
7553
+          handler._fromParent = true;
7554
+          vm.$on(name.replace(eventRE), handler);
7555
+        }
7556
+      }
7557
+    }
7558
+
7559
+    /**
7560
+     * Register callbacks for option events and watchers.
7561
+     *
7562
+     * @param {Vue} vm
7563
+     * @param {String} action
7564
+     * @param {Object} hash
7565
+     */
7566
+
7567
+    function registerCallbacks(vm, action, hash) {
7568
+      if (!hash) return;
7569
+      var handlers, key, i, j;
7570
+      for (key in hash) {
7571
+        handlers = hash[key];
7572
+        if (isArray(handlers)) {
7573
+          for (i = 0, j = handlers.length; i < j; i++) {
7574
+            register(vm, action, key, handlers[i]);
7575
+          }
7576
+        } else {
7577
+          register(vm, action, key, handlers);
7578
+        }
7579
+      }
7580
+    }
7581
+
7582
+    /**
7583
+     * Helper to register an event/watch callback.
7584
+     *
7585
+     * @param {Vue} vm
7586
+     * @param {String} action
7587
+     * @param {String} key
7588
+     * @param {Function|String|Object} handler
7589
+     * @param {Object} [options]
7590
+     */
7591
+
7592
+    function register(vm, action, key, handler, options) {
7593
+      var type = typeof handler;
7594
+      if (type === 'function') {
7595
+        vm[action](key, handler, options);
7596
+      } else if (type === 'string') {
7597
+        var methods = vm.$options.methods;
7598
+        var method = methods && methods[handler];
7599
+        if (method) {
7600
+          vm[action](key, method, options);
7601
+        } else {
7602
+          'development' !== 'production' && warn('Unknown method: "' + handler + '" when ' + 'registering callback for ' + action + ': "' + key + '".');
7603
+        }
7604
+      } else if (handler && type === 'object') {
7605
+        register(vm, action, key, handler.handler, handler);
7606
+      }
7607
+    }
7608
+
7609
+    /**
7610
+     * Setup recursive attached/detached calls
7611
+     */
7612
+
7613
+    Vue.prototype._initDOMHooks = function () {
7614
+      this.$on('hook:attached', onAttached);
7615
+      this.$on('hook:detached', onDetached);
7616
+    };
7617
+
7618
+    /**
7619
+     * Callback to recursively call attached hook on children
7620
+     */
7621
+
7622
+    function onAttached() {
7623
+      if (!this._isAttached) {
7624
+        this._isAttached = true;
7625
+        this.$children.forEach(callAttach);
7626
+      }
7627
+    }
7628
+
7629
+    /**
7630
+     * Iterator to call attached hook
7631
+     *
7632
+     * @param {Vue} child
7633
+     */
7634
+
7635
+    function callAttach(child) {
7636
+      if (!child._isAttached && inDoc(child.$el)) {
7637
+        child._callHook('attached');
7638
+      }
7639
+    }
7640
+
7641
+    /**
7642
+     * Callback to recursively call detached hook on children
7643
+     */
7644
+
7645
+    function onDetached() {
7646
+      if (this._isAttached) {
7647
+        this._isAttached = false;
7648
+        this.$children.forEach(callDetach);
7649
+      }
7650
+    }
7651
+
7652
+    /**
7653
+     * Iterator to call detached hook
7654
+     *
7655
+     * @param {Vue} child
7656
+     */
7657
+
7658
+    function callDetach(child) {
7659
+      if (child._isAttached && !inDoc(child.$el)) {
7660
+        child._callHook('detached');
7661
+      }
7662
+    }
7663
+
7664
+    /**
7665
+     * Trigger all handlers for a hook
7666
+     *
7667
+     * @param {String} hook
7668
+     */
7669
+
7670
+    Vue.prototype._callHook = function (hook) {
7671
+      this.$emit('pre-hook:' + hook);
7672
+      var handlers = this.$options[hook];
7673
+      if (handlers) {
7674
+        for (var i = 0, j = handlers.length; i < j; i++) {
7675
+          handlers[i].call(this);
7676
+        }
7677
+      }
7678
+      this.$emit('hook:' + hook);
7679
+    };
7680
+  }
7681
+
7682
+  function noop() {}
7683
+
7684
+  /**
7685
+   * A directive links a DOM element with a piece of data,
7686
+   * which is the result of evaluating an expression.
7687
+   * It registers a watcher with the expression and calls
7688
+   * the DOM update function when a change is triggered.
7689
+   *
7690
+   * @param {String} name
7691
+   * @param {Node} el
7692
+   * @param {Vue} vm
7693
+   * @param {Object} descriptor
7694
+   *                 - {String} name
7695
+   *                 - {Object} def
7696
+   *                 - {String} expression
7697
+   *                 - {Array<Object>} [filters]
7698
+   *                 - {Boolean} literal
7699
+   *                 - {String} attr
7700
+   *                 - {String} raw
7701
+   * @param {Object} def - directive definition object
7702
+   * @param {Vue} [host] - transclusion host component
7703
+   * @param {Object} [scope] - v-for scope
7704
+   * @param {Fragment} [frag] - owner fragment
7705
+   * @constructor
7706
+   */
7707
+  function Directive(descriptor, vm, el, host, scope, frag) {
7708
+    this.vm = vm;
7709
+    this.el = el;
7710
+    // copy descriptor properties
7711
+    this.descriptor = descriptor;
7712
+    this.name = descriptor.name;
7713
+    this.expression = descriptor.expression;
7714
+    this.arg = descriptor.arg;
7715
+    this.modifiers = descriptor.modifiers;
7716
+    this.filters = descriptor.filters;
7717
+    this.literal = this.modifiers && this.modifiers.literal;
7718
+    // private
7719
+    this._locked = false;
7720
+    this._bound = false;
7721
+    this._listeners = null;
7722
+    // link context
7723
+    this._host = host;
7724
+    this._scope = scope;
7725
+    this._frag = frag;
7726
+    // store directives on node in dev mode
7727
+    if ('development' !== 'production' && this.el) {
7728
+      this.el._vue_directives = this.el._vue_directives || [];
7729
+      this.el._vue_directives.push(this);
7730
+    }
7731
+  }
7732
+
7733
+  /**
7734
+   * Initialize the directive, mixin definition properties,
7735
+   * setup the watcher, call definition bind() and update()
7736
+   * if present.
7737
+   *
7738
+   * @param {Object} def
7739
+   */
7740
+
7741
+  Directive.prototype._bind = function () {
7742
+    var name = this.name;
7743
+    var descriptor = this.descriptor;
7744
+
7745
+    // remove attribute
7746
+    if ((name !== 'cloak' || this.vm._isCompiled) && this.el && this.el.removeAttribute) {
7747
+      var attr = descriptor.attr || 'v-' + name;
7748
+      this.el.removeAttribute(attr);
7749
+    }
7750
+
7751
+    // copy def properties
7752
+    var def = descriptor.def;
7753
+    if (typeof def === 'function') {
7754
+      this.update = def;
7755
+    } else {
7756
+      extend(this, def);
7757
+    }
7758
+
7759
+    // setup directive params
7760
+    this._setupParams();
7761
+
7762
+    // initial bind
7763
+    if (this.bind) {
7764
+      this.bind();
7765
+    }
7766
+    this._bound = true;
7767
+
7768
+    if (this.literal) {
7769
+      this.update && this.update(descriptor.raw);
7770
+    } else if ((this.expression || this.modifiers) && (this.update || this.twoWay) && !this._checkStatement()) {
7771
+      // wrapped updater for context
7772
+      var dir = this;
7773
+      if (this.update) {
7774
+        this._update = function (val, oldVal) {
7775
+          if (!dir._locked) {
7776
+            dir.update(val, oldVal);
7777
+          }
7778
+        };
7779
+      } else {
7780
+        this._update = noop;
7781
+      }
7782
+      var preProcess = this._preProcess ? bind$1(this._preProcess, this) : null;
7783
+      var postProcess = this._postProcess ? bind$1(this._postProcess, this) : null;
7784
+      var watcher = this._watcher = new Watcher(this.vm, this.expression, this._update, // callback
7785
+      {
7786
+        filters: this.filters,
7787
+        twoWay: this.twoWay,
7788
+        deep: this.deep,
7789
+        preProcess: preProcess,
7790
+        postProcess: postProcess,
7791
+        scope: this._scope
7792
+      });
7793
+      // v-model with inital inline value need to sync back to
7794
+      // model instead of update to DOM on init. They would
7795
+      // set the afterBind hook to indicate that.
7796
+      if (this.afterBind) {
7797
+        this.afterBind();
7798
+      } else if (this.update) {
7799
+        this.update(watcher.value);
7800
+      }
7801
+    }
7802
+  };
7803
+
7804
+  /**
7805
+   * Setup all param attributes, e.g. track-by,
7806
+   * transition-mode, etc...
7807
+   */
7808
+
7809
+  Directive.prototype._setupParams = function () {
7810
+    if (!this.params) {
7811
+      return;
7812
+    }
7813
+    var params = this.params;
7814
+    // swap the params array with a fresh object.
7815
+    this.params = Object.create(null);
7816
+    var i = params.length;
7817
+    var key, val, mappedKey;
7818
+    while (i--) {
7819
+      key = params[i];
7820
+      mappedKey = camelize(key);
7821
+      val = getBindAttr(this.el, key);
7822
+      if (val != null) {
7823
+        // dynamic
7824
+        this._setupParamWatcher(mappedKey, val);
7825
+      } else {
7826
+        // static
7827
+        val = getAttr(this.el, key);
7828
+        if (val != null) {
7829
+          this.params[mappedKey] = val === '' ? true : val;
7830
+        }
7831
+      }
7832
+    }
7833
+  };
7834
+
7835
+  /**
7836
+   * Setup a watcher for a dynamic param.
7837
+   *
7838
+   * @param {String} key
7839
+   * @param {String} expression
7840
+   */
7841
+
7842
+  Directive.prototype._setupParamWatcher = function (key, expression) {
7843
+    var self = this;
7844
+    var called = false;
7845
+    var unwatch = (this._scope || this.vm).$watch(expression, function (val, oldVal) {
7846
+      self.params[key] = val;
7847
+      // since we are in immediate mode,
7848
+      // only call the param change callbacks if this is not the first update.
7849
+      if (called) {
7850
+        var cb = self.paramWatchers && self.paramWatchers[key];
7851
+        if (cb) {
7852
+          cb.call(self, val, oldVal);
7853
+        }
7854
+      } else {
7855
+        called = true;
7856
+      }
7857
+    }, {
7858
+      immediate: true,
7859
+      user: false
7860
+    });(this._paramUnwatchFns || (this._paramUnwatchFns = [])).push(unwatch);
7861
+  };
7862
+
7863
+  /**
7864
+   * Check if the directive is a function caller
7865
+   * and if the expression is a callable one. If both true,
7866
+   * we wrap up the expression and use it as the event
7867
+   * handler.
7868
+   *
7869
+   * e.g. on-click="a++"
7870
+   *
7871
+   * @return {Boolean}
7872
+   */
7873
+
7874
+  Directive.prototype._checkStatement = function () {
7875
+    var expression = this.expression;
7876
+    if (expression && this.acceptStatement && !isSimplePath(expression)) {
7877
+      var fn = parseExpression(expression).get;
7878
+      var scope = this._scope || this.vm;
7879
+      var handler = function handler(e) {
7880
+        scope.$event = e;
7881
+        fn.call(scope, scope);
7882
+        scope.$event = null;
7883
+      };
7884
+      if (this.filters) {
7885
+        handler = scope._applyFilters(handler, null, this.filters);
7886
+      }
7887
+      this.update(handler);
7888
+      return true;
7889
+    }
7890
+  };
7891
+
7892
+  /**
7893
+   * Set the corresponding value with the setter.
7894
+   * This should only be used in two-way directives
7895
+   * e.g. v-model.
7896
+   *
7897
+   * @param {*} value
7898
+   * @public
7899
+   */
7900
+
7901
+  Directive.prototype.set = function (value) {
7902
+    /* istanbul ignore else */
7903
+    if (this.twoWay) {
7904
+      this._withLock(function () {
7905
+        this._watcher.set(value);
7906
+      });
7907
+    } else if ('development' !== 'production') {
7908
+      warn('Directive.set() can only be used inside twoWay' + 'directives.');
7909
+    }
7910
+  };
7911
+
7912
+  /**
7913
+   * Execute a function while preventing that function from
7914
+   * triggering updates on this directive instance.
7915
+   *
7916
+   * @param {Function} fn
7917
+   */
7918
+
7919
+  Directive.prototype._withLock = function (fn) {
7920
+    var self = this;
7921
+    self._locked = true;
7922
+    fn.call(self);
7923
+    nextTick(function () {
7924
+      self._locked = false;
7925
+    });
7926
+  };
7927
+
7928
+  /**
7929
+   * Convenience method that attaches a DOM event listener
7930
+   * to the directive element and autometically tears it down
7931
+   * during unbind.
7932
+   *
7933
+   * @param {String} event
7934
+   * @param {Function} handler
7935
+   */
7936
+
7937
+  Directive.prototype.on = function (event, handler) {
7938
+    on$1(this.el, event, handler);(this._listeners || (this._listeners = [])).push([event, handler]);
7939
+  };
7940
+
7941
+  /**
7942
+   * Teardown the watcher and call unbind.
7943
+   */
7944
+
7945
+  Directive.prototype._teardown = function () {
7946
+    if (this._bound) {
7947
+      this._bound = false;
7948
+      if (this.unbind) {
7949
+        this.unbind();
7950
+      }
7951
+      if (this._watcher) {
7952
+        this._watcher.teardown();
7953
+      }
7954
+      var listeners = this._listeners;
7955
+      var i;
7956
+      if (listeners) {
7957
+        i = listeners.length;
7958
+        while (i--) {
7959
+          off(this.el, listeners[i][0], listeners[i][1]);
7960
+        }
7961
+      }
7962
+      var unwatchFns = this._paramUnwatchFns;
7963
+      if (unwatchFns) {
7964
+        i = unwatchFns.length;
7965
+        while (i--) {
7966
+          unwatchFns[i]();
7967
+        }
7968
+      }
7969
+      if ('development' !== 'production' && this.el) {
7970
+        this.el._vue_directives.$remove(this);
7971
+      }
7972
+      this.vm = this.el = this._watcher = this._listeners = null;
7973
+    }
7974
+  };
7975
+
7976
+  function lifecycleMixin (Vue) {
7977
+
7978
+    /**
7979
+     * Update v-ref for component.
7980
+     *
7981
+     * @param {Boolean} remove
7982
+     */
7983
+
7984
+    Vue.prototype._updateRef = function (remove) {
7985
+      var ref = this.$options._ref;
7986
+      if (ref) {
7987
+        var refs = (this._scope || this._context).$refs;
7988
+        if (remove) {
7989
+          if (refs[ref] === this) {
7990
+            refs[ref] = null;
7991
+          }
7992
+        } else {
7993
+          refs[ref] = this;
7994
+        }
7995
+      }
7996
+    };
7997
+
7998
+    /**
7999
+     * Transclude, compile and link element.
8000
+     *
8001
+     * If a pre-compiled linker is available, that means the
8002
+     * passed in element will be pre-transcluded and compiled
8003
+     * as well - all we need to do is to call the linker.
8004
+     *
8005
+     * Otherwise we need to call transclude/compile/link here.
8006
+     *
8007
+     * @param {Element} el
8008
+     * @return {Element}
8009
+     */
8010
+
8011
+    Vue.prototype._compile = function (el) {
8012
+      var options = this.$options;
8013
+
8014
+      // transclude and init element
8015
+      // transclude can potentially replace original
8016
+      // so we need to keep reference; this step also injects
8017
+      // the template and caches the original attributes
8018
+      // on the container node and replacer node.
8019
+      var original = el;
8020
+      el = transclude(el, options);
8021
+      this._initElement(el);
8022
+
8023
+      // handle v-pre on root node (#2026)
8024
+      if (el.nodeType === 1 && getAttr(el, 'v-pre') !== null) {
8025
+        return;
8026
+      }
8027
+
8028
+      // root is always compiled per-instance, because
8029
+      // container attrs and props can be different every time.
8030
+      var contextOptions = this._context && this._context.$options;
8031
+      var rootLinker = compileRoot(el, options, contextOptions);
8032
+
8033
+      // compile and link the rest
8034
+      var contentLinkFn;
8035
+      var ctor = this.constructor;
8036
+      // component compilation can be cached
8037
+      // as long as it's not using inline-template
8038
+      if (options._linkerCachable) {
8039
+        contentLinkFn = ctor.linker;
8040
+        if (!contentLinkFn) {
8041
+          contentLinkFn = ctor.linker = compile(el, options);
8042
+        }
8043
+      }
8044
+
8045
+      // link phase
8046
+      // make sure to link root with prop scope!
8047
+      var rootUnlinkFn = rootLinker(this, el, this._scope);
8048
+      var contentUnlinkFn = contentLinkFn ? contentLinkFn(this, el) : compile(el, options)(this, el);
8049
+
8050
+      // register composite unlink function
8051
+      // to be called during instance destruction
8052
+      this._unlinkFn = function () {
8053
+        rootUnlinkFn();
8054
+        // passing destroying: true to avoid searching and
8055
+        // splicing the directives
8056
+        contentUnlinkFn(true);
8057
+      };
8058
+
8059
+      // finally replace original
8060
+      if (options.replace) {
8061
+        replace(original, el);
8062
+      }
8063
+
8064
+      this._isCompiled = true;
8065
+      this._callHook('compiled');
8066
+      return el;
8067
+    };
8068
+
8069
+    /**
8070
+     * Initialize instance element. Called in the public
8071
+     * $mount() method.
8072
+     *
8073
+     * @param {Element} el
8074
+     */
8075
+
8076
+    Vue.prototype._initElement = function (el) {
8077
+      if (el instanceof DocumentFragment) {
8078
+        this._isFragment = true;
8079
+        this.$el = this._fragmentStart = el.firstChild;
8080
+        this._fragmentEnd = el.lastChild;
8081
+        // set persisted text anchors to empty
8082
+        if (this._fragmentStart.nodeType === 3) {
8083
+          this._fragmentStart.data = this._fragmentEnd.data = '';
8084
+        }
8085
+        this._fragment = el;
8086
+      } else {
8087
+        this.$el = el;
8088
+      }
8089
+      this.$el.__vue__ = this;
8090
+      this._callHook('beforeCompile');
8091
+    };
8092
+
8093
+    /**
8094
+     * Create and bind a directive to an element.
8095
+     *
8096
+     * @param {String} name - directive name
8097
+     * @param {Node} node   - target node
8098
+     * @param {Object} desc - parsed directive descriptor
8099
+     * @param {Object} def  - directive definition object
8100
+     * @param {Vue} [host] - transclusion host component
8101
+     * @param {Object} [scope] - v-for scope
8102
+     * @param {Fragment} [frag] - owner fragment
8103
+     */
8104
+
8105
+    Vue.prototype._bindDir = function (descriptor, node, host, scope, frag) {
8106
+      this._directives.push(new Directive(descriptor, this, node, host, scope, frag));
8107
+    };
8108
+
8109
+    /**
8110
+     * Teardown an instance, unobserves the data, unbind all the
8111
+     * directives, turn off all the event listeners, etc.
8112
+     *
8113
+     * @param {Boolean} remove - whether to remove the DOM node.
8114
+     * @param {Boolean} deferCleanup - if true, defer cleanup to
8115
+     *                                 be called later
8116
+     */
8117
+
8118
+    Vue.prototype._destroy = function (remove, deferCleanup) {
8119
+      if (this._isBeingDestroyed) {
8120
+        if (!deferCleanup) {
8121
+          this._cleanup();
8122
+        }
8123
+        return;
8124
+      }
8125
+
8126
+      var destroyReady;
8127
+      var pendingRemoval;
8128
+
8129
+      var self = this;
8130
+      // Cleanup should be called either synchronously or asynchronoysly as
8131
+      // callback of this.$remove(), or if remove and deferCleanup are false.
8132
+      // In any case it should be called after all other removing, unbinding and
8133
+      // turning of is done
8134
+      var cleanupIfPossible = function cleanupIfPossible() {
8135
+        if (destroyReady && !pendingRemoval && !deferCleanup) {
8136
+          self._cleanup();
8137
+        }
8138
+      };
8139
+
8140
+      // remove DOM element
8141
+      if (remove && this.$el) {
8142
+        pendingRemoval = true;
8143
+        this.$remove(function () {
8144
+          pendingRemoval = false;
8145
+          cleanupIfPossible();
8146
+        });
8147
+      }
8148
+
8149
+      this._callHook('beforeDestroy');
8150
+      this._isBeingDestroyed = true;
8151
+      var i;
8152
+      // remove self from parent. only necessary
8153
+      // if parent is not being destroyed as well.
8154
+      var parent = this.$parent;
8155
+      if (parent && !parent._isBeingDestroyed) {
8156
+        parent.$children.$remove(this);
8157
+        // unregister ref (remove: true)
8158
+        this._updateRef(true);
8159
+      }
8160
+      // destroy all children.
8161
+      i = this.$children.length;
8162
+      while (i--) {
8163
+        this.$children[i].$destroy();
8164
+      }
8165
+      // teardown props
8166
+      if (this._propsUnlinkFn) {
8167
+        this._propsUnlinkFn();
8168
+      }
8169
+      // teardown all directives. this also tearsdown all
8170
+      // directive-owned watchers.
8171
+      if (this._unlinkFn) {
8172
+        this._unlinkFn();
8173
+      }
8174
+      i = this._watchers.length;
8175
+      while (i--) {
8176
+        this._watchers[i].teardown();
8177
+      }
8178
+      // remove reference to self on $el
8179
+      if (this.$el) {
8180
+        this.$el.__vue__ = null;
8181
+      }
8182
+
8183
+      destroyReady = true;
8184
+      cleanupIfPossible();
8185
+    };
8186
+
8187
+    /**
8188
+     * Clean up to ensure garbage collection.
8189
+     * This is called after the leave transition if there
8190
+     * is any.
8191
+     */
8192
+
8193
+    Vue.prototype._cleanup = function () {
8194
+      if (this._isDestroyed) {
8195
+        return;
8196
+      }
8197
+      // remove self from owner fragment
8198
+      // do it in cleanup so that we can call $destroy with
8199
+      // defer right when a fragment is about to be removed.
8200
+      if (this._frag) {
8201
+        this._frag.children.$remove(this);
8202
+      }
8203
+      // remove reference from data ob
8204
+      // frozen object may not have observer.
8205
+      if (this._data.__ob__) {
8206
+        this._data.__ob__.removeVm(this);
8207
+      }
8208
+      // Clean up references to private properties and other
8209
+      // instances. preserve reference to _data so that proxy
8210
+      // accessors still work. The only potential side effect
8211
+      // here is that mutating the instance after it's destroyed
8212
+      // may affect the state of other components that are still
8213
+      // observing the same object, but that seems to be a
8214
+      // reasonable responsibility for the user rather than
8215
+      // always throwing an error on them.
8216
+      this.$el = this.$parent = this.$root = this.$children = this._watchers = this._context = this._scope = this._directives = null;
8217
+      // call the last hook...
8218
+      this._isDestroyed = true;
8219
+      this._callHook('destroyed');
8220
+      // turn off all instance listeners.
8221
+      this.$off();
8222
+    };
8223
+  }
8224
+
8225
+  function miscMixin (Vue) {
8226
+
8227
+    /**
8228
+     * Apply a list of filter (descriptors) to a value.
8229
+     * Using plain for loops here because this will be called in
8230
+     * the getter of any watcher with filters so it is very
8231
+     * performance sensitive.
8232
+     *
8233
+     * @param {*} value
8234
+     * @param {*} [oldValue]
8235
+     * @param {Array} filters
8236
+     * @param {Boolean} write
8237
+     * @return {*}
8238
+     */
8239
+
8240
+    Vue.prototype._applyFilters = function (value, oldValue, filters, write) {
8241
+      var filter, fn, args, arg, offset, i, l, j, k;
8242
+      for (i = 0, l = filters.length; i < l; i++) {
8243
+        filter = filters[i];
8244
+        fn = resolveAsset(this.$options, 'filters', filter.name);
8245
+        if ('development' !== 'production') {
8246
+          assertAsset(fn, 'filter', filter.name);
8247
+        }
8248
+        if (!fn) continue;
8249
+        fn = write ? fn.write : fn.read || fn;
8250
+        if (typeof fn !== 'function') continue;
8251
+        args = write ? [value, oldValue] : [value];
8252
+        offset = write ? 2 : 1;
8253
+        if (filter.args) {
8254
+          for (j = 0, k = filter.args.length; j < k; j++) {
8255
+            arg = filter.args[j];
8256
+            args[j + offset] = arg.dynamic ? this.$get(arg.value) : arg.value;
8257
+          }
8258
+        }
8259
+        value = fn.apply(this, args);
8260
+      }
8261
+      return value;
8262
+    };
8263
+
8264
+    /**
8265
+     * Resolve a component, depending on whether the component
8266
+     * is defined normally or using an async factory function.
8267
+     * Resolves synchronously if already resolved, otherwise
8268
+     * resolves asynchronously and caches the resolved
8269
+     * constructor on the factory.
8270
+     *
8271
+     * @param {String} id
8272
+     * @param {Function} cb
8273
+     */
8274
+
8275
+    Vue.prototype._resolveComponent = function (id, cb) {
8276
+      var factory = resolveAsset(this.$options, 'components', id);
8277
+      if ('development' !== 'production') {
8278
+        assertAsset(factory, 'component', id);
8279
+      }
8280
+      if (!factory) {
8281
+        return;
8282
+      }
8283
+      // async component factory
8284
+      if (!factory.options) {
8285
+        if (factory.resolved) {
8286
+          // cached
8287
+          cb(factory.resolved);
8288
+        } else if (factory.requested) {
8289
+          // pool callbacks
8290
+          factory.pendingCallbacks.push(cb);
8291
+        } else {
8292
+          factory.requested = true;
8293
+          var cbs = factory.pendingCallbacks = [cb];
8294
+          factory(function resolve(res) {
8295
+            if (isPlainObject(res)) {
8296
+              res = Vue.extend(res);
8297
+            }
8298
+            // cache resolved
8299
+            factory.resolved = res;
8300
+            // invoke callbacks
8301
+            for (var i = 0, l = cbs.length; i < l; i++) {
8302
+              cbs[i](res);
8303
+            }
8304
+          }, function reject(reason) {
8305
+            'development' !== 'production' && warn('Failed to resolve async component: ' + id + '. ' + (reason ? '\nReason: ' + reason : ''));
8306
+          });
8307
+        }
8308
+      } else {
8309
+        // normal component
8310
+        cb(factory);
8311
+      }
8312
+    };
8313
+  }
8314
+
8315
+  function globalAPI (Vue) {
8316
+
8317
+    /**
8318
+     * Expose useful internals
8319
+     */
8320
+
8321
+    Vue.util = util;
8322
+    Vue.config = config;
8323
+    Vue.set = set;
8324
+    Vue['delete'] = del;
8325
+    Vue.nextTick = nextTick;
8326
+
8327
+    /**
8328
+     * The following are exposed for advanced usage / plugins
8329
+     */
8330
+
8331
+    Vue.compiler = compiler;
8332
+    Vue.FragmentFactory = FragmentFactory;
8333
+    Vue.internalDirectives = internalDirectives;
8334
+    Vue.parsers = {
8335
+      path: path,
8336
+      text: text$1,
8337
+      template: template,
8338
+      directive: directive,
8339
+      expression: expression
8340
+    };
8341
+
8342
+    /**
8343
+     * Each instance constructor, including Vue, has a unique
8344
+     * cid. This enables us to create wrapped "child
8345
+     * constructors" for prototypal inheritance and cache them.
8346
+     */
8347
+
8348
+    Vue.cid = 0;
8349
+    var cid = 1;
8350
+
8351
+    /**
8352
+     * Class inheritance
8353
+     *
8354
+     * @param {Object} extendOptions
8355
+     */
8356
+
8357
+    Vue.extend = function (extendOptions) {
8358
+      extendOptions = extendOptions || {};
8359
+      var Super = this;
8360
+      var isFirstExtend = Super.cid === 0;
8361
+      if (isFirstExtend && extendOptions._Ctor) {
8362
+        return extendOptions._Ctor;
8363
+      }
8364
+      var name = extendOptions.name || Super.options.name;
8365
+      if ('development' !== 'production') {
8366
+        if (!/^[a-zA-Z][\w-]+$/.test(name)) {
8367
+          warn('Invalid component name: ' + name);
8368
+          name = null;
8369
+        }
8370
+      }
8371
+      var Sub = createClass(name || 'VueComponent');
8372
+      Sub.prototype = Object.create(Super.prototype);
8373
+      Sub.prototype.constructor = Sub;
8374
+      Sub.cid = cid++;
8375
+      Sub.options = mergeOptions(Super.options, extendOptions);
8376
+      Sub['super'] = Super;
8377
+      // allow further extension
8378
+      Sub.extend = Super.extend;
8379
+      // create asset registers, so extended classes
8380
+      // can have their private assets too.
8381
+      config._assetTypes.forEach(function (type) {
8382
+        Sub[type] = Super[type];
8383
+      });
8384
+      // enable recursive self-lookup
8385
+      if (name) {
8386
+        Sub.options.components[name] = Sub;
8387
+      }
8388
+      // cache constructor
8389
+      if (isFirstExtend) {
8390
+        extendOptions._Ctor = Sub;
8391
+      }
8392
+      return Sub;
8393
+    };
8394
+
8395
+    /**
8396
+     * A function that returns a sub-class constructor with the
8397
+     * given name. This gives us much nicer output when
8398
+     * logging instances in the console.
8399
+     *
8400
+     * @param {String} name
8401
+     * @return {Function}
8402
+     */
8403
+
8404
+    function createClass(name) {
8405
+      return new Function('return function ' + classify(name) + ' (options) { this._init(options) }')();
8406
+    }
8407
+
8408
+    /**
8409
+     * Plugin system
8410
+     *
8411
+     * @param {Object} plugin
8412
+     */
8413
+
8414
+    Vue.use = function (plugin) {
8415
+      /* istanbul ignore if */
8416
+      if (plugin.installed) {
8417
+        return;
8418
+      }
8419
+      // additional parameters
8420
+      var args = toArray(arguments, 1);
8421
+      args.unshift(this);
8422
+      if (typeof plugin.install === 'function') {
8423
+        plugin.install.apply(plugin, args);
8424
+      } else {
8425
+        plugin.apply(null, args);
8426
+      }
8427
+      plugin.installed = true;
8428
+      return this;
8429
+    };
8430
+
8431
+    /**
8432
+     * Apply a global mixin by merging it into the default
8433
+     * options.
8434
+     */
8435
+
8436
+    Vue.mixin = function (mixin) {
8437
+      Vue.options = mergeOptions(Vue.options, mixin);
8438
+    };
8439
+
8440
+    /**
8441
+     * Create asset registration methods with the following
8442
+     * signature:
8443
+     *
8444
+     * @param {String} id
8445
+     * @param {*} definition
8446
+     */
8447
+
8448
+    config._assetTypes.forEach(function (type) {
8449
+      Vue[type] = function (id, definition) {
8450
+        if (!definition) {
8451
+          return this.options[type + 's'][id];
8452
+        } else {
8453
+          /* istanbul ignore if */
8454
+          if ('development' !== 'production') {
8455
+            if (type === 'component' && (commonTagRE.test(id) || reservedTagRE.test(id))) {
8456
+              warn('Do not use built-in or reserved HTML elements as component ' + 'id: ' + id);
8457
+            }
8458
+          }
8459
+          if (type === 'component' && isPlainObject(definition)) {
8460
+            definition.name = id;
8461
+            definition = Vue.extend(definition);
8462
+          }
8463
+          this.options[type + 's'][id] = definition;
8464
+          return definition;
8465
+        }
8466
+      };
8467
+    });
8468
+  }
8469
+
8470
+  var filterRE = /[^|]\|[^|]/;
8471
+
8472
+  function dataAPI (Vue) {
8473
+
8474
+    /**
8475
+     * Get the value from an expression on this vm.
8476
+     *
8477
+     * @param {String} exp
8478
+     * @param {Boolean} [asStatement]
8479
+     * @return {*}
8480
+     */
8481
+
8482
+    Vue.prototype.$get = function (exp, asStatement) {
8483
+      var res = parseExpression(exp);
8484
+      if (res) {
8485
+        if (asStatement && !isSimplePath(exp)) {
8486
+          var self = this;
8487
+          return function statementHandler() {
8488
+            self.$arguments = toArray(arguments);
8489
+            var result = res.get.call(self, self);
8490
+            self.$arguments = null;
8491
+            return result;
8492
+          };
8493
+        } else {
8494
+          try {
8495
+            return res.get.call(this, this);
8496
+          } catch (e) {}
8497
+        }
8498
+      }
8499
+    };
8500
+
8501
+    /**
8502
+     * Set the value from an expression on this vm.
8503
+     * The expression must be a valid left-hand
8504
+     * expression in an assignment.
8505
+     *
8506
+     * @param {String} exp
8507
+     * @param {*} val
8508
+     */
8509
+
8510
+    Vue.prototype.$set = function (exp, val) {
8511
+      var res = parseExpression(exp, true);
8512
+      if (res && res.set) {
8513
+        res.set.call(this, this, val);
8514
+      }
8515
+    };
8516
+
8517
+    /**
8518
+     * Delete a property on the VM
8519
+     *
8520
+     * @param {String} key
8521
+     */
8522
+
8523
+    Vue.prototype.$delete = function (key) {
8524
+      del(this._data, key);
8525
+    };
8526
+
8527
+    /**
8528
+     * Watch an expression, trigger callback when its
8529
+     * value changes.
8530
+     *
8531
+     * @param {String|Function} expOrFn
8532
+     * @param {Function} cb
8533
+     * @param {Object} [options]
8534
+     *                 - {Boolean} deep
8535
+     *                 - {Boolean} immediate
8536
+     * @return {Function} - unwatchFn
8537
+     */
8538
+
8539
+    Vue.prototype.$watch = function (expOrFn, cb, options) {
8540
+      var vm = this;
8541
+      var parsed;
8542
+      if (typeof expOrFn === 'string') {
8543
+        parsed = parseDirective(expOrFn);
8544
+        expOrFn = parsed.expression;
8545
+      }
8546
+      var watcher = new Watcher(vm, expOrFn, cb, {
8547
+        deep: options && options.deep,
8548
+        sync: options && options.sync,
8549
+        filters: parsed && parsed.filters,
8550
+        user: !options || options.user !== false
8551
+      });
8552
+      if (options && options.immediate) {
8553
+        cb.call(vm, watcher.value);
8554
+      }
8555
+      return function unwatchFn() {
8556
+        watcher.teardown();
8557
+      };
8558
+    };
8559
+
8560
+    /**
8561
+     * Evaluate a text directive, including filters.
8562
+     *
8563
+     * @param {String} text
8564
+     * @param {Boolean} [asStatement]
8565
+     * @return {String}
8566
+     */
8567
+
8568
+    Vue.prototype.$eval = function (text, asStatement) {
8569
+      // check for filters.
8570
+      if (filterRE.test(text)) {
8571
+        var dir = parseDirective(text);
8572
+        // the filter regex check might give false positive
8573
+        // for pipes inside strings, so it's possible that
8574
+        // we don't get any filters here
8575
+        var val = this.$get(dir.expression, asStatement);
8576
+        return dir.filters ? this._applyFilters(val, null, dir.filters) : val;
8577
+      } else {
8578
+        // no filter
8579
+        return this.$get(text, asStatement);
8580
+      }
8581
+    };
8582
+
8583
+    /**
8584
+     * Interpolate a piece of template text.
8585
+     *
8586
+     * @param {String} text
8587
+     * @return {String}
8588
+     */
8589
+
8590
+    Vue.prototype.$interpolate = function (text) {
8591
+      var tokens = parseText(text);
8592
+      var vm = this;
8593
+      if (tokens) {
8594
+        if (tokens.length === 1) {
8595
+          return vm.$eval(tokens[0].value) + '';
8596
+        } else {
8597
+          return tokens.map(function (token) {
8598
+            return token.tag ? vm.$eval(token.value) : token.value;
8599
+          }).join('');
8600
+        }
8601
+      } else {
8602
+        return text;
8603
+      }
8604
+    };
8605
+
8606
+    /**
8607
+     * Log instance data as a plain JS object
8608
+     * so that it is easier to inspect in console.
8609
+     * This method assumes console is available.
8610
+     *
8611
+     * @param {String} [path]
8612
+     */
8613
+
8614
+    Vue.prototype.$log = function (path) {
8615
+      var data = path ? getPath(this._data, path) : this._data;
8616
+      if (data) {
8617
+        data = clean(data);
8618
+      }
8619
+      // include computed fields
8620
+      if (!path) {
8621
+        for (var key in this.$options.computed) {
8622
+          data[key] = clean(this[key]);
8623
+        }
8624
+      }
8625
+      console.log(data);
8626
+    };
8627
+
8628
+    /**
8629
+     * "clean" a getter/setter converted object into a plain
8630
+     * object copy.
8631
+     *
8632
+     * @param {Object} - obj
8633
+     * @return {Object}
8634
+     */
8635
+
8636
+    function clean(obj) {
8637
+      return JSON.parse(JSON.stringify(obj));
8638
+    }
8639
+  }
8640
+
8641
+  function domAPI (Vue) {
8642
+
8643
+    /**
8644
+     * Convenience on-instance nextTick. The callback is
8645
+     * auto-bound to the instance, and this avoids component
8646
+     * modules having to rely on the global Vue.
8647
+     *
8648
+     * @param {Function} fn
8649
+     */
8650
+
8651
+    Vue.prototype.$nextTick = function (fn) {
8652
+      nextTick(fn, this);
8653
+    };
8654
+
8655
+    /**
8656
+     * Append instance to target
8657
+     *
8658
+     * @param {Node} target
8659
+     * @param {Function} [cb]
8660
+     * @param {Boolean} [withTransition] - defaults to true
8661
+     */
8662
+
8663
+    Vue.prototype.$appendTo = function (target, cb, withTransition) {
8664
+      return insert(this, target, cb, withTransition, append, appendWithTransition);
8665
+    };
8666
+
8667
+    /**
8668
+     * Prepend instance to target
8669
+     *
8670
+     * @param {Node} target
8671
+     * @param {Function} [cb]
8672
+     * @param {Boolean} [withTransition] - defaults to true
8673
+     */
8674
+
8675
+    Vue.prototype.$prependTo = function (target, cb, withTransition) {
8676
+      target = query(target);
8677
+      if (target.hasChildNodes()) {
8678
+        this.$before(target.firstChild, cb, withTransition);
8679
+      } else {
8680
+        this.$appendTo(target, cb, withTransition);
8681
+      }
8682
+      return this;
8683
+    };
8684
+
8685
+    /**
8686
+     * Insert instance before target
8687
+     *
8688
+     * @param {Node} target
8689
+     * @param {Function} [cb]
8690
+     * @param {Boolean} [withTransition] - defaults to true
8691
+     */
8692
+
8693
+    Vue.prototype.$before = function (target, cb, withTransition) {
8694
+      return insert(this, target, cb, withTransition, beforeWithCb, beforeWithTransition);
8695
+    };
8696
+
8697
+    /**
8698
+     * Insert instance after target
8699
+     *
8700
+     * @param {Node} target
8701
+     * @param {Function} [cb]
8702
+     * @param {Boolean} [withTransition] - defaults to true
8703
+     */
8704
+
8705
+    Vue.prototype.$after = function (target, cb, withTransition) {
8706
+      target = query(target);
8707
+      if (target.nextSibling) {
8708
+        this.$before(target.nextSibling, cb, withTransition);
8709
+      } else {
8710
+        this.$appendTo(target.parentNode, cb, withTransition);
8711
+      }
8712
+      return this;
8713
+    };
8714
+
8715
+    /**
8716
+     * Remove instance from DOM
8717
+     *
8718
+     * @param {Function} [cb]
8719
+     * @param {Boolean} [withTransition] - defaults to true
8720
+     */
8721
+
8722
+    Vue.prototype.$remove = function (cb, withTransition) {
8723
+      if (!this.$el.parentNode) {
8724
+        return cb && cb();
8725
+      }
8726
+      var inDocument = this._isAttached && inDoc(this.$el);
8727
+      // if we are not in document, no need to check
8728
+      // for transitions
8729
+      if (!inDocument) withTransition = false;
8730
+      var self = this;
8731
+      var realCb = function realCb() {
8732
+        if (inDocument) self._callHook('detached');
8733
+        if (cb) cb();
8734
+      };
8735
+      if (this._isFragment) {
8736
+        removeNodeRange(this._fragmentStart, this._fragmentEnd, this, this._fragment, realCb);
8737
+      } else {
8738
+        var op = withTransition === false ? removeWithCb : removeWithTransition;
8739
+        op(this.$el, this, realCb);
8740
+      }
8741
+      return this;
8742
+    };
8743
+
8744
+    /**
8745
+     * Shared DOM insertion function.
8746
+     *
8747
+     * @param {Vue} vm
8748
+     * @param {Element} target
8749
+     * @param {Function} [cb]
8750
+     * @param {Boolean} [withTransition]
8751
+     * @param {Function} op1 - op for non-transition insert
8752
+     * @param {Function} op2 - op for transition insert
8753
+     * @return vm
8754
+     */
8755
+
8756
+    function insert(vm, target, cb, withTransition, op1, op2) {
8757
+      target = query(target);
8758
+      var targetIsDetached = !inDoc(target);
8759
+      var op = withTransition === false || targetIsDetached ? op1 : op2;
8760
+      var shouldCallHook = !targetIsDetached && !vm._isAttached && !inDoc(vm.$el);
8761
+      if (vm._isFragment) {
8762
+        mapNodeRange(vm._fragmentStart, vm._fragmentEnd, function (node) {
8763
+          op(node, target, vm);
8764
+        });
8765
+        cb && cb();
8766
+      } else {
8767
+        op(vm.$el, target, vm, cb);
8768
+      }
8769
+      if (shouldCallHook) {
8770
+        vm._callHook('attached');
8771
+      }
8772
+      return vm;
8773
+    }
8774
+
8775
+    /**
8776
+     * Check for selectors
8777
+     *
8778
+     * @param {String|Element} el
8779
+     */
8780
+
8781
+    function query(el) {
8782
+      return typeof el === 'string' ? document.querySelector(el) : el;
8783
+    }
8784
+
8785
+    /**
8786
+     * Append operation that takes a callback.
8787
+     *
8788
+     * @param {Node} el
8789
+     * @param {Node} target
8790
+     * @param {Vue} vm - unused
8791
+     * @param {Function} [cb]
8792
+     */
8793
+
8794
+    function append(el, target, vm, cb) {
8795
+      target.appendChild(el);
8796
+      if (cb) cb();
8797
+    }
8798
+
8799
+    /**
8800
+     * InsertBefore operation that takes a callback.
8801
+     *
8802
+     * @param {Node} el
8803
+     * @param {Node} target
8804
+     * @param {Vue} vm - unused
8805
+     * @param {Function} [cb]
8806
+     */
8807
+
8808
+    function beforeWithCb(el, target, vm, cb) {
8809
+      before(el, target);
8810
+      if (cb) cb();
8811
+    }
8812
+
8813
+    /**
8814
+     * Remove operation that takes a callback.
8815
+     *
8816
+     * @param {Node} el
8817
+     * @param {Vue} vm - unused
8818
+     * @param {Function} [cb]
8819
+     */
8820
+
8821
+    function removeWithCb(el, vm, cb) {
8822
+      remove(el);
8823
+      if (cb) cb();
8824
+    }
8825
+  }
8826
+
8827
+  function eventsAPI (Vue) {
8828
+
8829
+    /**
8830
+     * Listen on the given `event` with `fn`.
8831
+     *
8832
+     * @param {String} event
8833
+     * @param {Function} fn
8834
+     */
8835
+
8836
+    Vue.prototype.$on = function (event, fn) {
8837
+      (this._events[event] || (this._events[event] = [])).push(fn);
8838
+      modifyListenerCount(this, event, 1);
8839
+      return this;
8840
+    };
8841
+
8842
+    /**
8843
+     * Adds an `event` listener that will be invoked a single
8844
+     * time then automatically removed.
8845
+     *
8846
+     * @param {String} event
8847
+     * @param {Function} fn
8848
+     */
8849
+
8850
+    Vue.prototype.$once = function (event, fn) {
8851
+      var self = this;
8852
+      function on() {
8853
+        self.$off(event, on);
8854
+        fn.apply(this, arguments);
8855
+      }
8856
+      on.fn = fn;
8857
+      this.$on(event, on);
8858
+      return this;
8859
+    };
8860
+
8861
+    /**
8862
+     * Remove the given callback for `event` or all
8863
+     * registered callbacks.
8864
+     *
8865
+     * @param {String} event
8866
+     * @param {Function} fn
8867
+     */
8868
+
8869
+    Vue.prototype.$off = function (event, fn) {
8870
+      var cbs;
8871
+      // all
8872
+      if (!arguments.length) {
8873
+        if (this.$parent) {
8874
+          for (event in this._events) {
8875
+            cbs = this._events[event];
8876
+            if (cbs) {
8877
+              modifyListenerCount(this, event, -cbs.length);
8878
+            }
8879
+          }
8880
+        }
8881
+        this._events = {};
8882
+        return this;
8883
+      }
8884
+      // specific event
8885
+      cbs = this._events[event];
8886
+      if (!cbs) {
8887
+        return this;
8888
+      }
8889
+      if (arguments.length === 1) {
8890
+        modifyListenerCount(this, event, -cbs.length);
8891
+        this._events[event] = null;
8892
+        return this;
8893
+      }
8894
+      // specific handler
8895
+      var cb;
8896
+      var i = cbs.length;
8897
+      while (i--) {
8898
+        cb = cbs[i];
8899
+        if (cb === fn || cb.fn === fn) {
8900
+          modifyListenerCount(this, event, -1);
8901
+          cbs.splice(i, 1);
8902
+          break;
8903
+        }
8904
+      }
8905
+      return this;
8906
+    };
8907
+
8908
+    /**
8909
+     * Trigger an event on self.
8910
+     *
8911
+     * @param {String|Object} event
8912
+     * @return {Boolean} shouldPropagate
8913
+     */
8914
+
8915
+    Vue.prototype.$emit = function (event) {
8916
+      var isSource = typeof event === 'string';
8917
+      event = isSource ? event : event.name;
8918
+      var cbs = this._events[event];
8919
+      var shouldPropagate = isSource || !cbs;
8920
+      if (cbs) {
8921
+        cbs = cbs.length > 1 ? toArray(cbs) : cbs;
8922
+        // this is a somewhat hacky solution to the question raised
8923
+        // in #2102: for an inline component listener like <comp @test="doThis">,
8924
+        // the propagation handling is somewhat broken. Therefore we
8925
+        // need to treat these inline callbacks differently.
8926
+        var hasParentCbs = isSource && cbs.some(function (cb) {
8927
+          return cb._fromParent;
8928
+        });
8929
+        if (hasParentCbs) {
8930
+          shouldPropagate = false;
8931
+        }
8932
+        var args = toArray(arguments, 1);
8933
+        for (var i = 0, l = cbs.length; i < l; i++) {
8934
+          var cb = cbs[i];
8935
+          var res = cb.apply(this, args);
8936
+          if (res === true && (!hasParentCbs || cb._fromParent)) {
8937
+            shouldPropagate = true;
8938
+          }
8939
+        }
8940
+      }
8941
+      return shouldPropagate;
8942
+    };
8943
+
8944
+    /**
8945
+     * Recursively broadcast an event to all children instances.
8946
+     *
8947
+     * @param {String|Object} event
8948
+     * @param {...*} additional arguments
8949
+     */
8950
+
8951
+    Vue.prototype.$broadcast = function (event) {
8952
+      var isSource = typeof event === 'string';
8953
+      event = isSource ? event : event.name;
8954
+      // if no child has registered for this event,
8955
+      // then there's no need to broadcast.
8956
+      if (!this._eventsCount[event]) return;
8957
+      var children = this.$children;
8958
+      var args = toArray(arguments);
8959
+      if (isSource) {
8960
+        // use object event to indicate non-source emit
8961
+        // on children
8962
+        args[0] = { name: event, source: this };
8963
+      }
8964
+      for (var i = 0, l = children.length; i < l; i++) {
8965
+        var child = children[i];
8966
+        var shouldPropagate = child.$emit.apply(child, args);
8967
+        if (shouldPropagate) {
8968
+          child.$broadcast.apply(child, args);
8969
+        }
8970
+      }
8971
+      return this;
8972
+    };
8973
+
8974
+    /**
8975
+     * Recursively propagate an event up the parent chain.
8976
+     *
8977
+     * @param {String} event
8978
+     * @param {...*} additional arguments
8979
+     */
8980
+
8981
+    Vue.prototype.$dispatch = function (event) {
8982
+      var shouldPropagate = this.$emit.apply(this, arguments);
8983
+      if (!shouldPropagate) return;
8984
+      var parent = this.$parent;
8985
+      var args = toArray(arguments);
8986
+      // use object event to indicate non-source emit
8987
+      // on parents
8988
+      args[0] = { name: event, source: this };
8989
+      while (parent) {
8990
+        shouldPropagate = parent.$emit.apply(parent, args);
8991
+        parent = shouldPropagate ? parent.$parent : null;
8992
+      }
8993
+      return this;
8994
+    };
8995
+
8996
+    /**
8997
+     * Modify the listener counts on all parents.
8998
+     * This bookkeeping allows $broadcast to return early when
8999
+     * no child has listened to a certain event.
9000
+     *
9001
+     * @param {Vue} vm
9002
+     * @param {String} event
9003
+     * @param {Number} count
9004
+     */
9005
+
9006
+    var hookRE = /^hook:/;
9007
+    function modifyListenerCount(vm, event, count) {
9008
+      var parent = vm.$parent;
9009
+      // hooks do not get broadcasted so no need
9010
+      // to do bookkeeping for them
9011
+      if (!parent || !count || hookRE.test(event)) return;
9012
+      while (parent) {
9013
+        parent._eventsCount[event] = (parent._eventsCount[event] || 0) + count;
9014
+        parent = parent.$parent;
9015
+      }
9016
+    }
9017
+  }
9018
+
9019
+  function lifecycleAPI (Vue) {
9020
+
9021
+    /**
9022
+     * Set instance target element and kick off the compilation
9023
+     * process. The passed in `el` can be a selector string, an
9024
+     * existing Element, or a DocumentFragment (for block
9025
+     * instances).
9026
+     *
9027
+     * @param {Element|DocumentFragment|string} el
9028
+     * @public
9029
+     */
9030
+
9031
+    Vue.prototype.$mount = function (el) {
9032
+      if (this._isCompiled) {
9033
+        'development' !== 'production' && warn('$mount() should be called only once.');
9034
+        return;
9035
+      }
9036
+      el = query(el);
9037
+      if (!el) {
9038
+        el = document.createElement('div');
9039
+      }
9040
+      this._compile(el);
9041
+      this._initDOMHooks();
9042
+      if (inDoc(this.$el)) {
9043
+        this._callHook('attached');
9044
+        ready.call(this);
9045
+      } else {
9046
+        this.$once('hook:attached', ready);
9047
+      }
9048
+      return this;
9049
+    };
9050
+
9051
+    /**
9052
+     * Mark an instance as ready.
9053
+     */
9054
+
9055
+    function ready() {
9056
+      this._isAttached = true;
9057
+      this._isReady = true;
9058
+      this._callHook('ready');
9059
+    }
9060
+
9061
+    /**
9062
+     * Teardown the instance, simply delegate to the internal
9063
+     * _destroy.
9064
+     */
9065
+
9066
+    Vue.prototype.$destroy = function (remove, deferCleanup) {
9067
+      this._destroy(remove, deferCleanup);
9068
+    };
9069
+
9070
+    /**
9071
+     * Partially compile a piece of DOM and return a
9072
+     * decompile function.
9073
+     *
9074
+     * @param {Element|DocumentFragment} el
9075
+     * @param {Vue} [host]
9076
+     * @return {Function}
9077
+     */
9078
+
9079
+    Vue.prototype.$compile = function (el, host, scope, frag) {
9080
+      return compile(el, this.$options, true)(this, el, host, scope, frag);
9081
+    };
9082
+  }
9083
+
9084
+  /**
9085
+   * The exposed Vue constructor.
9086
+   *
9087
+   * API conventions:
9088
+   * - public API methods/properties are prefixed with `$`
9089
+   * - internal methods/properties are prefixed with `_`
9090
+   * - non-prefixed properties are assumed to be proxied user
9091
+   *   data.
9092
+   *
9093
+   * @constructor
9094
+   * @param {Object} [options]
9095
+   * @public
9096
+   */
9097
+
9098
+  function Vue(options) {
9099
+    this._init(options);
9100
+  }
9101
+
9102
+  // install internals
9103
+  initMixin(Vue);
9104
+  stateMixin(Vue);
9105
+  eventsMixin(Vue);
9106
+  lifecycleMixin(Vue);
9107
+  miscMixin(Vue);
9108
+
9109
+  // install APIs
9110
+  globalAPI(Vue);
9111
+  dataAPI(Vue);
9112
+  domAPI(Vue);
9113
+  eventsAPI(Vue);
9114
+  lifecycleAPI(Vue);
9115
+
9116
+  var convertArray = vFor._postProcess;
9117
+
9118
+  /**
9119
+   * Limit filter for arrays
9120
+   *
9121
+   * @param {Number} n
9122
+   * @param {Number} offset (Decimal expected)
9123
+   */
9124
+
9125
+  function limitBy(arr, n, offset) {
9126
+    offset = offset ? parseInt(offset, 10) : 0;
9127
+    n = toNumber(n);
9128
+    return typeof n === 'number' ? arr.slice(offset, offset + n) : arr;
9129
+  }
9130
+
9131
+  /**
9132
+   * Filter filter for arrays
9133
+   *
9134
+   * @param {String} search
9135
+   * @param {String} [delimiter]
9136
+   * @param {String} ...dataKeys
9137
+   */
9138
+
9139
+  function filterBy(arr, search, delimiter) {
9140
+    arr = convertArray(arr);
9141
+    if (search == null) {
9142
+      return arr;
9143
+    }
9144
+    if (typeof search === 'function') {
9145
+      return arr.filter(search);
9146
+    }
9147
+    // cast to lowercase string
9148
+    search = ('' + search).toLowerCase();
9149
+    // allow optional `in` delimiter
9150
+    // because why not
9151
+    var n = delimiter === 'in' ? 3 : 2;
9152
+    // extract and flatten keys
9153
+    var keys = toArray(arguments, n).reduce(function (prev, cur) {
9154
+      return prev.concat(cur);
9155
+    }, []);
9156
+    var res = [];
9157
+    var item, key, val, j;
9158
+    for (var i = 0, l = arr.length; i < l; i++) {
9159
+      item = arr[i];
9160
+      val = item && item.$value || item;
9161
+      j = keys.length;
9162
+      if (j) {
9163
+        while (j--) {
9164
+          key = keys[j];
9165
+          if (key === '$key' && contains(item.$key, search) || contains(getPath(val, key), search)) {
9166
+            res.push(item);
9167
+            break;
9168
+          }
9169
+        }
9170
+      } else if (contains(item, search)) {
9171
+        res.push(item);
9172
+      }
9173
+    }
9174
+    return res;
9175
+  }
9176
+
9177
+  /**
9178
+   * Filter filter for arrays
9179
+   *
9180
+   * @param {String} sortKey
9181
+   * @param {String} reverse
9182
+   */
9183
+
9184
+  function orderBy(arr, sortKey, reverse) {
9185
+    arr = convertArray(arr);
9186
+    if (!sortKey) {
9187
+      return arr;
9188
+    }
9189
+    var order = reverse && reverse < 0 ? -1 : 1;
9190
+    // sort on a copy to avoid mutating original array
9191
+    return arr.slice().sort(function (a, b) {
9192
+      if (sortKey !== '$key') {
9193
+        if (isObject(a) && '$value' in a) a = a.$value;
9194
+        if (isObject(b) && '$value' in b) b = b.$value;
9195
+      }
9196
+      a = isObject(a) ? getPath(a, sortKey) : a;
9197
+      b = isObject(b) ? getPath(b, sortKey) : b;
9198
+      return a === b ? 0 : a > b ? order : -order;
9199
+    });
9200
+  }
9201
+
9202
+  /**
9203
+   * String contain helper
9204
+   *
9205
+   * @param {*} val
9206
+   * @param {String} search
9207
+   */
9208
+
9209
+  function contains(val, search) {
9210
+    var i;
9211
+    if (isPlainObject(val)) {
9212
+      var keys = Object.keys(val);
9213
+      i = keys.length;
9214
+      while (i--) {
9215
+        if (contains(val[keys[i]], search)) {
9216
+          return true;
9217
+        }
9218
+      }
9219
+    } else if (isArray(val)) {
9220
+      i = val.length;
9221
+      while (i--) {
9222
+        if (contains(val[i], search)) {
9223
+          return true;
9224
+        }
9225
+      }
9226
+    } else if (val != null) {
9227
+      return val.toString().toLowerCase().indexOf(search) > -1;
9228
+    }
9229
+  }
9230
+
9231
+  var digitsRE = /(\d{3})(?=\d)/g;
9232
+
9233
+  // asset collections must be a plain object.
9234
+  var filters = {
9235
+
9236
+    orderBy: orderBy,
9237
+    filterBy: filterBy,
9238
+    limitBy: limitBy,
9239
+
9240
+    /**
9241
+     * Stringify value.
9242
+     *
9243
+     * @param {Number} indent
9244
+     */
9245
+
9246
+    json: {
9247
+      read: function read(value, indent) {
9248
+        return typeof value === 'string' ? value : JSON.stringify(value, null, Number(indent) || 2);
9249
+      },
9250
+      write: function write(value) {
9251
+        try {
9252
+          return JSON.parse(value);
9253
+        } catch (e) {
9254
+          return value;
9255
+        }
9256
+      }
9257
+    },
9258
+
9259
+    /**
9260
+     * 'abc' => 'Abc'
9261
+     */
9262
+
9263
+    capitalize: function capitalize(value) {
9264
+      if (!value && value !== 0) return '';
9265
+      value = value.toString();
9266
+      return value.charAt(0).toUpperCase() + value.slice(1);
9267
+    },
9268
+
9269
+    /**
9270
+     * 'abc' => 'ABC'
9271
+     */
9272
+
9273
+    uppercase: function uppercase(value) {
9274
+      return value || value === 0 ? value.toString().toUpperCase() : '';
9275
+    },
9276
+
9277
+    /**
9278
+     * 'AbC' => 'abc'
9279
+     */
9280
+
9281
+    lowercase: function lowercase(value) {
9282
+      return value || value === 0 ? value.toString().toLowerCase() : '';
9283
+    },
9284
+
9285
+    /**
9286
+     * 12345 => $12,345.00
9287
+     *
9288
+     * @param {String} sign
9289
+     */
9290
+
9291
+    currency: function currency(value, _currency) {
9292
+      value = parseFloat(value);
9293
+      if (!isFinite(value) || !value && value !== 0) return '';
9294
+      _currency = _currency != null ? _currency : '$';
9295
+      var stringified = Math.abs(value).toFixed(2);
9296
+      var _int = stringified.slice(0, -3);
9297
+      var i = _int.length % 3;
9298
+      var head = i > 0 ? _int.slice(0, i) + (_int.length > 3 ? ',' : '') : '';
9299
+      var _float = stringified.slice(-3);
9300
+      var sign = value < 0 ? '-' : '';
9301
+      return _currency + sign + head + _int.slice(i).replace(digitsRE, '$1,') + _float;
9302
+    },
9303
+
9304
+    /**
9305
+     * 'item' => 'items'
9306
+     *
9307
+     * @params
9308
+     *  an array of strings corresponding to
9309
+     *  the single, double, triple ... forms of the word to
9310
+     *  be pluralized. When the number to be pluralized
9311
+     *  exceeds the length of the args, it will use the last
9312
+     *  entry in the array.
9313
+     *
9314
+     *  e.g. ['single', 'double', 'triple', 'multiple']
9315
+     */
9316
+
9317
+    pluralize: function pluralize(value) {
9318
+      var args = toArray(arguments, 1);
9319
+      return args.length > 1 ? args[value % 10 - 1] || args[args.length - 1] : args[0] + (value === 1 ? '' : 's');
9320
+    },
9321
+
9322
+    /**
9323
+     * Debounce a handler function.
9324
+     *
9325
+     * @param {Function} handler
9326
+     * @param {Number} delay = 300
9327
+     * @return {Function}
9328
+     */
9329
+
9330
+    debounce: function debounce(handler, delay) {
9331
+      if (!handler) return;
9332
+      if (!delay) {
9333
+        delay = 300;
9334
+      }
9335
+      return _debounce(handler, delay);
9336
+    }
9337
+  };
9338
+
9339
+  var partial = {
9340
+
9341
+    priority: PARTIAL,
9342
+
9343
+    params: ['name'],
9344
+
9345
+    // watch changes to name for dynamic partials
9346
+    paramWatchers: {
9347
+      name: function name(value) {
9348
+        vIf.remove.call(this);
9349
+        if (value) {
9350
+          this.insert(value);
9351
+        }
9352
+      }
9353
+    },
9354
+
9355
+    bind: function bind() {
9356
+      this.anchor = createAnchor('v-partial');
9357
+      replace(this.el, this.anchor);
9358
+      this.insert(this.params.name);
9359
+    },
9360
+
9361
+    insert: function insert(id) {
9362
+      var partial = resolveAsset(this.vm.$options, 'partials', id);
9363
+      if ('development' !== 'production') {
9364
+        assertAsset(partial, 'partial', id);
9365
+      }
9366
+      if (partial) {
9367
+        this.factory = new FragmentFactory(this.vm, partial);
9368
+        vIf.insert.call(this);
9369
+      }
9370
+    },
9371
+
9372
+    unbind: function unbind() {
9373
+      if (this.frag) {
9374
+        this.frag.destroy();
9375
+      }
9376
+    }
9377
+  };
9378
+
9379
+  // This is the elementDirective that handles <content>
9380
+  // transclusions. It relies on the raw content of an
9381
+  // instance being stored as `$options._content` during
9382
+  // the transclude phase.
9383
+
9384
+  // We are exporting two versions, one for named and one
9385
+  // for unnamed, because the unnamed slots must be compiled
9386
+  // AFTER all named slots have selected their content. So
9387
+  // we need to give them different priorities in the compilation
9388
+  // process. (See #1965)
9389
+
9390
+  var slot = {
9391
+
9392
+    priority: SLOT,
9393
+
9394
+    bind: function bind() {
9395
+      var host = this.vm;
9396
+      var raw = host.$options._content;
9397
+      if (!raw) {
9398
+        this.fallback();
9399
+        return;
9400
+      }
9401
+      var context = host._context;
9402
+      var slotName = this.params && this.params.name;
9403
+      if (!slotName) {
9404
+        // Default slot
9405
+        this.tryCompile(extractFragment(raw.childNodes, raw, true), context, host);
9406
+      } else {
9407
+        // Named slot
9408
+        var selector = '[slot="' + slotName + '"]';
9409
+        var nodes = raw.querySelectorAll(selector);
9410
+        if (nodes.length) {
9411
+          this.tryCompile(extractFragment(nodes, raw), context, host);
9412
+        } else {
9413
+          this.fallback();
9414
+        }
9415
+      }
9416
+    },
9417
+
9418
+    tryCompile: function tryCompile(content, context, host) {
9419
+      if (content.hasChildNodes()) {
9420
+        this.compile(content, context, host);
9421
+      } else {
9422
+        this.fallback();
9423
+      }
9424
+    },
9425
+
9426
+    compile: function compile(content, context, host) {
9427
+      if (content && context) {
9428
+        var scope = host ? host._scope : this._scope;
9429
+        this.unlink = context.$compile(content, host, scope, this._frag);
9430
+      }
9431
+      if (content) {
9432
+        replace(this.el, content);
9433
+      } else {
9434
+        remove(this.el);
9435
+      }
9436
+    },
9437
+
9438
+    fallback: function fallback() {
9439
+      this.compile(extractContent(this.el, true), this.vm);
9440
+    },
9441
+
9442
+    unbind: function unbind() {
9443
+      if (this.unlink) {
9444
+        this.unlink();
9445
+      }
9446
+    }
9447
+  };
9448
+
9449
+  var namedSlot = extend(extend({}, slot), {
9450
+    priority: slot.priority + 1,
9451
+    params: ['name']
9452
+  });
9453
+
9454
+  /**
9455
+   * Extract qualified content nodes from a node list.
9456
+   *
9457
+   * @param {NodeList} nodes
9458
+   * @param {Element} parent
9459
+   * @param {Boolean} main
9460
+   * @return {DocumentFragment}
9461
+   */
9462
+
9463
+  function extractFragment(nodes, parent, main) {
9464
+    var frag = document.createDocumentFragment();
9465
+    for (var i = 0, l = nodes.length; i < l; i++) {
9466
+      var node = nodes[i];
9467
+      // if this is the main outlet, we want to skip all
9468
+      // previously selected nodes;
9469
+      // otherwise, we want to mark the node as selected.
9470
+      // clone the node so the original raw content remains
9471
+      // intact. this ensures proper re-compilation in cases
9472
+      // where the outlet is inside a conditional block
9473
+      if (main && !node.__v_selected) {
9474
+        append(node);
9475
+      } else if (!main && node.parentNode === parent) {
9476
+        node.__v_selected = true;
9477
+        append(node);
9478
+      }
9479
+    }
9480
+    return frag;
9481
+
9482
+    function append(node) {
9483
+      if (isTemplate(node) && !node.hasAttribute('v-if') && !node.hasAttribute('v-for')) {
9484
+        node = parseTemplate(node);
9485
+      }
9486
+      node = cloneNode(node);
9487
+      frag.appendChild(node);
9488
+    }
9489
+  }
9490
+
9491
+  var elementDirectives = {
9492
+    slot: slot,
9493
+    _namedSlot: namedSlot, // same as slot but with higher priority
9494
+    partial: partial
9495
+  };
9496
+
9497
+  Vue.version = '1.0.15';
9498
+
9499
+  /**
9500
+   * Vue and every constructor that extends Vue has an
9501
+   * associated options object, which can be accessed during
9502
+   * compilation steps as `this.constructor.options`.
9503
+   *
9504
+   * These can be seen as the default options of every
9505
+   * Vue instance.
9506
+   */
9507
+
9508
+  Vue.options = {
9509
+    directives: publicDirectives,
9510
+    elementDirectives: elementDirectives,
9511
+    filters: filters,
9512
+    transitions: {},
9513
+    components: {},
9514
+    partials: {},
9515
+    replace: true
9516
+  };
9517
+
9518
+  // devtools global hook
9519
+  /* istanbul ignore if */
9520
+  if ('development' !== 'production' && inBrowser) {
9521
+    if (window.__VUE_DEVTOOLS_GLOBAL_HOOK__) {
9522
+      window.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit('init', Vue);
9523
+    } else if (/Chrome\/\d+/.test(navigator.userAgent)) {
9524
+      console.log('Download the Vue Devtools for a better development experience:\n' + 'https://github.com/vuejs/vue-devtools');
9525
+    }
9526
+  }
9527
+
9528
+  return Vue;
9529
+
9530
+}));
0 9531
\ No newline at end of file