1 | (function (global, factory) {
|
2 | typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
3 | typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
4 | (global = global || self, factory(global.VueTemplateCompiler = {}));
|
5 | }(this, function (exports) { 'use strict';
|
6 |
|
7 | var splitRE = /\r?\n/g;
|
8 | var emptyRE = /^\s*$/;
|
9 | var needFixRE = /^(\r?\n)*[\t\s]/;
|
10 |
|
11 | var deIndent = function deindent (str) {
|
12 | if (!needFixRE.test(str)) {
|
13 | return str
|
14 | }
|
15 | var lines = str.split(splitRE);
|
16 | var min = Infinity;
|
17 | var type, cur, c;
|
18 | for (var i = 0; i < lines.length; i++) {
|
19 | var line = lines[i];
|
20 | if (!emptyRE.test(line)) {
|
21 | if (!type) {
|
22 | c = line.charAt(0);
|
23 | if (c === ' ' || c === '\t') {
|
24 | type = c;
|
25 | cur = count(line, type);
|
26 | if (cur < min) {
|
27 | min = cur;
|
28 | }
|
29 | } else {
|
30 | return str
|
31 | }
|
32 | } else {
|
33 | cur = count(line, type);
|
34 | if (cur < min) {
|
35 | min = cur;
|
36 | }
|
37 | }
|
38 | }
|
39 | }
|
40 | return lines.map(function (line) {
|
41 | return line.slice(min)
|
42 | }).join('\n')
|
43 | };
|
44 |
|
45 | function count (line, type) {
|
46 | var i = 0;
|
47 | while (line.charAt(i) === type) {
|
48 | i++;
|
49 | }
|
50 | return i
|
51 | }
|
52 |
|
53 |
|
54 |
|
55 | var emptyObject = Object.freeze({});
|
56 |
|
57 |
|
58 |
|
59 | function isUndef (v) {
|
60 | return v === undefined || v === null
|
61 | }
|
62 |
|
63 | |
64 |
|
65 |
|
66 | function isPrimitive (value) {
|
67 | return (
|
68 | typeof value === 'string' ||
|
69 | typeof value === 'number' ||
|
70 |
|
71 | typeof value === 'symbol' ||
|
72 | typeof value === 'boolean'
|
73 | )
|
74 | }
|
75 |
|
76 | |
77 |
|
78 |
|
79 |
|
80 |
|
81 | function isObject (obj) {
|
82 | return obj !== null && typeof obj === 'object'
|
83 | }
|
84 |
|
85 | |
86 |
|
87 |
|
88 | var _toString = Object.prototype.toString;
|
89 |
|
90 | function toRawType (value) {
|
91 | return _toString.call(value).slice(8, -1)
|
92 | }
|
93 |
|
94 | |
95 |
|
96 |
|
97 |
|
98 | function isPlainObject (obj) {
|
99 | return _toString.call(obj) === '[object Object]'
|
100 | }
|
101 |
|
102 | |
103 |
|
104 |
|
105 | function isValidArrayIndex (val) {
|
106 | var n = parseFloat(String(val));
|
107 | return n >= 0 && Math.floor(n) === n && isFinite(val)
|
108 | }
|
109 |
|
110 | |
111 |
|
112 |
|
113 |
|
114 | function makeMap (
|
115 | str,
|
116 | expectsLowerCase
|
117 | ) {
|
118 | var map = Object.create(null);
|
119 | var list = str.split(',');
|
120 | for (var i = 0; i < list.length; i++) {
|
121 | map[list[i]] = true;
|
122 | }
|
123 | return expectsLowerCase
|
124 | ? function (val) { return map[val.toLowerCase()]; }
|
125 | : function (val) { return map[val]; }
|
126 | }
|
127 |
|
128 | |
129 |
|
130 |
|
131 | var isBuiltInTag = makeMap('slot,component', true);
|
132 |
|
133 | |
134 |
|
135 |
|
136 | var isReservedAttribute = makeMap('key,ref,slot,slot-scope,is');
|
137 |
|
138 | |
139 |
|
140 |
|
141 | function remove (arr, item) {
|
142 | if (arr.length) {
|
143 | var index = arr.indexOf(item);
|
144 | if (index > -1) {
|
145 | return arr.splice(index, 1)
|
146 | }
|
147 | }
|
148 | }
|
149 |
|
150 | |
151 |
|
152 |
|
153 | var hasOwnProperty = Object.prototype.hasOwnProperty;
|
154 | function hasOwn (obj, key) {
|
155 | return hasOwnProperty.call(obj, key)
|
156 | }
|
157 |
|
158 | |
159 |
|
160 |
|
161 | function cached (fn) {
|
162 | var cache = Object.create(null);
|
163 | return (function cachedFn (str) {
|
164 | var hit = cache[str];
|
165 | return hit || (cache[str] = fn(str))
|
166 | })
|
167 | }
|
168 |
|
169 | |
170 |
|
171 |
|
172 | var camelizeRE = /-(\w)/g;
|
173 | var camelize = cached(function (str) {
|
174 | return str.replace(camelizeRE, function (_, c) { return c ? c.toUpperCase() : ''; })
|
175 | });
|
176 |
|
177 | |
178 |
|
179 |
|
180 | var hyphenateRE = /\B([A-Z])/g;
|
181 | var hyphenate = cached(function (str) {
|
182 | return str.replace(hyphenateRE, '-$1').toLowerCase()
|
183 | });
|
184 |
|
185 | |
186 |
|
187 |
|
188 |
|
189 |
|
190 |
|
191 |
|
192 |
|
193 |
|
194 | function polyfillBind (fn, ctx) {
|
195 | function boundFn (a) {
|
196 | var l = arguments.length;
|
197 | return l
|
198 | ? l > 1
|
199 | ? fn.apply(ctx, arguments)
|
200 | : fn.call(ctx, a)
|
201 | : fn.call(ctx)
|
202 | }
|
203 |
|
204 | boundFn._length = fn.length;
|
205 | return boundFn
|
206 | }
|
207 |
|
208 | function nativeBind (fn, ctx) {
|
209 | return fn.bind(ctx)
|
210 | }
|
211 |
|
212 | var bind = Function.prototype.bind
|
213 | ? nativeBind
|
214 | : polyfillBind;
|
215 |
|
216 | |
217 |
|
218 |
|
219 | function extend (to, _from) {
|
220 | for (var key in _from) {
|
221 | to[key] = _from[key];
|
222 | }
|
223 | return to
|
224 | }
|
225 |
|
226 |
|
227 |
|
228 | |
229 |
|
230 |
|
231 |
|
232 |
|
233 | function noop (a, b, c) {}
|
234 |
|
235 | |
236 |
|
237 |
|
238 | var no = function (a, b, c) { return false; };
|
239 |
|
240 |
|
241 |
|
242 | |
243 |
|
244 |
|
245 | var identity = function (_) { return _; };
|
246 |
|
247 | |
248 |
|
249 |
|
250 | function genStaticKeys (modules) {
|
251 | return modules.reduce(function (keys, m) {
|
252 | return keys.concat(m.staticKeys || [])
|
253 | }, []).join(',')
|
254 | }
|
255 |
|
256 |
|
257 |
|
258 | var isUnaryTag = makeMap(
|
259 | 'area,base,br,col,embed,frame,hr,img,input,isindex,keygen,' +
|
260 | 'link,meta,param,source,track,wbr'
|
261 | );
|
262 |
|
263 |
|
264 |
|
265 | var canBeLeftOpenTag = makeMap(
|
266 | 'colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source'
|
267 | );
|
268 |
|
269 |
|
270 |
|
271 | var isNonPhrasingTag = makeMap(
|
272 | 'address,article,aside,base,blockquote,body,caption,col,colgroup,dd,' +
|
273 | 'details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,' +
|
274 | 'h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,' +
|
275 | 'optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,' +
|
276 | 'title,tr,track'
|
277 | );
|
278 |
|
279 |
|
280 |
|
281 | |
282 |
|
283 |
|
284 |
|
285 |
|
286 | var unicodeRegExp = /a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/;
|
287 |
|
288 | |
289 |
|
290 |
|
291 | function def (obj, key, val, enumerable) {
|
292 | Object.defineProperty(obj, key, {
|
293 | value: val,
|
294 | enumerable: !!enumerable,
|
295 | writable: true,
|
296 | configurable: true
|
297 | });
|
298 | }
|
299 |
|
300 | |
301 |
|
302 |
|
303 |
|
304 |
|
305 | var attribute = /^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/;
|
306 | var dynamicArgAttribute = /^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/;
|
307 | var ncname = "[a-zA-Z_][\\-\\.0-9_a-zA-Z" + (unicodeRegExp.source) + "]*";
|
308 | var qnameCapture = "((?:" + ncname + "\\:)?" + ncname + ")";
|
309 | var startTagOpen = new RegExp(("^<" + qnameCapture));
|
310 | var startTagClose = /^\s*(\/?)>/;
|
311 | var endTag = new RegExp(("^<\\/" + qnameCapture + "[^>]*>"));
|
312 | var doctype = /^<!DOCTYPE [^>]+>/i;
|
313 |
|
314 | var comment = /^<!\--/;
|
315 | var conditionalComment = /^<!\[/;
|
316 |
|
317 |
|
318 | var isPlainTextElement = makeMap('script,style,textarea', true);
|
319 | var reCache = {};
|
320 |
|
321 | var decodingMap = {
|
322 | '<': '<',
|
323 | '>': '>',
|
324 | '"': '"',
|
325 | '&': '&',
|
326 | ' ': '\n',
|
327 | '	': '\t',
|
328 | ''': "'"
|
329 | };
|
330 | var encodedAttr = /&(?:lt|gt|quot|amp|#39);/g;
|
331 | var encodedAttrWithNewLines = /&(?:lt|gt|quot|amp|#39|#10|#9);/g;
|
332 |
|
333 |
|
334 | var isIgnoreNewlineTag = makeMap('pre,textarea', true);
|
335 | var shouldIgnoreFirstNewline = function (tag, html) { return tag && isIgnoreNewlineTag(tag) && html[0] === '\n'; };
|
336 |
|
337 | function decodeAttr (value, shouldDecodeNewlines) {
|
338 | var re = shouldDecodeNewlines ? encodedAttrWithNewLines : encodedAttr;
|
339 | return value.replace(re, function (match) { return decodingMap[match]; })
|
340 | }
|
341 |
|
342 | function parseHTML (html, options) {
|
343 | var stack = [];
|
344 | var expectHTML = options.expectHTML;
|
345 | var isUnaryTag$$1 = options.isUnaryTag || no;
|
346 | var canBeLeftOpenTag$$1 = options.canBeLeftOpenTag || no;
|
347 | var index = 0;
|
348 | var last, lastTag;
|
349 | while (html) {
|
350 | last = html;
|
351 |
|
352 | if (!lastTag || !isPlainTextElement(lastTag)) {
|
353 | var textEnd = html.indexOf('<');
|
354 | if (textEnd === 0) {
|
355 |
|
356 | if (comment.test(html)) {
|
357 | var commentEnd = html.indexOf('-->');
|
358 |
|
359 | if (commentEnd >= 0) {
|
360 | if (options.shouldKeepComment) {
|
361 | options.comment(html.substring(4, commentEnd), index, index + commentEnd + 3);
|
362 | }
|
363 | advance(commentEnd + 3);
|
364 | continue
|
365 | }
|
366 | }
|
367 |
|
368 |
|
369 | if (conditionalComment.test(html)) {
|
370 | var conditionalEnd = html.indexOf(']>');
|
371 |
|
372 | if (conditionalEnd >= 0) {
|
373 | advance(conditionalEnd + 2);
|
374 | continue
|
375 | }
|
376 | }
|
377 |
|
378 |
|
379 | var doctypeMatch = html.match(doctype);
|
380 | if (doctypeMatch) {
|
381 | advance(doctypeMatch[0].length);
|
382 | continue
|
383 | }
|
384 |
|
385 |
|
386 | var endTagMatch = html.match(endTag);
|
387 | if (endTagMatch) {
|
388 | var curIndex = index;
|
389 | advance(endTagMatch[0].length);
|
390 | parseEndTag(endTagMatch[1], curIndex, index);
|
391 | continue
|
392 | }
|
393 |
|
394 |
|
395 | var startTagMatch = parseStartTag();
|
396 | if (startTagMatch) {
|
397 | handleStartTag(startTagMatch);
|
398 | if (shouldIgnoreFirstNewline(startTagMatch.tagName, html)) {
|
399 | advance(1);
|
400 | }
|
401 | continue
|
402 | }
|
403 | }
|
404 |
|
405 | var text = (void 0), rest = (void 0), next = (void 0);
|
406 | if (textEnd >= 0) {
|
407 | rest = html.slice(textEnd);
|
408 | while (
|
409 | !endTag.test(rest) &&
|
410 | !startTagOpen.test(rest) &&
|
411 | !comment.test(rest) &&
|
412 | !conditionalComment.test(rest)
|
413 | ) {
|
414 |
|
415 | next = rest.indexOf('<', 1);
|
416 | if (next < 0) { break }
|
417 | textEnd += next;
|
418 | rest = html.slice(textEnd);
|
419 | }
|
420 | text = html.substring(0, textEnd);
|
421 | }
|
422 |
|
423 | if (textEnd < 0) {
|
424 | text = html;
|
425 | }
|
426 |
|
427 | if (text) {
|
428 | advance(text.length);
|
429 | }
|
430 |
|
431 | if (options.chars && text) {
|
432 | options.chars(text, index - text.length, index);
|
433 | }
|
434 | } else {
|
435 | var endTagLength = 0;
|
436 | var stackedTag = lastTag.toLowerCase();
|
437 | var reStackedTag = reCache[stackedTag] || (reCache[stackedTag] = new RegExp('([\\s\\S]*?)(</' + stackedTag + '[^>]*>)', 'i'));
|
438 | var rest$1 = html.replace(reStackedTag, function (all, text, endTag) {
|
439 | endTagLength = endTag.length;
|
440 | if (!isPlainTextElement(stackedTag) && stackedTag !== 'noscript') {
|
441 | text = text
|
442 | .replace(/<!\--([\s\S]*?)-->/g, '$1')
|
443 | .replace(/<!\[CDATA\[([\s\S]*?)]]>/g, '$1');
|
444 | }
|
445 | if (shouldIgnoreFirstNewline(stackedTag, text)) {
|
446 | text = text.slice(1);
|
447 | }
|
448 | if (options.chars) {
|
449 | options.chars(text);
|
450 | }
|
451 | return ''
|
452 | });
|
453 | index += html.length - rest$1.length;
|
454 | html = rest$1;
|
455 | parseEndTag(stackedTag, index - endTagLength, index);
|
456 | }
|
457 |
|
458 | if (html === last) {
|
459 | options.chars && options.chars(html);
|
460 | if (!stack.length && options.warn) {
|
461 | options.warn(("Mal-formatted tag at end of template: \"" + html + "\""), { start: index + html.length });
|
462 | }
|
463 | break
|
464 | }
|
465 | }
|
466 |
|
467 |
|
468 | parseEndTag();
|
469 |
|
470 | function advance (n) {
|
471 | index += n;
|
472 | html = html.substring(n);
|
473 | }
|
474 |
|
475 | function parseStartTag () {
|
476 | var start = html.match(startTagOpen);
|
477 | if (start) {
|
478 | var match = {
|
479 | tagName: start[1],
|
480 | attrs: [],
|
481 | start: index
|
482 | };
|
483 | advance(start[0].length);
|
484 | var end, attr;
|
485 | while (!(end = html.match(startTagClose)) && (attr = html.match(dynamicArgAttribute) || html.match(attribute))) {
|
486 | attr.start = index;
|
487 | advance(attr[0].length);
|
488 | attr.end = index;
|
489 | match.attrs.push(attr);
|
490 | }
|
491 | if (end) {
|
492 | match.unarySlash = end[1];
|
493 | advance(end[0].length);
|
494 | match.end = index;
|
495 | return match
|
496 | }
|
497 | }
|
498 | }
|
499 |
|
500 | function handleStartTag (match) {
|
501 | var tagName = match.tagName;
|
502 | var unarySlash = match.unarySlash;
|
503 |
|
504 | if (expectHTML) {
|
505 | if (lastTag === 'p' && isNonPhrasingTag(tagName)) {
|
506 | parseEndTag(lastTag);
|
507 | }
|
508 | if (canBeLeftOpenTag$$1(tagName) && lastTag === tagName) {
|
509 | parseEndTag(tagName);
|
510 | }
|
511 | }
|
512 |
|
513 | var unary = isUnaryTag$$1(tagName) || !!unarySlash;
|
514 |
|
515 | var l = match.attrs.length;
|
516 | var attrs = new Array(l);
|
517 | for (var i = 0; i < l; i++) {
|
518 | var args = match.attrs[i];
|
519 | var value = args[3] || args[4] || args[5] || '';
|
520 | var shouldDecodeNewlines = tagName === 'a' && args[1] === 'href'
|
521 | ? options.shouldDecodeNewlinesForHref
|
522 | : options.shouldDecodeNewlines;
|
523 | attrs[i] = {
|
524 | name: args[1],
|
525 | value: decodeAttr(value, shouldDecodeNewlines)
|
526 | };
|
527 | if (options.outputSourceRange) {
|
528 | attrs[i].start = args.start + args[0].match(/^\s*/).length;
|
529 | attrs[i].end = args.end;
|
530 | }
|
531 | }
|
532 |
|
533 | if (!unary) {
|
534 | stack.push({ tag: tagName, lowerCasedTag: tagName.toLowerCase(), attrs: attrs, start: match.start, end: match.end });
|
535 | lastTag = tagName;
|
536 | }
|
537 |
|
538 | if (options.start) {
|
539 | options.start(tagName, attrs, unary, match.start, match.end);
|
540 | }
|
541 | }
|
542 |
|
543 | function parseEndTag (tagName, start, end) {
|
544 | var pos, lowerCasedTagName;
|
545 | if (start == null) { start = index; }
|
546 | if (end == null) { end = index; }
|
547 |
|
548 |
|
549 | if (tagName) {
|
550 | lowerCasedTagName = tagName.toLowerCase();
|
551 | for (pos = stack.length - 1; pos >= 0; pos--) {
|
552 | if (stack[pos].lowerCasedTag === lowerCasedTagName) {
|
553 | break
|
554 | }
|
555 | }
|
556 | } else {
|
557 |
|
558 | pos = 0;
|
559 | }
|
560 |
|
561 | if (pos >= 0) {
|
562 |
|
563 | for (var i = stack.length - 1; i >= pos; i--) {
|
564 | if (i > pos || !tagName &&
|
565 | options.warn
|
566 | ) {
|
567 | options.warn(
|
568 | ("tag <" + (stack[i].tag) + "> has no matching end tag."),
|
569 | { start: stack[i].start, end: stack[i].end }
|
570 | );
|
571 | }
|
572 | if (options.end) {
|
573 | options.end(stack[i].tag, start, end);
|
574 | }
|
575 | }
|
576 |
|
577 |
|
578 | stack.length = pos;
|
579 | lastTag = pos && stack[pos - 1].tag;
|
580 | } else if (lowerCasedTagName === 'br') {
|
581 | if (options.start) {
|
582 | options.start(tagName, [], true, start, end);
|
583 | }
|
584 | } else if (lowerCasedTagName === 'p') {
|
585 | if (options.start) {
|
586 | options.start(tagName, [], false, start, end);
|
587 | }
|
588 | if (options.end) {
|
589 | options.end(tagName, start, end);
|
590 | }
|
591 | }
|
592 | }
|
593 | }
|
594 |
|
595 |
|
596 |
|
597 | var splitRE$1 = /\r?\n/g;
|
598 | var replaceRE = /./g;
|
599 | var isSpecialTag = makeMap('script,style,template', true);
|
600 |
|
601 | |
602 |
|
603 |
|
604 | function parseComponent (
|
605 | content,
|
606 | options
|
607 | ) {
|
608 | if ( options === void 0 ) options = {};
|
609 |
|
610 | var sfc = {
|
611 | template: null,
|
612 | script: null,
|
613 | styles: [],
|
614 | customBlocks: [],
|
615 | errors: []
|
616 | };
|
617 | var depth = 0;
|
618 | var currentBlock = null;
|
619 |
|
620 | var warn = function (msg) {
|
621 | sfc.errors.push(msg);
|
622 | };
|
623 |
|
624 | if (options.outputSourceRange) {
|
625 | warn = function (msg, range) {
|
626 | var data = { msg: msg };
|
627 | if (range.start != null) {
|
628 | data.start = range.start;
|
629 | }
|
630 | if (range.end != null) {
|
631 | data.end = range.end;
|
632 | }
|
633 | sfc.errors.push(data);
|
634 | };
|
635 | }
|
636 |
|
637 | function start (
|
638 | tag,
|
639 | attrs,
|
640 | unary,
|
641 | start,
|
642 | end
|
643 | ) {
|
644 | if (depth === 0) {
|
645 | currentBlock = {
|
646 | type: tag,
|
647 | content: '',
|
648 | start: end,
|
649 | attrs: attrs.reduce(function (cumulated, ref) {
|
650 | var name = ref.name;
|
651 | var value = ref.value;
|
652 |
|
653 | cumulated[name] = value || true;
|
654 | return cumulated
|
655 | }, {})
|
656 | };
|
657 | if (isSpecialTag(tag)) {
|
658 | checkAttrs(currentBlock, attrs);
|
659 | if (tag === 'style') {
|
660 | sfc.styles.push(currentBlock);
|
661 | } else {
|
662 | sfc[tag] = currentBlock;
|
663 | }
|
664 | } else {
|
665 | sfc.customBlocks.push(currentBlock);
|
666 | }
|
667 | }
|
668 | if (!unary) {
|
669 | depth++;
|
670 | }
|
671 | }
|
672 |
|
673 | function checkAttrs (block, attrs) {
|
674 | for (var i = 0; i < attrs.length; i++) {
|
675 | var attr = attrs[i];
|
676 | if (attr.name === 'lang') {
|
677 | block.lang = attr.value;
|
678 | }
|
679 | if (attr.name === 'scoped') {
|
680 | block.scoped = true;
|
681 | }
|
682 | if (attr.name === 'module') {
|
683 | block.module = attr.value || true;
|
684 | }
|
685 | if (attr.name === 'src') {
|
686 | block.src = attr.value;
|
687 | }
|
688 | }
|
689 | }
|
690 |
|
691 | function end (tag, start) {
|
692 | if (depth === 1 && currentBlock) {
|
693 | currentBlock.end = start;
|
694 | var text = content.slice(currentBlock.start, currentBlock.end);
|
695 | if (options.deindent !== false) {
|
696 | text = deIndent(text);
|
697 | }
|
698 |
|
699 |
|
700 | if (currentBlock.type !== 'template' && options.pad) {
|
701 | text = padContent(currentBlock, options.pad) + text;
|
702 | }
|
703 | currentBlock.content = text;
|
704 | currentBlock = null;
|
705 | }
|
706 | depth--;
|
707 | }
|
708 |
|
709 | function padContent (block, pad) {
|
710 | if (pad === 'space') {
|
711 | return content.slice(0, block.start).replace(replaceRE, ' ')
|
712 | } else {
|
713 | var offset = content.slice(0, block.start).split(splitRE$1).length;
|
714 | var padChar = block.type === 'script' && !block.lang
|
715 | ? '//\n'
|
716 | : '\n';
|
717 | return Array(offset).join(padChar)
|
718 | }
|
719 | }
|
720 |
|
721 | parseHTML(content, {
|
722 | warn: warn,
|
723 | start: start,
|
724 | end: end,
|
725 | outputSourceRange: options.outputSourceRange
|
726 | });
|
727 |
|
728 | return sfc
|
729 | }
|
730 |
|
731 |
|
732 |
|
733 |
|
734 | var hasProto = '__proto__' in {};
|
735 |
|
736 |
|
737 | var inBrowser = typeof window !== 'undefined';
|
738 | var inWeex = typeof WXEnvironment !== 'undefined' && !!WXEnvironment.platform;
|
739 | var weexPlatform = inWeex && WXEnvironment.platform.toLowerCase();
|
740 | var UA = inBrowser && window.navigator.userAgent.toLowerCase();
|
741 | var isIE = UA && /msie|trident/.test(UA);
|
742 | var isIE9 = UA && UA.indexOf('msie 9.0') > 0;
|
743 | var isEdge = UA && UA.indexOf('edge/') > 0;
|
744 | var isAndroid = (UA && UA.indexOf('android') > 0) || (weexPlatform === 'android');
|
745 | var isIOS = (UA && /iphone|ipad|ipod|ios/.test(UA)) || (weexPlatform === 'ios');
|
746 | var isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
|
747 | var isPhantomJS = UA && /phantomjs/.test(UA);
|
748 | var isFF = UA && UA.match(/firefox\/(\d+)/);
|
749 |
|
750 |
|
751 | var nativeWatch = ({}).watch;
|
752 | if (inBrowser) {
|
753 | try {
|
754 | var opts = {};
|
755 | Object.defineProperty(opts, 'passive', ({
|
756 | get: function get () {
|
757 | }
|
758 | }));
|
759 | window.addEventListener('test-passive', null, opts);
|
760 | } catch (e) {}
|
761 | }
|
762 |
|
763 |
|
764 |
|
765 | var _isServer;
|
766 | var isServerRendering = function () {
|
767 | if (_isServer === undefined) {
|
768 |
|
769 | if (!inBrowser && !inWeex && typeof global !== 'undefined') {
|
770 |
|
771 |
|
772 | _isServer = global['process'] && global['process'].env.VUE_ENV === 'server';
|
773 | } else {
|
774 | _isServer = false;
|
775 | }
|
776 | }
|
777 | return _isServer
|
778 | };
|
779 |
|
780 |
|
781 | var devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
782 |
|
783 |
|
784 | function isNative (Ctor) {
|
785 | return typeof Ctor === 'function' && /native code/.test(Ctor.toString())
|
786 | }
|
787 |
|
788 | var hasSymbol =
|
789 | typeof Symbol !== 'undefined' && isNative(Symbol) &&
|
790 | typeof Reflect !== 'undefined' && isNative(Reflect.ownKeys);
|
791 |
|
792 | var _Set;
|
793 |
|
794 | if (typeof Set !== 'undefined' && isNative(Set)) {
|
795 |
|
796 | _Set = Set;
|
797 | } else {
|
798 |
|
799 | _Set = (function () {
|
800 | function Set () {
|
801 | this.set = Object.create(null);
|
802 | }
|
803 | Set.prototype.has = function has (key) {
|
804 | return this.set[key] === true
|
805 | };
|
806 | Set.prototype.add = function add (key) {
|
807 | this.set[key] = true;
|
808 | };
|
809 | Set.prototype.clear = function clear () {
|
810 | this.set = Object.create(null);
|
811 | };
|
812 |
|
813 | return Set;
|
814 | }());
|
815 | }
|
816 |
|
817 | var ASSET_TYPES = [
|
818 | 'component',
|
819 | 'directive',
|
820 | 'filter'
|
821 | ];
|
822 |
|
823 | var LIFECYCLE_HOOKS = [
|
824 | 'beforeCreate',
|
825 | 'created',
|
826 | 'beforeMount',
|
827 | 'mounted',
|
828 | 'beforeUpdate',
|
829 | 'updated',
|
830 | 'beforeDestroy',
|
831 | 'destroyed',
|
832 | 'activated',
|
833 | 'deactivated',
|
834 | 'errorCaptured',
|
835 | 'serverPrefetch'
|
836 | ];
|
837 |
|
838 |
|
839 |
|
840 |
|
841 |
|
842 | var config = ({
|
843 | |
844 |
|
845 |
|
846 |
|
847 | optionMergeStrategies: Object.create(null),
|
848 |
|
849 | |
850 |
|
851 |
|
852 | silent: false,
|
853 |
|
854 | |
855 |
|
856 |
|
857 | productionTip: "development" !== 'production',
|
858 |
|
859 | |
860 |
|
861 |
|
862 | devtools: "development" !== 'production',
|
863 |
|
864 | |
865 |
|
866 |
|
867 | performance: false,
|
868 |
|
869 | |
870 |
|
871 |
|
872 | errorHandler: null,
|
873 |
|
874 | |
875 |
|
876 |
|
877 | warnHandler: null,
|
878 |
|
879 | |
880 |
|
881 |
|
882 | ignoredElements: [],
|
883 |
|
884 | |
885 |
|
886 |
|
887 |
|
888 | keyCodes: Object.create(null),
|
889 |
|
890 | |
891 |
|
892 |
|
893 |
|
894 | isReservedTag: no,
|
895 |
|
896 | |
897 |
|
898 |
|
899 |
|
900 | isReservedAttr: no,
|
901 |
|
902 | |
903 |
|
904 |
|
905 |
|
906 | isUnknownElement: no,
|
907 |
|
908 | |
909 |
|
910 |
|
911 | getTagNamespace: noop,
|
912 |
|
913 | |
914 |
|
915 |
|
916 | parsePlatformTagName: identity,
|
917 |
|
918 | |
919 |
|
920 |
|
921 |
|
922 | mustUseProp: no,
|
923 |
|
924 | |
925 |
|
926 |
|
927 |
|
928 | async: true,
|
929 |
|
930 | |
931 |
|
932 |
|
933 | _lifecycleHooks: LIFECYCLE_HOOKS
|
934 | });
|
935 |
|
936 |
|
937 |
|
938 | var warn = noop;
|
939 | var tip = noop;
|
940 | var generateComponentTrace = (noop);
|
941 | var formatComponentName = (noop);
|
942 |
|
943 | {
|
944 | var hasConsole = typeof console !== 'undefined';
|
945 | var classifyRE = /(?:^|[-_])(\w)/g;
|
946 | var classify = function (str) { return str
|
947 | .replace(classifyRE, function (c) { return c.toUpperCase(); })
|
948 | .replace(/[-_]/g, ''); };
|
949 |
|
950 | warn = function (msg, vm) {
|
951 | var trace = vm ? generateComponentTrace(vm) : '';
|
952 |
|
953 | if (hasConsole && (!config.silent)) {
|
954 | console.error(("[Vue warn]: " + msg + trace));
|
955 | }
|
956 | };
|
957 |
|
958 | tip = function (msg, vm) {
|
959 | if (hasConsole && (!config.silent)) {
|
960 | console.warn("[Vue tip]: " + msg + (
|
961 | vm ? generateComponentTrace(vm) : ''
|
962 | ));
|
963 | }
|
964 | };
|
965 |
|
966 | formatComponentName = function (vm, includeFile) {
|
967 | if (vm.$root === vm) {
|
968 | return '<Root>'
|
969 | }
|
970 | var options = typeof vm === 'function' && vm.cid != null
|
971 | ? vm.options
|
972 | : vm._isVue
|
973 | ? vm.$options || vm.constructor.options
|
974 | : vm;
|
975 | var name = options.name || options._componentTag;
|
976 | var file = options.__file;
|
977 | if (!name && file) {
|
978 | var match = file.match(/([^/\\]+)\.vue$/);
|
979 | name = match && match[1];
|
980 | }
|
981 |
|
982 | return (
|
983 | (name ? ("<" + (classify(name)) + ">") : "<Anonymous>") +
|
984 | (file && includeFile !== false ? (" at " + file) : '')
|
985 | )
|
986 | };
|
987 |
|
988 | var repeat = function (str, n) {
|
989 | var res = '';
|
990 | while (n) {
|
991 | if (n % 2 === 1) { res += str; }
|
992 | if (n > 1) { str += str; }
|
993 | n >>= 1;
|
994 | }
|
995 | return res
|
996 | };
|
997 |
|
998 | generateComponentTrace = function (vm) {
|
999 | if (vm._isVue && vm.$parent) {
|
1000 | var tree = [];
|
1001 | var currentRecursiveSequence = 0;
|
1002 | while (vm) {
|
1003 | if (tree.length > 0) {
|
1004 | var last = tree[tree.length - 1];
|
1005 | if (last.constructor === vm.constructor) {
|
1006 | currentRecursiveSequence++;
|
1007 | vm = vm.$parent;
|
1008 | continue
|
1009 | } else if (currentRecursiveSequence > 0) {
|
1010 | tree[tree.length - 1] = [last, currentRecursiveSequence];
|
1011 | currentRecursiveSequence = 0;
|
1012 | }
|
1013 | }
|
1014 | tree.push(vm);
|
1015 | vm = vm.$parent;
|
1016 | }
|
1017 | return '\n\nfound in\n\n' + tree
|
1018 | .map(function (vm, i) { return ("" + (i === 0 ? '---> ' : repeat(' ', 5 + i * 2)) + (Array.isArray(vm)
|
1019 | ? ((formatComponentName(vm[0])) + "... (" + (vm[1]) + " recursive calls)")
|
1020 | : formatComponentName(vm))); })
|
1021 | .join('\n')
|
1022 | } else {
|
1023 | return ("\n\n(found in " + (formatComponentName(vm)) + ")")
|
1024 | }
|
1025 | };
|
1026 | }
|
1027 |
|
1028 |
|
1029 |
|
1030 | var uid = 0;
|
1031 |
|
1032 | |
1033 |
|
1034 |
|
1035 |
|
1036 | var Dep = function Dep () {
|
1037 | this.id = uid++;
|
1038 | this.subs = [];
|
1039 | };
|
1040 |
|
1041 | Dep.prototype.addSub = function addSub (sub) {
|
1042 | this.subs.push(sub);
|
1043 | };
|
1044 |
|
1045 | Dep.prototype.removeSub = function removeSub (sub) {
|
1046 | remove(this.subs, sub);
|
1047 | };
|
1048 |
|
1049 | Dep.prototype.depend = function depend () {
|
1050 | if (Dep.target) {
|
1051 | Dep.target.addDep(this);
|
1052 | }
|
1053 | };
|
1054 |
|
1055 | Dep.prototype.notify = function notify () {
|
1056 |
|
1057 | var subs = this.subs.slice();
|
1058 | for (var i = 0, l = subs.length; i < l; i++) {
|
1059 | subs[i].update();
|
1060 | }
|
1061 | };
|
1062 |
|
1063 |
|
1064 |
|
1065 |
|
1066 | Dep.target = null;
|
1067 |
|
1068 |
|
1069 |
|
1070 | var VNode = function VNode (
|
1071 | tag,
|
1072 | data,
|
1073 | children,
|
1074 | text,
|
1075 | elm,
|
1076 | context,
|
1077 | componentOptions,
|
1078 | asyncFactory
|
1079 | ) {
|
1080 | this.tag = tag;
|
1081 | this.data = data;
|
1082 | this.children = children;
|
1083 | this.text = text;
|
1084 | this.elm = elm;
|
1085 | this.ns = undefined;
|
1086 | this.context = context;
|
1087 | this.fnContext = undefined;
|
1088 | this.fnOptions = undefined;
|
1089 | this.fnScopeId = undefined;
|
1090 | this.key = data && data.key;
|
1091 | this.componentOptions = componentOptions;
|
1092 | this.componentInstance = undefined;
|
1093 | this.parent = undefined;
|
1094 | this.raw = false;
|
1095 | this.isStatic = false;
|
1096 | this.isRootInsert = true;
|
1097 | this.isComment = false;
|
1098 | this.isCloned = false;
|
1099 | this.isOnce = false;
|
1100 | this.asyncFactory = asyncFactory;
|
1101 | this.asyncMeta = undefined;
|
1102 | this.isAsyncPlaceholder = false;
|
1103 | };
|
1104 |
|
1105 | var prototypeAccessors = { child: { configurable: true } };
|
1106 |
|
1107 |
|
1108 |
|
1109 | prototypeAccessors.child.get = function () {
|
1110 | return this.componentInstance
|
1111 | };
|
1112 |
|
1113 | Object.defineProperties( VNode.prototype, prototypeAccessors );
|
1114 |
|
1115 | |
1116 |
|
1117 |
|
1118 |
|
1119 |
|
1120 | var arrayProto = Array.prototype;
|
1121 | var arrayMethods = Object.create(arrayProto);
|
1122 |
|
1123 | var methodsToPatch = [
|
1124 | 'push',
|
1125 | 'pop',
|
1126 | 'shift',
|
1127 | 'unshift',
|
1128 | 'splice',
|
1129 | 'sort',
|
1130 | 'reverse'
|
1131 | ];
|
1132 |
|
1133 | |
1134 |
|
1135 |
|
1136 | methodsToPatch.forEach(function (method) {
|
1137 |
|
1138 | var original = arrayProto[method];
|
1139 | def(arrayMethods, method, function mutator () {
|
1140 | var args = [], len = arguments.length;
|
1141 | while ( len-- ) args[ len ] = arguments[ len ];
|
1142 |
|
1143 | var result = original.apply(this, args);
|
1144 | var ob = this.__ob__;
|
1145 | var inserted;
|
1146 | switch (method) {
|
1147 | case 'push':
|
1148 | case 'unshift':
|
1149 | inserted = args;
|
1150 | break
|
1151 | case 'splice':
|
1152 | inserted = args.slice(2);
|
1153 | break
|
1154 | }
|
1155 | if (inserted) { ob.observeArray(inserted); }
|
1156 |
|
1157 | ob.dep.notify();
|
1158 | return result
|
1159 | });
|
1160 | });
|
1161 |
|
1162 |
|
1163 |
|
1164 | var arrayKeys = Object.getOwnPropertyNames(arrayMethods);
|
1165 |
|
1166 | |
1167 |
|
1168 |
|
1169 |
|
1170 | var shouldObserve = true;
|
1171 |
|
1172 | |
1173 |
|
1174 |
|
1175 |
|
1176 |
|
1177 |
|
1178 | var Observer = function Observer (value) {
|
1179 | this.value = value;
|
1180 | this.dep = new Dep();
|
1181 | this.vmCount = 0;
|
1182 | def(value, '__ob__', this);
|
1183 | if (Array.isArray(value)) {
|
1184 | if (hasProto) {
|
1185 | protoAugment(value, arrayMethods);
|
1186 | } else {
|
1187 | copyAugment(value, arrayMethods, arrayKeys);
|
1188 | }
|
1189 | this.observeArray(value);
|
1190 | } else {
|
1191 | this.walk(value);
|
1192 | }
|
1193 | };
|
1194 |
|
1195 | |
1196 |
|
1197 |
|
1198 |
|
1199 |
|
1200 | Observer.prototype.walk = function walk (obj) {
|
1201 | var keys = Object.keys(obj);
|
1202 | for (var i = 0; i < keys.length; i++) {
|
1203 | defineReactive$$1(obj, keys[i]);
|
1204 | }
|
1205 | };
|
1206 |
|
1207 | |
1208 |
|
1209 |
|
1210 | Observer.prototype.observeArray = function observeArray (items) {
|
1211 | for (var i = 0, l = items.length; i < l; i++) {
|
1212 | observe(items[i]);
|
1213 | }
|
1214 | };
|
1215 |
|
1216 |
|
1217 |
|
1218 | |
1219 |
|
1220 |
|
1221 |
|
1222 | function protoAugment (target, src) {
|
1223 |
|
1224 | target.__proto__ = src;
|
1225 |
|
1226 | }
|
1227 |
|
1228 | |
1229 |
|
1230 |
|
1231 |
|
1232 |
|
1233 | function copyAugment (target, src, keys) {
|
1234 | for (var i = 0, l = keys.length; i < l; i++) {
|
1235 | var key = keys[i];
|
1236 | def(target, key, src[key]);
|
1237 | }
|
1238 | }
|
1239 |
|
1240 | |
1241 |
|
1242 |
|
1243 |
|
1244 |
|
1245 | function observe (value, asRootData) {
|
1246 | if (!isObject(value) || value instanceof VNode) {
|
1247 | return
|
1248 | }
|
1249 | var ob;
|
1250 | if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
|
1251 | ob = value.__ob__;
|
1252 | } else if (
|
1253 | shouldObserve &&
|
1254 | !isServerRendering() &&
|
1255 | (Array.isArray(value) || isPlainObject(value)) &&
|
1256 | Object.isExtensible(value) &&
|
1257 | !value._isVue
|
1258 | ) {
|
1259 | ob = new Observer(value);
|
1260 | }
|
1261 | if (asRootData && ob) {
|
1262 | ob.vmCount++;
|
1263 | }
|
1264 | return ob
|
1265 | }
|
1266 |
|
1267 | |
1268 |
|
1269 |
|
1270 | function defineReactive$$1 (
|
1271 | obj,
|
1272 | key,
|
1273 | val,
|
1274 | customSetter,
|
1275 | shallow
|
1276 | ) {
|
1277 | var dep = new Dep();
|
1278 |
|
1279 | var property = Object.getOwnPropertyDescriptor(obj, key);
|
1280 | if (property && property.configurable === false) {
|
1281 | return
|
1282 | }
|
1283 |
|
1284 |
|
1285 | var getter = property && property.get;
|
1286 | var setter = property && property.set;
|
1287 | if ((!getter || setter) && arguments.length === 2) {
|
1288 | val = obj[key];
|
1289 | }
|
1290 |
|
1291 | var childOb = !shallow && observe(val);
|
1292 | Object.defineProperty(obj, key, {
|
1293 | enumerable: true,
|
1294 | configurable: true,
|
1295 | get: function reactiveGetter () {
|
1296 | var value = getter ? getter.call(obj) : val;
|
1297 | if (Dep.target) {
|
1298 | dep.depend();
|
1299 | if (childOb) {
|
1300 | childOb.dep.depend();
|
1301 | if (Array.isArray(value)) {
|
1302 | dependArray(value);
|
1303 | }
|
1304 | }
|
1305 | }
|
1306 | return value
|
1307 | },
|
1308 | set: function reactiveSetter (newVal) {
|
1309 | var value = getter ? getter.call(obj) : val;
|
1310 |
|
1311 | if (newVal === value || (newVal !== newVal && value !== value)) {
|
1312 | return
|
1313 | }
|
1314 |
|
1315 | if (customSetter) {
|
1316 | customSetter();
|
1317 | }
|
1318 |
|
1319 | if (getter && !setter) { return }
|
1320 | if (setter) {
|
1321 | setter.call(obj, newVal);
|
1322 | } else {
|
1323 | val = newVal;
|
1324 | }
|
1325 | childOb = !shallow && observe(newVal);
|
1326 | dep.notify();
|
1327 | }
|
1328 | });
|
1329 | }
|
1330 |
|
1331 | |
1332 |
|
1333 |
|
1334 |
|
1335 |
|
1336 | function set (target, key, val) {
|
1337 | if (isUndef(target) || isPrimitive(target)
|
1338 | ) {
|
1339 | warn(("Cannot set reactive property on undefined, null, or primitive value: " + ((target))));
|
1340 | }
|
1341 | if (Array.isArray(target) && isValidArrayIndex(key)) {
|
1342 | target.length = Math.max(target.length, key);
|
1343 | target.splice(key, 1, val);
|
1344 | return val
|
1345 | }
|
1346 | if (key in target && !(key in Object.prototype)) {
|
1347 | target[key] = val;
|
1348 | return val
|
1349 | }
|
1350 | var ob = (target).__ob__;
|
1351 | if (target._isVue || (ob && ob.vmCount)) {
|
1352 | warn(
|
1353 | 'Avoid adding reactive properties to a Vue instance or its root $data ' +
|
1354 | 'at runtime - declare it upfront in the data option.'
|
1355 | );
|
1356 | return val
|
1357 | }
|
1358 | if (!ob) {
|
1359 | target[key] = val;
|
1360 | return val
|
1361 | }
|
1362 | defineReactive$$1(ob.value, key, val);
|
1363 | ob.dep.notify();
|
1364 | return val
|
1365 | }
|
1366 |
|
1367 | |
1368 |
|
1369 |
|
1370 |
|
1371 | function dependArray (value) {
|
1372 | for (var e = (void 0), i = 0, l = value.length; i < l; i++) {
|
1373 | e = value[i];
|
1374 | e && e.__ob__ && e.__ob__.dep.depend();
|
1375 | if (Array.isArray(e)) {
|
1376 | dependArray(e);
|
1377 | }
|
1378 | }
|
1379 | }
|
1380 |
|
1381 |
|
1382 |
|
1383 | |
1384 |
|
1385 |
|
1386 |
|
1387 |
|
1388 | var strats = config.optionMergeStrategies;
|
1389 |
|
1390 | |
1391 |
|
1392 |
|
1393 | {
|
1394 | strats.el = strats.propsData = function (parent, child, vm, key) {
|
1395 | if (!vm) {
|
1396 | warn(
|
1397 | "option \"" + key + "\" can only be used during instance " +
|
1398 | 'creation with the `new` keyword.'
|
1399 | );
|
1400 | }
|
1401 | return defaultStrat(parent, child)
|
1402 | };
|
1403 | }
|
1404 |
|
1405 | |
1406 |
|
1407 |
|
1408 | function mergeData (to, from) {
|
1409 | if (!from) { return to }
|
1410 | var key, toVal, fromVal;
|
1411 |
|
1412 | var keys = hasSymbol
|
1413 | ? Reflect.ownKeys(from)
|
1414 | : Object.keys(from);
|
1415 |
|
1416 | for (var i = 0; i < keys.length; i++) {
|
1417 | key = keys[i];
|
1418 |
|
1419 | if (key === '__ob__') { continue }
|
1420 | toVal = to[key];
|
1421 | fromVal = from[key];
|
1422 | if (!hasOwn(to, key)) {
|
1423 | set(to, key, fromVal);
|
1424 | } else if (
|
1425 | toVal !== fromVal &&
|
1426 | isPlainObject(toVal) &&
|
1427 | isPlainObject(fromVal)
|
1428 | ) {
|
1429 | mergeData(toVal, fromVal);
|
1430 | }
|
1431 | }
|
1432 | return to
|
1433 | }
|
1434 |
|
1435 | |
1436 |
|
1437 |
|
1438 | function mergeDataOrFn (
|
1439 | parentVal,
|
1440 | childVal,
|
1441 | vm
|
1442 | ) {
|
1443 | if (!vm) {
|
1444 |
|
1445 | if (!childVal) {
|
1446 | return parentVal
|
1447 | }
|
1448 | if (!parentVal) {
|
1449 | return childVal
|
1450 | }
|
1451 |
|
1452 |
|
1453 |
|
1454 |
|
1455 |
|
1456 | return function mergedDataFn () {
|
1457 | return mergeData(
|
1458 | typeof childVal === 'function' ? childVal.call(this, this) : childVal,
|
1459 | typeof parentVal === 'function' ? parentVal.call(this, this) : parentVal
|
1460 | )
|
1461 | }
|
1462 | } else {
|
1463 | return function mergedInstanceDataFn () {
|
1464 |
|
1465 | var instanceData = typeof childVal === 'function'
|
1466 | ? childVal.call(vm, vm)
|
1467 | : childVal;
|
1468 | var defaultData = typeof parentVal === 'function'
|
1469 | ? parentVal.call(vm, vm)
|
1470 | : parentVal;
|
1471 | if (instanceData) {
|
1472 | return mergeData(instanceData, defaultData)
|
1473 | } else {
|
1474 | return defaultData
|
1475 | }
|
1476 | }
|
1477 | }
|
1478 | }
|
1479 |
|
1480 | strats.data = function (
|
1481 | parentVal,
|
1482 | childVal,
|
1483 | vm
|
1484 | ) {
|
1485 | if (!vm) {
|
1486 | if (childVal && typeof childVal !== 'function') {
|
1487 | warn(
|
1488 | 'The "data" option should be a function ' +
|
1489 | 'that returns a per-instance value in component ' +
|
1490 | 'definitions.',
|
1491 | vm
|
1492 | );
|
1493 |
|
1494 | return parentVal
|
1495 | }
|
1496 | return mergeDataOrFn(parentVal, childVal)
|
1497 | }
|
1498 |
|
1499 | return mergeDataOrFn(parentVal, childVal, vm)
|
1500 | };
|
1501 |
|
1502 | |
1503 |
|
1504 |
|
1505 | function mergeHook (
|
1506 | parentVal,
|
1507 | childVal
|
1508 | ) {
|
1509 | var res = childVal
|
1510 | ? parentVal
|
1511 | ? parentVal.concat(childVal)
|
1512 | : Array.isArray(childVal)
|
1513 | ? childVal
|
1514 | : [childVal]
|
1515 | : parentVal;
|
1516 | return res
|
1517 | ? dedupeHooks(res)
|
1518 | : res
|
1519 | }
|
1520 |
|
1521 | function dedupeHooks (hooks) {
|
1522 | var res = [];
|
1523 | for (var i = 0; i < hooks.length; i++) {
|
1524 | if (res.indexOf(hooks[i]) === -1) {
|
1525 | res.push(hooks[i]);
|
1526 | }
|
1527 | }
|
1528 | return res
|
1529 | }
|
1530 |
|
1531 | LIFECYCLE_HOOKS.forEach(function (hook) {
|
1532 | strats[hook] = mergeHook;
|
1533 | });
|
1534 |
|
1535 | |
1536 |
|
1537 |
|
1538 |
|
1539 |
|
1540 |
|
1541 |
|
1542 | function mergeAssets (
|
1543 | parentVal,
|
1544 | childVal,
|
1545 | vm,
|
1546 | key
|
1547 | ) {
|
1548 | var res = Object.create(parentVal || null);
|
1549 | if (childVal) {
|
1550 | assertObjectType(key, childVal, vm);
|
1551 | return extend(res, childVal)
|
1552 | } else {
|
1553 | return res
|
1554 | }
|
1555 | }
|
1556 |
|
1557 | ASSET_TYPES.forEach(function (type) {
|
1558 | strats[type + 's'] = mergeAssets;
|
1559 | });
|
1560 |
|
1561 | |
1562 |
|
1563 |
|
1564 |
|
1565 |
|
1566 |
|
1567 | strats.watch = function (
|
1568 | parentVal,
|
1569 | childVal,
|
1570 | vm,
|
1571 | key
|
1572 | ) {
|
1573 |
|
1574 | if (parentVal === nativeWatch) { parentVal = undefined; }
|
1575 | if (childVal === nativeWatch) { childVal = undefined; }
|
1576 |
|
1577 | if (!childVal) { return Object.create(parentVal || null) }
|
1578 | {
|
1579 | assertObjectType(key, childVal, vm);
|
1580 | }
|
1581 | if (!parentVal) { return childVal }
|
1582 | var ret = {};
|
1583 | extend(ret, parentVal);
|
1584 | for (var key$1 in childVal) {
|
1585 | var parent = ret[key$1];
|
1586 | var child = childVal[key$1];
|
1587 | if (parent && !Array.isArray(parent)) {
|
1588 | parent = [parent];
|
1589 | }
|
1590 | ret[key$1] = parent
|
1591 | ? parent.concat(child)
|
1592 | : Array.isArray(child) ? child : [child];
|
1593 | }
|
1594 | return ret
|
1595 | };
|
1596 |
|
1597 | |
1598 |
|
1599 |
|
1600 | strats.props =
|
1601 | strats.methods =
|
1602 | strats.inject =
|
1603 | strats.computed = function (
|
1604 | parentVal,
|
1605 | childVal,
|
1606 | vm,
|
1607 | key
|
1608 | ) {
|
1609 | if (childVal && "development" !== 'production') {
|
1610 | assertObjectType(key, childVal, vm);
|
1611 | }
|
1612 | if (!parentVal) { return childVal }
|
1613 | var ret = Object.create(null);
|
1614 | extend(ret, parentVal);
|
1615 | if (childVal) { extend(ret, childVal); }
|
1616 | return ret
|
1617 | };
|
1618 | strats.provide = mergeDataOrFn;
|
1619 |
|
1620 | |
1621 |
|
1622 |
|
1623 | var defaultStrat = function (parentVal, childVal) {
|
1624 | return childVal === undefined
|
1625 | ? parentVal
|
1626 | : childVal
|
1627 | };
|
1628 |
|
1629 | function assertObjectType (name, value, vm) {
|
1630 | if (!isPlainObject(value)) {
|
1631 | warn(
|
1632 | "Invalid value for option \"" + name + "\": expected an Object, " +
|
1633 | "but got " + (toRawType(value)) + ".",
|
1634 | vm
|
1635 | );
|
1636 | }
|
1637 | }
|
1638 |
|
1639 |
|
1640 |
|
1641 |
|
1642 |
|
1643 |
|
1644 |
|
1645 | var callbacks = [];
|
1646 |
|
1647 | function flushCallbacks () {
|
1648 | var copies = callbacks.slice(0);
|
1649 | callbacks.length = 0;
|
1650 | for (var i = 0; i < copies.length; i++) {
|
1651 | copies[i]();
|
1652 | }
|
1653 | }
|
1654 |
|
1655 |
|
1656 |
|
1657 |
|
1658 |
|
1659 |
|
1660 |
|
1661 |
|
1662 | if (typeof Promise !== 'undefined' && isNative(Promise)) ; else if (!isIE && typeof MutationObserver !== 'undefined' && (
|
1663 | isNative(MutationObserver) ||
|
1664 |
|
1665 | MutationObserver.toString() === '[object MutationObserverConstructor]'
|
1666 | )) {
|
1667 |
|
1668 |
|
1669 |
|
1670 | var counter = 1;
|
1671 | var observer = new MutationObserver(flushCallbacks);
|
1672 | var textNode = document.createTextNode(String(counter));
|
1673 | observer.observe(textNode, {
|
1674 | characterData: true
|
1675 | });
|
1676 | } else if (typeof setImmediate !== 'undefined' && isNative(setImmediate)) ;
|
1677 |
|
1678 |
|
1679 |
|
1680 |
|
1681 |
|
1682 |
|
1683 |
|
1684 | var isReservedAttr = makeMap('style,class');
|
1685 |
|
1686 |
|
1687 | var acceptValue = makeMap('input,textarea,option,select,progress');
|
1688 | var mustUseProp = function (tag, type, attr) {
|
1689 | return (
|
1690 | (attr === 'value' && acceptValue(tag)) && type !== 'button' ||
|
1691 | (attr === 'selected' && tag === 'option') ||
|
1692 | (attr === 'checked' && tag === 'input') ||
|
1693 | (attr === 'muted' && tag === 'video')
|
1694 | )
|
1695 | };
|
1696 |
|
1697 | var isEnumeratedAttr = makeMap('contenteditable,draggable,spellcheck');
|
1698 |
|
1699 | var isValidContentEditableValue = makeMap('events,caret,typing,plaintext-only');
|
1700 |
|
1701 | var isBooleanAttr = makeMap(
|
1702 | 'allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,' +
|
1703 | 'default,defaultchecked,defaultmuted,defaultselected,defer,disabled,' +
|
1704 | 'enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,' +
|
1705 | 'muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,' +
|
1706 | 'required,reversed,scoped,seamless,selected,sortable,translate,' +
|
1707 | 'truespeed,typemustmatch,visible'
|
1708 | );
|
1709 |
|
1710 |
|
1711 |
|
1712 |
|
1713 |
|
1714 | var isHTMLTag = makeMap(
|
1715 | 'html,body,base,head,link,meta,style,title,' +
|
1716 | 'address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,' +
|
1717 | 'div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,' +
|
1718 | 'a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,' +
|
1719 | 's,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,' +
|
1720 | 'embed,object,param,source,canvas,script,noscript,del,ins,' +
|
1721 | 'caption,col,colgroup,table,thead,tbody,td,th,tr,' +
|
1722 | 'button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,' +
|
1723 | 'output,progress,select,textarea,' +
|
1724 | 'details,dialog,menu,menuitem,summary,' +
|
1725 | 'content,element,shadow,template,blockquote,iframe,tfoot'
|
1726 | );
|
1727 |
|
1728 |
|
1729 |
|
1730 | var isSVG = makeMap(
|
1731 | 'svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,' +
|
1732 | 'foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,' +
|
1733 | 'polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view',
|
1734 | true
|
1735 | );
|
1736 |
|
1737 | var isPreTag = function (tag) { return tag === 'pre'; };
|
1738 |
|
1739 | var isReservedTag = function (tag) {
|
1740 | return isHTMLTag(tag) || isSVG(tag)
|
1741 | };
|
1742 |
|
1743 | function getTagNamespace (tag) {
|
1744 | if (isSVG(tag)) {
|
1745 | return 'svg'
|
1746 | }
|
1747 |
|
1748 |
|
1749 | if (tag === 'math') {
|
1750 | return 'math'
|
1751 | }
|
1752 | }
|
1753 |
|
1754 | var isTextInputType = makeMap('text,number,password,search,email,tel,url');
|
1755 |
|
1756 |
|
1757 |
|
1758 |
|
1759 |
|
1760 | var validDivisionCharRE = /[\w).+\-_$\]]/;
|
1761 |
|
1762 | function parseFilters (exp) {
|
1763 | var inSingle = false;
|
1764 | var inDouble = false;
|
1765 | var inTemplateString = false;
|
1766 | var inRegex = false;
|
1767 | var curly = 0;
|
1768 | var square = 0;
|
1769 | var paren = 0;
|
1770 | var lastFilterIndex = 0;
|
1771 | var c, prev, i, expression, filters;
|
1772 |
|
1773 | for (i = 0; i < exp.length; i++) {
|
1774 | prev = c;
|
1775 | c = exp.charCodeAt(i);
|
1776 | if (inSingle) {
|
1777 | if (c === 0x27 && prev !== 0x5C) { inSingle = false; }
|
1778 | } else if (inDouble) {
|
1779 | if (c === 0x22 && prev !== 0x5C) { inDouble = false; }
|
1780 | } else if (inTemplateString) {
|
1781 | if (c === 0x60 && prev !== 0x5C) { inTemplateString = false; }
|
1782 | } else if (inRegex) {
|
1783 | if (c === 0x2f && prev !== 0x5C) { inRegex = false; }
|
1784 | } else if (
|
1785 | c === 0x7C &&
|
1786 | exp.charCodeAt(i + 1) !== 0x7C &&
|
1787 | exp.charCodeAt(i - 1) !== 0x7C &&
|
1788 | !curly && !square && !paren
|
1789 | ) {
|
1790 | if (expression === undefined) {
|
1791 |
|
1792 | lastFilterIndex = i + 1;
|
1793 | expression = exp.slice(0, i).trim();
|
1794 | } else {
|
1795 | pushFilter();
|
1796 | }
|
1797 | } else {
|
1798 | switch (c) {
|
1799 | case 0x22: inDouble = true; break
|
1800 | case 0x27: inSingle = true; break
|
1801 | case 0x60: inTemplateString = true; break
|
1802 | case 0x28: paren++; break
|
1803 | case 0x29: paren--; break
|
1804 | case 0x5B: square++; break
|
1805 | case 0x5D: square--; break
|
1806 | case 0x7B: curly++; break
|
1807 | case 0x7D: curly--; break
|
1808 | }
|
1809 | if (c === 0x2f) {
|
1810 | var j = i - 1;
|
1811 | var p = (void 0);
|
1812 |
|
1813 | for (; j >= 0; j--) {
|
1814 | p = exp.charAt(j);
|
1815 | if (p !== ' ') { break }
|
1816 | }
|
1817 | if (!p || !validDivisionCharRE.test(p)) {
|
1818 | inRegex = true;
|
1819 | }
|
1820 | }
|
1821 | }
|
1822 | }
|
1823 |
|
1824 | if (expression === undefined) {
|
1825 | expression = exp.slice(0, i).trim();
|
1826 | } else if (lastFilterIndex !== 0) {
|
1827 | pushFilter();
|
1828 | }
|
1829 |
|
1830 | function pushFilter () {
|
1831 | (filters || (filters = [])).push(exp.slice(lastFilterIndex, i).trim());
|
1832 | lastFilterIndex = i + 1;
|
1833 | }
|
1834 |
|
1835 | if (filters) {
|
1836 | for (i = 0; i < filters.length; i++) {
|
1837 | expression = wrapFilter(expression, filters[i]);
|
1838 | }
|
1839 | }
|
1840 |
|
1841 | return expression
|
1842 | }
|
1843 |
|
1844 | function wrapFilter (exp, filter) {
|
1845 | var i = filter.indexOf('(');
|
1846 | if (i < 0) {
|
1847 |
|
1848 | return ("_f(\"" + filter + "\")(" + exp + ")")
|
1849 | } else {
|
1850 | var name = filter.slice(0, i);
|
1851 | var args = filter.slice(i + 1);
|
1852 | return ("_f(\"" + name + "\")(" + exp + (args !== ')' ? ',' + args : args))
|
1853 | }
|
1854 | }
|
1855 |
|
1856 |
|
1857 |
|
1858 | var defaultTagRE = /\{\{((?:.|\r?\n)+?)\}\}/g;
|
1859 | var regexEscapeRE = /[-.*+?^${}()|[\]\/\\]/g;
|
1860 |
|
1861 | var buildRegex = cached(function (delimiters) {
|
1862 | var open = delimiters[0].replace(regexEscapeRE, '\\$&');
|
1863 | var close = delimiters[1].replace(regexEscapeRE, '\\$&');
|
1864 | return new RegExp(open + '((?:.|\\n)+?)' + close, 'g')
|
1865 | });
|
1866 |
|
1867 |
|
1868 |
|
1869 | function parseText (
|
1870 | text,
|
1871 | delimiters
|
1872 | ) {
|
1873 | var tagRE = delimiters ? buildRegex(delimiters) : defaultTagRE;
|
1874 | if (!tagRE.test(text)) {
|
1875 | return
|
1876 | }
|
1877 | var tokens = [];
|
1878 | var rawTokens = [];
|
1879 | var lastIndex = tagRE.lastIndex = 0;
|
1880 | var match, index, tokenValue;
|
1881 | while ((match = tagRE.exec(text))) {
|
1882 | index = match.index;
|
1883 |
|
1884 | if (index > lastIndex) {
|
1885 | rawTokens.push(tokenValue = text.slice(lastIndex, index));
|
1886 | tokens.push(JSON.stringify(tokenValue));
|
1887 | }
|
1888 |
|
1889 | var exp = parseFilters(match[1].trim());
|
1890 | tokens.push(("_s(" + exp + ")"));
|
1891 | rawTokens.push({ '@binding': exp });
|
1892 | lastIndex = index + match[0].length;
|
1893 | }
|
1894 | if (lastIndex < text.length) {
|
1895 | rawTokens.push(tokenValue = text.slice(lastIndex));
|
1896 | tokens.push(JSON.stringify(tokenValue));
|
1897 | }
|
1898 | return {
|
1899 | expression: tokens.join('+'),
|
1900 | tokens: rawTokens
|
1901 | }
|
1902 | }
|
1903 |
|
1904 |
|
1905 |
|
1906 |
|
1907 |
|
1908 |
|
1909 | function baseWarn (msg, range) {
|
1910 | console.error(("[Vue compiler]: " + msg));
|
1911 | }
|
1912 |
|
1913 |
|
1914 | function pluckModuleFunction (
|
1915 | modules,
|
1916 | key
|
1917 | ) {
|
1918 | return modules
|
1919 | ? modules.map(function (m) { return m[key]; }).filter(function (_) { return _; })
|
1920 | : []
|
1921 | }
|
1922 |
|
1923 | function addProp (el, name, value, range, dynamic) {
|
1924 | (el.props || (el.props = [])).push(rangeSetItem({ name: name, value: value, dynamic: dynamic }, range));
|
1925 | el.plain = false;
|
1926 | }
|
1927 |
|
1928 | function addAttr (el, name, value, range, dynamic) {
|
1929 | var attrs = dynamic
|
1930 | ? (el.dynamicAttrs || (el.dynamicAttrs = []))
|
1931 | : (el.attrs || (el.attrs = []));
|
1932 | attrs.push(rangeSetItem({ name: name, value: value, dynamic: dynamic }, range));
|
1933 | el.plain = false;
|
1934 | }
|
1935 |
|
1936 |
|
1937 | function addRawAttr (el, name, value, range) {
|
1938 | el.attrsMap[name] = value;
|
1939 | el.attrsList.push(rangeSetItem({ name: name, value: value }, range));
|
1940 | }
|
1941 |
|
1942 | function addDirective (
|
1943 | el,
|
1944 | name,
|
1945 | rawName,
|
1946 | value,
|
1947 | arg,
|
1948 | isDynamicArg,
|
1949 | modifiers,
|
1950 | range
|
1951 | ) {
|
1952 | (el.directives || (el.directives = [])).push(rangeSetItem({
|
1953 | name: name,
|
1954 | rawName: rawName,
|
1955 | value: value,
|
1956 | arg: arg,
|
1957 | isDynamicArg: isDynamicArg,
|
1958 | modifiers: modifiers
|
1959 | }, range));
|
1960 | el.plain = false;
|
1961 | }
|
1962 |
|
1963 | function prependModifierMarker (symbol, name, dynamic) {
|
1964 | return dynamic
|
1965 | ? ("_p(" + name + ",\"" + symbol + "\")")
|
1966 | : symbol + name
|
1967 | }
|
1968 |
|
1969 | function addHandler (
|
1970 | el,
|
1971 | name,
|
1972 | value,
|
1973 | modifiers,
|
1974 | important,
|
1975 | warn,
|
1976 | range,
|
1977 | dynamic
|
1978 | ) {
|
1979 | modifiers = modifiers || emptyObject;
|
1980 |
|
1981 |
|
1982 | if (
|
1983 | warn &&
|
1984 | modifiers.prevent && modifiers.passive
|
1985 | ) {
|
1986 | warn(
|
1987 | 'passive and prevent can\'t be used together. ' +
|
1988 | 'Passive handler can\'t prevent default event.',
|
1989 | range
|
1990 | );
|
1991 | }
|
1992 |
|
1993 |
|
1994 |
|
1995 |
|
1996 | if (modifiers.right) {
|
1997 | if (dynamic) {
|
1998 | name = "(" + name + ")==='click'?'contextmenu':(" + name + ")";
|
1999 | } else if (name === 'click') {
|
2000 | name = 'contextmenu';
|
2001 | delete modifiers.right;
|
2002 | }
|
2003 | } else if (modifiers.middle) {
|
2004 | if (dynamic) {
|
2005 | name = "(" + name + ")==='click'?'mouseup':(" + name + ")";
|
2006 | } else if (name === 'click') {
|
2007 | name = 'mouseup';
|
2008 | }
|
2009 | }
|
2010 |
|
2011 |
|
2012 | if (modifiers.capture) {
|
2013 | delete modifiers.capture;
|
2014 | name = prependModifierMarker('!', name, dynamic);
|
2015 | }
|
2016 | if (modifiers.once) {
|
2017 | delete modifiers.once;
|
2018 | name = prependModifierMarker('~', name, dynamic);
|
2019 | }
|
2020 |
|
2021 | if (modifiers.passive) {
|
2022 | delete modifiers.passive;
|
2023 | name = prependModifierMarker('&', name, dynamic);
|
2024 | }
|
2025 |
|
2026 | var events;
|
2027 | if (modifiers.native) {
|
2028 | delete modifiers.native;
|
2029 | events = el.nativeEvents || (el.nativeEvents = {});
|
2030 | } else {
|
2031 | events = el.events || (el.events = {});
|
2032 | }
|
2033 |
|
2034 | var newHandler = rangeSetItem({ value: value.trim(), dynamic: dynamic }, range);
|
2035 | if (modifiers !== emptyObject) {
|
2036 | newHandler.modifiers = modifiers;
|
2037 | }
|
2038 |
|
2039 | var handlers = events[name];
|
2040 |
|
2041 | if (Array.isArray(handlers)) {
|
2042 | important ? handlers.unshift(newHandler) : handlers.push(newHandler);
|
2043 | } else if (handlers) {
|
2044 | events[name] = important ? [newHandler, handlers] : [handlers, newHandler];
|
2045 | } else {
|
2046 | events[name] = newHandler;
|
2047 | }
|
2048 |
|
2049 | el.plain = false;
|
2050 | }
|
2051 |
|
2052 | function getRawBindingAttr (
|
2053 | el,
|
2054 | name
|
2055 | ) {
|
2056 | return el.rawAttrsMap[':' + name] ||
|
2057 | el.rawAttrsMap['v-bind:' + name] ||
|
2058 | el.rawAttrsMap[name]
|
2059 | }
|
2060 |
|
2061 | function getBindingAttr (
|
2062 | el,
|
2063 | name,
|
2064 | getStatic
|
2065 | ) {
|
2066 | var dynamicValue =
|
2067 | getAndRemoveAttr(el, ':' + name) ||
|
2068 | getAndRemoveAttr(el, 'v-bind:' + name);
|
2069 | if (dynamicValue != null) {
|
2070 | return parseFilters(dynamicValue)
|
2071 | } else if (getStatic !== false) {
|
2072 | var staticValue = getAndRemoveAttr(el, name);
|
2073 | if (staticValue != null) {
|
2074 | return JSON.stringify(staticValue)
|
2075 | }
|
2076 | }
|
2077 | }
|
2078 |
|
2079 |
|
2080 |
|
2081 |
|
2082 |
|
2083 | function getAndRemoveAttr (
|
2084 | el,
|
2085 | name,
|
2086 | removeFromMap
|
2087 | ) {
|
2088 | var val;
|
2089 | if ((val = el.attrsMap[name]) != null) {
|
2090 | var list = el.attrsList;
|
2091 | for (var i = 0, l = list.length; i < l; i++) {
|
2092 | if (list[i].name === name) {
|
2093 | list.splice(i, 1);
|
2094 | break
|
2095 | }
|
2096 | }
|
2097 | }
|
2098 | if (removeFromMap) {
|
2099 | delete el.attrsMap[name];
|
2100 | }
|
2101 | return val
|
2102 | }
|
2103 |
|
2104 | function getAndRemoveAttrByRegex (
|
2105 | el,
|
2106 | name
|
2107 | ) {
|
2108 | var list = el.attrsList;
|
2109 | for (var i = 0, l = list.length; i < l; i++) {
|
2110 | var attr = list[i];
|
2111 | if (name.test(attr.name)) {
|
2112 | list.splice(i, 1);
|
2113 | return attr
|
2114 | }
|
2115 | }
|
2116 | }
|
2117 |
|
2118 | function rangeSetItem (
|
2119 | item,
|
2120 | range
|
2121 | ) {
|
2122 | if (range) {
|
2123 | if (range.start != null) {
|
2124 | item.start = range.start;
|
2125 | }
|
2126 | if (range.end != null) {
|
2127 | item.end = range.end;
|
2128 | }
|
2129 | }
|
2130 | return item
|
2131 | }
|
2132 |
|
2133 |
|
2134 |
|
2135 | function transformNode (el, options) {
|
2136 | var warn = options.warn || baseWarn;
|
2137 | var staticClass = getAndRemoveAttr(el, 'class');
|
2138 | if (staticClass) {
|
2139 | var res = parseText(staticClass, options.delimiters);
|
2140 | if (res) {
|
2141 | warn(
|
2142 | "class=\"" + staticClass + "\": " +
|
2143 | 'Interpolation inside attributes has been removed. ' +
|
2144 | 'Use v-bind or the colon shorthand instead. For example, ' +
|
2145 | 'instead of <div class="{{ val }}">, use <div :class="val">.',
|
2146 | el.rawAttrsMap['class']
|
2147 | );
|
2148 | }
|
2149 | }
|
2150 | if (staticClass) {
|
2151 | el.staticClass = JSON.stringify(staticClass);
|
2152 | }
|
2153 | var classBinding = getBindingAttr(el, 'class', false );
|
2154 | if (classBinding) {
|
2155 | el.classBinding = classBinding;
|
2156 | }
|
2157 | }
|
2158 |
|
2159 | function genData (el) {
|
2160 | var data = '';
|
2161 | if (el.staticClass) {
|
2162 | data += "staticClass:" + (el.staticClass) + ",";
|
2163 | }
|
2164 | if (el.classBinding) {
|
2165 | data += "class:" + (el.classBinding) + ",";
|
2166 | }
|
2167 | return data
|
2168 | }
|
2169 |
|
2170 | var klass = {
|
2171 | staticKeys: ['staticClass'],
|
2172 | transformNode: transformNode,
|
2173 | genData: genData
|
2174 | };
|
2175 |
|
2176 |
|
2177 |
|
2178 | var parseStyleText = cached(function (cssText) {
|
2179 | var res = {};
|
2180 | var listDelimiter = /;(?![^(]*\))/g;
|
2181 | var propertyDelimiter = /:(.+)/;
|
2182 | cssText.split(listDelimiter).forEach(function (item) {
|
2183 | if (item) {
|
2184 | var tmp = item.split(propertyDelimiter);
|
2185 | tmp.length > 1 && (res[tmp[0].trim()] = tmp[1].trim());
|
2186 | }
|
2187 | });
|
2188 | return res
|
2189 | });
|
2190 |
|
2191 |
|
2192 |
|
2193 | function transformNode$1 (el, options) {
|
2194 | var warn = options.warn || baseWarn;
|
2195 | var staticStyle = getAndRemoveAttr(el, 'style');
|
2196 | if (staticStyle) {
|
2197 |
|
2198 | {
|
2199 | var res = parseText(staticStyle, options.delimiters);
|
2200 | if (res) {
|
2201 | warn(
|
2202 | "style=\"" + staticStyle + "\": " +
|
2203 | 'Interpolation inside attributes has been removed. ' +
|
2204 | 'Use v-bind or the colon shorthand instead. For example, ' +
|
2205 | 'instead of <div style="{{ val }}">, use <div :style="val">.',
|
2206 | el.rawAttrsMap['style']
|
2207 | );
|
2208 | }
|
2209 | }
|
2210 | el.staticStyle = JSON.stringify(parseStyleText(staticStyle));
|
2211 | }
|
2212 |
|
2213 | var styleBinding = getBindingAttr(el, 'style', false );
|
2214 | if (styleBinding) {
|
2215 | el.styleBinding = styleBinding;
|
2216 | }
|
2217 | }
|
2218 |
|
2219 | function genData$1 (el) {
|
2220 | var data = '';
|
2221 | if (el.staticStyle) {
|
2222 | data += "staticStyle:" + (el.staticStyle) + ",";
|
2223 | }
|
2224 | if (el.styleBinding) {
|
2225 | data += "style:(" + (el.styleBinding) + "),";
|
2226 | }
|
2227 | return data
|
2228 | }
|
2229 |
|
2230 | var style = {
|
2231 | staticKeys: ['staticStyle'],
|
2232 | transformNode: transformNode$1,
|
2233 | genData: genData$1
|
2234 | };
|
2235 |
|
2236 | var commonjsGlobal = typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
2237 |
|
2238 | function createCommonjsModule(fn, module) {
|
2239 | return module = { exports: {} }, fn(module, module.exports), module.exports;
|
2240 | }
|
2241 |
|
2242 | var he = createCommonjsModule(function (module, exports) {
|
2243 | (function(root) {
|
2244 |
|
2245 |
|
2246 | var freeExports = exports;
|
2247 |
|
2248 |
|
2249 | var freeModule = module &&
|
2250 | module.exports == freeExports && module;
|
2251 |
|
2252 |
|
2253 |
|
2254 | var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal;
|
2255 | if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) {
|
2256 | root = freeGlobal;
|
2257 | }
|
2258 |
|
2259 |
|
2260 |
|
2261 |
|
2262 | var regexAstralSymbols = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g;
|
2263 |
|
2264 |
|
2265 |
|
2266 | var regexAsciiWhitelist = /[\x01-\x7F]/g;
|
2267 |
|
2268 |
|
2269 |
|
2270 | var regexBmpWhitelist = /[\x01-\t\x0B\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g;
|
2271 |
|
2272 | var regexEncodeNonAscii = /<\u20D2|=\u20E5|>\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g;
|
2273 | var encodeMap = {'\xAD':'shy','\u200C':'zwnj','\u200D':'zwj','\u200E':'lrm','\u2063':'ic','\u2062':'it','\u2061':'af','\u200F':'rlm','\u200B':'ZeroWidthSpace','\u2060':'NoBreak','\u0311':'DownBreve','\u20DB':'tdot','\u20DC':'DotDot','\t':'Tab','\n':'NewLine','\u2008':'puncsp','\u205F':'MediumSpace','\u2009':'thinsp','\u200A':'hairsp','\u2004':'emsp13','\u2002':'ensp','\u2005':'emsp14','\u2003':'emsp','\u2007':'numsp','\xA0':'nbsp','\u205F\u200A':'ThickSpace','\u203E':'oline','_':'lowbar','\u2010':'dash','\u2013':'ndash','\u2014':'mdash','\u2015':'horbar',',':'comma',';':'semi','\u204F':'bsemi',':':'colon','\u2A74':'Colone','!':'excl','\xA1':'iexcl','?':'quest','\xBF':'iquest','.':'period','\u2025':'nldr','\u2026':'mldr','\xB7':'middot','\'':'apos','\u2018':'lsquo','\u2019':'rsquo','\u201A':'sbquo','\u2039':'lsaquo','\u203A':'rsaquo','"':'quot','\u201C':'ldquo','\u201D':'rdquo','\u201E':'bdquo','\xAB':'laquo','\xBB':'raquo','(':'lpar',')':'rpar','[':'lsqb',']':'rsqb','{':'lcub','}':'rcub','\u2308':'lceil','\u2309':'rceil','\u230A':'lfloor','\u230B':'rfloor','\u2985':'lopar','\u2986':'ropar','\u298B':'lbrke','\u298C':'rbrke','\u298D':'lbrkslu','\u298E':'rbrksld','\u298F':'lbrksld','\u2990':'rbrkslu','\u2991':'langd','\u2992':'rangd','\u2993':'lparlt','\u2994':'rpargt','\u2995':'gtlPar','\u2996':'ltrPar','\u27E6':'lobrk','\u27E7':'robrk','\u27E8':'lang','\u27E9':'rang','\u27EA':'Lang','\u27EB':'Rang','\u27EC':'loang','\u27ED':'roang','\u2772':'lbbrk','\u2773':'rbbrk','\u2016':'Vert','\xA7':'sect','\xB6':'para','@':'commat','*':'ast','/':'sol','undefined':null,'&':'amp','#':'num','%':'percnt','\u2030':'permil','\u2031':'pertenk','\u2020':'dagger','\u2021':'Dagger','\u2022':'bull','\u2043':'hybull','\u2032':'prime','\u2033':'Prime','\u2034':'tprime','\u2057':'qprime','\u2035':'bprime','\u2041':'caret','`':'grave','\xB4':'acute','\u02DC':'tilde','^':'Hat','\xAF':'macr','\u02D8':'breve','\u02D9':'dot','\xA8':'die','\u02DA':'ring','\u02DD':'dblac','\xB8':'cedil','\u02DB':'ogon','\u02C6':'circ','\u02C7':'caron','\xB0':'deg','\xA9':'copy','\xAE':'reg','\u2117':'copysr','\u2118':'wp','\u211E':'rx','\u2127':'mho','\u2129':'iiota','\u2190':'larr','\u219A':'nlarr','\u2192':'rarr','\u219B':'nrarr','\u2191':'uarr','\u2193':'darr','\u2194':'harr','\u21AE':'nharr','\u2195':'varr','\u2196':'nwarr','\u2197':'nearr','\u2198':'searr','\u2199':'swarr','\u219D':'rarrw','\u219D\u0338':'nrarrw','\u219E':'Larr','\u219F':'Uarr','\u21A0':'Rarr','\u21A1':'Darr','\u21A2':'larrtl','\u21A3':'rarrtl','\u21A4':'mapstoleft','\u21A5':'mapstoup','\u21A6':'map','\u21A7':'mapstodown','\u21A9':'larrhk','\u21AA':'rarrhk','\u21AB':'larrlp','\u21AC':'rarrlp','\u21AD':'harrw','\u21B0':'lsh','\u21B1':'rsh','\u21B2':'ldsh','\u21B3':'rdsh','\u21B5':'crarr','\u21B6':'cularr','\u21B7':'curarr','\u21BA':'olarr','\u21BB':'orarr','\u21BC':'lharu','\u21BD':'lhard','\u21BE':'uharr','\u21BF':'uharl','\u21C0':'rharu','\u21C1':'rhard','\u21C2':'dharr','\u21C3':'dharl','\u21C4':'rlarr','\u21C5':'udarr','\u21C6':'lrarr','\u21C7':'llarr','\u21C8':'uuarr','\u21C9':'rrarr','\u21CA':'ddarr','\u21CB':'lrhar','\u21CC':'rlhar','\u21D0':'lArr','\u21CD':'nlArr','\u21D1':'uArr','\u21D2':'rArr','\u21CF':'nrArr','\u21D3':'dArr','\u21D4':'iff','\u21CE':'nhArr','\u21D5':'vArr','\u21D6':'nwArr','\u21D7':'neArr','\u21D8':'seArr','\u21D9':'swArr','\u21DA':'lAarr','\u21DB':'rAarr','\u21DD':'zigrarr','\u21E4':'larrb','\u21E5':'rarrb','\u21F5':'duarr','\u21FD':'loarr','\u21FE':'roarr','\u21FF':'hoarr','\u2200':'forall','\u2201':'comp','\u2202':'part','\u2202\u0338':'npart','\u2203':'exist','\u2204':'nexist','\u2205':'empty','\u2207':'Del','\u2208':'in','\u2209':'notin','\u220B':'ni','\u220C':'notni','\u03F6':'bepsi','\u220F':'prod','\u2210':'coprod','\u2211':'sum','+':'plus','\xB1':'pm','\xF7':'div','\xD7':'times','<':'lt','\u226E':'nlt','<\u20D2':'nvlt','=':'equals','\u2260':'ne','=\u20E5':'bne','\u2A75':'Equal','>':'gt','\u226F':'ngt','>\u20D2':'nvgt','\xAC':'not','|':'vert','\xA6':'brvbar','\u2212':'minus','\u2213':'mp','\u2214':'plusdo','\u2044':'frasl','\u2216':'setmn','\u2217':'lowast','\u2218':'compfn','\u221A':'Sqrt','\u221D':'prop','\u221E':'infin','\u221F':'angrt','\u2220':'ang','\u2220\u20D2':'nang','\u2221':'angmsd','\u2222':'angsph','\u2223':'mid','\u2224':'nmid','\u2225':'par','\u2226':'npar','\u2227':'and','\u2228':'or','\u2229':'cap','\u2229\uFE00':'caps','\u222A':'cup','\u222A\uFE00':'cups','\u222B':'int','\u222C':'Int','\u222D':'tint','\u2A0C':'qint','\u222E':'oint','\u222F':'Conint','\u2230':'Cconint','\u2231':'cwint','\u2232':'cwconint','\u2233':'awconint','\u2234':'there4','\u2235':'becaus','\u2236':'ratio','\u2237':'Colon','\u2238':'minusd','\u223A':'mDDot','\u223B':'homtht','\u223C':'sim','\u2241':'nsim','\u223C\u20D2':'nvsim','\u223D':'bsim','\u223D\u0331':'race','\u223E':'ac','\u223E\u0333':'acE','\u223F':'acd','\u2240':'wr','\u2242':'esim','\u2242\u0338':'nesim','\u2243':'sime','\u2244':'nsime','\u2245':'cong','\u2247':'ncong','\u2246':'simne','\u2248':'ap','\u2249':'nap','\u224A':'ape','\u224B':'apid','\u224B\u0338':'napid','\u224C':'bcong','\u224D':'CupCap','\u226D':'NotCupCap','\u224D\u20D2':'nvap','\u224E':'bump','\u224E\u0338':'nbump','\u224F':'bumpe','\u224F\u0338':'nbumpe','\u2250':'doteq','\u2250\u0338':'nedot','\u2251':'eDot','\u2252':'efDot','\u2253':'erDot','\u2254':'colone','\u2255':'ecolon','\u2256':'ecir','\u2257':'cire','\u2259':'wedgeq','\u225A':'veeeq','\u225C':'trie','\u225F':'equest','\u2261':'equiv','\u2262':'nequiv','\u2261\u20E5':'bnequiv','\u2264':'le','\u2270':'nle','\u2264\u20D2':'nvle','\u2265':'ge','\u2271':'nge','\u2265\u20D2':'nvge','\u2266':'lE','\u2266\u0338':'nlE','\u2267':'gE','\u2267\u0338':'ngE','\u2268\uFE00':'lvnE','\u2268':'lnE','\u2269':'gnE','\u2269\uFE00':'gvnE','\u226A':'ll','\u226A\u0338':'nLtv','\u226A\u20D2':'nLt','\u226B':'gg','\u226B\u0338':'nGtv','\u226B\u20D2':'nGt','\u226C':'twixt','\u2272':'lsim','\u2274':'nlsim','\u2273':'gsim','\u2275':'ngsim','\u2276':'lg','\u2278':'ntlg','\u2277':'gl','\u2279':'ntgl','\u227A':'pr','\u2280':'npr','\u227B':'sc','\u2281':'nsc','\u227C':'prcue','\u22E0':'nprcue','\u227D':'sccue','\u22E1':'nsccue','\u227E':'prsim','\u227F':'scsim','\u227F\u0338':'NotSucceedsTilde','\u2282':'sub','\u2284':'nsub','\u2282\u20D2':'vnsub','\u2283':'sup','\u2285':'nsup','\u2283\u20D2':'vnsup','\u2286':'sube','\u2288':'nsube','\u2287':'supe','\u2289':'nsupe','\u228A\uFE00':'vsubne','\u228A':'subne','\u228B\uFE00':'vsupne','\u228B':'supne','\u228D':'cupdot','\u228E':'uplus','\u228F':'sqsub','\u228F\u0338':'NotSquareSubset','\u2290':'sqsup','\u2290\u0338':'NotSquareSuperset','\u2291':'sqsube','\u22E2':'nsqsube','\u2292':'sqsupe','\u22E3':'nsqsupe','\u2293':'sqcap','\u2293\uFE00':'sqcaps','\u2294':'sqcup','\u2294\uFE00':'sqcups','\u2295':'oplus','\u2296':'ominus','\u2297':'otimes','\u2298':'osol','\u2299':'odot','\u229A':'ocir','\u229B':'oast','\u229D':'odash','\u229E':'plusb','\u229F':'minusb','\u22A0':'timesb','\u22A1':'sdotb','\u22A2':'vdash','\u22AC':'nvdash','\u22A3':'dashv','\u22A4':'top','\u22A5':'bot','\u22A7':'models','\u22A8':'vDash','\u22AD':'nvDash','\u22A9':'Vdash','\u22AE':'nVdash','\u22AA':'Vvdash','\u22AB':'VDash','\u22AF':'nVDash','\u22B0':'prurel','\u22B2':'vltri','\u22EA':'nltri','\u22B3':'vrtri','\u22EB':'nrtri','\u22B4':'ltrie','\u22EC':'nltrie','\u22B4\u20D2':'nvltrie','\u22B5':'rtrie','\u22ED':'nrtrie','\u22B5\u20D2':'nvrtrie','\u22B6':'origof','\u22B7':'imof','\u22B8':'mumap','\u22B9':'hercon','\u22BA':'intcal','\u22BB':'veebar','\u22BD':'barvee','\u22BE':'angrtvb','\u22BF':'lrtri','\u22C0':'Wedge','\u22C1':'Vee','\u22C2':'xcap','\u22C3':'xcup','\u22C4':'diam','\u22C5':'sdot','\u22C6':'Star','\u22C7':'divonx','\u22C8':'bowtie','\u22C9':'ltimes','\u22CA':'rtimes','\u22CB':'lthree','\u22CC':'rthree','\u22CD':'bsime','\u22CE':'cuvee','\u22CF':'cuwed','\u22D0':'Sub','\u22D1':'Sup','\u22D2':'Cap','\u22D3':'Cup','\u22D4':'fork','\u22D5':'epar','\u22D6':'ltdot','\u22D7':'gtdot','\u22D8':'Ll','\u22D8\u0338':'nLl','\u22D9':'Gg','\u22D9\u0338':'nGg','\u22DA\uFE00':'lesg','\u22DA':'leg','\u22DB':'gel','\u22DB\uFE00':'gesl','\u22DE':'cuepr','\u22DF':'cuesc','\u22E6':'lnsim','\u22E7':'gnsim','\u22E8':'prnsim','\u22E9':'scnsim','\u22EE':'vellip','\u22EF':'ctdot','\u22F0':'utdot','\u22F1':'dtdot','\u22F2':'disin','\u22F3':'isinsv','\u22F4':'isins','\u22F5':'isindot','\u22F5\u0338':'notindot','\u22F6':'notinvc','\u22F7':'notinvb','\u22F9':'isinE','\u22F9\u0338':'notinE','\u22FA':'nisd','\u22FB':'xnis','\u22FC':'nis','\u22FD':'notnivc','\u22FE':'notnivb','\u2305':'barwed','\u2306':'Barwed','\u230C':'drcrop','\u230D':'dlcrop','\u230E':'urcrop','\u230F':'ulcrop','\u2310':'bnot','\u2312':'profline','\u2313':'profsurf','\u2315':'telrec','\u2316':'target','\u231C':'ulcorn','\u231D':'urcorn','\u231E':'dlcorn','\u231F':'drcorn','\u2322':'frown','\u2323':'smile','\u232D':'cylcty','\u232E':'profalar','\u2336':'topbot','\u233D':'ovbar','\u233F':'solbar','\u237C':'angzarr','\u23B0':'lmoust','\u23B1':'rmoust','\u23B4':'tbrk','\u23B5':'bbrk','\u23B6':'bbrktbrk','\u23DC':'OverParenthesis','\u23DD':'UnderParenthesis','\u23DE':'OverBrace','\u23DF':'UnderBrace','\u23E2':'trpezium','\u23E7':'elinters','\u2423':'blank','\u2500':'boxh','\u2502':'boxv','\u250C':'boxdr','\u2510':'boxdl','\u2514':'boxur','\u2518':'boxul','\u251C':'boxvr','\u2524':'boxvl','\u252C':'boxhd','\u2534':'boxhu','\u253C':'boxvh','\u2550':'boxH','\u2551':'boxV','\u2552':'boxdR','\u2553':'boxDr','\u2554':'boxDR','\u2555':'boxdL','\u2556':'boxDl','\u2557':'boxDL','\u2558':'boxuR','\u2559':'boxUr','\u255A':'boxUR','\u255B':'boxuL','\u255C':'boxUl','\u255D':'boxUL','\u255E':'boxvR','\u255F':'boxVr','\u2560':'boxVR','\u2561':'boxvL','\u2562':'boxVl','\u2563':'boxVL','\u2564':'boxHd','\u2565':'boxhD','\u2566':'boxHD','\u2567':'boxHu','\u2568':'boxhU','\u2569':'boxHU','\u256A':'boxvH','\u256B':'boxVh','\u256C':'boxVH','\u2580':'uhblk','\u2584':'lhblk','\u2588':'block','\u2591':'blk14','\u2592':'blk12','\u2593':'blk34','\u25A1':'squ','\u25AA':'squf','\u25AB':'EmptyVerySmallSquare','\u25AD':'rect','\u25AE':'marker','\u25B1':'fltns','\u25B3':'xutri','\u25B4':'utrif','\u25B5':'utri','\u25B8':'rtrif','\u25B9':'rtri','\u25BD':'xdtri','\u25BE':'dtrif','\u25BF':'dtri','\u25C2':'ltrif','\u25C3':'ltri','\u25CA':'loz','\u25CB':'cir','\u25EC':'tridot','\u25EF':'xcirc','\u25F8':'ultri','\u25F9':'urtri','\u25FA':'lltri','\u25FB':'EmptySmallSquare','\u25FC':'FilledSmallSquare','\u2605':'starf','\u2606':'star','\u260E':'phone','\u2640':'female','\u2642':'male','\u2660':'spades','\u2663':'clubs','\u2665':'hearts','\u2666':'diams','\u266A':'sung','\u2713':'check','\u2717':'cross','\u2720':'malt','\u2736':'sext','\u2758':'VerticalSeparator','\u27C8':'bsolhsub','\u27C9':'suphsol','\u27F5':'xlarr','\u27F6':'xrarr','\u27F7':'xharr','\u27F8':'xlArr','\u27F9':'xrArr','\u27FA':'xhArr','\u27FC':'xmap','\u27FF':'dzigrarr','\u2902':'nvlArr','\u2903':'nvrArr','\u2904':'nvHarr','\u2905':'Map','\u290C':'lbarr','\u290D':'rbarr','\u290E':'lBarr','\u290F':'rBarr','\u2910':'RBarr','\u2911':'DDotrahd','\u2912':'UpArrowBar','\u2913':'DownArrowBar','\u2916':'Rarrtl','\u2919':'latail','\u291A':'ratail','\u291B':'lAtail','\u291C':'rAtail','\u291D':'larrfs','\u291E':'rarrfs','\u291F':'larrbfs','\u2920':'rarrbfs','\u2923':'nwarhk','\u2924':'nearhk','\u2925':'searhk','\u2926':'swarhk','\u2927':'nwnear','\u2928':'toea','\u2929':'tosa','\u292A':'swnwar','\u2933':'rarrc','\u2933\u0338':'nrarrc','\u2935':'cudarrr','\u2936':'ldca','\u2937':'rdca','\u2938':'cudarrl','\u2939':'larrpl','\u293C':'curarrm','\u293D':'cularrp','\u2945':'rarrpl','\u2948':'harrcir','\u2949':'Uarrocir','\u294A':'lurdshar','\u294B':'ldrushar','\u294E':'LeftRightVector','\u294F':'RightUpDownVector','\u2950':'DownLeftRightVector','\u2951':'LeftUpDownVector','\u2952':'LeftVectorBar','\u2953':'RightVectorBar','\u2954':'RightUpVectorBar','\u2955':'RightDownVectorBar','\u2956':'DownLeftVectorBar','\u2957':'DownRightVectorBar','\u2958':'LeftUpVectorBar','\u2959':'LeftDownVectorBar','\u295A':'LeftTeeVector','\u295B':'RightTeeVector','\u295C':'RightUpTeeVector','\u295D':'RightDownTeeVector','\u295E':'DownLeftTeeVector','\u295F':'DownRightTeeVector','\u2960':'LeftUpTeeVector','\u2961':'LeftDownTeeVector','\u2962':'lHar','\u2963':'uHar','\u2964':'rHar','\u2965':'dHar','\u2966':'luruhar','\u2967':'ldrdhar','\u2968':'ruluhar','\u2969':'rdldhar','\u296A':'lharul','\u296B':'llhard','\u296C':'rharul','\u296D':'lrhard','\u296E':'udhar','\u296F':'duhar','\u2970':'RoundImplies','\u2971':'erarr','\u2972':'simrarr','\u2973':'larrsim','\u2974':'rarrsim','\u2975':'rarrap','\u2976':'ltlarr','\u2978':'gtrarr','\u2979':'subrarr','\u297B':'suplarr','\u297C':'lfisht','\u297D':'rfisht','\u297E':'ufisht','\u297F':'dfisht','\u299A':'vzigzag','\u299C':'vangrt','\u299D':'angrtvbd','\u29A4':'ange','\u29A5':'range','\u29A6':'dwangle','\u29A7':'uwangle','\u29A8':'angmsdaa','\u29A9':'angmsdab','\u29AA':'angmsdac','\u29AB':'angmsdad','\u29AC':'angmsdae','\u29AD':'angmsdaf','\u29AE':'angmsdag','\u29AF':'angmsdah','\u29B0':'bemptyv','\u29B1':'demptyv','\u29B2':'cemptyv','\u29B3':'raemptyv','\u29B4':'laemptyv','\u29B5':'ohbar','\u29B6':'omid','\u29B7':'opar','\u29B9':'operp','\u29BB':'olcross','\u29BC':'odsold','\u29BE':'olcir','\u29BF':'ofcir','\u29C0':'olt','\u29C1':'ogt','\u29C2':'cirscir','\u29C3':'cirE','\u29C4':'solb','\u29C5':'bsolb','\u29C9':'boxbox','\u29CD':'trisb','\u29CE':'rtriltri','\u29CF':'LeftTriangleBar','\u29CF\u0338':'NotLeftTriangleBar','\u29D0':'RightTriangleBar','\u29D0\u0338':'NotRightTriangleBar','\u29DC':'iinfin','\u29DD':'infintie','\u29DE':'nvinfin','\u29E3':'eparsl','\u29E4':'smeparsl','\u29E5':'eqvparsl','\u29EB':'lozf','\u29F4':'RuleDelayed','\u29F6':'dsol','\u2A00':'xodot','\u2A01':'xoplus','\u2A02':'xotime','\u2A04':'xuplus','\u2A06':'xsqcup','\u2A0D':'fpartint','\u2A10':'cirfnint','\u2A11':'awint','\u2A12':'rppolint','\u2A13':'scpolint','\u2A14':'npolint','\u2A15':'pointint','\u2A16':'quatint','\u2A17':'intlarhk','\u2A22':'pluscir','\u2A23':'plusacir','\u2A24':'simplus','\u2A25':'plusdu','\u2A26':'plussim','\u2A27':'plustwo','\u2A29':'mcomma','\u2A2A':'minusdu','\u2A2D':'loplus','\u2A2E':'roplus','\u2A2F':'Cross','\u2A30':'timesd','\u2A31':'timesbar','\u2A33':'smashp','\u2A34':'lotimes','\u2A35':'rotimes','\u2A36':'otimesas','\u2A37':'Otimes','\u2A38':'odiv','\u2A39':'triplus','\u2A3A':'triminus','\u2A3B':'tritime','\u2A3C':'iprod','\u2A3F':'amalg','\u2A40':'capdot','\u2A42':'ncup','\u2A43':'ncap','\u2A44':'capand','\u2A45':'cupor','\u2A46':'cupcap','\u2A47':'capcup','\u2A48':'cupbrcap','\u2A49':'capbrcup','\u2A4A':'cupcup','\u2A4B':'capcap','\u2A4C':'ccups','\u2A4D':'ccaps','\u2A50':'ccupssm','\u2A53':'And','\u2A54':'Or','\u2A55':'andand','\u2A56':'oror','\u2A57':'orslope','\u2A58':'andslope','\u2A5A':'andv','\u2A5B':'orv','\u2A5C':'andd','\u2A5D':'ord','\u2A5F':'wedbar','\u2A66':'sdote','\u2A6A':'simdot','\u2A6D':'congdot','\u2A6D\u0338':'ncongdot','\u2A6E':'easter','\u2A6F':'apacir','\u2A70':'apE','\u2A70\u0338':'napE','\u2A71':'eplus','\u2A72':'pluse','\u2A73':'Esim','\u2A77':'eDDot','\u2A78':'equivDD','\u2A79':'ltcir','\u2A7A':'gtcir','\u2A7B':'ltquest','\u2A7C':'gtquest','\u2A7D':'les','\u2A7D\u0338':'nles','\u2A7E':'ges','\u2A7E\u0338':'nges','\u2A7F':'lesdot','\u2A80':'gesdot','\u2A81':'lesdoto','\u2A82':'gesdoto','\u2A83':'lesdotor','\u2A84':'gesdotol','\u2A85':'lap','\u2A86':'gap','\u2A87':'lne','\u2A88':'gne','\u2A89':'lnap','\u2A8A':'gnap','\u2A8B':'lEg','\u2A8C':'gEl','\u2A8D':'lsime','\u2A8E':'gsime','\u2A8F':'lsimg','\u2A90':'gsiml','\u2A91':'lgE','\u2A92':'glE','\u2A93':'lesges','\u2A94':'gesles','\u2A95':'els','\u2A96':'egs','\u2A97':'elsdot','\u2A98':'egsdot','\u2A99':'el','\u2A9A':'eg','\u2A9D':'siml','\u2A9E':'simg','\u2A9F':'simlE','\u2AA0':'simgE','\u2AA1':'LessLess','\u2AA1\u0338':'NotNestedLessLess','\u2AA2':'GreaterGreater','\u2AA2\u0338':'NotNestedGreaterGreater','\u2AA4':'glj','\u2AA5':'gla','\u2AA6':'ltcc','\u2AA7':'gtcc','\u2AA8':'lescc','\u2AA9':'gescc','\u2AAA':'smt','\u2AAB':'lat','\u2AAC':'smte','\u2AAC\uFE00':'smtes','\u2AAD':'late','\u2AAD\uFE00':'lates','\u2AAE':'bumpE','\u2AAF':'pre','\u2AAF\u0338':'npre','\u2AB0':'sce','\u2AB0\u0338':'nsce','\u2AB3':'prE','\u2AB4':'scE','\u2AB5':'prnE','\u2AB6':'scnE','\u2AB7':'prap','\u2AB8':'scap','\u2AB9':'prnap','\u2ABA':'scnap','\u2ABB':'Pr','\u2ABC':'Sc','\u2ABD':'subdot','\u2ABE':'supdot','\u2ABF':'subplus','\u2AC0':'supplus','\u2AC1':'submult','\u2AC2':'supmult','\u2AC3':'subedot','\u2AC4':'supedot','\u2AC5':'subE','\u2AC5\u0338':'nsubE','\u2AC6':'supE','\u2AC6\u0338':'nsupE','\u2AC7':'subsim','\u2AC8':'supsim','\u2ACB\uFE00':'vsubnE','\u2ACB':'subnE','\u2ACC\uFE00':'vsupnE','\u2ACC':'supnE','\u2ACF':'csub','\u2AD0':'csup','\u2AD1':'csube','\u2AD2':'csupe','\u2AD3':'subsup','\u2AD4':'supsub','\u2AD5':'subsub','\u2AD6':'supsup','\u2AD7':'suphsub','\u2AD8':'supdsub','\u2AD9':'forkv','\u2ADA':'topfork','\u2ADB':'mlcp','\u2AE4':'Dashv','\u2AE6':'Vdashl','\u2AE7':'Barv','\u2AE8':'vBar','\u2AE9':'vBarv','\u2AEB':'Vbar','\u2AEC':'Not','\u2AED':'bNot','\u2AEE':'rnmid','\u2AEF':'cirmid','\u2AF0':'midcir','\u2AF1':'topcir','\u2AF2':'nhpar','\u2AF3':'parsim','\u2AFD':'parsl','\u2AFD\u20E5':'nparsl','\u266D':'flat','\u266E':'natur','\u266F':'sharp','\xA4':'curren','\xA2':'cent','$':'dollar','\xA3':'pound','\xA5':'yen','\u20AC':'euro','\xB9':'sup1','\xBD':'half','\u2153':'frac13','\xBC':'frac14','\u2155':'frac15','\u2159':'frac16','\u215B':'frac18','\xB2':'sup2','\u2154':'frac23','\u2156':'frac25','\xB3':'sup3','\xBE':'frac34','\u2157':'frac35','\u215C':'frac38','\u2158':'frac45','\u215A':'frac56','\u215D':'frac58','\u215E':'frac78','\uD835\uDCB6':'ascr','\uD835\uDD52':'aopf','\uD835\uDD1E':'afr','\uD835\uDD38':'Aopf','\uD835\uDD04':'Afr','\uD835\uDC9C':'Ascr','\xAA':'ordf','\xE1':'aacute','\xC1':'Aacute','\xE0':'agrave','\xC0':'Agrave','\u0103':'abreve','\u0102':'Abreve','\xE2':'acirc','\xC2':'Acirc','\xE5':'aring','\xC5':'angst','\xE4':'auml','\xC4':'Auml','\xE3':'atilde','\xC3':'Atilde','\u0105':'aogon','\u0104':'Aogon','\u0101':'amacr','\u0100':'Amacr','\xE6':'aelig','\xC6':'AElig','\uD835\uDCB7':'bscr','\uD835\uDD53':'bopf','\uD835\uDD1F':'bfr','\uD835\uDD39':'Bopf','\u212C':'Bscr','\uD835\uDD05':'Bfr','\uD835\uDD20':'cfr','\uD835\uDCB8':'cscr','\uD835\uDD54':'copf','\u212D':'Cfr','\uD835\uDC9E':'Cscr','\u2102':'Copf','\u0107':'cacute','\u0106':'Cacute','\u0109':'ccirc','\u0108':'Ccirc','\u010D':'ccaron','\u010C':'Ccaron','\u010B':'cdot','\u010A':'Cdot','\xE7':'ccedil','\xC7':'Ccedil','\u2105':'incare','\uD835\uDD21':'dfr','\u2146':'dd','\uD835\uDD55':'dopf','\uD835\uDCB9':'dscr','\uD835\uDC9F':'Dscr','\uD835\uDD07':'Dfr','\u2145':'DD','\uD835\uDD3B':'Dopf','\u010F':'dcaron','\u010E':'Dcaron','\u0111':'dstrok','\u0110':'Dstrok','\xF0':'eth','\xD0':'ETH','\u2147':'ee','\u212F':'escr','\uD835\uDD22':'efr','\uD835\uDD56':'eopf','\u2130':'Escr','\uD835\uDD08':'Efr','\uD835\uDD3C':'Eopf','\xE9':'eacute','\xC9':'Eacute','\xE8':'egrave','\xC8':'Egrave','\xEA':'ecirc','\xCA':'Ecirc','\u011B':'ecaron','\u011A':'Ecaron','\xEB':'euml','\xCB':'Euml','\u0117':'edot','\u0116':'Edot','\u0119':'eogon','\u0118':'Eogon','\u0113':'emacr','\u0112':'Emacr','\uD835\uDD23':'ffr','\uD835\uDD57':'fopf','\uD835\uDCBB':'fscr','\uD835\uDD09':'Ffr','\uD835\uDD3D':'Fopf','\u2131':'Fscr','\uFB00':'fflig','\uFB03':'ffilig','\uFB04':'ffllig','\uFB01':'filig','fj':'fjlig','\uFB02':'fllig','\u0192':'fnof','\u210A':'gscr','\uD835\uDD58':'gopf','\uD835\uDD24':'gfr','\uD835\uDCA2':'Gscr','\uD835\uDD3E':'Gopf','\uD835\uDD0A':'Gfr','\u01F5':'gacute','\u011F':'gbreve','\u011E':'Gbreve','\u011D':'gcirc','\u011C':'Gcirc','\u0121':'gdot','\u0120':'Gdot','\u0122':'Gcedil','\uD835\uDD25':'hfr','\u210E':'planckh','\uD835\uDCBD':'hscr','\uD835\uDD59':'hopf','\u210B':'Hscr','\u210C':'Hfr','\u210D':'Hopf','\u0125':'hcirc','\u0124':'Hcirc','\u210F':'hbar','\u0127':'hstrok','\u0126':'Hstrok','\uD835\uDD5A':'iopf','\uD835\uDD26':'ifr','\uD835\uDCBE':'iscr','\u2148':'ii','\uD835\uDD40':'Iopf','\u2110':'Iscr','\u2111':'Im','\xED':'iacute','\xCD':'Iacute','\xEC':'igrave','\xCC':'Igrave','\xEE':'icirc','\xCE':'Icirc','\xEF':'iuml','\xCF':'Iuml','\u0129':'itilde','\u0128':'Itilde','\u0130':'Idot','\u012F':'iogon','\u012E':'Iogon','\u012B':'imacr','\u012A':'Imacr','\u0133':'ijlig','\u0132':'IJlig','\u0131':'imath','\uD835\uDCBF':'jscr','\uD835\uDD5B':'jopf','\uD835\uDD27':'jfr','\uD835\uDCA5':'Jscr','\uD835\uDD0D':'Jfr','\uD835\uDD41':'Jopf','\u0135':'jcirc','\u0134':'Jcirc','\u0237':'jmath','\uD835\uDD5C':'kopf','\uD835\uDCC0':'kscr','\uD835\uDD28':'kfr','\uD835\uDCA6':'Kscr','\uD835\uDD42':'Kopf','\uD835\uDD0E':'Kfr','\u0137':'kcedil','\u0136':'Kcedil','\uD835\uDD29':'lfr','\uD835\uDCC1':'lscr','\u2113':'ell','\uD835\uDD5D':'lopf','\u2112':'Lscr','\uD835\uDD0F':'Lfr','\uD835\uDD43':'Lopf','\u013A':'lacute','\u0139':'Lacute','\u013E':'lcaron','\u013D':'Lcaron','\u013C':'lcedil','\u013B':'Lcedil','\u0142':'lstrok','\u0141':'Lstrok','\u0140':'lmidot','\u013F':'Lmidot','\uD835\uDD2A':'mfr','\uD835\uDD5E':'mopf','\uD835\uDCC2':'mscr','\uD835\uDD10':'Mfr','\uD835\uDD44':'Mopf','\u2133':'Mscr','\uD835\uDD2B':'nfr','\uD835\uDD5F':'nopf','\uD835\uDCC3':'nscr','\u2115':'Nopf','\uD835\uDCA9':'Nscr','\uD835\uDD11':'Nfr','\u0144':'nacute','\u0143':'Nacute','\u0148':'ncaron','\u0147':'Ncaron','\xF1':'ntilde','\xD1':'Ntilde','\u0146':'ncedil','\u0145':'Ncedil','\u2116':'numero','\u014B':'eng','\u014A':'ENG','\uD835\uDD60':'oopf','\uD835\uDD2C':'ofr','\u2134':'oscr','\uD835\uDCAA':'Oscr','\uD835\uDD12':'Ofr','\uD835\uDD46':'Oopf','\xBA':'ordm','\xF3':'oacute','\xD3':'Oacute','\xF2':'ograve','\xD2':'Ograve','\xF4':'ocirc','\xD4':'Ocirc','\xF6':'ouml','\xD6':'Ouml','\u0151':'odblac','\u0150':'Odblac','\xF5':'otilde','\xD5':'Otilde','\xF8':'oslash','\xD8':'Oslash','\u014D':'omacr','\u014C':'Omacr','\u0153':'oelig','\u0152':'OElig','\uD835\uDD2D':'pfr','\uD835\uDCC5':'pscr','\uD835\uDD61':'popf','\u2119':'Popf','\uD835\uDD13':'Pfr','\uD835\uDCAB':'Pscr','\uD835\uDD62':'qopf','\uD835\uDD2E':'qfr','\uD835\uDCC6':'qscr','\uD835\uDCAC':'Qscr','\uD835\uDD14':'Qfr','\u211A':'Qopf','\u0138':'kgreen','\uD835\uDD2F':'rfr','\uD835\uDD63':'ropf','\uD835\uDCC7':'rscr','\u211B':'Rscr','\u211C':'Re','\u211D':'Ropf','\u0155':'racute','\u0154':'Racute','\u0159':'rcaron','\u0158':'Rcaron','\u0157':'rcedil','\u0156':'Rcedil','\uD835\uDD64':'sopf','\uD835\uDCC8':'sscr','\uD835\uDD30':'sfr','\uD835\uDD4A':'Sopf','\uD835\uDD16':'Sfr','\uD835\uDCAE':'Sscr','\u24C8':'oS','\u015B':'sacute','\u015A':'Sacute','\u015D':'scirc','\u015C':'Scirc','\u0161':'scaron','\u0160':'Scaron','\u015F':'scedil','\u015E':'Scedil','\xDF':'szlig','\uD835\uDD31':'tfr','\uD835\uDCC9':'tscr','\uD835\uDD65':'topf','\uD835\uDCAF':'Tscr','\uD835\uDD17':'Tfr','\uD835\uDD4B':'Topf','\u0165':'tcaron','\u0164':'Tcaron','\u0163':'tcedil','\u0162':'Tcedil','\u2122':'trade','\u0167':'tstrok','\u0166':'Tstrok','\uD835\uDCCA':'uscr','\uD835\uDD66':'uopf','\uD835\uDD32':'ufr','\uD835\uDD4C':'Uopf','\uD835\uDD18':'Ufr','\uD835\uDCB0':'Uscr','\xFA':'uacute','\xDA':'Uacute','\xF9':'ugrave','\xD9':'Ugrave','\u016D':'ubreve','\u016C':'Ubreve','\xFB':'ucirc','\xDB':'Ucirc','\u016F':'uring','\u016E':'Uring','\xFC':'uuml','\xDC':'Uuml','\u0171':'udblac','\u0170':'Udblac','\u0169':'utilde','\u0168':'Utilde','\u0173':'uogon','\u0172':'Uogon','\u016B':'umacr','\u016A':'Umacr','\uD835\uDD33':'vfr','\uD835\uDD67':'vopf','\uD835\uDCCB':'vscr','\uD835\uDD19':'Vfr','\uD835\uDD4D':'Vopf','\uD835\uDCB1':'Vscr','\uD835\uDD68':'wopf','\uD835\uDCCC':'wscr','\uD835\uDD34':'wfr','\uD835\uDCB2':'Wscr','\uD835\uDD4E':'Wopf','\uD835\uDD1A':'Wfr','\u0175':'wcirc','\u0174':'Wcirc','\uD835\uDD35':'xfr','\uD835\uDCCD':'xscr','\uD835\uDD69':'xopf','\uD835\uDD4F':'Xopf','\uD835\uDD1B':'Xfr','\uD835\uDCB3':'Xscr','\uD835\uDD36':'yfr','\uD835\uDCCE':'yscr','\uD835\uDD6A':'yopf','\uD835\uDCB4':'Yscr','\uD835\uDD1C':'Yfr','\uD835\uDD50':'Yopf','\xFD':'yacute','\xDD':'Yacute','\u0177':'ycirc','\u0176':'Ycirc','\xFF':'yuml','\u0178':'Yuml','\uD835\uDCCF':'zscr','\uD835\uDD37':'zfr','\uD835\uDD6B':'zopf','\u2128':'Zfr','\u2124':'Zopf','\uD835\uDCB5':'Zscr','\u017A':'zacute','\u0179':'Zacute','\u017E':'zcaron','\u017D':'Zcaron','\u017C':'zdot','\u017B':'Zdot','\u01B5':'imped','\xFE':'thorn','\xDE':'THORN','\u0149':'napos','\u03B1':'alpha','\u0391':'Alpha','\u03B2':'beta','\u0392':'Beta','\u03B3':'gamma','\u0393':'Gamma','\u03B4':'delta','\u0394':'Delta','\u03B5':'epsi','\u03F5':'epsiv','\u0395':'Epsilon','\u03DD':'gammad','\u03DC':'Gammad','\u03B6':'zeta','\u0396':'Zeta','\u03B7':'eta','\u0397':'Eta','\u03B8':'theta','\u03D1':'thetav','\u0398':'Theta','\u03B9':'iota','\u0399':'Iota','\u03BA':'kappa','\u03F0':'kappav','\u039A':'Kappa','\u03BB':'lambda','\u039B':'Lambda','\u03BC':'mu','\xB5':'micro','\u039C':'Mu','\u03BD':'nu','\u039D':'Nu','\u03BE':'xi','\u039E':'Xi','\u03BF':'omicron','\u039F':'Omicron','\u03C0':'pi','\u03D6':'piv','\u03A0':'Pi','\u03C1':'rho','\u03F1':'rhov','\u03A1':'Rho','\u03C3':'sigma','\u03A3':'Sigma','\u03C2':'sigmaf','\u03C4':'tau','\u03A4':'Tau','\u03C5':'upsi','\u03A5':'Upsilon','\u03D2':'Upsi','\u03C6':'phi','\u03D5':'phiv','\u03A6':'Phi','\u03C7':'chi','\u03A7':'Chi','\u03C8':'psi','\u03A8':'Psi','\u03C9':'omega','\u03A9':'ohm','\u0430':'acy','\u0410':'Acy','\u0431':'bcy','\u0411':'Bcy','\u0432':'vcy','\u0412':'Vcy','\u0433':'gcy','\u0413':'Gcy','\u0453':'gjcy','\u0403':'GJcy','\u0434':'dcy','\u0414':'Dcy','\u0452':'djcy','\u0402':'DJcy','\u0435':'iecy','\u0415':'IEcy','\u0451':'iocy','\u0401':'IOcy','\u0454':'jukcy','\u0404':'Jukcy','\u0436':'zhcy','\u0416':'ZHcy','\u0437':'zcy','\u0417':'Zcy','\u0455':'dscy','\u0405':'DScy','\u0438':'icy','\u0418':'Icy','\u0456':'iukcy','\u0406':'Iukcy','\u0457':'yicy','\u0407':'YIcy','\u0439':'jcy','\u0419':'Jcy','\u0458':'jsercy','\u0408':'Jsercy','\u043A':'kcy','\u041A':'Kcy','\u045C':'kjcy','\u040C':'KJcy','\u043B':'lcy','\u041B':'Lcy','\u0459':'ljcy','\u0409':'LJcy','\u043C':'mcy','\u041C':'Mcy','\u043D':'ncy','\u041D':'Ncy','\u045A':'njcy','\u040A':'NJcy','\u043E':'ocy','\u041E':'Ocy','\u043F':'pcy','\u041F':'Pcy','\u0440':'rcy','\u0420':'Rcy','\u0441':'scy','\u0421':'Scy','\u0442':'tcy','\u0422':'Tcy','\u045B':'tshcy','\u040B':'TSHcy','\u0443':'ucy','\u0423':'Ucy','\u045E':'ubrcy','\u040E':'Ubrcy','\u0444':'fcy','\u0424':'Fcy','\u0445':'khcy','\u0425':'KHcy','\u0446':'tscy','\u0426':'TScy','\u0447':'chcy','\u0427':'CHcy','\u045F':'dzcy','\u040F':'DZcy','\u0448':'shcy','\u0428':'SHcy','\u0449':'shchcy','\u0429':'SHCHcy','\u044A':'hardcy','\u042A':'HARDcy','\u044B':'ycy','\u042B':'Ycy','\u044C':'softcy','\u042C':'SOFTcy','\u044D':'ecy','\u042D':'Ecy','\u044E':'yucy','\u042E':'YUcy','\u044F':'yacy','\u042F':'YAcy','\u2135':'aleph','\u2136':'beth','\u2137':'gimel','\u2138':'daleth'};
|
2274 |
|
2275 | var regexEscape = /["&'<>`]/g;
|
2276 | var escapeMap = {
|
2277 | '"': '"',
|
2278 | '&': '&',
|
2279 | '\'': ''',
|
2280 | '<': '<',
|
2281 |
|
2282 |
|
2283 |
|
2284 |
|
2285 | '>': '>',
|
2286 |
|
2287 |
|
2288 |
|
2289 |
|
2290 | '`': '`'
|
2291 | };
|
2292 |
|
2293 | var regexInvalidEntity = /&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/;
|
2294 | var regexInvalidRawCodePoint = /[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;
|
2295 | var regexDecode = /&(CounterClockwiseContourIntegral|DoubleLongLeftRightArrow|ClockwiseContourIntegral|NotNestedGreaterGreater|NotSquareSupersetEqual|DiacriticalDoubleAcute|NotRightTriangleEqual|NotSucceedsSlantEqual|NotPrecedesSlantEqual|CloseCurlyDoubleQuote|NegativeVeryThinSpace|DoubleContourIntegral|FilledVerySmallSquare|CapitalDifferentialD|OpenCurlyDoubleQuote|EmptyVerySmallSquare|NestedGreaterGreater|DoubleLongRightArrow|NotLeftTriangleEqual|NotGreaterSlantEqual|ReverseUpEquilibrium|DoubleLeftRightArrow|NotSquareSubsetEqual|NotDoubleVerticalBar|RightArrowLeftArrow|NotGreaterFullEqual|NotRightTriangleBar|SquareSupersetEqual|DownLeftRightVector|DoubleLongLeftArrow|leftrightsquigarrow|LeftArrowRightArrow|NegativeMediumSpace|blacktriangleright|RightDownVectorBar|PrecedesSlantEqual|RightDoubleBracket|SucceedsSlantEqual|NotLeftTriangleBar|RightTriangleEqual|SquareIntersection|RightDownTeeVector|ReverseEquilibrium|NegativeThickSpace|longleftrightarrow|Longleftrightarrow|LongLeftRightArrow|DownRightTeeVector|DownRightVectorBar|GreaterSlantEqual|SquareSubsetEqual|LeftDownVectorBar|LeftDoubleBracket|VerticalSeparator|rightleftharpoons|NotGreaterGreater|NotSquareSuperset|blacktriangleleft|blacktriangledown|NegativeThinSpace|LeftDownTeeVector|NotLessSlantEqual|leftrightharpoons|DoubleUpDownArrow|DoubleVerticalBar|LeftTriangleEqual|FilledSmallSquare|twoheadrightarrow|NotNestedLessLess|DownLeftTeeVector|DownLeftVectorBar|RightAngleBracket|NotTildeFullEqual|NotReverseElement|RightUpDownVector|DiacriticalTilde|NotSucceedsTilde|circlearrowright|NotPrecedesEqual|rightharpoondown|DoubleRightArrow|NotSucceedsEqual|NonBreakingSpace|NotRightTriangle|LessEqualGreater|RightUpTeeVector|LeftAngleBracket|GreaterFullEqual|DownArrowUpArrow|RightUpVectorBar|twoheadleftarrow|GreaterEqualLess|downharpoonright|RightTriangleBar|ntrianglerighteq|NotSupersetEqual|LeftUpDownVector|DiacriticalAcute|rightrightarrows|vartriangleright|UpArrowDownArrow|DiacriticalGrave|UnderParenthesis|EmptySmallSquare|LeftUpVectorBar|leftrightarrows|DownRightVector|downharpoonleft|trianglerighteq|ShortRightArrow|OverParenthesis|DoubleLeftArrow|DoubleDownArrow|NotSquareSubset|bigtriangledown|ntrianglelefteq|UpperRightArrow|curvearrowright|vartriangleleft|NotLeftTriangle|nleftrightarrow|LowerRightArrow|NotHumpDownHump|NotGreaterTilde|rightthreetimes|LeftUpTeeVector|NotGreaterEqual|straightepsilon|LeftTriangleBar|rightsquigarrow|ContourIntegral|rightleftarrows|CloseCurlyQuote|RightDownVector|LeftRightVector|nLeftrightarrow|leftharpoondown|circlearrowleft|SquareSuperset|OpenCurlyQuote|hookrightarrow|HorizontalLine|DiacriticalDot|NotLessGreater|ntriangleright|DoubleRightTee|InvisibleComma|InvisibleTimes|LowerLeftArrow|DownLeftVector|NotSubsetEqual|curvearrowleft|trianglelefteq|NotVerticalBar|TildeFullEqual|downdownarrows|NotGreaterLess|RightTeeVector|ZeroWidthSpace|looparrowright|LongRightArrow|doublebarwedge|ShortLeftArrow|ShortDownArrow|RightVectorBar|GreaterGreater|ReverseElement|rightharpoonup|LessSlantEqual|leftthreetimes|upharpoonright|rightarrowtail|LeftDownVector|Longrightarrow|NestedLessLess|UpperLeftArrow|nshortparallel|leftleftarrows|leftrightarrow|Leftrightarrow|LeftRightArrow|longrightarrow|upharpoonleft|RightArrowBar|ApplyFunction|LeftTeeVector|leftarrowtail|NotEqualTilde|varsubsetneqq|varsupsetneqq|RightTeeArrow|SucceedsEqual|SucceedsTilde|LeftVectorBar|SupersetEqual|hookleftarrow|DifferentialD|VerticalTilde|VeryThinSpace|blacktriangle|bigtriangleup|LessFullEqual|divideontimes|leftharpoonup|UpEquilibrium|ntriangleleft|RightTriangle|measuredangle|shortparallel|longleftarrow|Longleftarrow|LongLeftArrow|DoubleLeftTee|Poincareplane|PrecedesEqual|triangleright|DoubleUpArrow|RightUpVector|fallingdotseq|looparrowleft|PrecedesTilde|NotTildeEqual|NotTildeTilde|smallsetminus|Proportional|triangleleft|triangledown|UnderBracket|NotHumpEqual|exponentiale|ExponentialE|NotLessTilde|HilbertSpace|RightCeiling|blacklozenge|varsupsetneq|HumpDownHump|GreaterEqual|VerticalLine|LeftTeeArrow|NotLessEqual|DownTeeArrow|LeftTriangle|varsubsetneq|Intersection|NotCongruent|DownArrowBar|LeftUpVector|LeftArrowBar|risingdotseq|GreaterTilde|RoundImplies|SquareSubset|ShortUpArrow|NotSuperset|quaternions|precnapprox|backepsilon|preccurlyeq|OverBracket|blacksquare|MediumSpace|VerticalBar|circledcirc|circleddash|CircleMinus|CircleTimes|LessGreater|curlyeqprec|curlyeqsucc|diamondsuit|UpDownArrow|Updownarrow|RuleDelayed|Rrightarrow|updownarrow|RightVector|nRightarrow|nrightarrow|eqslantless|LeftCeiling|Equilibrium|SmallCircle|expectation|NotSucceeds|thickapprox|GreaterLess|SquareUnion|NotPrecedes|NotLessLess|straightphi|succnapprox|succcurlyeq|SubsetEqual|sqsupseteq|Proportion|Laplacetrf|ImaginaryI|supsetneqq|NotGreater|gtreqqless|NotElement|ThickSpace|TildeEqual|TildeTilde|Fouriertrf|rmoustache|EqualTilde|eqslantgtr|UnderBrace|LeftVector|UpArrowBar|nLeftarrow|nsubseteqq|subsetneqq|nsupseteqq|nleftarrow|succapprox|lessapprox|UpTeeArrow|upuparrows|curlywedge|lesseqqgtr|varepsilon|varnothing|RightFloor|complement|CirclePlus|sqsubseteq|Lleftarrow|circledast|RightArrow|Rightarrow|rightarrow|lmoustache|Bernoullis|precapprox|mapstoleft|mapstodown|longmapsto|dotsquare|downarrow|DoubleDot|nsubseteq|supsetneq|leftarrow|nsupseteq|subsetneq|ThinSpace|ngeqslant|subseteqq|HumpEqual|NotSubset|triangleq|NotCupCap|lesseqgtr|heartsuit|TripleDot|Leftarrow|Coproduct|Congruent|varpropto|complexes|gvertneqq|LeftArrow|LessTilde|supseteqq|MinusPlus|CircleDot|nleqslant|NotExists|gtreqless|nparallel|UnionPlus|LeftFloor|checkmark|CenterDot|centerdot|Mellintrf|gtrapprox|bigotimes|OverBrace|spadesuit|therefore|pitchfork|rationals|PlusMinus|Backslash|Therefore|DownBreve|backsimeq|backprime|DownArrow|nshortmid|Downarrow|lvertneqq|eqvparsl|imagline|imagpart|infintie|integers|Integral|intercal|LessLess|Uarrocir|intlarhk|sqsupset|angmsdaf|sqsubset|llcorner|vartheta|cupbrcap|lnapprox|Superset|SuchThat|succnsim|succneqq|angmsdag|biguplus|curlyvee|trpezium|Succeeds|NotTilde|bigwedge|angmsdah|angrtvbd|triminus|cwconint|fpartint|lrcorner|smeparsl|subseteq|urcorner|lurdshar|laemptyv|DDotrahd|approxeq|ldrushar|awconint|mapstoup|backcong|shortmid|triangle|geqslant|gesdotol|timesbar|circledR|circledS|setminus|multimap|naturals|scpolint|ncongdot|RightTee|boxminus|gnapprox|boxtimes|andslope|thicksim|angmsdaa|varsigma|cirfnint|rtriltri|angmsdab|rppolint|angmsdac|barwedge|drbkarow|clubsuit|thetasym|bsolhsub|capbrcup|dzigrarr|doteqdot|DotEqual|dotminus|UnderBar|NotEqual|realpart|otimesas|ulcorner|hksearow|hkswarow|parallel|PartialD|elinters|emptyset|plusacir|bbrktbrk|angmsdad|pointint|bigoplus|angmsdae|Precedes|bigsqcup|varkappa|notindot|supseteq|precneqq|precnsim|profalar|profline|profsurf|leqslant|lesdotor|raemptyv|subplus|notnivb|notnivc|subrarr|zigrarr|vzigzag|submult|subedot|Element|between|cirscir|larrbfs|larrsim|lotimes|lbrksld|lbrkslu|lozenge|ldrdhar|dbkarow|bigcirc|epsilon|simrarr|simplus|ltquest|Epsilon|luruhar|gtquest|maltese|npolint|eqcolon|npreceq|bigodot|ddagger|gtrless|bnequiv|harrcir|ddotseq|equivDD|backsim|demptyv|nsqsube|nsqsupe|Upsilon|nsubset|upsilon|minusdu|nsucceq|swarrow|nsupset|coloneq|searrow|boxplus|napprox|natural|asympeq|alefsym|congdot|nearrow|bigstar|diamond|supplus|tritime|LeftTee|nvinfin|triplus|NewLine|nvltrie|nvrtrie|nwarrow|nexists|Diamond|ruluhar|Implies|supmult|angzarr|suplarr|suphsub|questeq|because|digamma|Because|olcross|bemptyv|omicron|Omicron|rotimes|NoBreak|intprod|angrtvb|orderof|uwangle|suphsol|lesdoto|orslope|DownTee|realine|cudarrl|rdldhar|OverBar|supedot|lessdot|supdsub|topfork|succsim|rbrkslu|rbrksld|pertenk|cudarrr|isindot|planckh|lessgtr|pluscir|gesdoto|plussim|plustwo|lesssim|cularrp|rarrsim|Cayleys|notinva|notinvb|notinvc|UpArrow|Uparrow|uparrow|NotLess|dwangle|precsim|Product|curarrm|Cconint|dotplus|rarrbfs|ccupssm|Cedilla|cemptyv|notniva|quatint|frac35|frac38|frac45|frac56|frac58|frac78|tridot|xoplus|gacute|gammad|Gammad|lfisht|lfloor|bigcup|sqsupe|gbreve|Gbreve|lharul|sqsube|sqcups|Gcedil|apacir|llhard|lmidot|Lmidot|lmoust|andand|sqcaps|approx|Abreve|spades|circeq|tprime|divide|topcir|Assign|topbot|gesdot|divonx|xuplus|timesd|gesles|atilde|solbar|SOFTcy|loplus|timesb|lowast|lowbar|dlcorn|dlcrop|softcy|dollar|lparlt|thksim|lrhard|Atilde|lsaquo|smashp|bigvee|thinsp|wreath|bkarow|lsquor|lstrok|Lstrok|lthree|ltimes|ltlarr|DotDot|simdot|ltrPar|weierp|xsqcup|angmsd|sigmav|sigmaf|zeetrf|Zcaron|zcaron|mapsto|vsupne|thetav|cirmid|marker|mcomma|Zacute|vsubnE|there4|gtlPar|vsubne|bottom|gtrarr|SHCHcy|shchcy|midast|midcir|middot|minusb|minusd|gtrdot|bowtie|sfrown|mnplus|models|colone|seswar|Colone|mstpos|searhk|gtrsim|nacute|Nacute|boxbox|telrec|hairsp|Tcedil|nbumpe|scnsim|ncaron|Ncaron|ncedil|Ncedil|hamilt|Scedil|nearhk|hardcy|HARDcy|tcedil|Tcaron|commat|nequiv|nesear|tcaron|target|hearts|nexist|varrho|scedil|Scaron|scaron|hellip|Sacute|sacute|hercon|swnwar|compfn|rtimes|rthree|rsquor|rsaquo|zacute|wedgeq|homtht|barvee|barwed|Barwed|rpargt|horbar|conint|swarhk|roplus|nltrie|hslash|hstrok|Hstrok|rmoust|Conint|bprime|hybull|hyphen|iacute|Iacute|supsup|supsub|supsim|varphi|coprod|brvbar|agrave|Supset|supset|igrave|Igrave|notinE|Agrave|iiiint|iinfin|copysr|wedbar|Verbar|vangrt|becaus|incare|verbar|inodot|bullet|drcorn|intcal|drcrop|cularr|vellip|Utilde|bumpeq|cupcap|dstrok|Dstrok|CupCap|cupcup|cupdot|eacute|Eacute|supdot|iquest|easter|ecaron|Ecaron|ecolon|isinsv|utilde|itilde|Itilde|curarr|succeq|Bumpeq|cacute|ulcrop|nparsl|Cacute|nprcue|egrave|Egrave|nrarrc|nrarrw|subsup|subsub|nrtrie|jsercy|nsccue|Jsercy|kappav|kcedil|Kcedil|subsim|ulcorn|nsimeq|egsdot|veebar|kgreen|capand|elsdot|Subset|subset|curren|aacute|lacute|Lacute|emptyv|ntilde|Ntilde|lagran|lambda|Lambda|capcap|Ugrave|langle|subdot|emsp13|numero|emsp14|nvdash|nvDash|nVdash|nVDash|ugrave|ufisht|nvHarr|larrfs|nvlArr|larrhk|larrlp|larrpl|nvrArr|Udblac|nwarhk|larrtl|nwnear|oacute|Oacute|latail|lAtail|sstarf|lbrace|odblac|Odblac|lbrack|udblac|odsold|eparsl|lcaron|Lcaron|ograve|Ograve|lcedil|Lcedil|Aacute|ssmile|ssetmn|squarf|ldquor|capcup|ominus|cylcty|rharul|eqcirc|dagger|rfloor|rfisht|Dagger|daleth|equals|origof|capdot|equest|dcaron|Dcaron|rdquor|oslash|Oslash|otilde|Otilde|otimes|Otimes|urcrop|Ubreve|ubreve|Yacute|Uacute|uacute|Rcedil|rcedil|urcorn|parsim|Rcaron|Vdashl|rcaron|Tstrok|percnt|period|permil|Exists|yacute|rbrack|rbrace|phmmat|ccaron|Ccaron|planck|ccedil|plankv|tstrok|female|plusdo|plusdu|ffilig|plusmn|ffllig|Ccedil|rAtail|dfisht|bernou|ratail|Rarrtl|rarrtl|angsph|rarrpl|rarrlp|rarrhk|xwedge|xotime|forall|ForAll|Vvdash|vsupnE|preceq|bigcap|frac12|frac13|frac14|primes|rarrfs|prnsim|frac15|Square|frac16|square|lesdot|frac18|frac23|propto|prurel|rarrap|rangle|puncsp|frac25|Racute|qprime|racute|lesges|frac34|abreve|AElig|eqsim|utdot|setmn|urtri|Equal|Uring|seArr|uring|searr|dashv|Dashv|mumap|nabla|iogon|Iogon|sdote|sdotb|scsim|napid|napos|equiv|natur|Acirc|dblac|erarr|nbump|iprod|erDot|ucirc|awint|esdot|angrt|ncong|isinE|scnap|Scirc|scirc|ndash|isins|Ubrcy|nearr|neArr|isinv|nedot|ubrcy|acute|Ycirc|iukcy|Iukcy|xutri|nesim|caret|jcirc|Jcirc|caron|twixt|ddarr|sccue|exist|jmath|sbquo|ngeqq|angst|ccaps|lceil|ngsim|UpTee|delta|Delta|rtrif|nharr|nhArr|nhpar|rtrie|jukcy|Jukcy|kappa|rsquo|Kappa|nlarr|nlArr|TSHcy|rrarr|aogon|Aogon|fflig|xrarr|tshcy|ccirc|nleqq|filig|upsih|nless|dharl|nlsim|fjlig|ropar|nltri|dharr|robrk|roarr|fllig|fltns|roang|rnmid|subnE|subne|lAarr|trisb|Ccirc|acirc|ccups|blank|VDash|forkv|Vdash|langd|cedil|blk12|blk14|laquo|strns|diams|notin|vDash|larrb|blk34|block|disin|uplus|vdash|vBarv|aelig|starf|Wedge|check|xrArr|lates|lbarr|lBarr|notni|lbbrk|bcong|frasl|lbrke|frown|vrtri|vprop|vnsup|gamma|Gamma|wedge|xodot|bdquo|srarr|doteq|ldquo|boxdl|boxdL|gcirc|Gcirc|boxDl|boxDL|boxdr|boxdR|boxDr|TRADE|trade|rlhar|boxDR|vnsub|npart|vltri|rlarr|boxhd|boxhD|nprec|gescc|nrarr|nrArr|boxHd|boxHD|boxhu|boxhU|nrtri|boxHu|clubs|boxHU|times|colon|Colon|gimel|xlArr|Tilde|nsime|tilde|nsmid|nspar|THORN|thorn|xlarr|nsube|nsubE|thkap|xhArr|comma|nsucc|boxul|boxuL|nsupe|nsupE|gneqq|gnsim|boxUl|boxUL|grave|boxur|boxuR|boxUr|boxUR|lescc|angle|bepsi|boxvh|varpi|boxvH|numsp|Theta|gsime|gsiml|theta|boxVh|boxVH|boxvl|gtcir|gtdot|boxvL|boxVl|boxVL|crarr|cross|Cross|nvsim|boxvr|nwarr|nwArr|sqsup|dtdot|Uogon|lhard|lharu|dtrif|ocirc|Ocirc|lhblk|duarr|odash|sqsub|Hacek|sqcup|llarr|duhar|oelig|OElig|ofcir|boxvR|uogon|lltri|boxVr|csube|uuarr|ohbar|csupe|ctdot|olarr|olcir|harrw|oline|sqcap|omacr|Omacr|omega|Omega|boxVR|aleph|lneqq|lnsim|loang|loarr|rharu|lobrk|hcirc|operp|oplus|rhard|Hcirc|orarr|Union|order|ecirc|Ecirc|cuepr|szlig|cuesc|breve|reals|eDDot|Breve|hoarr|lopar|utrif|rdquo|Umacr|umacr|efDot|swArr|ultri|alpha|rceil|ovbar|swarr|Wcirc|wcirc|smtes|smile|bsemi|lrarr|aring|parsl|lrhar|bsime|uhblk|lrtri|cupor|Aring|uharr|uharl|slarr|rbrke|bsolb|lsime|rbbrk|RBarr|lsimg|phone|rBarr|rbarr|icirc|lsquo|Icirc|emacr|Emacr|ratio|simne|plusb|simlE|simgE|simeq|pluse|ltcir|ltdot|empty|xharr|xdtri|iexcl|Alpha|ltrie|rarrw|pound|ltrif|xcirc|bumpe|prcue|bumpE|asymp|amacr|cuvee|Sigma|sigma|iiint|udhar|iiota|ijlig|IJlig|supnE|imacr|Imacr|prime|Prime|image|prnap|eogon|Eogon|rarrc|mdash|mDDot|cuwed|imath|supne|imped|Amacr|udarr|prsim|micro|rarrb|cwint|raquo|infin|eplus|range|rangd|Ucirc|radic|minus|amalg|veeeq|rAarr|epsiv|ycirc|quest|sharp|quot|zwnj|Qscr|race|qscr|Qopf|qopf|qint|rang|Rang|Zscr|zscr|Zopf|zopf|rarr|rArr|Rarr|Pscr|pscr|prop|prod|prnE|prec|ZHcy|zhcy|prap|Zeta|zeta|Popf|popf|Zdot|plus|zdot|Yuml|yuml|phiv|YUcy|yucy|Yscr|yscr|perp|Yopf|yopf|part|para|YIcy|Ouml|rcub|yicy|YAcy|rdca|ouml|osol|Oscr|rdsh|yacy|real|oscr|xvee|andd|rect|andv|Xscr|oror|ordm|ordf|xscr|ange|aopf|Aopf|rHar|Xopf|opar|Oopf|xopf|xnis|rhov|oopf|omid|xmap|oint|apid|apos|ogon|ascr|Ascr|odot|odiv|xcup|xcap|ocir|oast|nvlt|nvle|nvgt|nvge|nvap|Wscr|wscr|auml|ntlg|ntgl|nsup|nsub|nsim|Nscr|nscr|nsce|Wopf|ring|npre|wopf|npar|Auml|Barv|bbrk|Nopf|nopf|nmid|nLtv|beta|ropf|Ropf|Beta|beth|nles|rpar|nleq|bnot|bNot|nldr|NJcy|rscr|Rscr|Vscr|vscr|rsqb|njcy|bopf|nisd|Bopf|rtri|Vopf|nGtv|ngtr|vopf|boxh|boxH|boxv|nges|ngeq|boxV|bscr|scap|Bscr|bsim|Vert|vert|bsol|bull|bump|caps|cdot|ncup|scnE|ncap|nbsp|napE|Cdot|cent|sdot|Vbar|nang|vBar|chcy|Mscr|mscr|sect|semi|CHcy|Mopf|mopf|sext|circ|cire|mldr|mlcp|cirE|comp|shcy|SHcy|vArr|varr|cong|copf|Copf|copy|COPY|malt|male|macr|lvnE|cscr|ltri|sime|ltcc|simg|Cscr|siml|csub|Uuml|lsqb|lsim|uuml|csup|Lscr|lscr|utri|smid|lpar|cups|smte|lozf|darr|Lopf|Uscr|solb|lopf|sopf|Sopf|lneq|uscr|spar|dArr|lnap|Darr|dash|Sqrt|LJcy|ljcy|lHar|dHar|Upsi|upsi|diam|lesg|djcy|DJcy|leqq|dopf|Dopf|dscr|Dscr|dscy|ldsh|ldca|squf|DScy|sscr|Sscr|dsol|lcub|late|star|Star|Uopf|Larr|lArr|larr|uopf|dtri|dzcy|sube|subE|Lang|lang|Kscr|kscr|Kopf|kopf|KJcy|kjcy|KHcy|khcy|DZcy|ecir|edot|eDot|Jscr|jscr|succ|Jopf|jopf|Edot|uHar|emsp|ensp|Iuml|iuml|eopf|isin|Iscr|iscr|Eopf|epar|sung|epsi|escr|sup1|sup2|sup3|Iota|iota|supe|supE|Iopf|iopf|IOcy|iocy|Escr|esim|Esim|imof|Uarr|QUOT|uArr|uarr|euml|IEcy|iecy|Idot|Euml|euro|excl|Hscr|hscr|Hopf|hopf|TScy|tscy|Tscr|hbar|tscr|flat|tbrk|fnof|hArr|harr|half|fopf|Fopf|tdot|gvnE|fork|trie|gtcc|fscr|Fscr|gdot|gsim|Gscr|gscr|Gopf|gopf|gneq|Gdot|tosa|gnap|Topf|topf|geqq|toea|GJcy|gjcy|tint|gesl|mid|Sfr|ggg|top|ges|gla|glE|glj|geq|gne|gEl|gel|gnE|Gcy|gcy|gap|Tfr|tfr|Tcy|tcy|Hat|Tau|Ffr|tau|Tab|hfr|Hfr|ffr|Fcy|fcy|icy|Icy|iff|ETH|eth|ifr|Ifr|Eta|eta|int|Int|Sup|sup|ucy|Ucy|Sum|sum|jcy|ENG|ufr|Ufr|eng|Jcy|jfr|els|ell|egs|Efr|efr|Jfr|uml|kcy|Kcy|Ecy|ecy|kfr|Kfr|lap|Sub|sub|lat|lcy|Lcy|leg|Dot|dot|lEg|leq|les|squ|div|die|lfr|Lfr|lgE|Dfr|dfr|Del|deg|Dcy|dcy|lne|lnE|sol|loz|smt|Cup|lrm|cup|lsh|Lsh|sim|shy|map|Map|mcy|Mcy|mfr|Mfr|mho|gfr|Gfr|sfr|cir|Chi|chi|nap|Cfr|vcy|Vcy|cfr|Scy|scy|ncy|Ncy|vee|Vee|Cap|cap|nfr|scE|sce|Nfr|nge|ngE|nGg|vfr|Vfr|ngt|bot|nGt|nis|niv|Rsh|rsh|nle|nlE|bne|Bfr|bfr|nLl|nlt|nLt|Bcy|bcy|not|Not|rlm|wfr|Wfr|npr|nsc|num|ocy|ast|Ocy|ofr|xfr|Xfr|Ofr|ogt|ohm|apE|olt|Rho|ape|rho|Rfr|rfr|ord|REG|ang|reg|orv|And|and|AMP|Rcy|amp|Afr|ycy|Ycy|yen|yfr|Yfr|rcy|par|pcy|Pcy|pfr|Pfr|phi|Phi|afr|Acy|acy|zcy|Zcy|piv|acE|acd|zfr|Zfr|pre|prE|psi|Psi|qfr|Qfr|zwj|Or|ge|Gg|gt|gg|el|oS|lt|Lt|LT|Re|lg|gl|eg|ne|Im|it|le|DD|wp|wr|nu|Nu|dd|lE|Sc|sc|pi|Pi|ee|af|ll|Ll|rx|gE|xi|pm|Xi|ic|pr|Pr|in|ni|mp|mu|ac|Mu|or|ap|Gt|GT|ii);|&(Aacute|Agrave|Atilde|Ccedil|Eacute|Egrave|Iacute|Igrave|Ntilde|Oacute|Ograve|Oslash|Otilde|Uacute|Ugrave|Yacute|aacute|agrave|atilde|brvbar|ccedil|curren|divide|eacute|egrave|frac12|frac14|frac34|iacute|igrave|iquest|middot|ntilde|oacute|ograve|oslash|otilde|plusmn|uacute|ugrave|yacute|AElig|Acirc|Aring|Ecirc|Icirc|Ocirc|THORN|Ucirc|acirc|acute|aelig|aring|cedil|ecirc|icirc|iexcl|laquo|micro|ocirc|pound|raquo|szlig|thorn|times|ucirc|Auml|COPY|Euml|Iuml|Ouml|QUOT|Uuml|auml|cent|copy|euml|iuml|macr|nbsp|ordf|ordm|ouml|para|quot|sect|sup1|sup2|sup3|uuml|yuml|AMP|ETH|REG|amp|deg|eth|not|reg|shy|uml|yen|GT|LT|gt|lt)(?!;)([=a-zA-Z0-9]?)|&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+)/g;
|
2296 | var decodeMap = {'aacute':'\xE1','Aacute':'\xC1','abreve':'\u0103','Abreve':'\u0102','ac':'\u223E','acd':'\u223F','acE':'\u223E\u0333','acirc':'\xE2','Acirc':'\xC2','acute':'\xB4','acy':'\u0430','Acy':'\u0410','aelig':'\xE6','AElig':'\xC6','af':'\u2061','afr':'\uD835\uDD1E','Afr':'\uD835\uDD04','agrave':'\xE0','Agrave':'\xC0','alefsym':'\u2135','aleph':'\u2135','alpha':'\u03B1','Alpha':'\u0391','amacr':'\u0101','Amacr':'\u0100','amalg':'\u2A3F','amp':'&','AMP':'&','and':'\u2227','And':'\u2A53','andand':'\u2A55','andd':'\u2A5C','andslope':'\u2A58','andv':'\u2A5A','ang':'\u2220','ange':'\u29A4','angle':'\u2220','angmsd':'\u2221','angmsdaa':'\u29A8','angmsdab':'\u29A9','angmsdac':'\u29AA','angmsdad':'\u29AB','angmsdae':'\u29AC','angmsdaf':'\u29AD','angmsdag':'\u29AE','angmsdah':'\u29AF','angrt':'\u221F','angrtvb':'\u22BE','angrtvbd':'\u299D','angsph':'\u2222','angst':'\xC5','angzarr':'\u237C','aogon':'\u0105','Aogon':'\u0104','aopf':'\uD835\uDD52','Aopf':'\uD835\uDD38','ap':'\u2248','apacir':'\u2A6F','ape':'\u224A','apE':'\u2A70','apid':'\u224B','apos':'\'','ApplyFunction':'\u2061','approx':'\u2248','approxeq':'\u224A','aring':'\xE5','Aring':'\xC5','ascr':'\uD835\uDCB6','Ascr':'\uD835\uDC9C','Assign':'\u2254','ast':'*','asymp':'\u2248','asympeq':'\u224D','atilde':'\xE3','Atilde':'\xC3','auml':'\xE4','Auml':'\xC4','awconint':'\u2233','awint':'\u2A11','backcong':'\u224C','backepsilon':'\u03F6','backprime':'\u2035','backsim':'\u223D','backsimeq':'\u22CD','Backslash':'\u2216','Barv':'\u2AE7','barvee':'\u22BD','barwed':'\u2305','Barwed':'\u2306','barwedge':'\u2305','bbrk':'\u23B5','bbrktbrk':'\u23B6','bcong':'\u224C','bcy':'\u0431','Bcy':'\u0411','bdquo':'\u201E','becaus':'\u2235','because':'\u2235','Because':'\u2235','bemptyv':'\u29B0','bepsi':'\u03F6','bernou':'\u212C','Bernoullis':'\u212C','beta':'\u03B2','Beta':'\u0392','beth':'\u2136','between':'\u226C','bfr':'\uD835\uDD1F','Bfr':'\uD835\uDD05','bigcap':'\u22C2','bigcirc':'\u25EF','bigcup':'\u22C3','bigodot':'\u2A00','bigoplus':'\u2A01','bigotimes':'\u2A02','bigsqcup':'\u2A06','bigstar':'\u2605','bigtriangledown':'\u25BD','bigtriangleup':'\u25B3','biguplus':'\u2A04','bigvee':'\u22C1','bigwedge':'\u22C0','bkarow':'\u290D','blacklozenge':'\u29EB','blacksquare':'\u25AA','blacktriangle':'\u25B4','blacktriangledown':'\u25BE','blacktriangleleft':'\u25C2','blacktriangleright':'\u25B8','blank':'\u2423','blk12':'\u2592','blk14':'\u2591','blk34':'\u2593','block':'\u2588','bne':'=\u20E5','bnequiv':'\u2261\u20E5','bnot':'\u2310','bNot':'\u2AED','bopf':'\uD835\uDD53','Bopf':'\uD835\uDD39','bot':'\u22A5','bottom':'\u22A5','bowtie':'\u22C8','boxbox':'\u29C9','boxdl':'\u2510','boxdL':'\u2555','boxDl':'\u2556','boxDL':'\u2557','boxdr':'\u250C','boxdR':'\u2552','boxDr':'\u2553','boxDR':'\u2554','boxh':'\u2500','boxH':'\u2550','boxhd':'\u252C','boxhD':'\u2565','boxHd':'\u2564','boxHD':'\u2566','boxhu':'\u2534','boxhU':'\u2568','boxHu':'\u2567','boxHU':'\u2569','boxminus':'\u229F','boxplus':'\u229E','boxtimes':'\u22A0','boxul':'\u2518','boxuL':'\u255B','boxUl':'\u255C','boxUL':'\u255D','boxur':'\u2514','boxuR':'\u2558','boxUr':'\u2559','boxUR':'\u255A','boxv':'\u2502','boxV':'\u2551','boxvh':'\u253C','boxvH':'\u256A','boxVh':'\u256B','boxVH':'\u256C','boxvl':'\u2524','boxvL':'\u2561','boxVl':'\u2562','boxVL':'\u2563','boxvr':'\u251C','boxvR':'\u255E','boxVr':'\u255F','boxVR':'\u2560','bprime':'\u2035','breve':'\u02D8','Breve':'\u02D8','brvbar':'\xA6','bscr':'\uD835\uDCB7','Bscr':'\u212C','bsemi':'\u204F','bsim':'\u223D','bsime':'\u22CD','bsol':'\\','bsolb':'\u29C5','bsolhsub':'\u27C8','bull':'\u2022','bullet':'\u2022','bump':'\u224E','bumpe':'\u224F','bumpE':'\u2AAE','bumpeq':'\u224F','Bumpeq':'\u224E','cacute':'\u0107','Cacute':'\u0106','cap':'\u2229','Cap':'\u22D2','capand':'\u2A44','capbrcup':'\u2A49','capcap':'\u2A4B','capcup':'\u2A47','capdot':'\u2A40','CapitalDifferentialD':'\u2145','caps':'\u2229\uFE00','caret':'\u2041','caron':'\u02C7','Cayleys':'\u212D','ccaps':'\u2A4D','ccaron':'\u010D','Ccaron':'\u010C','ccedil':'\xE7','Ccedil':'\xC7','ccirc':'\u0109','Ccirc':'\u0108','Cconint':'\u2230','ccups':'\u2A4C','ccupssm':'\u2A50','cdot':'\u010B','Cdot':'\u010A','cedil':'\xB8','Cedilla':'\xB8','cemptyv':'\u29B2','cent':'\xA2','centerdot':'\xB7','CenterDot':'\xB7','cfr':'\uD835\uDD20','Cfr':'\u212D','chcy':'\u0447','CHcy':'\u0427','check':'\u2713','checkmark':'\u2713','chi':'\u03C7','Chi':'\u03A7','cir':'\u25CB','circ':'\u02C6','circeq':'\u2257','circlearrowleft':'\u21BA','circlearrowright':'\u21BB','circledast':'\u229B','circledcirc':'\u229A','circleddash':'\u229D','CircleDot':'\u2299','circledR':'\xAE','circledS':'\u24C8','CircleMinus':'\u2296','CirclePlus':'\u2295','CircleTimes':'\u2297','cire':'\u2257','cirE':'\u29C3','cirfnint':'\u2A10','cirmid':'\u2AEF','cirscir':'\u29C2','ClockwiseContourIntegral':'\u2232','CloseCurlyDoubleQuote':'\u201D','CloseCurlyQuote':'\u2019','clubs':'\u2663','clubsuit':'\u2663','colon':':','Colon':'\u2237','colone':'\u2254','Colone':'\u2A74','coloneq':'\u2254','comma':',','commat':'@','comp':'\u2201','compfn':'\u2218','complement':'\u2201','complexes':'\u2102','cong':'\u2245','congdot':'\u2A6D','Congruent':'\u2261','conint':'\u222E','Conint':'\u222F','ContourIntegral':'\u222E','copf':'\uD835\uDD54','Copf':'\u2102','coprod':'\u2210','Coproduct':'\u2210','copy':'\xA9','COPY':'\xA9','copysr':'\u2117','CounterClockwiseContourIntegral':'\u2233','crarr':'\u21B5','cross':'\u2717','Cross':'\u2A2F','cscr':'\uD835\uDCB8','Cscr':'\uD835\uDC9E','csub':'\u2ACF','csube':'\u2AD1','csup':'\u2AD0','csupe':'\u2AD2','ctdot':'\u22EF','cudarrl':'\u2938','cudarrr':'\u2935','cuepr':'\u22DE','cuesc':'\u22DF','cularr':'\u21B6','cularrp':'\u293D','cup':'\u222A','Cup':'\u22D3','cupbrcap':'\u2A48','cupcap':'\u2A46','CupCap':'\u224D','cupcup':'\u2A4A','cupdot':'\u228D','cupor':'\u2A45','cups':'\u222A\uFE00','curarr':'\u21B7','curarrm':'\u293C','curlyeqprec':'\u22DE','curlyeqsucc':'\u22DF','curlyvee':'\u22CE','curlywedge':'\u22CF','curren':'\xA4','curvearrowleft':'\u21B6','curvearrowright':'\u21B7','cuvee':'\u22CE','cuwed':'\u22CF','cwconint':'\u2232','cwint':'\u2231','cylcty':'\u232D','dagger':'\u2020','Dagger':'\u2021','daleth':'\u2138','darr':'\u2193','dArr':'\u21D3','Darr':'\u21A1','dash':'\u2010','dashv':'\u22A3','Dashv':'\u2AE4','dbkarow':'\u290F','dblac':'\u02DD','dcaron':'\u010F','Dcaron':'\u010E','dcy':'\u0434','Dcy':'\u0414','dd':'\u2146','DD':'\u2145','ddagger':'\u2021','ddarr':'\u21CA','DDotrahd':'\u2911','ddotseq':'\u2A77','deg':'\xB0','Del':'\u2207','delta':'\u03B4','Delta':'\u0394','demptyv':'\u29B1','dfisht':'\u297F','dfr':'\uD835\uDD21','Dfr':'\uD835\uDD07','dHar':'\u2965','dharl':'\u21C3','dharr':'\u21C2','DiacriticalAcute':'\xB4','DiacriticalDot':'\u02D9','DiacriticalDoubleAcute':'\u02DD','DiacriticalGrave':'`','DiacriticalTilde':'\u02DC','diam':'\u22C4','diamond':'\u22C4','Diamond':'\u22C4','diamondsuit':'\u2666','diams':'\u2666','die':'\xA8','DifferentialD':'\u2146','digamma':'\u03DD','disin':'\u22F2','div':'\xF7','divide':'\xF7','divideontimes':'\u22C7','divonx':'\u22C7','djcy':'\u0452','DJcy':'\u0402','dlcorn':'\u231E','dlcrop':'\u230D','dollar':'$','dopf':'\uD835\uDD55','Dopf':'\uD835\uDD3B','dot':'\u02D9','Dot':'\xA8','DotDot':'\u20DC','doteq':'\u2250','doteqdot':'\u2251','DotEqual':'\u2250','dotminus':'\u2238','dotplus':'\u2214','dotsquare':'\u22A1','doublebarwedge':'\u2306','DoubleContourIntegral':'\u222F','DoubleDot':'\xA8','DoubleDownArrow':'\u21D3','DoubleLeftArrow':'\u21D0','DoubleLeftRightArrow':'\u21D4','DoubleLeftTee':'\u2AE4','DoubleLongLeftArrow':'\u27F8','DoubleLongLeftRightArrow':'\u27FA','DoubleLongRightArrow':'\u27F9','DoubleRightArrow':'\u21D2','DoubleRightTee':'\u22A8','DoubleUpArrow':'\u21D1','DoubleUpDownArrow':'\u21D5','DoubleVerticalBar':'\u2225','downarrow':'\u2193','Downarrow':'\u21D3','DownArrow':'\u2193','DownArrowBar':'\u2913','DownArrowUpArrow':'\u21F5','DownBreve':'\u0311','downdownarrows':'\u21CA','downharpoonleft':'\u21C3','downharpoonright':'\u21C2','DownLeftRightVector':'\u2950','DownLeftTeeVector':'\u295E','DownLeftVector':'\u21BD','DownLeftVectorBar':'\u2956','DownRightTeeVector':'\u295F','DownRightVector':'\u21C1','DownRightVectorBar':'\u2957','DownTee':'\u22A4','DownTeeArrow':'\u21A7','drbkarow':'\u2910','drcorn':'\u231F','drcrop':'\u230C','dscr':'\uD835\uDCB9','Dscr':'\uD835\uDC9F','dscy':'\u0455','DScy':'\u0405','dsol':'\u29F6','dstrok':'\u0111','Dstrok':'\u0110','dtdot':'\u22F1','dtri':'\u25BF','dtrif':'\u25BE','duarr':'\u21F5','duhar':'\u296F','dwangle':'\u29A6','dzcy':'\u045F','DZcy':'\u040F','dzigrarr':'\u27FF','eacute':'\xE9','Eacute':'\xC9','easter':'\u2A6E','ecaron':'\u011B','Ecaron':'\u011A','ecir':'\u2256','ecirc':'\xEA','Ecirc':'\xCA','ecolon':'\u2255','ecy':'\u044D','Ecy':'\u042D','eDDot':'\u2A77','edot':'\u0117','eDot':'\u2251','Edot':'\u0116','ee':'\u2147','efDot':'\u2252','efr':'\uD835\uDD22','Efr':'\uD835\uDD08','eg':'\u2A9A','egrave':'\xE8','Egrave':'\xC8','egs':'\u2A96','egsdot':'\u2A98','el':'\u2A99','Element':'\u2208','elinters':'\u23E7','ell':'\u2113','els':'\u2A95','elsdot':'\u2A97','emacr':'\u0113','Emacr':'\u0112','empty':'\u2205','emptyset':'\u2205','EmptySmallSquare':'\u25FB','emptyv':'\u2205','EmptyVerySmallSquare':'\u25AB','emsp':'\u2003','emsp13':'\u2004','emsp14':'\u2005','eng':'\u014B','ENG':'\u014A','ensp':'\u2002','eogon':'\u0119','Eogon':'\u0118','eopf':'\uD835\uDD56','Eopf':'\uD835\uDD3C','epar':'\u22D5','eparsl':'\u29E3','eplus':'\u2A71','epsi':'\u03B5','epsilon':'\u03B5','Epsilon':'\u0395','epsiv':'\u03F5','eqcirc':'\u2256','eqcolon':'\u2255','eqsim':'\u2242','eqslantgtr':'\u2A96','eqslantless':'\u2A95','Equal':'\u2A75','equals':'=','EqualTilde':'\u2242','equest':'\u225F','Equilibrium':'\u21CC','equiv':'\u2261','equivDD':'\u2A78','eqvparsl':'\u29E5','erarr':'\u2971','erDot':'\u2253','escr':'\u212F','Escr':'\u2130','esdot':'\u2250','esim':'\u2242','Esim':'\u2A73','eta':'\u03B7','Eta':'\u0397','eth':'\xF0','ETH':'\xD0','euml':'\xEB','Euml':'\xCB','euro':'\u20AC','excl':'!','exist':'\u2203','Exists':'\u2203','expectation':'\u2130','exponentiale':'\u2147','ExponentialE':'\u2147','fallingdotseq':'\u2252','fcy':'\u0444','Fcy':'\u0424','female':'\u2640','ffilig':'\uFB03','fflig':'\uFB00','ffllig':'\uFB04','ffr':'\uD835\uDD23','Ffr':'\uD835\uDD09','filig':'\uFB01','FilledSmallSquare':'\u25FC','FilledVerySmallSquare':'\u25AA','fjlig':'fj','flat':'\u266D','fllig':'\uFB02','fltns':'\u25B1','fnof':'\u0192','fopf':'\uD835\uDD57','Fopf':'\uD835\uDD3D','forall':'\u2200','ForAll':'\u2200','fork':'\u22D4','forkv':'\u2AD9','Fouriertrf':'\u2131','fpartint':'\u2A0D','frac12':'\xBD','frac13':'\u2153','frac14':'\xBC','frac15':'\u2155','frac16':'\u2159','frac18':'\u215B','frac23':'\u2154','frac25':'\u2156','frac34':'\xBE','frac35':'\u2157','frac38':'\u215C','frac45':'\u2158','frac56':'\u215A','frac58':'\u215D','frac78':'\u215E','frasl':'\u2044','frown':'\u2322','fscr':'\uD835\uDCBB','Fscr':'\u2131','gacute':'\u01F5','gamma':'\u03B3','Gamma':'\u0393','gammad':'\u03DD','Gammad':'\u03DC','gap':'\u2A86','gbreve':'\u011F','Gbreve':'\u011E','Gcedil':'\u0122','gcirc':'\u011D','Gcirc':'\u011C','gcy':'\u0433','Gcy':'\u0413','gdot':'\u0121','Gdot':'\u0120','ge':'\u2265','gE':'\u2267','gel':'\u22DB','gEl':'\u2A8C','geq':'\u2265','geqq':'\u2267','geqslant':'\u2A7E','ges':'\u2A7E','gescc':'\u2AA9','gesdot':'\u2A80','gesdoto':'\u2A82','gesdotol':'\u2A84','gesl':'\u22DB\uFE00','gesles':'\u2A94','gfr':'\uD835\uDD24','Gfr':'\uD835\uDD0A','gg':'\u226B','Gg':'\u22D9','ggg':'\u22D9','gimel':'\u2137','gjcy':'\u0453','GJcy':'\u0403','gl':'\u2277','gla':'\u2AA5','glE':'\u2A92','glj':'\u2AA4','gnap':'\u2A8A','gnapprox':'\u2A8A','gne':'\u2A88','gnE':'\u2269','gneq':'\u2A88','gneqq':'\u2269','gnsim':'\u22E7','gopf':'\uD835\uDD58','Gopf':'\uD835\uDD3E','grave':'`','GreaterEqual':'\u2265','GreaterEqualLess':'\u22DB','GreaterFullEqual':'\u2267','GreaterGreater':'\u2AA2','GreaterLess':'\u2277','GreaterSlantEqual':'\u2A7E','GreaterTilde':'\u2273','gscr':'\u210A','Gscr':'\uD835\uDCA2','gsim':'\u2273','gsime':'\u2A8E','gsiml':'\u2A90','gt':'>','Gt':'\u226B','GT':'>','gtcc':'\u2AA7','gtcir':'\u2A7A','gtdot':'\u22D7','gtlPar':'\u2995','gtquest':'\u2A7C','gtrapprox':'\u2A86','gtrarr':'\u2978','gtrdot':'\u22D7','gtreqless':'\u22DB','gtreqqless':'\u2A8C','gtrless':'\u2277','gtrsim':'\u2273','gvertneqq':'\u2269\uFE00','gvnE':'\u2269\uFE00','Hacek':'\u02C7','hairsp':'\u200A','half':'\xBD','hamilt':'\u210B','hardcy':'\u044A','HARDcy':'\u042A','harr':'\u2194','hArr':'\u21D4','harrcir':'\u2948','harrw':'\u21AD','Hat':'^','hbar':'\u210F','hcirc':'\u0125','Hcirc':'\u0124','hearts':'\u2665','heartsuit':'\u2665','hellip':'\u2026','hercon':'\u22B9','hfr':'\uD835\uDD25','Hfr':'\u210C','HilbertSpace':'\u210B','hksearow':'\u2925','hkswarow':'\u2926','hoarr':'\u21FF','homtht':'\u223B','hookleftarrow':'\u21A9','hookrightarrow':'\u21AA','hopf':'\uD835\uDD59','Hopf':'\u210D','horbar':'\u2015','HorizontalLine':'\u2500','hscr':'\uD835\uDCBD','Hscr':'\u210B','hslash':'\u210F','hstrok':'\u0127','Hstrok':'\u0126','HumpDownHump':'\u224E','HumpEqual':'\u224F','hybull':'\u2043','hyphen':'\u2010','iacute':'\xED','Iacute':'\xCD','ic':'\u2063','icirc':'\xEE','Icirc':'\xCE','icy':'\u0438','Icy':'\u0418','Idot':'\u0130','iecy':'\u0435','IEcy':'\u0415','iexcl':'\xA1','iff':'\u21D4','ifr':'\uD835\uDD26','Ifr':'\u2111','igrave':'\xEC','Igrave':'\xCC','ii':'\u2148','iiiint':'\u2A0C','iiint':'\u222D','iinfin':'\u29DC','iiota':'\u2129','ijlig':'\u0133','IJlig':'\u0132','Im':'\u2111','imacr':'\u012B','Imacr':'\u012A','image':'\u2111','ImaginaryI':'\u2148','imagline':'\u2110','imagpart':'\u2111','imath':'\u0131','imof':'\u22B7','imped':'\u01B5','Implies':'\u21D2','in':'\u2208','incare':'\u2105','infin':'\u221E','infintie':'\u29DD','inodot':'\u0131','int':'\u222B','Int':'\u222C','intcal':'\u22BA','integers':'\u2124','Integral':'\u222B','intercal':'\u22BA','Intersection':'\u22C2','intlarhk':'\u2A17','intprod':'\u2A3C','InvisibleComma':'\u2063','InvisibleTimes':'\u2062','iocy':'\u0451','IOcy':'\u0401','iogon':'\u012F','Iogon':'\u012E','iopf':'\uD835\uDD5A','Iopf':'\uD835\uDD40','iota':'\u03B9','Iota':'\u0399','iprod':'\u2A3C','iquest':'\xBF','iscr':'\uD835\uDCBE','Iscr':'\u2110','isin':'\u2208','isindot':'\u22F5','isinE':'\u22F9','isins':'\u22F4','isinsv':'\u22F3','isinv':'\u2208','it':'\u2062','itilde':'\u0129','Itilde':'\u0128','iukcy':'\u0456','Iukcy':'\u0406','iuml':'\xEF','Iuml':'\xCF','jcirc':'\u0135','Jcirc':'\u0134','jcy':'\u0439','Jcy':'\u0419','jfr':'\uD835\uDD27','Jfr':'\uD835\uDD0D','jmath':'\u0237','jopf':'\uD835\uDD5B','Jopf':'\uD835\uDD41','jscr':'\uD835\uDCBF','Jscr':'\uD835\uDCA5','jsercy':'\u0458','Jsercy':'\u0408','jukcy':'\u0454','Jukcy':'\u0404','kappa':'\u03BA','Kappa':'\u039A','kappav':'\u03F0','kcedil':'\u0137','Kcedil':'\u0136','kcy':'\u043A','Kcy':'\u041A','kfr':'\uD835\uDD28','Kfr':'\uD835\uDD0E','kgreen':'\u0138','khcy':'\u0445','KHcy':'\u0425','kjcy':'\u045C','KJcy':'\u040C','kopf':'\uD835\uDD5C','Kopf':'\uD835\uDD42','kscr':'\uD835\uDCC0','Kscr':'\uD835\uDCA6','lAarr':'\u21DA','lacute':'\u013A','Lacute':'\u0139','laemptyv':'\u29B4','lagran':'\u2112','lambda':'\u03BB','Lambda':'\u039B','lang':'\u27E8','Lang':'\u27EA','langd':'\u2991','langle':'\u27E8','lap':'\u2A85','Laplacetrf':'\u2112','laquo':'\xAB','larr':'\u2190','lArr':'\u21D0','Larr':'\u219E','larrb':'\u21E4','larrbfs':'\u291F','larrfs':'\u291D','larrhk':'\u21A9','larrlp':'\u21AB','larrpl':'\u2939','larrsim':'\u2973','larrtl':'\u21A2','lat':'\u2AAB','latail':'\u2919','lAtail':'\u291B','late':'\u2AAD','lates':'\u2AAD\uFE00','lbarr':'\u290C','lBarr':'\u290E','lbbrk':'\u2772','lbrace':'{','lbrack':'[','lbrke':'\u298B','lbrksld':'\u298F','lbrkslu':'\u298D','lcaron':'\u013E','Lcaron':'\u013D','lcedil':'\u013C','Lcedil':'\u013B','lceil':'\u2308','lcub':'{','lcy':'\u043B','Lcy':'\u041B','ldca':'\u2936','ldquo':'\u201C','ldquor':'\u201E','ldrdhar':'\u2967','ldrushar':'\u294B','ldsh':'\u21B2','le':'\u2264','lE':'\u2266','LeftAngleBracket':'\u27E8','leftarrow':'\u2190','Leftarrow':'\u21D0','LeftArrow':'\u2190','LeftArrowBar':'\u21E4','LeftArrowRightArrow':'\u21C6','leftarrowtail':'\u21A2','LeftCeiling':'\u2308','LeftDoubleBracket':'\u27E6','LeftDownTeeVector':'\u2961','LeftDownVector':'\u21C3','LeftDownVectorBar':'\u2959','LeftFloor':'\u230A','leftharpoondown':'\u21BD','leftharpoonup':'\u21BC','leftleftarrows':'\u21C7','leftrightarrow':'\u2194','Leftrightarrow':'\u21D4','LeftRightArrow':'\u2194','leftrightarrows':'\u21C6','leftrightharpoons':'\u21CB','leftrightsquigarrow':'\u21AD','LeftRightVector':'\u294E','LeftTee':'\u22A3','LeftTeeArrow':'\u21A4','LeftTeeVector':'\u295A','leftthreetimes':'\u22CB','LeftTriangle':'\u22B2','LeftTriangleBar':'\u29CF','LeftTriangleEqual':'\u22B4','LeftUpDownVector':'\u2951','LeftUpTeeVector':'\u2960','LeftUpVector':'\u21BF','LeftUpVectorBar':'\u2958','LeftVector':'\u21BC','LeftVectorBar':'\u2952','leg':'\u22DA','lEg':'\u2A8B','leq':'\u2264','leqq':'\u2266','leqslant':'\u2A7D','les':'\u2A7D','lescc':'\u2AA8','lesdot':'\u2A7F','lesdoto':'\u2A81','lesdotor':'\u2A83','lesg':'\u22DA\uFE00','lesges':'\u2A93','lessapprox':'\u2A85','lessdot':'\u22D6','lesseqgtr':'\u22DA','lesseqqgtr':'\u2A8B','LessEqualGreater':'\u22DA','LessFullEqual':'\u2266','LessGreater':'\u2276','lessgtr':'\u2276','LessLess':'\u2AA1','lesssim':'\u2272','LessSlantEqual':'\u2A7D','LessTilde':'\u2272','lfisht':'\u297C','lfloor':'\u230A','lfr':'\uD835\uDD29','Lfr':'\uD835\uDD0F','lg':'\u2276','lgE':'\u2A91','lHar':'\u2962','lhard':'\u21BD','lharu':'\u21BC','lharul':'\u296A','lhblk':'\u2584','ljcy':'\u0459','LJcy':'\u0409','ll':'\u226A','Ll':'\u22D8','llarr':'\u21C7','llcorner':'\u231E','Lleftarrow':'\u21DA','llhard':'\u296B','lltri':'\u25FA','lmidot':'\u0140','Lmidot':'\u013F','lmoust':'\u23B0','lmoustache':'\u23B0','lnap':'\u2A89','lnapprox':'\u2A89','lne':'\u2A87','lnE':'\u2268','lneq':'\u2A87','lneqq':'\u2268','lnsim':'\u22E6','loang':'\u27EC','loarr':'\u21FD','lobrk':'\u27E6','longleftarrow':'\u27F5','Longleftarrow':'\u27F8','LongLeftArrow':'\u27F5','longleftrightarrow':'\u27F7','Longleftrightarrow':'\u27FA','LongLeftRightArrow':'\u27F7','longmapsto':'\u27FC','longrightarrow':'\u27F6','Longrightarrow':'\u27F9','LongRightArrow':'\u27F6','looparrowleft':'\u21AB','looparrowright':'\u21AC','lopar':'\u2985','lopf':'\uD835\uDD5D','Lopf':'\uD835\uDD43','loplus':'\u2A2D','lotimes':'\u2A34','lowast':'\u2217','lowbar':'_','LowerLeftArrow':'\u2199','LowerRightArrow':'\u2198','loz':'\u25CA','lozenge':'\u25CA','lozf':'\u29EB','lpar':'(','lparlt':'\u2993','lrarr':'\u21C6','lrcorner':'\u231F','lrhar':'\u21CB','lrhard':'\u296D','lrm':'\u200E','lrtri':'\u22BF','lsaquo':'\u2039','lscr':'\uD835\uDCC1','Lscr':'\u2112','lsh':'\u21B0','Lsh':'\u21B0','lsim':'\u2272','lsime':'\u2A8D','lsimg':'\u2A8F','lsqb':'[','lsquo':'\u2018','lsquor':'\u201A','lstrok':'\u0142','Lstrok':'\u0141','lt':'<','Lt':'\u226A','LT':'<','ltcc':'\u2AA6','ltcir':'\u2A79','ltdot':'\u22D6','lthree':'\u22CB','ltimes':'\u22C9','ltlarr':'\u2976','ltquest':'\u2A7B','ltri':'\u25C3','ltrie':'\u22B4','ltrif':'\u25C2','ltrPar':'\u2996','lurdshar':'\u294A','luruhar':'\u2966','lvertneqq':'\u2268\uFE00','lvnE':'\u2268\uFE00','macr':'\xAF','male':'\u2642','malt':'\u2720','maltese':'\u2720','map':'\u21A6','Map':'\u2905','mapsto':'\u21A6','mapstodown':'\u21A7','mapstoleft':'\u21A4','mapstoup':'\u21A5','marker':'\u25AE','mcomma':'\u2A29','mcy':'\u043C','Mcy':'\u041C','mdash':'\u2014','mDDot':'\u223A','measuredangle':'\u2221','MediumSpace':'\u205F','Mellintrf':'\u2133','mfr':'\uD835\uDD2A','Mfr':'\uD835\uDD10','mho':'\u2127','micro':'\xB5','mid':'\u2223','midast':'*','midcir':'\u2AF0','middot':'\xB7','minus':'\u2212','minusb':'\u229F','minusd':'\u2238','minusdu':'\u2A2A','MinusPlus':'\u2213','mlcp':'\u2ADB','mldr':'\u2026','mnplus':'\u2213','models':'\u22A7','mopf':'\uD835\uDD5E','Mopf':'\uD835\uDD44','mp':'\u2213','mscr':'\uD835\uDCC2','Mscr':'\u2133','mstpos':'\u223E','mu':'\u03BC','Mu':'\u039C','multimap':'\u22B8','mumap':'\u22B8','nabla':'\u2207','nacute':'\u0144','Nacute':'\u0143','nang':'\u2220\u20D2','nap':'\u2249','napE':'\u2A70\u0338','napid':'\u224B\u0338','napos':'\u0149','napprox':'\u2249','natur':'\u266E','natural':'\u266E','naturals':'\u2115','nbsp':'\xA0','nbump':'\u224E\u0338','nbumpe':'\u224F\u0338','ncap':'\u2A43','ncaron':'\u0148','Ncaron':'\u0147','ncedil':'\u0146','Ncedil':'\u0145','ncong':'\u2247','ncongdot':'\u2A6D\u0338','ncup':'\u2A42','ncy':'\u043D','Ncy':'\u041D','ndash':'\u2013','ne':'\u2260','nearhk':'\u2924','nearr':'\u2197','neArr':'\u21D7','nearrow':'\u2197','nedot':'\u2250\u0338','NegativeMediumSpace':'\u200B','NegativeThickSpace':'\u200B','NegativeThinSpace':'\u200B','NegativeVeryThinSpace':'\u200B','nequiv':'\u2262','nesear':'\u2928','nesim':'\u2242\u0338','NestedGreaterGreater':'\u226B','NestedLessLess':'\u226A','NewLine':'\n','nexist':'\u2204','nexists':'\u2204','nfr':'\uD835\uDD2B','Nfr':'\uD835\uDD11','nge':'\u2271','ngE':'\u2267\u0338','ngeq':'\u2271','ngeqq':'\u2267\u0338','ngeqslant':'\u2A7E\u0338','nges':'\u2A7E\u0338','nGg':'\u22D9\u0338','ngsim':'\u2275','ngt':'\u226F','nGt':'\u226B\u20D2','ngtr':'\u226F','nGtv':'\u226B\u0338','nharr':'\u21AE','nhArr':'\u21CE','nhpar':'\u2AF2','ni':'\u220B','nis':'\u22FC','nisd':'\u22FA','niv':'\u220B','njcy':'\u045A','NJcy':'\u040A','nlarr':'\u219A','nlArr':'\u21CD','nldr':'\u2025','nle':'\u2270','nlE':'\u2266\u0338','nleftarrow':'\u219A','nLeftarrow':'\u21CD','nleftrightarrow':'\u21AE','nLeftrightarrow':'\u21CE','nleq':'\u2270','nleqq':'\u2266\u0338','nleqslant':'\u2A7D\u0338','nles':'\u2A7D\u0338','nless':'\u226E','nLl':'\u22D8\u0338','nlsim':'\u2274','nlt':'\u226E','nLt':'\u226A\u20D2','nltri':'\u22EA','nltrie':'\u22EC','nLtv':'\u226A\u0338','nmid':'\u2224','NoBreak':'\u2060','NonBreakingSpace':'\xA0','nopf':'\uD835\uDD5F','Nopf':'\u2115','not':'\xAC','Not':'\u2AEC','NotCongruent':'\u2262','NotCupCap':'\u226D','NotDoubleVerticalBar':'\u2226','NotElement':'\u2209','NotEqual':'\u2260','NotEqualTilde':'\u2242\u0338','NotExists':'\u2204','NotGreater':'\u226F','NotGreaterEqual':'\u2271','NotGreaterFullEqual':'\u2267\u0338','NotGreaterGreater':'\u226B\u0338','NotGreaterLess':'\u2279','NotGreaterSlantEqual':'\u2A7E\u0338','NotGreaterTilde':'\u2275','NotHumpDownHump':'\u224E\u0338','NotHumpEqual':'\u224F\u0338','notin':'\u2209','notindot':'\u22F5\u0338','notinE':'\u22F9\u0338','notinva':'\u2209','notinvb':'\u22F7','notinvc':'\u22F6','NotLeftTriangle':'\u22EA','NotLeftTriangleBar':'\u29CF\u0338','NotLeftTriangleEqual':'\u22EC','NotLess':'\u226E','NotLessEqual':'\u2270','NotLessGreater':'\u2278','NotLessLess':'\u226A\u0338','NotLessSlantEqual':'\u2A7D\u0338','NotLessTilde':'\u2274','NotNestedGreaterGreater':'\u2AA2\u0338','NotNestedLessLess':'\u2AA1\u0338','notni':'\u220C','notniva':'\u220C','notnivb':'\u22FE','notnivc':'\u22FD','NotPrecedes':'\u2280','NotPrecedesEqual':'\u2AAF\u0338','NotPrecedesSlantEqual':'\u22E0','NotReverseElement':'\u220C','NotRightTriangle':'\u22EB','NotRightTriangleBar':'\u29D0\u0338','NotRightTriangleEqual':'\u22ED','NotSquareSubset':'\u228F\u0338','NotSquareSubsetEqual':'\u22E2','NotSquareSuperset':'\u2290\u0338','NotSquareSupersetEqual':'\u22E3','NotSubset':'\u2282\u20D2','NotSubsetEqual':'\u2288','NotSucceeds':'\u2281','NotSucceedsEqual':'\u2AB0\u0338','NotSucceedsSlantEqual':'\u22E1','NotSucceedsTilde':'\u227F\u0338','NotSuperset':'\u2283\u20D2','NotSupersetEqual':'\u2289','NotTilde':'\u2241','NotTildeEqual':'\u2244','NotTildeFullEqual':'\u2247','NotTildeTilde':'\u2249','NotVerticalBar':'\u2224','npar':'\u2226','nparallel':'\u2226','nparsl':'\u2AFD\u20E5','npart':'\u2202\u0338','npolint':'\u2A14','npr':'\u2280','nprcue':'\u22E0','npre':'\u2AAF\u0338','nprec':'\u2280','npreceq':'\u2AAF\u0338','nrarr':'\u219B','nrArr':'\u21CF','nrarrc':'\u2933\u0338','nrarrw':'\u219D\u0338','nrightarrow':'\u219B','nRightarrow':'\u21CF','nrtri':'\u22EB','nrtrie':'\u22ED','nsc':'\u2281','nsccue':'\u22E1','nsce':'\u2AB0\u0338','nscr':'\uD835\uDCC3','Nscr':'\uD835\uDCA9','nshortmid':'\u2224','nshortparallel':'\u2226','nsim':'\u2241','nsime':'\u2244','nsimeq':'\u2244','nsmid':'\u2224','nspar':'\u2226','nsqsube':'\u22E2','nsqsupe':'\u22E3','nsub':'\u2284','nsube':'\u2288','nsubE':'\u2AC5\u0338','nsubset':'\u2282\u20D2','nsubseteq':'\u2288','nsubseteqq':'\u2AC5\u0338','nsucc':'\u2281','nsucceq':'\u2AB0\u0338','nsup':'\u2285','nsupe':'\u2289','nsupE':'\u2AC6\u0338','nsupset':'\u2283\u20D2','nsupseteq':'\u2289','nsupseteqq':'\u2AC6\u0338','ntgl':'\u2279','ntilde':'\xF1','Ntilde':'\xD1','ntlg':'\u2278','ntriangleleft':'\u22EA','ntrianglelefteq':'\u22EC','ntriangleright':'\u22EB','ntrianglerighteq':'\u22ED','nu':'\u03BD','Nu':'\u039D','num':'#','numero':'\u2116','numsp':'\u2007','nvap':'\u224D\u20D2','nvdash':'\u22AC','nvDash':'\u22AD','nVdash':'\u22AE','nVDash':'\u22AF','nvge':'\u2265\u20D2','nvgt':'>\u20D2','nvHarr':'\u2904','nvinfin':'\u29DE','nvlArr':'\u2902','nvle':'\u2264\u20D2','nvlt':'<\u20D2','nvltrie':'\u22B4\u20D2','nvrArr':'\u2903','nvrtrie':'\u22B5\u20D2','nvsim':'\u223C\u20D2','nwarhk':'\u2923','nwarr':'\u2196','nwArr':'\u21D6','nwarrow':'\u2196','nwnear':'\u2927','oacute':'\xF3','Oacute':'\xD3','oast':'\u229B','ocir':'\u229A','ocirc':'\xF4','Ocirc':'\xD4','ocy':'\u043E','Ocy':'\u041E','odash':'\u229D','odblac':'\u0151','Odblac':'\u0150','odiv':'\u2A38','odot':'\u2299','odsold':'\u29BC','oelig':'\u0153','OElig':'\u0152','ofcir':'\u29BF','ofr':'\uD835\uDD2C','Ofr':'\uD835\uDD12','ogon':'\u02DB','ograve':'\xF2','Ograve':'\xD2','ogt':'\u29C1','ohbar':'\u29B5','ohm':'\u03A9','oint':'\u222E','olarr':'\u21BA','olcir':'\u29BE','olcross':'\u29BB','oline':'\u203E','olt':'\u29C0','omacr':'\u014D','Omacr':'\u014C','omega':'\u03C9','Omega':'\u03A9','omicron':'\u03BF','Omicron':'\u039F','omid':'\u29B6','ominus':'\u2296','oopf':'\uD835\uDD60','Oopf':'\uD835\uDD46','opar':'\u29B7','OpenCurlyDoubleQuote':'\u201C','OpenCurlyQuote':'\u2018','operp':'\u29B9','oplus':'\u2295','or':'\u2228','Or':'\u2A54','orarr':'\u21BB','ord':'\u2A5D','order':'\u2134','orderof':'\u2134','ordf':'\xAA','ordm':'\xBA','origof':'\u22B6','oror':'\u2A56','orslope':'\u2A57','orv':'\u2A5B','oS':'\u24C8','oscr':'\u2134','Oscr':'\uD835\uDCAA','oslash':'\xF8','Oslash':'\xD8','osol':'\u2298','otilde':'\xF5','Otilde':'\xD5','otimes':'\u2297','Otimes':'\u2A37','otimesas':'\u2A36','ouml':'\xF6','Ouml':'\xD6','ovbar':'\u233D','OverBar':'\u203E','OverBrace':'\u23DE','OverBracket':'\u23B4','OverParenthesis':'\u23DC','par':'\u2225','para':'\xB6','parallel':'\u2225','parsim':'\u2AF3','parsl':'\u2AFD','part':'\u2202','PartialD':'\u2202','pcy':'\u043F','Pcy':'\u041F','percnt':'%','period':'.','permil':'\u2030','perp':'\u22A5','pertenk':'\u2031','pfr':'\uD835\uDD2D','Pfr':'\uD835\uDD13','phi':'\u03C6','Phi':'\u03A6','phiv':'\u03D5','phmmat':'\u2133','phone':'\u260E','pi':'\u03C0','Pi':'\u03A0','pitchfork':'\u22D4','piv':'\u03D6','planck':'\u210F','planckh':'\u210E','plankv':'\u210F','plus':'+','plusacir':'\u2A23','plusb':'\u229E','pluscir':'\u2A22','plusdo':'\u2214','plusdu':'\u2A25','pluse':'\u2A72','PlusMinus':'\xB1','plusmn':'\xB1','plussim':'\u2A26','plustwo':'\u2A27','pm':'\xB1','Poincareplane':'\u210C','pointint':'\u2A15','popf':'\uD835\uDD61','Popf':'\u2119','pound':'\xA3','pr':'\u227A','Pr':'\u2ABB','prap':'\u2AB7','prcue':'\u227C','pre':'\u2AAF','prE':'\u2AB3','prec':'\u227A','precapprox':'\u2AB7','preccurlyeq':'\u227C','Precedes':'\u227A','PrecedesEqual':'\u2AAF','PrecedesSlantEqual':'\u227C','PrecedesTilde':'\u227E','preceq':'\u2AAF','precnapprox':'\u2AB9','precneqq':'\u2AB5','precnsim':'\u22E8','precsim':'\u227E','prime':'\u2032','Prime':'\u2033','primes':'\u2119','prnap':'\u2AB9','prnE':'\u2AB5','prnsim':'\u22E8','prod':'\u220F','Product':'\u220F','profalar':'\u232E','profline':'\u2312','profsurf':'\u2313','prop':'\u221D','Proportion':'\u2237','Proportional':'\u221D','propto':'\u221D','prsim':'\u227E','prurel':'\u22B0','pscr':'\uD835\uDCC5','Pscr':'\uD835\uDCAB','psi':'\u03C8','Psi':'\u03A8','puncsp':'\u2008','qfr':'\uD835\uDD2E','Qfr':'\uD835\uDD14','qint':'\u2A0C','qopf':'\uD835\uDD62','Qopf':'\u211A','qprime':'\u2057','qscr':'\uD835\uDCC6','Qscr':'\uD835\uDCAC','quaternions':'\u210D','quatint':'\u2A16','quest':'?','questeq':'\u225F','quot':'"','QUOT':'"','rAarr':'\u21DB','race':'\u223D\u0331','racute':'\u0155','Racute':'\u0154','radic':'\u221A','raemptyv':'\u29B3','rang':'\u27E9','Rang':'\u27EB','rangd':'\u2992','range':'\u29A5','rangle':'\u27E9','raquo':'\xBB','rarr':'\u2192','rArr':'\u21D2','Rarr':'\u21A0','rarrap':'\u2975','rarrb':'\u21E5','rarrbfs':'\u2920','rarrc':'\u2933','rarrfs':'\u291E','rarrhk':'\u21AA','rarrlp':'\u21AC','rarrpl':'\u2945','rarrsim':'\u2974','rarrtl':'\u21A3','Rarrtl':'\u2916','rarrw':'\u219D','ratail':'\u291A','rAtail':'\u291C','ratio':'\u2236','rationals':'\u211A','rbarr':'\u290D','rBarr':'\u290F','RBarr':'\u2910','rbbrk':'\u2773','rbrace':'}','rbrack':']','rbrke':'\u298C','rbrksld':'\u298E','rbrkslu':'\u2990','rcaron':'\u0159','Rcaron':'\u0158','rcedil':'\u0157','Rcedil':'\u0156','rceil':'\u2309','rcub':'}','rcy':'\u0440','Rcy':'\u0420','rdca':'\u2937','rdldhar':'\u2969','rdquo':'\u201D','rdquor':'\u201D','rdsh':'\u21B3','Re':'\u211C','real':'\u211C','realine':'\u211B','realpart':'\u211C','reals':'\u211D','rect':'\u25AD','reg':'\xAE','REG':'\xAE','ReverseElement':'\u220B','ReverseEquilibrium':'\u21CB','ReverseUpEquilibrium':'\u296F','rfisht':'\u297D','rfloor':'\u230B','rfr':'\uD835\uDD2F','Rfr':'\u211C','rHar':'\u2964','rhard':'\u21C1','rharu':'\u21C0','rharul':'\u296C','rho':'\u03C1','Rho':'\u03A1','rhov':'\u03F1','RightAngleBracket':'\u27E9','rightarrow':'\u2192','Rightarrow':'\u21D2','RightArrow':'\u2192','RightArrowBar':'\u21E5','RightArrowLeftArrow':'\u21C4','rightarrowtail':'\u21A3','RightCeiling':'\u2309','RightDoubleBracket':'\u27E7','RightDownTeeVector':'\u295D','RightDownVector':'\u21C2','RightDownVectorBar':'\u2955','RightFloor':'\u230B','rightharpoondown':'\u21C1','rightharpoonup':'\u21C0','rightleftarrows':'\u21C4','rightleftharpoons':'\u21CC','rightrightarrows':'\u21C9','rightsquigarrow':'\u219D','RightTee':'\u22A2','RightTeeArrow':'\u21A6','RightTeeVector':'\u295B','rightthreetimes':'\u22CC','RightTriangle':'\u22B3','RightTriangleBar':'\u29D0','RightTriangleEqual':'\u22B5','RightUpDownVector':'\u294F','RightUpTeeVector':'\u295C','RightUpVector':'\u21BE','RightUpVectorBar':'\u2954','RightVector':'\u21C0','RightVectorBar':'\u2953','ring':'\u02DA','risingdotseq':'\u2253','rlarr':'\u21C4','rlhar':'\u21CC','rlm':'\u200F','rmoust':'\u23B1','rmoustache':'\u23B1','rnmid':'\u2AEE','roang':'\u27ED','roarr':'\u21FE','robrk':'\u27E7','ropar':'\u2986','ropf':'\uD835\uDD63','Ropf':'\u211D','roplus':'\u2A2E','rotimes':'\u2A35','RoundImplies':'\u2970','rpar':')','rpargt':'\u2994','rppolint':'\u2A12','rrarr':'\u21C9','Rrightarrow':'\u21DB','rsaquo':'\u203A','rscr':'\uD835\uDCC7','Rscr':'\u211B','rsh':'\u21B1','Rsh':'\u21B1','rsqb':']','rsquo':'\u2019','rsquor':'\u2019','rthree':'\u22CC','rtimes':'\u22CA','rtri':'\u25B9','rtrie':'\u22B5','rtrif':'\u25B8','rtriltri':'\u29CE','RuleDelayed':'\u29F4','ruluhar':'\u2968','rx':'\u211E','sacute':'\u015B','Sacute':'\u015A','sbquo':'\u201A','sc':'\u227B','Sc':'\u2ABC','scap':'\u2AB8','scaron':'\u0161','Scaron':'\u0160','sccue':'\u227D','sce':'\u2AB0','scE':'\u2AB4','scedil':'\u015F','Scedil':'\u015E','scirc':'\u015D','Scirc':'\u015C','scnap':'\u2ABA','scnE':'\u2AB6','scnsim':'\u22E9','scpolint':'\u2A13','scsim':'\u227F','scy':'\u0441','Scy':'\u0421','sdot':'\u22C5','sdotb':'\u22A1','sdote':'\u2A66','searhk':'\u2925','searr':'\u2198','seArr':'\u21D8','searrow':'\u2198','sect':'\xA7','semi':';','seswar':'\u2929','setminus':'\u2216','setmn':'\u2216','sext':'\u2736','sfr':'\uD835\uDD30','Sfr':'\uD835\uDD16','sfrown':'\u2322','sharp':'\u266F','shchcy':'\u0449','SHCHcy':'\u0429','shcy':'\u0448','SHcy':'\u0428','ShortDownArrow':'\u2193','ShortLeftArrow':'\u2190','shortmid':'\u2223','shortparallel':'\u2225','ShortRightArrow':'\u2192','ShortUpArrow':'\u2191','shy':'\xAD','sigma':'\u03C3','Sigma':'\u03A3','sigmaf':'\u03C2','sigmav':'\u03C2','sim':'\u223C','simdot':'\u2A6A','sime':'\u2243','simeq':'\u2243','simg':'\u2A9E','simgE':'\u2AA0','siml':'\u2A9D','simlE':'\u2A9F','simne':'\u2246','simplus':'\u2A24','simrarr':'\u2972','slarr':'\u2190','SmallCircle':'\u2218','smallsetminus':'\u2216','smashp':'\u2A33','smeparsl':'\u29E4','smid':'\u2223','smile':'\u2323','smt':'\u2AAA','smte':'\u2AAC','smtes':'\u2AAC\uFE00','softcy':'\u044C','SOFTcy':'\u042C','sol':'/','solb':'\u29C4','solbar':'\u233F','sopf':'\uD835\uDD64','Sopf':'\uD835\uDD4A','spades':'\u2660','spadesuit':'\u2660','spar':'\u2225','sqcap':'\u2293','sqcaps':'\u2293\uFE00','sqcup':'\u2294','sqcups':'\u2294\uFE00','Sqrt':'\u221A','sqsub':'\u228F','sqsube':'\u2291','sqsubset':'\u228F','sqsubseteq':'\u2291','sqsup':'\u2290','sqsupe':'\u2292','sqsupset':'\u2290','sqsupseteq':'\u2292','squ':'\u25A1','square':'\u25A1','Square':'\u25A1','SquareIntersection':'\u2293','SquareSubset':'\u228F','SquareSubsetEqual':'\u2291','SquareSuperset':'\u2290','SquareSupersetEqual':'\u2292','SquareUnion':'\u2294','squarf':'\u25AA','squf':'\u25AA','srarr':'\u2192','sscr':'\uD835\uDCC8','Sscr':'\uD835\uDCAE','ssetmn':'\u2216','ssmile':'\u2323','sstarf':'\u22C6','star':'\u2606','Star':'\u22C6','starf':'\u2605','straightepsilon':'\u03F5','straightphi':'\u03D5','strns':'\xAF','sub':'\u2282','Sub':'\u22D0','subdot':'\u2ABD','sube':'\u2286','subE':'\u2AC5','subedot':'\u2AC3','submult':'\u2AC1','subne':'\u228A','subnE':'\u2ACB','subplus':'\u2ABF','subrarr':'\u2979','subset':'\u2282','Subset':'\u22D0','subseteq':'\u2286','subseteqq':'\u2AC5','SubsetEqual':'\u2286','subsetneq':'\u228A','subsetneqq':'\u2ACB','subsim':'\u2AC7','subsub':'\u2AD5','subsup':'\u2AD3','succ':'\u227B','succapprox':'\u2AB8','succcurlyeq':'\u227D','Succeeds':'\u227B','SucceedsEqual':'\u2AB0','SucceedsSlantEqual':'\u227D','SucceedsTilde':'\u227F','succeq':'\u2AB0','succnapprox':'\u2ABA','succneqq':'\u2AB6','succnsim':'\u22E9','succsim':'\u227F','SuchThat':'\u220B','sum':'\u2211','Sum':'\u2211','sung':'\u266A','sup':'\u2283','Sup':'\u22D1','sup1':'\xB9','sup2':'\xB2','sup3':'\xB3','supdot':'\u2ABE','supdsub':'\u2AD8','supe':'\u2287','supE':'\u2AC6','supedot':'\u2AC4','Superset':'\u2283','SupersetEqual':'\u2287','suphsol':'\u27C9','suphsub':'\u2AD7','suplarr':'\u297B','supmult':'\u2AC2','supne':'\u228B','supnE':'\u2ACC','supplus':'\u2AC0','supset':'\u2283','Supset':'\u22D1','supseteq':'\u2287','supseteqq':'\u2AC6','supsetneq':'\u228B','supsetneqq':'\u2ACC','supsim':'\u2AC8','supsub':'\u2AD4','supsup':'\u2AD6','swarhk':'\u2926','swarr':'\u2199','swArr':'\u21D9','swarrow':'\u2199','swnwar':'\u292A','szlig':'\xDF','Tab':'\t','target':'\u2316','tau':'\u03C4','Tau':'\u03A4','tbrk':'\u23B4','tcaron':'\u0165','Tcaron':'\u0164','tcedil':'\u0163','Tcedil':'\u0162','tcy':'\u0442','Tcy':'\u0422','tdot':'\u20DB','telrec':'\u2315','tfr':'\uD835\uDD31','Tfr':'\uD835\uDD17','there4':'\u2234','therefore':'\u2234','Therefore':'\u2234','theta':'\u03B8','Theta':'\u0398','thetasym':'\u03D1','thetav':'\u03D1','thickapprox':'\u2248','thicksim':'\u223C','ThickSpace':'\u205F\u200A','thinsp':'\u2009','ThinSpace':'\u2009','thkap':'\u2248','thksim':'\u223C','thorn':'\xFE','THORN':'\xDE','tilde':'\u02DC','Tilde':'\u223C','TildeEqual':'\u2243','TildeFullEqual':'\u2245','TildeTilde':'\u2248','times':'\xD7','timesb':'\u22A0','timesbar':'\u2A31','timesd':'\u2A30','tint':'\u222D','toea':'\u2928','top':'\u22A4','topbot':'\u2336','topcir':'\u2AF1','topf':'\uD835\uDD65','Topf':'\uD835\uDD4B','topfork':'\u2ADA','tosa':'\u2929','tprime':'\u2034','trade':'\u2122','TRADE':'\u2122','triangle':'\u25B5','triangledown':'\u25BF','triangleleft':'\u25C3','trianglelefteq':'\u22B4','triangleq':'\u225C','triangleright':'\u25B9','trianglerighteq':'\u22B5','tridot':'\u25EC','trie':'\u225C','triminus':'\u2A3A','TripleDot':'\u20DB','triplus':'\u2A39','trisb':'\u29CD','tritime':'\u2A3B','trpezium':'\u23E2','tscr':'\uD835\uDCC9','Tscr':'\uD835\uDCAF','tscy':'\u0446','TScy':'\u0426','tshcy':'\u045B','TSHcy':'\u040B','tstrok':'\u0167','Tstrok':'\u0166','twixt':'\u226C','twoheadleftarrow':'\u219E','twoheadrightarrow':'\u21A0','uacute':'\xFA','Uacute':'\xDA','uarr':'\u2191','uArr':'\u21D1','Uarr':'\u219F','Uarrocir':'\u2949','ubrcy':'\u045E','Ubrcy':'\u040E','ubreve':'\u016D','Ubreve':'\u016C','ucirc':'\xFB','Ucirc':'\xDB','ucy':'\u0443','Ucy':'\u0423','udarr':'\u21C5','udblac':'\u0171','Udblac':'\u0170','udhar':'\u296E','ufisht':'\u297E','ufr':'\uD835\uDD32','Ufr':'\uD835\uDD18','ugrave':'\xF9','Ugrave':'\xD9','uHar':'\u2963','uharl':'\u21BF','uharr':'\u21BE','uhblk':'\u2580','ulcorn':'\u231C','ulcorner':'\u231C','ulcrop':'\u230F','ultri':'\u25F8','umacr':'\u016B','Umacr':'\u016A','uml':'\xA8','UnderBar':'_','UnderBrace':'\u23DF','UnderBracket':'\u23B5','UnderParenthesis':'\u23DD','Union':'\u22C3','UnionPlus':'\u228E','uogon':'\u0173','Uogon':'\u0172','uopf':'\uD835\uDD66','Uopf':'\uD835\uDD4C','uparrow':'\u2191','Uparrow':'\u21D1','UpArrow':'\u2191','UpArrowBar':'\u2912','UpArrowDownArrow':'\u21C5','updownarrow':'\u2195','Updownarrow':'\u21D5','UpDownArrow':'\u2195','UpEquilibrium':'\u296E','upharpoonleft':'\u21BF','upharpoonright':'\u21BE','uplus':'\u228E','UpperLeftArrow':'\u2196','UpperRightArrow':'\u2197','upsi':'\u03C5','Upsi':'\u03D2','upsih':'\u03D2','upsilon':'\u03C5','Upsilon':'\u03A5','UpTee':'\u22A5','UpTeeArrow':'\u21A5','upuparrows':'\u21C8','urcorn':'\u231D','urcorner':'\u231D','urcrop':'\u230E','uring':'\u016F','Uring':'\u016E','urtri':'\u25F9','uscr':'\uD835\uDCCA','Uscr':'\uD835\uDCB0','utdot':'\u22F0','utilde':'\u0169','Utilde':'\u0168','utri':'\u25B5','utrif':'\u25B4','uuarr':'\u21C8','uuml':'\xFC','Uuml':'\xDC','uwangle':'\u29A7','vangrt':'\u299C','varepsilon':'\u03F5','varkappa':'\u03F0','varnothing':'\u2205','varphi':'\u03D5','varpi':'\u03D6','varpropto':'\u221D','varr':'\u2195','vArr':'\u21D5','varrho':'\u03F1','varsigma':'\u03C2','varsubsetneq':'\u228A\uFE00','varsubsetneqq':'\u2ACB\uFE00','varsupsetneq':'\u228B\uFE00','varsupsetneqq':'\u2ACC\uFE00','vartheta':'\u03D1','vartriangleleft':'\u22B2','vartriangleright':'\u22B3','vBar':'\u2AE8','Vbar':'\u2AEB','vBarv':'\u2AE9','vcy':'\u0432','Vcy':'\u0412','vdash':'\u22A2','vDash':'\u22A8','Vdash':'\u22A9','VDash':'\u22AB','Vdashl':'\u2AE6','vee':'\u2228','Vee':'\u22C1','veebar':'\u22BB','veeeq':'\u225A','vellip':'\u22EE','verbar':'|','Verbar':'\u2016','vert':'|','Vert':'\u2016','VerticalBar':'\u2223','VerticalLine':'|','VerticalSeparator':'\u2758','VerticalTilde':'\u2240','VeryThinSpace':'\u200A','vfr':'\uD835\uDD33','Vfr':'\uD835\uDD19','vltri':'\u22B2','vnsub':'\u2282\u20D2','vnsup':'\u2283\u20D2','vopf':'\uD835\uDD67','Vopf':'\uD835\uDD4D','vprop':'\u221D','vrtri':'\u22B3','vscr':'\uD835\uDCCB','Vscr':'\uD835\uDCB1','vsubne':'\u228A\uFE00','vsubnE':'\u2ACB\uFE00','vsupne':'\u228B\uFE00','vsupnE':'\u2ACC\uFE00','Vvdash':'\u22AA','vzigzag':'\u299A','wcirc':'\u0175','Wcirc':'\u0174','wedbar':'\u2A5F','wedge':'\u2227','Wedge':'\u22C0','wedgeq':'\u2259','weierp':'\u2118','wfr':'\uD835\uDD34','Wfr':'\uD835\uDD1A','wopf':'\uD835\uDD68','Wopf':'\uD835\uDD4E','wp':'\u2118','wr':'\u2240','wreath':'\u2240','wscr':'\uD835\uDCCC','Wscr':'\uD835\uDCB2','xcap':'\u22C2','xcirc':'\u25EF','xcup':'\u22C3','xdtri':'\u25BD','xfr':'\uD835\uDD35','Xfr':'\uD835\uDD1B','xharr':'\u27F7','xhArr':'\u27FA','xi':'\u03BE','Xi':'\u039E','xlarr':'\u27F5','xlArr':'\u27F8','xmap':'\u27FC','xnis':'\u22FB','xodot':'\u2A00','xopf':'\uD835\uDD69','Xopf':'\uD835\uDD4F','xoplus':'\u2A01','xotime':'\u2A02','xrarr':'\u27F6','xrArr':'\u27F9','xscr':'\uD835\uDCCD','Xscr':'\uD835\uDCB3','xsqcup':'\u2A06','xuplus':'\u2A04','xutri':'\u25B3','xvee':'\u22C1','xwedge':'\u22C0','yacute':'\xFD','Yacute':'\xDD','yacy':'\u044F','YAcy':'\u042F','ycirc':'\u0177','Ycirc':'\u0176','ycy':'\u044B','Ycy':'\u042B','yen':'\xA5','yfr':'\uD835\uDD36','Yfr':'\uD835\uDD1C','yicy':'\u0457','YIcy':'\u0407','yopf':'\uD835\uDD6A','Yopf':'\uD835\uDD50','yscr':'\uD835\uDCCE','Yscr':'\uD835\uDCB4','yucy':'\u044E','YUcy':'\u042E','yuml':'\xFF','Yuml':'\u0178','zacute':'\u017A','Zacute':'\u0179','zcaron':'\u017E','Zcaron':'\u017D','zcy':'\u0437','Zcy':'\u0417','zdot':'\u017C','Zdot':'\u017B','zeetrf':'\u2128','ZeroWidthSpace':'\u200B','zeta':'\u03B6','Zeta':'\u0396','zfr':'\uD835\uDD37','Zfr':'\u2128','zhcy':'\u0436','ZHcy':'\u0416','zigrarr':'\u21DD','zopf':'\uD835\uDD6B','Zopf':'\u2124','zscr':'\uD835\uDCCF','Zscr':'\uD835\uDCB5','zwj':'\u200D','zwnj':'\u200C'};
|
2297 | var decodeMapLegacy = {'aacute':'\xE1','Aacute':'\xC1','acirc':'\xE2','Acirc':'\xC2','acute':'\xB4','aelig':'\xE6','AElig':'\xC6','agrave':'\xE0','Agrave':'\xC0','amp':'&','AMP':'&','aring':'\xE5','Aring':'\xC5','atilde':'\xE3','Atilde':'\xC3','auml':'\xE4','Auml':'\xC4','brvbar':'\xA6','ccedil':'\xE7','Ccedil':'\xC7','cedil':'\xB8','cent':'\xA2','copy':'\xA9','COPY':'\xA9','curren':'\xA4','deg':'\xB0','divide':'\xF7','eacute':'\xE9','Eacute':'\xC9','ecirc':'\xEA','Ecirc':'\xCA','egrave':'\xE8','Egrave':'\xC8','eth':'\xF0','ETH':'\xD0','euml':'\xEB','Euml':'\xCB','frac12':'\xBD','frac14':'\xBC','frac34':'\xBE','gt':'>','GT':'>','iacute':'\xED','Iacute':'\xCD','icirc':'\xEE','Icirc':'\xCE','iexcl':'\xA1','igrave':'\xEC','Igrave':'\xCC','iquest':'\xBF','iuml':'\xEF','Iuml':'\xCF','laquo':'\xAB','lt':'<','LT':'<','macr':'\xAF','micro':'\xB5','middot':'\xB7','nbsp':'\xA0','not':'\xAC','ntilde':'\xF1','Ntilde':'\xD1','oacute':'\xF3','Oacute':'\xD3','ocirc':'\xF4','Ocirc':'\xD4','ograve':'\xF2','Ograve':'\xD2','ordf':'\xAA','ordm':'\xBA','oslash':'\xF8','Oslash':'\xD8','otilde':'\xF5','Otilde':'\xD5','ouml':'\xF6','Ouml':'\xD6','para':'\xB6','plusmn':'\xB1','pound':'\xA3','quot':'"','QUOT':'"','raquo':'\xBB','reg':'\xAE','REG':'\xAE','sect':'\xA7','shy':'\xAD','sup1':'\xB9','sup2':'\xB2','sup3':'\xB3','szlig':'\xDF','thorn':'\xFE','THORN':'\xDE','times':'\xD7','uacute':'\xFA','Uacute':'\xDA','ucirc':'\xFB','Ucirc':'\xDB','ugrave':'\xF9','Ugrave':'\xD9','uml':'\xA8','uuml':'\xFC','Uuml':'\xDC','yacute':'\xFD','Yacute':'\xDD','yen':'\xA5','yuml':'\xFF'};
|
2298 | var decodeMapNumeric = {'0':'\uFFFD','128':'\u20AC','130':'\u201A','131':'\u0192','132':'\u201E','133':'\u2026','134':'\u2020','135':'\u2021','136':'\u02C6','137':'\u2030','138':'\u0160','139':'\u2039','140':'\u0152','142':'\u017D','145':'\u2018','146':'\u2019','147':'\u201C','148':'\u201D','149':'\u2022','150':'\u2013','151':'\u2014','152':'\u02DC','153':'\u2122','154':'\u0161','155':'\u203A','156':'\u0153','158':'\u017E','159':'\u0178'};
|
2299 | var invalidReferenceCodePoints = [1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65000,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111];
|
2300 |
|
2301 |
|
2302 |
|
2303 | var stringFromCharCode = String.fromCharCode;
|
2304 |
|
2305 | var object = {};
|
2306 | var hasOwnProperty = object.hasOwnProperty;
|
2307 | var has = function(object, propertyName) {
|
2308 | return hasOwnProperty.call(object, propertyName);
|
2309 | };
|
2310 |
|
2311 | var contains = function(array, value) {
|
2312 | var index = -1;
|
2313 | var length = array.length;
|
2314 | while (++index < length) {
|
2315 | if (array[index] == value) {
|
2316 | return true;
|
2317 | }
|
2318 | }
|
2319 | return false;
|
2320 | };
|
2321 |
|
2322 | var merge = function(options, defaults) {
|
2323 | if (!options) {
|
2324 | return defaults;
|
2325 | }
|
2326 | var result = {};
|
2327 | var key;
|
2328 | for (key in defaults) {
|
2329 |
|
2330 |
|
2331 | result[key] = has(options, key) ? options[key] : defaults[key];
|
2332 | }
|
2333 | return result;
|
2334 | };
|
2335 |
|
2336 |
|
2337 | var codePointToSymbol = function(codePoint, strict) {
|
2338 | var output = '';
|
2339 | if ((codePoint >= 0xD800 && codePoint <= 0xDFFF) || codePoint > 0x10FFFF) {
|
2340 |
|
2341 |
|
2342 |
|
2343 |
|
2344 | if (strict) {
|
2345 | parseError('character reference outside the permissible Unicode range');
|
2346 | }
|
2347 | return '\uFFFD';
|
2348 | }
|
2349 | if (has(decodeMapNumeric, codePoint)) {
|
2350 | if (strict) {
|
2351 | parseError('disallowed character reference');
|
2352 | }
|
2353 | return decodeMapNumeric[codePoint];
|
2354 | }
|
2355 | if (strict && contains(invalidReferenceCodePoints, codePoint)) {
|
2356 | parseError('disallowed character reference');
|
2357 | }
|
2358 | if (codePoint > 0xFFFF) {
|
2359 | codePoint -= 0x10000;
|
2360 | output += stringFromCharCode(codePoint >>> 10 & 0x3FF | 0xD800);
|
2361 | codePoint = 0xDC00 | codePoint & 0x3FF;
|
2362 | }
|
2363 | output += stringFromCharCode(codePoint);
|
2364 | return output;
|
2365 | };
|
2366 |
|
2367 | var hexEscape = function(codePoint) {
|
2368 | return '&#x' + codePoint.toString(16).toUpperCase() + ';';
|
2369 | };
|
2370 |
|
2371 | var decEscape = function(codePoint) {
|
2372 | return '&#' + codePoint + ';';
|
2373 | };
|
2374 |
|
2375 | var parseError = function(message) {
|
2376 | throw Error('Parse error: ' + message);
|
2377 | };
|
2378 |
|
2379 |
|
2380 |
|
2381 | var encode = function(string, options) {
|
2382 | options = merge(options, encode.options);
|
2383 | var strict = options.strict;
|
2384 | if (strict && regexInvalidRawCodePoint.test(string)) {
|
2385 | parseError('forbidden code point');
|
2386 | }
|
2387 | var encodeEverything = options.encodeEverything;
|
2388 | var useNamedReferences = options.useNamedReferences;
|
2389 | var allowUnsafeSymbols = options.allowUnsafeSymbols;
|
2390 | var escapeCodePoint = options.decimal ? decEscape : hexEscape;
|
2391 |
|
2392 | var escapeBmpSymbol = function(symbol) {
|
2393 | return escapeCodePoint(symbol.charCodeAt(0));
|
2394 | };
|
2395 |
|
2396 | if (encodeEverything) {
|
2397 |
|
2398 | string = string.replace(regexAsciiWhitelist, function(symbol) {
|
2399 |
|
2400 | if (useNamedReferences && has(encodeMap, symbol)) {
|
2401 | return '&' + encodeMap[symbol] + ';';
|
2402 | }
|
2403 | return escapeBmpSymbol(symbol);
|
2404 | });
|
2405 |
|
2406 |
|
2407 | if (useNamedReferences) {
|
2408 | string = string
|
2409 | .replace(/>\u20D2/g, '>⃒')
|
2410 | .replace(/<\u20D2/g, '<⃒')
|
2411 | .replace(/fj/g, 'fj');
|
2412 | }
|
2413 |
|
2414 | if (useNamedReferences) {
|
2415 |
|
2416 | string = string.replace(regexEncodeNonAscii, function(string) {
|
2417 |
|
2418 | return '&' + encodeMap[string] + ';';
|
2419 | });
|
2420 | }
|
2421 |
|
2422 | } else if (useNamedReferences) {
|
2423 |
|
2424 |
|
2425 | if (!allowUnsafeSymbols) {
|
2426 | string = string.replace(regexEscape, function(string) {
|
2427 | return '&' + encodeMap[string] + ';';
|
2428 | });
|
2429 | }
|
2430 |
|
2431 |
|
2432 | string = string
|
2433 | .replace(/>\u20D2/g, '>⃒')
|
2434 | .replace(/<\u20D2/g, '<⃒');
|
2435 |
|
2436 | string = string.replace(regexEncodeNonAscii, function(string) {
|
2437 |
|
2438 | return '&' + encodeMap[string] + ';';
|
2439 | });
|
2440 | } else if (!allowUnsafeSymbols) {
|
2441 |
|
2442 |
|
2443 | string = string.replace(regexEscape, escapeBmpSymbol);
|
2444 | }
|
2445 | return string
|
2446 |
|
2447 | .replace(regexAstralSymbols, function($0) {
|
2448 |
|
2449 | var high = $0.charCodeAt(0);
|
2450 | var low = $0.charCodeAt(1);
|
2451 | var codePoint = (high - 0xD800) * 0x400 + low - 0xDC00 + 0x10000;
|
2452 | return escapeCodePoint(codePoint);
|
2453 | })
|
2454 |
|
2455 |
|
2456 | .replace(regexBmpWhitelist, escapeBmpSymbol);
|
2457 | };
|
2458 |
|
2459 | encode.options = {
|
2460 | 'allowUnsafeSymbols': false,
|
2461 | 'encodeEverything': false,
|
2462 | 'strict': false,
|
2463 | 'useNamedReferences': false,
|
2464 | 'decimal' : false
|
2465 | };
|
2466 |
|
2467 | var decode = function(html, options) {
|
2468 | options = merge(options, decode.options);
|
2469 | var strict = options.strict;
|
2470 | if (strict && regexInvalidEntity.test(html)) {
|
2471 | parseError('malformed character reference');
|
2472 | }
|
2473 | return html.replace(regexDecode, function($0, $1, $2, $3, $4, $5, $6, $7, $8) {
|
2474 | var codePoint;
|
2475 | var semicolon;
|
2476 | var decDigits;
|
2477 | var hexDigits;
|
2478 | var reference;
|
2479 | var next;
|
2480 |
|
2481 | if ($1) {
|
2482 | reference = $1;
|
2483 |
|
2484 | return decodeMap[reference];
|
2485 | }
|
2486 |
|
2487 | if ($2) {
|
2488 |
|
2489 |
|
2490 |
|
2491 | reference = $2;
|
2492 | next = $3;
|
2493 | if (next && options.isAttributeValue) {
|
2494 | if (strict && next == '=') {
|
2495 | parseError('`&` did not start a character reference');
|
2496 | }
|
2497 | return $0;
|
2498 | } else {
|
2499 | if (strict) {
|
2500 | parseError(
|
2501 | 'named character reference was not terminated by a semicolon'
|
2502 | );
|
2503 | }
|
2504 |
|
2505 | return decodeMapLegacy[reference] + (next || '');
|
2506 | }
|
2507 | }
|
2508 |
|
2509 | if ($4) {
|
2510 |
|
2511 | decDigits = $4;
|
2512 | semicolon = $5;
|
2513 | if (strict && !semicolon) {
|
2514 | parseError('character reference was not terminated by a semicolon');
|
2515 | }
|
2516 | codePoint = parseInt(decDigits, 10);
|
2517 | return codePointToSymbol(codePoint, strict);
|
2518 | }
|
2519 |
|
2520 | if ($6) {
|
2521 |
|
2522 | hexDigits = $6;
|
2523 | semicolon = $7;
|
2524 | if (strict && !semicolon) {
|
2525 | parseError('character reference was not terminated by a semicolon');
|
2526 | }
|
2527 | codePoint = parseInt(hexDigits, 16);
|
2528 | return codePointToSymbol(codePoint, strict);
|
2529 | }
|
2530 |
|
2531 |
|
2532 |
|
2533 | if (strict) {
|
2534 | parseError(
|
2535 | 'named character reference was not terminated by a semicolon'
|
2536 | );
|
2537 | }
|
2538 | return $0;
|
2539 | });
|
2540 | };
|
2541 |
|
2542 | decode.options = {
|
2543 | 'isAttributeValue': false,
|
2544 | 'strict': false
|
2545 | };
|
2546 |
|
2547 | var escape = function(string) {
|
2548 | return string.replace(regexEscape, function($0) {
|
2549 |
|
2550 | return escapeMap[$0];
|
2551 | });
|
2552 | };
|
2553 |
|
2554 |
|
2555 |
|
2556 | var he = {
|
2557 | 'version': '1.2.0',
|
2558 | 'encode': encode,
|
2559 | 'decode': decode,
|
2560 | 'escape': escape,
|
2561 | 'unescape': decode
|
2562 | };
|
2563 |
|
2564 |
|
2565 |
|
2566 | if (freeExports && !freeExports.nodeType) {
|
2567 | if (freeModule) {
|
2568 | freeModule.exports = he;
|
2569 | } else {
|
2570 | for (var key in he) {
|
2571 | has(he, key) && (freeExports[key] = he[key]);
|
2572 | }
|
2573 | }
|
2574 | } else {
|
2575 | root.he = he;
|
2576 | }
|
2577 |
|
2578 | }(commonjsGlobal));
|
2579 | });
|
2580 |
|
2581 |
|
2582 |
|
2583 | |
2584 |
|
2585 |
|
2586 | function genComponentModel (
|
2587 | el,
|
2588 | value,
|
2589 | modifiers
|
2590 | ) {
|
2591 | var ref = modifiers || {};
|
2592 | var number = ref.number;
|
2593 | var trim = ref.trim;
|
2594 |
|
2595 | var baseValueExpression = '$$v';
|
2596 | var valueExpression = baseValueExpression;
|
2597 | if (trim) {
|
2598 | valueExpression =
|
2599 | "(typeof " + baseValueExpression + " === 'string'" +
|
2600 | "? " + baseValueExpression + ".trim()" +
|
2601 | ": " + baseValueExpression + ")";
|
2602 | }
|
2603 | if (number) {
|
2604 | valueExpression = "_n(" + valueExpression + ")";
|
2605 | }
|
2606 | var assignment = genAssignmentCode(value, valueExpression);
|
2607 |
|
2608 | el.model = {
|
2609 | value: ("(" + value + ")"),
|
2610 | expression: JSON.stringify(value),
|
2611 | callback: ("function (" + baseValueExpression + ") {" + assignment + "}")
|
2612 | };
|
2613 | }
|
2614 |
|
2615 | |
2616 |
|
2617 |
|
2618 | function genAssignmentCode (
|
2619 | value,
|
2620 | assignment
|
2621 | ) {
|
2622 | var res = parseModel(value);
|
2623 | if (res.key === null) {
|
2624 | return (value + "=" + assignment)
|
2625 | } else {
|
2626 | return ("$set(" + (res.exp) + ", " + (res.key) + ", " + assignment + ")")
|
2627 | }
|
2628 | }
|
2629 |
|
2630 | |
2631 |
|
2632 |
|
2633 |
|
2634 |
|
2635 |
|
2636 |
|
2637 |
|
2638 |
|
2639 |
|
2640 |
|
2641 |
|
2642 |
|
2643 |
|
2644 |
|
2645 | var len, str, chr, index, expressionPos, expressionEndPos;
|
2646 |
|
2647 |
|
2648 |
|
2649 | function parseModel (val) {
|
2650 |
|
2651 |
|
2652 | val = val.trim();
|
2653 | len = val.length;
|
2654 |
|
2655 | if (val.indexOf('[') < 0 || val.lastIndexOf(']') < len - 1) {
|
2656 | index = val.lastIndexOf('.');
|
2657 | if (index > -1) {
|
2658 | return {
|
2659 | exp: val.slice(0, index),
|
2660 | key: '"' + val.slice(index + 1) + '"'
|
2661 | }
|
2662 | } else {
|
2663 | return {
|
2664 | exp: val,
|
2665 | key: null
|
2666 | }
|
2667 | }
|
2668 | }
|
2669 |
|
2670 | str = val;
|
2671 | index = expressionPos = expressionEndPos = 0;
|
2672 |
|
2673 | while (!eof()) {
|
2674 | chr = next();
|
2675 |
|
2676 | if (isStringStart(chr)) {
|
2677 | parseString(chr);
|
2678 | } else if (chr === 0x5B) {
|
2679 | parseBracket(chr);
|
2680 | }
|
2681 | }
|
2682 |
|
2683 | return {
|
2684 | exp: val.slice(0, expressionPos),
|
2685 | key: val.slice(expressionPos + 1, expressionEndPos)
|
2686 | }
|
2687 | }
|
2688 |
|
2689 | function next () {
|
2690 | return str.charCodeAt(++index)
|
2691 | }
|
2692 |
|
2693 | function eof () {
|
2694 | return index >= len
|
2695 | }
|
2696 |
|
2697 | function isStringStart (chr) {
|
2698 | return chr === 0x22 || chr === 0x27
|
2699 | }
|
2700 |
|
2701 | function parseBracket (chr) {
|
2702 | var inBracket = 1;
|
2703 | expressionPos = index;
|
2704 | while (!eof()) {
|
2705 | chr = next();
|
2706 | if (isStringStart(chr)) {
|
2707 | parseString(chr);
|
2708 | continue
|
2709 | }
|
2710 | if (chr === 0x5B) { inBracket++; }
|
2711 | if (chr === 0x5D) { inBracket--; }
|
2712 | if (inBracket === 0) {
|
2713 | expressionEndPos = index;
|
2714 | break
|
2715 | }
|
2716 | }
|
2717 | }
|
2718 |
|
2719 | function parseString (chr) {
|
2720 | var stringQuote = chr;
|
2721 | while (!eof()) {
|
2722 | chr = next();
|
2723 | if (chr === stringQuote) {
|
2724 | break
|
2725 | }
|
2726 | }
|
2727 | }
|
2728 |
|
2729 |
|
2730 |
|
2731 | var onRE = /^@|^v-on:/;
|
2732 | var dirRE = /^v-|^@|^:|^#/;
|
2733 | var forAliasRE = /([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/;
|
2734 | var forIteratorRE = /,([^,\}\]]*)(?:,([^,\}\]]*))?$/;
|
2735 | var stripParensRE = /^\(|\)$/g;
|
2736 | var dynamicArgRE = /^\[.*\]$/;
|
2737 |
|
2738 | var argRE = /:(.*)$/;
|
2739 | var bindRE = /^:|^\.|^v-bind:/;
|
2740 | var modifierRE = /\.[^.\]]+(?=[^\]]*$)/g;
|
2741 |
|
2742 | var slotRE = /^v-slot(:|$)|^#/;
|
2743 |
|
2744 | var lineBreakRE = /[\r\n]/;
|
2745 | var whitespaceRE = /\s+/g;
|
2746 |
|
2747 | var invalidAttributeRE = /[\s"'<>\/=]/;
|
2748 |
|
2749 | var decodeHTMLCached = cached(he.decode);
|
2750 |
|
2751 | var emptySlotScopeToken = "_empty_";
|
2752 |
|
2753 |
|
2754 | var warn$1;
|
2755 | var delimiters;
|
2756 | var transforms;
|
2757 | var preTransforms;
|
2758 | var postTransforms;
|
2759 | var platformIsPreTag;
|
2760 | var platformMustUseProp;
|
2761 | var platformGetTagNamespace;
|
2762 | var maybeComponent;
|
2763 |
|
2764 | function createASTElement (
|
2765 | tag,
|
2766 | attrs,
|
2767 | parent
|
2768 | ) {
|
2769 | return {
|
2770 | type: 1,
|
2771 | tag: tag,
|
2772 | attrsList: attrs,
|
2773 | attrsMap: makeAttrsMap(attrs),
|
2774 | rawAttrsMap: {},
|
2775 | parent: parent,
|
2776 | children: []
|
2777 | }
|
2778 | }
|
2779 |
|
2780 | |
2781 |
|
2782 |
|
2783 | function parse (
|
2784 | template,
|
2785 | options
|
2786 | ) {
|
2787 | warn$1 = options.warn || baseWarn;
|
2788 |
|
2789 | platformIsPreTag = options.isPreTag || no;
|
2790 | platformMustUseProp = options.mustUseProp || no;
|
2791 | platformGetTagNamespace = options.getTagNamespace || no;
|
2792 | var isReservedTag = options.isReservedTag || no;
|
2793 | maybeComponent = function (el) { return !!el.component || !isReservedTag(el.tag); };
|
2794 |
|
2795 | transforms = pluckModuleFunction(options.modules, 'transformNode');
|
2796 | preTransforms = pluckModuleFunction(options.modules, 'preTransformNode');
|
2797 | postTransforms = pluckModuleFunction(options.modules, 'postTransformNode');
|
2798 |
|
2799 | delimiters = options.delimiters;
|
2800 |
|
2801 | var stack = [];
|
2802 | var preserveWhitespace = options.preserveWhitespace !== false;
|
2803 | var whitespaceOption = options.whitespace;
|
2804 | var root;
|
2805 | var currentParent;
|
2806 | var inVPre = false;
|
2807 | var inPre = false;
|
2808 | var warned = false;
|
2809 |
|
2810 | function warnOnce (msg, range) {
|
2811 | if (!warned) {
|
2812 | warned = true;
|
2813 | warn$1(msg, range);
|
2814 | }
|
2815 | }
|
2816 |
|
2817 | function closeElement (element) {
|
2818 | trimEndingWhitespace(element);
|
2819 | if (!inVPre && !element.processed) {
|
2820 | element = processElement(element, options);
|
2821 | }
|
2822 |
|
2823 | if (!stack.length && element !== root) {
|
2824 |
|
2825 | if (root.if && (element.elseif || element.else)) {
|
2826 | {
|
2827 | checkRootConstraints(element);
|
2828 | }
|
2829 | addIfCondition(root, {
|
2830 | exp: element.elseif,
|
2831 | block: element
|
2832 | });
|
2833 | } else {
|
2834 | warnOnce(
|
2835 | "Component template should contain exactly one root element. " +
|
2836 | "If you are using v-if on multiple elements, " +
|
2837 | "use v-else-if to chain them instead.",
|
2838 | { start: element.start }
|
2839 | );
|
2840 | }
|
2841 | }
|
2842 | if (currentParent && !element.forbidden) {
|
2843 | if (element.elseif || element.else) {
|
2844 | processIfConditions(element, currentParent);
|
2845 | } else {
|
2846 | if (element.slotScope) {
|
2847 |
|
2848 |
|
2849 |
|
2850 | var name = element.slotTarget || '"default"'
|
2851 | ;(currentParent.scopedSlots || (currentParent.scopedSlots = {}))[name] = element;
|
2852 | }
|
2853 | currentParent.children.push(element);
|
2854 | element.parent = currentParent;
|
2855 | }
|
2856 | }
|
2857 |
|
2858 |
|
2859 |
|
2860 | element.children = element.children.filter(function (c) { return !(c).slotScope; });
|
2861 |
|
2862 | trimEndingWhitespace(element);
|
2863 |
|
2864 |
|
2865 | if (element.pre) {
|
2866 | inVPre = false;
|
2867 | }
|
2868 | if (platformIsPreTag(element.tag)) {
|
2869 | inPre = false;
|
2870 | }
|
2871 |
|
2872 | for (var i = 0; i < postTransforms.length; i++) {
|
2873 | postTransforms[i](element, options);
|
2874 | }
|
2875 | }
|
2876 |
|
2877 | function trimEndingWhitespace (el) {
|
2878 |
|
2879 | if (!inPre) {
|
2880 | var lastNode;
|
2881 | while (
|
2882 | (lastNode = el.children[el.children.length - 1]) &&
|
2883 | lastNode.type === 3 &&
|
2884 | lastNode.text === ' '
|
2885 | ) {
|
2886 | el.children.pop();
|
2887 | }
|
2888 | }
|
2889 | }
|
2890 |
|
2891 | function checkRootConstraints (el) {
|
2892 | if (el.tag === 'slot' || el.tag === 'template') {
|
2893 | warnOnce(
|
2894 | "Cannot use <" + (el.tag) + "> as component root element because it may " +
|
2895 | 'contain multiple nodes.',
|
2896 | { start: el.start }
|
2897 | );
|
2898 | }
|
2899 | if (el.attrsMap.hasOwnProperty('v-for')) {
|
2900 | warnOnce(
|
2901 | 'Cannot use v-for on stateful component root element because ' +
|
2902 | 'it renders multiple elements.',
|
2903 | el.rawAttrsMap['v-for']
|
2904 | );
|
2905 | }
|
2906 | }
|
2907 |
|
2908 | parseHTML(template, {
|
2909 | warn: warn$1,
|
2910 | expectHTML: options.expectHTML,
|
2911 | isUnaryTag: options.isUnaryTag,
|
2912 | canBeLeftOpenTag: options.canBeLeftOpenTag,
|
2913 | shouldDecodeNewlines: options.shouldDecodeNewlines,
|
2914 | shouldDecodeNewlinesForHref: options.shouldDecodeNewlinesForHref,
|
2915 | shouldKeepComment: options.comments,
|
2916 | outputSourceRange: options.outputSourceRange,
|
2917 | start: function start (tag, attrs, unary, start$1, end) {
|
2918 |
|
2919 |
|
2920 | var ns = (currentParent && currentParent.ns) || platformGetTagNamespace(tag);
|
2921 |
|
2922 |
|
2923 |
|
2924 | if (isIE && ns === 'svg') {
|
2925 | attrs = guardIESVGBug(attrs);
|
2926 | }
|
2927 |
|
2928 | var element = createASTElement(tag, attrs, currentParent);
|
2929 | if (ns) {
|
2930 | element.ns = ns;
|
2931 | }
|
2932 |
|
2933 | {
|
2934 | if (options.outputSourceRange) {
|
2935 | element.start = start$1;
|
2936 | element.end = end;
|
2937 | element.rawAttrsMap = element.attrsList.reduce(function (cumulated, attr) {
|
2938 | cumulated[attr.name] = attr;
|
2939 | return cumulated
|
2940 | }, {});
|
2941 | }
|
2942 | attrs.forEach(function (attr) {
|
2943 | if (invalidAttributeRE.test(attr.name)) {
|
2944 | warn$1(
|
2945 | "Invalid dynamic argument expression: attribute names cannot contain " +
|
2946 | "spaces, quotes, <, >, / or =.",
|
2947 | {
|
2948 | start: attr.start + attr.name.indexOf("["),
|
2949 | end: attr.start + attr.name.length
|
2950 | }
|
2951 | );
|
2952 | }
|
2953 | });
|
2954 | }
|
2955 |
|
2956 | if (isForbiddenTag(element) && !isServerRendering()) {
|
2957 | element.forbidden = true;
|
2958 | warn$1(
|
2959 | 'Templates should only be responsible for mapping the state to the ' +
|
2960 | 'UI. Avoid placing tags with side-effects in your templates, such as ' +
|
2961 | "<" + tag + ">" + ', as they will not be parsed.',
|
2962 | { start: element.start }
|
2963 | );
|
2964 | }
|
2965 |
|
2966 |
|
2967 | for (var i = 0; i < preTransforms.length; i++) {
|
2968 | element = preTransforms[i](element, options) || element;
|
2969 | }
|
2970 |
|
2971 | if (!inVPre) {
|
2972 | processPre(element);
|
2973 | if (element.pre) {
|
2974 | inVPre = true;
|
2975 | }
|
2976 | }
|
2977 | if (platformIsPreTag(element.tag)) {
|
2978 | inPre = true;
|
2979 | }
|
2980 | if (inVPre) {
|
2981 | processRawAttrs(element);
|
2982 | } else if (!element.processed) {
|
2983 |
|
2984 | processFor(element);
|
2985 | processIf(element);
|
2986 | processOnce(element);
|
2987 | }
|
2988 |
|
2989 | if (!root) {
|
2990 | root = element;
|
2991 | {
|
2992 | checkRootConstraints(root);
|
2993 | }
|
2994 | }
|
2995 |
|
2996 | if (!unary) {
|
2997 | currentParent = element;
|
2998 | stack.push(element);
|
2999 | } else {
|
3000 | closeElement(element);
|
3001 | }
|
3002 | },
|
3003 |
|
3004 | end: function end (tag, start, end$1) {
|
3005 | var element = stack[stack.length - 1];
|
3006 |
|
3007 | stack.length -= 1;
|
3008 | currentParent = stack[stack.length - 1];
|
3009 | if (options.outputSourceRange) {
|
3010 | element.end = end$1;
|
3011 | }
|
3012 | closeElement(element);
|
3013 | },
|
3014 |
|
3015 | chars: function chars (text, start, end) {
|
3016 | if (!currentParent) {
|
3017 | {
|
3018 | if (text === template) {
|
3019 | warnOnce(
|
3020 | 'Component template requires a root element, rather than just text.',
|
3021 | { start: start }
|
3022 | );
|
3023 | } else if ((text = text.trim())) {
|
3024 | warnOnce(
|
3025 | ("text \"" + text + "\" outside root element will be ignored."),
|
3026 | { start: start }
|
3027 | );
|
3028 | }
|
3029 | }
|
3030 | return
|
3031 | }
|
3032 |
|
3033 |
|
3034 | if (isIE &&
|
3035 | currentParent.tag === 'textarea' &&
|
3036 | currentParent.attrsMap.placeholder === text
|
3037 | ) {
|
3038 | return
|
3039 | }
|
3040 | var children = currentParent.children;
|
3041 | if (inPre || text.trim()) {
|
3042 | text = isTextTag(currentParent) ? text : decodeHTMLCached(text);
|
3043 | } else if (!children.length) {
|
3044 |
|
3045 | text = '';
|
3046 | } else if (whitespaceOption) {
|
3047 | if (whitespaceOption === 'condense') {
|
3048 |
|
3049 |
|
3050 | text = lineBreakRE.test(text) ? '' : ' ';
|
3051 | } else {
|
3052 | text = ' ';
|
3053 | }
|
3054 | } else {
|
3055 | text = preserveWhitespace ? ' ' : '';
|
3056 | }
|
3057 | if (text) {
|
3058 | if (!inPre && whitespaceOption === 'condense') {
|
3059 |
|
3060 | text = text.replace(whitespaceRE, ' ');
|
3061 | }
|
3062 | var res;
|
3063 | var child;
|
3064 | if (!inVPre && text !== ' ' && (res = parseText(text, delimiters))) {
|
3065 | child = {
|
3066 | type: 2,
|
3067 | expression: res.expression,
|
3068 | tokens: res.tokens,
|
3069 | text: text
|
3070 | };
|
3071 | } else if (text !== ' ' || !children.length || children[children.length - 1].text !== ' ') {
|
3072 | child = {
|
3073 | type: 3,
|
3074 | text: text
|
3075 | };
|
3076 | }
|
3077 | if (child) {
|
3078 | if (options.outputSourceRange) {
|
3079 | child.start = start;
|
3080 | child.end = end;
|
3081 | }
|
3082 | children.push(child);
|
3083 | }
|
3084 | }
|
3085 | },
|
3086 | comment: function comment (text, start, end) {
|
3087 |
|
3088 |
|
3089 | if (currentParent) {
|
3090 | var child = {
|
3091 | type: 3,
|
3092 | text: text,
|
3093 | isComment: true
|
3094 | };
|
3095 | if (options.outputSourceRange) {
|
3096 | child.start = start;
|
3097 | child.end = end;
|
3098 | }
|
3099 | currentParent.children.push(child);
|
3100 | }
|
3101 | }
|
3102 | });
|
3103 | return root
|
3104 | }
|
3105 |
|
3106 | function processPre (el) {
|
3107 | if (getAndRemoveAttr(el, 'v-pre') != null) {
|
3108 | el.pre = true;
|
3109 | }
|
3110 | }
|
3111 |
|
3112 | function processRawAttrs (el) {
|
3113 | var list = el.attrsList;
|
3114 | var len = list.length;
|
3115 | if (len) {
|
3116 | var attrs = el.attrs = new Array(len);
|
3117 | for (var i = 0; i < len; i++) {
|
3118 | attrs[i] = {
|
3119 | name: list[i].name,
|
3120 | value: JSON.stringify(list[i].value)
|
3121 | };
|
3122 | if (list[i].start != null) {
|
3123 | attrs[i].start = list[i].start;
|
3124 | attrs[i].end = list[i].end;
|
3125 | }
|
3126 | }
|
3127 | } else if (!el.pre) {
|
3128 |
|
3129 | el.plain = true;
|
3130 | }
|
3131 | }
|
3132 |
|
3133 | function processElement (
|
3134 | element,
|
3135 | options
|
3136 | ) {
|
3137 | processKey(element);
|
3138 |
|
3139 |
|
3140 |
|
3141 | element.plain = (
|
3142 | !element.key &&
|
3143 | !element.scopedSlots &&
|
3144 | !element.attrsList.length
|
3145 | );
|
3146 |
|
3147 | processRef(element);
|
3148 | processSlotContent(element);
|
3149 | processSlotOutlet(element);
|
3150 | processComponent(element);
|
3151 | for (var i = 0; i < transforms.length; i++) {
|
3152 | element = transforms[i](element, options) || element;
|
3153 | }
|
3154 | processAttrs(element);
|
3155 | return element
|
3156 | }
|
3157 |
|
3158 | function processKey (el) {
|
3159 | var exp = getBindingAttr(el, 'key');
|
3160 | if (exp) {
|
3161 | {
|
3162 | if (el.tag === 'template') {
|
3163 | warn$1(
|
3164 | "<template> cannot be keyed. Place the key on real elements instead.",
|
3165 | getRawBindingAttr(el, 'key')
|
3166 | );
|
3167 | }
|
3168 | if (el.for) {
|
3169 | var iterator = el.iterator2 || el.iterator1;
|
3170 | var parent = el.parent;
|
3171 | if (iterator && iterator === exp && parent && parent.tag === 'transition-group') {
|
3172 | warn$1(
|
3173 | "Do not use v-for index as key on <transition-group> children, " +
|
3174 | "this is the same as not using keys.",
|
3175 | getRawBindingAttr(el, 'key'),
|
3176 | true
|
3177 | );
|
3178 | }
|
3179 | }
|
3180 | }
|
3181 | el.key = exp;
|
3182 | }
|
3183 | }
|
3184 |
|
3185 | function processRef (el) {
|
3186 | var ref = getBindingAttr(el, 'ref');
|
3187 | if (ref) {
|
3188 | el.ref = ref;
|
3189 | el.refInFor = checkInFor(el);
|
3190 | }
|
3191 | }
|
3192 |
|
3193 | function processFor (el) {
|
3194 | var exp;
|
3195 | if ((exp = getAndRemoveAttr(el, 'v-for'))) {
|
3196 | var res = parseFor(exp);
|
3197 | if (res) {
|
3198 | extend(el, res);
|
3199 | } else {
|
3200 | warn$1(
|
3201 | ("Invalid v-for expression: " + exp),
|
3202 | el.rawAttrsMap['v-for']
|
3203 | );
|
3204 | }
|
3205 | }
|
3206 | }
|
3207 |
|
3208 |
|
3209 |
|
3210 | function parseFor (exp) {
|
3211 | var inMatch = exp.match(forAliasRE);
|
3212 | if (!inMatch) { return }
|
3213 | var res = {};
|
3214 | res.for = inMatch[2].trim();
|
3215 | var alias = inMatch[1].trim().replace(stripParensRE, '');
|
3216 | var iteratorMatch = alias.match(forIteratorRE);
|
3217 | if (iteratorMatch) {
|
3218 | res.alias = alias.replace(forIteratorRE, '').trim();
|
3219 | res.iterator1 = iteratorMatch[1].trim();
|
3220 | if (iteratorMatch[2]) {
|
3221 | res.iterator2 = iteratorMatch[2].trim();
|
3222 | }
|
3223 | } else {
|
3224 | res.alias = alias;
|
3225 | }
|
3226 | return res
|
3227 | }
|
3228 |
|
3229 | function processIf (el) {
|
3230 | var exp = getAndRemoveAttr(el, 'v-if');
|
3231 | if (exp) {
|
3232 | el.if = exp;
|
3233 | addIfCondition(el, {
|
3234 | exp: exp,
|
3235 | block: el
|
3236 | });
|
3237 | } else {
|
3238 | if (getAndRemoveAttr(el, 'v-else') != null) {
|
3239 | el.else = true;
|
3240 | }
|
3241 | var elseif = getAndRemoveAttr(el, 'v-else-if');
|
3242 | if (elseif) {
|
3243 | el.elseif = elseif;
|
3244 | }
|
3245 | }
|
3246 | }
|
3247 |
|
3248 | function processIfConditions (el, parent) {
|
3249 | var prev = findPrevElement(parent.children);
|
3250 | if (prev && prev.if) {
|
3251 | addIfCondition(prev, {
|
3252 | exp: el.elseif,
|
3253 | block: el
|
3254 | });
|
3255 | } else {
|
3256 | warn$1(
|
3257 | "v-" + (el.elseif ? ('else-if="' + el.elseif + '"') : 'else') + " " +
|
3258 | "used on element <" + (el.tag) + "> without corresponding v-if.",
|
3259 | el.rawAttrsMap[el.elseif ? 'v-else-if' : 'v-else']
|
3260 | );
|
3261 | }
|
3262 | }
|
3263 |
|
3264 | function findPrevElement (children) {
|
3265 | var i = children.length;
|
3266 | while (i--) {
|
3267 | if (children[i].type === 1) {
|
3268 | return children[i]
|
3269 | } else {
|
3270 | if (children[i].text !== ' ') {
|
3271 | warn$1(
|
3272 | "text \"" + (children[i].text.trim()) + "\" between v-if and v-else(-if) " +
|
3273 | "will be ignored.",
|
3274 | children[i]
|
3275 | );
|
3276 | }
|
3277 | children.pop();
|
3278 | }
|
3279 | }
|
3280 | }
|
3281 |
|
3282 | function addIfCondition (el, condition) {
|
3283 | if (!el.ifConditions) {
|
3284 | el.ifConditions = [];
|
3285 | }
|
3286 | el.ifConditions.push(condition);
|
3287 | }
|
3288 |
|
3289 | function processOnce (el) {
|
3290 | var once$$1 = getAndRemoveAttr(el, 'v-once');
|
3291 | if (once$$1 != null) {
|
3292 | el.once = true;
|
3293 | }
|
3294 | }
|
3295 |
|
3296 |
|
3297 |
|
3298 | function processSlotContent (el) {
|
3299 | var slotScope;
|
3300 | if (el.tag === 'template') {
|
3301 | slotScope = getAndRemoveAttr(el, 'scope');
|
3302 |
|
3303 | if (slotScope) {
|
3304 | warn$1(
|
3305 | "the \"scope\" attribute for scoped slots have been deprecated and " +
|
3306 | "replaced by \"slot-scope\" since 2.5. The new \"slot-scope\" attribute " +
|
3307 | "can also be used on plain elements in addition to <template> to " +
|
3308 | "denote scoped slots.",
|
3309 | el.rawAttrsMap['scope'],
|
3310 | true
|
3311 | );
|
3312 | }
|
3313 | el.slotScope = slotScope || getAndRemoveAttr(el, 'slot-scope');
|
3314 | } else if ((slotScope = getAndRemoveAttr(el, 'slot-scope'))) {
|
3315 |
|
3316 | if (el.attrsMap['v-for']) {
|
3317 | warn$1(
|
3318 | "Ambiguous combined usage of slot-scope and v-for on <" + (el.tag) + "> " +
|
3319 | "(v-for takes higher priority). Use a wrapper <template> for the " +
|
3320 | "scoped slot to make it clearer.",
|
3321 | el.rawAttrsMap['slot-scope'],
|
3322 | true
|
3323 | );
|
3324 | }
|
3325 | el.slotScope = slotScope;
|
3326 | }
|
3327 |
|
3328 |
|
3329 | var slotTarget = getBindingAttr(el, 'slot');
|
3330 | if (slotTarget) {
|
3331 | el.slotTarget = slotTarget === '""' ? '"default"' : slotTarget;
|
3332 | el.slotTargetDynamic = !!(el.attrsMap[':slot'] || el.attrsMap['v-bind:slot']);
|
3333 |
|
3334 |
|
3335 | if (el.tag !== 'template' && !el.slotScope) {
|
3336 | addAttr(el, 'slot', slotTarget, getRawBindingAttr(el, 'slot'));
|
3337 | }
|
3338 | }
|
3339 |
|
3340 |
|
3341 | {
|
3342 | if (el.tag === 'template') {
|
3343 |
|
3344 | var slotBinding = getAndRemoveAttrByRegex(el, slotRE);
|
3345 | if (slotBinding) {
|
3346 | {
|
3347 | if (el.slotTarget || el.slotScope) {
|
3348 | warn$1(
|
3349 | "Unexpected mixed usage of different slot syntaxes.",
|
3350 | el
|
3351 | );
|
3352 | }
|
3353 | if (el.parent && !maybeComponent(el.parent)) {
|
3354 | warn$1(
|
3355 | "<template v-slot> can only appear at the root level inside " +
|
3356 | "the receiving component",
|
3357 | el
|
3358 | );
|
3359 | }
|
3360 | }
|
3361 | var ref = getSlotName(slotBinding);
|
3362 | var name = ref.name;
|
3363 | var dynamic = ref.dynamic;
|
3364 | el.slotTarget = name;
|
3365 | el.slotTargetDynamic = dynamic;
|
3366 | el.slotScope = slotBinding.value || emptySlotScopeToken;
|
3367 | }
|
3368 | } else {
|
3369 |
|
3370 | var slotBinding$1 = getAndRemoveAttrByRegex(el, slotRE);
|
3371 | if (slotBinding$1) {
|
3372 | {
|
3373 | if (!maybeComponent(el)) {
|
3374 | warn$1(
|
3375 | "v-slot can only be used on components or <template>.",
|
3376 | slotBinding$1
|
3377 | );
|
3378 | }
|
3379 | if (el.slotScope || el.slotTarget) {
|
3380 | warn$1(
|
3381 | "Unexpected mixed usage of different slot syntaxes.",
|
3382 | el
|
3383 | );
|
3384 | }
|
3385 | if (el.scopedSlots) {
|
3386 | warn$1(
|
3387 | "To avoid scope ambiguity, the default slot should also use " +
|
3388 | "<template> syntax when there are other named slots.",
|
3389 | slotBinding$1
|
3390 | );
|
3391 | }
|
3392 | }
|
3393 |
|
3394 | var slots = el.scopedSlots || (el.scopedSlots = {});
|
3395 | var ref$1 = getSlotName(slotBinding$1);
|
3396 | var name$1 = ref$1.name;
|
3397 | var dynamic$1 = ref$1.dynamic;
|
3398 | var slotContainer = slots[name$1] = createASTElement('template', [], el);
|
3399 | slotContainer.slotTarget = name$1;
|
3400 | slotContainer.slotTargetDynamic = dynamic$1;
|
3401 | slotContainer.children = el.children.filter(function (c) {
|
3402 | if (!c.slotScope) {
|
3403 | c.parent = slotContainer;
|
3404 | return true
|
3405 | }
|
3406 | });
|
3407 | slotContainer.slotScope = slotBinding$1.value || emptySlotScopeToken;
|
3408 |
|
3409 | el.children = [];
|
3410 |
|
3411 | el.plain = false;
|
3412 | }
|
3413 | }
|
3414 | }
|
3415 | }
|
3416 |
|
3417 | function getSlotName (binding) {
|
3418 | var name = binding.name.replace(slotRE, '');
|
3419 | if (!name) {
|
3420 | if (binding.name[0] !== '#') {
|
3421 | name = 'default';
|
3422 | } else {
|
3423 | warn$1(
|
3424 | "v-slot shorthand syntax requires a slot name.",
|
3425 | binding
|
3426 | );
|
3427 | }
|
3428 | }
|
3429 | return dynamicArgRE.test(name)
|
3430 |
|
3431 | ? { name: name.slice(1, -1), dynamic: true }
|
3432 |
|
3433 | : { name: ("\"" + name + "\""), dynamic: false }
|
3434 | }
|
3435 |
|
3436 |
|
3437 | function processSlotOutlet (el) {
|
3438 | if (el.tag === 'slot') {
|
3439 | el.slotName = getBindingAttr(el, 'name');
|
3440 | if (el.key) {
|
3441 | warn$1(
|
3442 | "`key` does not work on <slot> because slots are abstract outlets " +
|
3443 | "and can possibly expand into multiple elements. " +
|
3444 | "Use the key on a wrapping element instead.",
|
3445 | getRawBindingAttr(el, 'key')
|
3446 | );
|
3447 | }
|
3448 | }
|
3449 | }
|
3450 |
|
3451 | function processComponent (el) {
|
3452 | var binding;
|
3453 | if ((binding = getBindingAttr(el, 'is'))) {
|
3454 | el.component = binding;
|
3455 | }
|
3456 | if (getAndRemoveAttr(el, 'inline-template') != null) {
|
3457 | el.inlineTemplate = true;
|
3458 | }
|
3459 | }
|
3460 |
|
3461 | function processAttrs (el) {
|
3462 | var list = el.attrsList;
|
3463 | var i, l, name, rawName, value, modifiers, syncGen, isDynamic;
|
3464 | for (i = 0, l = list.length; i < l; i++) {
|
3465 | name = rawName = list[i].name;
|
3466 | value = list[i].value;
|
3467 | if (dirRE.test(name)) {
|
3468 |
|
3469 | el.hasBindings = true;
|
3470 |
|
3471 | modifiers = parseModifiers(name.replace(dirRE, ''));
|
3472 |
|
3473 | if (modifiers) {
|
3474 | name = name.replace(modifierRE, '');
|
3475 | }
|
3476 | if (bindRE.test(name)) {
|
3477 | name = name.replace(bindRE, '');
|
3478 | value = parseFilters(value);
|
3479 | isDynamic = dynamicArgRE.test(name);
|
3480 | if (isDynamic) {
|
3481 | name = name.slice(1, -1);
|
3482 | }
|
3483 | if (
|
3484 | value.trim().length === 0
|
3485 | ) {
|
3486 | warn$1(
|
3487 | ("The value for a v-bind expression cannot be empty. Found in \"v-bind:" + name + "\"")
|
3488 | );
|
3489 | }
|
3490 | if (modifiers) {
|
3491 | if (modifiers.prop && !isDynamic) {
|
3492 | name = camelize(name);
|
3493 | if (name === 'innerHtml') { name = 'innerHTML'; }
|
3494 | }
|
3495 | if (modifiers.camel && !isDynamic) {
|
3496 | name = camelize(name);
|
3497 | }
|
3498 | if (modifiers.sync) {
|
3499 | syncGen = genAssignmentCode(value, "$event");
|
3500 | if (!isDynamic) {
|
3501 | addHandler(
|
3502 | el,
|
3503 | ("update:" + (camelize(name))),
|
3504 | syncGen,
|
3505 | null,
|
3506 | false,
|
3507 | warn$1,
|
3508 | list[i]
|
3509 | );
|
3510 | if (hyphenate(name) !== camelize(name)) {
|
3511 | addHandler(
|
3512 | el,
|
3513 | ("update:" + (hyphenate(name))),
|
3514 | syncGen,
|
3515 | null,
|
3516 | false,
|
3517 | warn$1,
|
3518 | list[i]
|
3519 | );
|
3520 | }
|
3521 | } else {
|
3522 |
|
3523 | addHandler(
|
3524 | el,
|
3525 | ("\"update:\"+(" + name + ")"),
|
3526 | syncGen,
|
3527 | null,
|
3528 | false,
|
3529 | warn$1,
|
3530 | list[i],
|
3531 | true
|
3532 | );
|
3533 | }
|
3534 | }
|
3535 | }
|
3536 | if ((modifiers && modifiers.prop) || (
|
3537 | !el.component && platformMustUseProp(el.tag, el.attrsMap.type, name)
|
3538 | )) {
|
3539 | addProp(el, name, value, list[i], isDynamic);
|
3540 | } else {
|
3541 | addAttr(el, name, value, list[i], isDynamic);
|
3542 | }
|
3543 | } else if (onRE.test(name)) {
|
3544 | name = name.replace(onRE, '');
|
3545 | isDynamic = dynamicArgRE.test(name);
|
3546 | if (isDynamic) {
|
3547 | name = name.slice(1, -1);
|
3548 | }
|
3549 | addHandler(el, name, value, modifiers, false, warn$1, list[i], isDynamic);
|
3550 | } else {
|
3551 | name = name.replace(dirRE, '');
|
3552 |
|
3553 | var argMatch = name.match(argRE);
|
3554 | var arg = argMatch && argMatch[1];
|
3555 | isDynamic = false;
|
3556 | if (arg) {
|
3557 | name = name.slice(0, -(arg.length + 1));
|
3558 | if (dynamicArgRE.test(arg)) {
|
3559 | arg = arg.slice(1, -1);
|
3560 | isDynamic = true;
|
3561 | }
|
3562 | }
|
3563 | addDirective(el, name, rawName, value, arg, isDynamic, modifiers, list[i]);
|
3564 | if (name === 'model') {
|
3565 | checkForAliasModel(el, value);
|
3566 | }
|
3567 | }
|
3568 | } else {
|
3569 |
|
3570 | {
|
3571 | var res = parseText(value, delimiters);
|
3572 | if (res) {
|
3573 | warn$1(
|
3574 | name + "=\"" + value + "\": " +
|
3575 | 'Interpolation inside attributes has been removed. ' +
|
3576 | 'Use v-bind or the colon shorthand instead. For example, ' +
|
3577 | 'instead of <div id="{{ val }}">, use <div :id="val">.',
|
3578 | list[i]
|
3579 | );
|
3580 | }
|
3581 | }
|
3582 | addAttr(el, name, JSON.stringify(value), list[i]);
|
3583 |
|
3584 |
|
3585 | if (!el.component &&
|
3586 | name === 'muted' &&
|
3587 | platformMustUseProp(el.tag, el.attrsMap.type, name)) {
|
3588 | addProp(el, name, 'true', list[i]);
|
3589 | }
|
3590 | }
|
3591 | }
|
3592 | }
|
3593 |
|
3594 | function checkInFor (el) {
|
3595 | var parent = el;
|
3596 | while (parent) {
|
3597 | if (parent.for !== undefined) {
|
3598 | return true
|
3599 | }
|
3600 | parent = parent.parent;
|
3601 | }
|
3602 | return false
|
3603 | }
|
3604 |
|
3605 | function parseModifiers (name) {
|
3606 | var match = name.match(modifierRE);
|
3607 | if (match) {
|
3608 | var ret = {};
|
3609 | match.forEach(function (m) { ret[m.slice(1)] = true; });
|
3610 | return ret
|
3611 | }
|
3612 | }
|
3613 |
|
3614 | function makeAttrsMap (attrs) {
|
3615 | var map = {};
|
3616 | for (var i = 0, l = attrs.length; i < l; i++) {
|
3617 | if (
|
3618 | map[attrs[i].name] && !isIE && !isEdge
|
3619 | ) {
|
3620 | warn$1('duplicate attribute: ' + attrs[i].name, attrs[i]);
|
3621 | }
|
3622 | map[attrs[i].name] = attrs[i].value;
|
3623 | }
|
3624 | return map
|
3625 | }
|
3626 |
|
3627 |
|
3628 | function isTextTag (el) {
|
3629 | return el.tag === 'script' || el.tag === 'style'
|
3630 | }
|
3631 |
|
3632 | function isForbiddenTag (el) {
|
3633 | return (
|
3634 | el.tag === 'style' ||
|
3635 | (el.tag === 'script' && (
|
3636 | !el.attrsMap.type ||
|
3637 | el.attrsMap.type === 'text/javascript'
|
3638 | ))
|
3639 | )
|
3640 | }
|
3641 |
|
3642 | var ieNSBug = /^xmlns:NS\d+/;
|
3643 | var ieNSPrefix = /^NS\d+:/;
|
3644 |
|
3645 |
|
3646 | function guardIESVGBug (attrs) {
|
3647 | var res = [];
|
3648 | for (var i = 0; i < attrs.length; i++) {
|
3649 | var attr = attrs[i];
|
3650 | if (!ieNSBug.test(attr.name)) {
|
3651 | attr.name = attr.name.replace(ieNSPrefix, '');
|
3652 | res.push(attr);
|
3653 | }
|
3654 | }
|
3655 | return res
|
3656 | }
|
3657 |
|
3658 | function checkForAliasModel (el, value) {
|
3659 | var _el = el;
|
3660 | while (_el) {
|
3661 | if (_el.for && _el.alias === value) {
|
3662 | warn$1(
|
3663 | "<" + (el.tag) + " v-model=\"" + value + "\">: " +
|
3664 | "You are binding v-model directly to a v-for iteration alias. " +
|
3665 | "This will not be able to modify the v-for source array because " +
|
3666 | "writing to the alias is like modifying a function local variable. " +
|
3667 | "Consider using an array of objects and use v-model on an object property instead.",
|
3668 | el.rawAttrsMap['v-model']
|
3669 | );
|
3670 | }
|
3671 | _el = _el.parent;
|
3672 | }
|
3673 | }
|
3674 |
|
3675 |
|
3676 |
|
3677 | function preTransformNode (el, options) {
|
3678 | if (el.tag === 'input') {
|
3679 | var map = el.attrsMap;
|
3680 | if (!map['v-model']) {
|
3681 | return
|
3682 | }
|
3683 |
|
3684 | var typeBinding;
|
3685 | if (map[':type'] || map['v-bind:type']) {
|
3686 | typeBinding = getBindingAttr(el, 'type');
|
3687 | }
|
3688 | if (!map.type && !typeBinding && map['v-bind']) {
|
3689 | typeBinding = "(" + (map['v-bind']) + ").type";
|
3690 | }
|
3691 |
|
3692 | if (typeBinding) {
|
3693 | var ifCondition = getAndRemoveAttr(el, 'v-if', true);
|
3694 | var ifConditionExtra = ifCondition ? ("&&(" + ifCondition + ")") : "";
|
3695 | var hasElse = getAndRemoveAttr(el, 'v-else', true) != null;
|
3696 | var elseIfCondition = getAndRemoveAttr(el, 'v-else-if', true);
|
3697 |
|
3698 | var branch0 = cloneASTElement(el);
|
3699 |
|
3700 | processFor(branch0);
|
3701 | addRawAttr(branch0, 'type', 'checkbox');
|
3702 | processElement(branch0, options);
|
3703 | branch0.processed = true;
|
3704 | branch0.if = "(" + typeBinding + ")==='checkbox'" + ifConditionExtra;
|
3705 | addIfCondition(branch0, {
|
3706 | exp: branch0.if,
|
3707 | block: branch0
|
3708 | });
|
3709 |
|
3710 | var branch1 = cloneASTElement(el);
|
3711 | getAndRemoveAttr(branch1, 'v-for', true);
|
3712 | addRawAttr(branch1, 'type', 'radio');
|
3713 | processElement(branch1, options);
|
3714 | addIfCondition(branch0, {
|
3715 | exp: "(" + typeBinding + ")==='radio'" + ifConditionExtra,
|
3716 | block: branch1
|
3717 | });
|
3718 |
|
3719 | var branch2 = cloneASTElement(el);
|
3720 | getAndRemoveAttr(branch2, 'v-for', true);
|
3721 | addRawAttr(branch2, ':type', typeBinding);
|
3722 | processElement(branch2, options);
|
3723 | addIfCondition(branch0, {
|
3724 | exp: ifCondition,
|
3725 | block: branch2
|
3726 | });
|
3727 |
|
3728 | if (hasElse) {
|
3729 | branch0.else = true;
|
3730 | } else if (elseIfCondition) {
|
3731 | branch0.elseif = elseIfCondition;
|
3732 | }
|
3733 |
|
3734 | return branch0
|
3735 | }
|
3736 | }
|
3737 | }
|
3738 |
|
3739 | function cloneASTElement (el) {
|
3740 | return createASTElement(el.tag, el.attrsList.slice(), el.parent)
|
3741 | }
|
3742 |
|
3743 | var model = {
|
3744 | preTransformNode: preTransformNode
|
3745 | };
|
3746 |
|
3747 | var modules = [
|
3748 | klass,
|
3749 | style,
|
3750 | model
|
3751 | ];
|
3752 |
|
3753 |
|
3754 |
|
3755 | var warn$2;
|
3756 |
|
3757 |
|
3758 |
|
3759 | var RANGE_TOKEN = '__r';
|
3760 |
|
3761 | function model$1 (
|
3762 | el,
|
3763 | dir,
|
3764 | _warn
|
3765 | ) {
|
3766 | warn$2 = _warn;
|
3767 | var value = dir.value;
|
3768 | var modifiers = dir.modifiers;
|
3769 | var tag = el.tag;
|
3770 | var type = el.attrsMap.type;
|
3771 |
|
3772 | {
|
3773 |
|
3774 |
|
3775 | if (tag === 'input' && type === 'file') {
|
3776 | warn$2(
|
3777 | "<" + (el.tag) + " v-model=\"" + value + "\" type=\"file\">:\n" +
|
3778 | "File inputs are read only. Use a v-on:change listener instead.",
|
3779 | el.rawAttrsMap['v-model']
|
3780 | );
|
3781 | }
|
3782 | }
|
3783 |
|
3784 | if (el.component) {
|
3785 | genComponentModel(el, value, modifiers);
|
3786 |
|
3787 | return false
|
3788 | } else if (tag === 'select') {
|
3789 | genSelect(el, value, modifiers);
|
3790 | } else if (tag === 'input' && type === 'checkbox') {
|
3791 | genCheckboxModel(el, value, modifiers);
|
3792 | } else if (tag === 'input' && type === 'radio') {
|
3793 | genRadioModel(el, value, modifiers);
|
3794 | } else if (tag === 'input' || tag === 'textarea') {
|
3795 | genDefaultModel(el, value, modifiers);
|
3796 | } else {
|
3797 | genComponentModel(el, value, modifiers);
|
3798 |
|
3799 | return false
|
3800 | }
|
3801 |
|
3802 |
|
3803 | return true
|
3804 | }
|
3805 |
|
3806 | function genCheckboxModel (
|
3807 | el,
|
3808 | value,
|
3809 | modifiers
|
3810 | ) {
|
3811 | var number = modifiers && modifiers.number;
|
3812 | var valueBinding = getBindingAttr(el, 'value') || 'null';
|
3813 | var trueValueBinding = getBindingAttr(el, 'true-value') || 'true';
|
3814 | var falseValueBinding = getBindingAttr(el, 'false-value') || 'false';
|
3815 | addProp(el, 'checked',
|
3816 | "Array.isArray(" + value + ")" +
|
3817 | "?_i(" + value + "," + valueBinding + ")>-1" + (
|
3818 | trueValueBinding === 'true'
|
3819 | ? (":(" + value + ")")
|
3820 | : (":_q(" + value + "," + trueValueBinding + ")")
|
3821 | )
|
3822 | );
|
3823 | addHandler(el, 'change',
|
3824 | "var $$a=" + value + "," +
|
3825 | '$$el=$event.target,' +
|
3826 | "$$c=$$el.checked?(" + trueValueBinding + "):(" + falseValueBinding + ");" +
|
3827 | 'if(Array.isArray($$a)){' +
|
3828 | "var $$v=" + (number ? '_n(' + valueBinding + ')' : valueBinding) + "," +
|
3829 | '$$i=_i($$a,$$v);' +
|
3830 | "if($$el.checked){$$i<0&&(" + (genAssignmentCode(value, '$$a.concat([$$v])')) + ")}" +
|
3831 | "else{$$i>-1&&(" + (genAssignmentCode(value, '$$a.slice(0,$$i).concat($$a.slice($$i+1))')) + ")}" +
|
3832 | "}else{" + (genAssignmentCode(value, '$$c')) + "}",
|
3833 | null, true
|
3834 | );
|
3835 | }
|
3836 |
|
3837 | function genRadioModel (
|
3838 | el,
|
3839 | value,
|
3840 | modifiers
|
3841 | ) {
|
3842 | var number = modifiers && modifiers.number;
|
3843 | var valueBinding = getBindingAttr(el, 'value') || 'null';
|
3844 | valueBinding = number ? ("_n(" + valueBinding + ")") : valueBinding;
|
3845 | addProp(el, 'checked', ("_q(" + value + "," + valueBinding + ")"));
|
3846 | addHandler(el, 'change', genAssignmentCode(value, valueBinding), null, true);
|
3847 | }
|
3848 |
|
3849 | function genSelect (
|
3850 | el,
|
3851 | value,
|
3852 | modifiers
|
3853 | ) {
|
3854 | var number = modifiers && modifiers.number;
|
3855 | var selectedVal = "Array.prototype.filter" +
|
3856 | ".call($event.target.options,function(o){return o.selected})" +
|
3857 | ".map(function(o){var val = \"_value\" in o ? o._value : o.value;" +
|
3858 | "return " + (number ? '_n(val)' : 'val') + "})";
|
3859 |
|
3860 | var assignment = '$event.target.multiple ? $$selectedVal : $$selectedVal[0]';
|
3861 | var code = "var $$selectedVal = " + selectedVal + ";";
|
3862 | code = code + " " + (genAssignmentCode(value, assignment));
|
3863 | addHandler(el, 'change', code, null, true);
|
3864 | }
|
3865 |
|
3866 | function genDefaultModel (
|
3867 | el,
|
3868 | value,
|
3869 | modifiers
|
3870 | ) {
|
3871 | var type = el.attrsMap.type;
|
3872 |
|
3873 |
|
3874 |
|
3875 | {
|
3876 | var value$1 = el.attrsMap['v-bind:value'] || el.attrsMap[':value'];
|
3877 | var typeBinding = el.attrsMap['v-bind:type'] || el.attrsMap[':type'];
|
3878 | if (value$1 && !typeBinding) {
|
3879 | var binding = el.attrsMap['v-bind:value'] ? 'v-bind:value' : ':value';
|
3880 | warn$2(
|
3881 | binding + "=\"" + value$1 + "\" conflicts with v-model on the same element " +
|
3882 | 'because the latter already expands to a value binding internally',
|
3883 | el.rawAttrsMap[binding]
|
3884 | );
|
3885 | }
|
3886 | }
|
3887 |
|
3888 | var ref = modifiers || {};
|
3889 | var lazy = ref.lazy;
|
3890 | var number = ref.number;
|
3891 | var trim = ref.trim;
|
3892 | var needCompositionGuard = !lazy && type !== 'range';
|
3893 | var event = lazy
|
3894 | ? 'change'
|
3895 | : type === 'range'
|
3896 | ? RANGE_TOKEN
|
3897 | : 'input';
|
3898 |
|
3899 | var valueExpression = '$event.target.value';
|
3900 | if (trim) {
|
3901 | valueExpression = "$event.target.value.trim()";
|
3902 | }
|
3903 | if (number) {
|
3904 | valueExpression = "_n(" + valueExpression + ")";
|
3905 | }
|
3906 |
|
3907 | var code = genAssignmentCode(value, valueExpression);
|
3908 | if (needCompositionGuard) {
|
3909 | code = "if($event.target.composing)return;" + code;
|
3910 | }
|
3911 |
|
3912 | addProp(el, 'value', ("(" + value + ")"));
|
3913 | addHandler(el, event, code, null, true);
|
3914 | if (trim || number) {
|
3915 | addHandler(el, 'blur', '$forceUpdate()');
|
3916 | }
|
3917 | }
|
3918 |
|
3919 |
|
3920 |
|
3921 | function text (el, dir) {
|
3922 | if (dir.value) {
|
3923 | addProp(el, 'textContent', ("_s(" + (dir.value) + ")"), dir);
|
3924 | }
|
3925 | }
|
3926 |
|
3927 |
|
3928 |
|
3929 | function html (el, dir) {
|
3930 | if (dir.value) {
|
3931 | addProp(el, 'innerHTML', ("_s(" + (dir.value) + ")"), dir);
|
3932 | }
|
3933 | }
|
3934 |
|
3935 | var directives = {
|
3936 | model: model$1,
|
3937 | text: text,
|
3938 | html: html
|
3939 | };
|
3940 |
|
3941 |
|
3942 |
|
3943 | var baseOptions = {
|
3944 | expectHTML: true,
|
3945 | modules: modules,
|
3946 | directives: directives,
|
3947 | isPreTag: isPreTag,
|
3948 | isUnaryTag: isUnaryTag,
|
3949 | mustUseProp: mustUseProp,
|
3950 | canBeLeftOpenTag: canBeLeftOpenTag,
|
3951 | isReservedTag: isReservedTag,
|
3952 | getTagNamespace: getTagNamespace,
|
3953 | staticKeys: genStaticKeys(modules)
|
3954 | };
|
3955 |
|
3956 |
|
3957 |
|
3958 | var isStaticKey;
|
3959 | var isPlatformReservedTag;
|
3960 |
|
3961 | var genStaticKeysCached = cached(genStaticKeys$1);
|
3962 |
|
3963 | |
3964 |
|
3965 |
|
3966 |
|
3967 |
|
3968 |
|
3969 |
|
3970 |
|
3971 |
|
3972 |
|
3973 |
|
3974 | function optimize (root, options) {
|
3975 | if (!root) { return }
|
3976 | isStaticKey = genStaticKeysCached(options.staticKeys || '');
|
3977 | isPlatformReservedTag = options.isReservedTag || no;
|
3978 |
|
3979 | markStatic(root);
|
3980 |
|
3981 | markStaticRoots(root, false);
|
3982 | }
|
3983 |
|
3984 | function genStaticKeys$1 (keys) {
|
3985 | return makeMap(
|
3986 | 'type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap' +
|
3987 | (keys ? ',' + keys : '')
|
3988 | )
|
3989 | }
|
3990 |
|
3991 | function markStatic (node) {
|
3992 | node.static = isStatic(node);
|
3993 | if (node.type === 1) {
|
3994 |
|
3995 |
|
3996 |
|
3997 | if (
|
3998 | !isPlatformReservedTag(node.tag) &&
|
3999 | node.tag !== 'slot' &&
|
4000 | node.attrsMap['inline-template'] == null
|
4001 | ) {
|
4002 | return
|
4003 | }
|
4004 | for (var i = 0, l = node.children.length; i < l; i++) {
|
4005 | var child = node.children[i];
|
4006 | markStatic(child);
|
4007 | if (!child.static) {
|
4008 | node.static = false;
|
4009 | }
|
4010 | }
|
4011 | if (node.ifConditions) {
|
4012 | for (var i$1 = 1, l$1 = node.ifConditions.length; i$1 < l$1; i$1++) {
|
4013 | var block = node.ifConditions[i$1].block;
|
4014 | markStatic(block);
|
4015 | if (!block.static) {
|
4016 | node.static = false;
|
4017 | }
|
4018 | }
|
4019 | }
|
4020 | }
|
4021 | }
|
4022 |
|
4023 | function markStaticRoots (node, isInFor) {
|
4024 | if (node.type === 1) {
|
4025 | if (node.static || node.once) {
|
4026 | node.staticInFor = isInFor;
|
4027 | }
|
4028 |
|
4029 |
|
4030 |
|
4031 | if (node.static && node.children.length && !(
|
4032 | node.children.length === 1 &&
|
4033 | node.children[0].type === 3
|
4034 | )) {
|
4035 | node.staticRoot = true;
|
4036 | return
|
4037 | } else {
|
4038 | node.staticRoot = false;
|
4039 | }
|
4040 | if (node.children) {
|
4041 | for (var i = 0, l = node.children.length; i < l; i++) {
|
4042 | markStaticRoots(node.children[i], isInFor || !!node.for);
|
4043 | }
|
4044 | }
|
4045 | if (node.ifConditions) {
|
4046 | for (var i$1 = 1, l$1 = node.ifConditions.length; i$1 < l$1; i$1++) {
|
4047 | markStaticRoots(node.ifConditions[i$1].block, isInFor);
|
4048 | }
|
4049 | }
|
4050 | }
|
4051 | }
|
4052 |
|
4053 | function isStatic (node) {
|
4054 | if (node.type === 2) {
|
4055 | return false
|
4056 | }
|
4057 | if (node.type === 3) {
|
4058 | return true
|
4059 | }
|
4060 | return !!(node.pre || (
|
4061 | !node.hasBindings &&
|
4062 | !node.if && !node.for &&
|
4063 | !isBuiltInTag(node.tag) &&
|
4064 | isPlatformReservedTag(node.tag) &&
|
4065 | !isDirectChildOfTemplateFor(node) &&
|
4066 | Object.keys(node).every(isStaticKey)
|
4067 | ))
|
4068 | }
|
4069 |
|
4070 | function isDirectChildOfTemplateFor (node) {
|
4071 | while (node.parent) {
|
4072 | node = node.parent;
|
4073 | if (node.tag !== 'template') {
|
4074 | return false
|
4075 | }
|
4076 | if (node.for) {
|
4077 | return true
|
4078 | }
|
4079 | }
|
4080 | return false
|
4081 | }
|
4082 |
|
4083 |
|
4084 |
|
4085 | var fnExpRE = /^([\w$_]+|\([^)]*?\))\s*=>|^function(?:\s+[\w$]+)?\s*\(/;
|
4086 | var fnInvokeRE = /\([^)]*?\);*$/;
|
4087 | var simplePathRE = /^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/;
|
4088 |
|
4089 |
|
4090 | var keyCodes = {
|
4091 | esc: 27,
|
4092 | tab: 9,
|
4093 | enter: 13,
|
4094 | space: 32,
|
4095 | up: 38,
|
4096 | left: 37,
|
4097 | right: 39,
|
4098 | down: 40,
|
4099 | 'delete': [8, 46]
|
4100 | };
|
4101 |
|
4102 |
|
4103 | var keyNames = {
|
4104 |
|
4105 | esc: ['Esc', 'Escape'],
|
4106 | tab: 'Tab',
|
4107 | enter: 'Enter',
|
4108 |
|
4109 | space: [' ', 'Spacebar'],
|
4110 |
|
4111 | up: ['Up', 'ArrowUp'],
|
4112 | left: ['Left', 'ArrowLeft'],
|
4113 | right: ['Right', 'ArrowRight'],
|
4114 | down: ['Down', 'ArrowDown'],
|
4115 |
|
4116 | 'delete': ['Backspace', 'Delete', 'Del']
|
4117 | };
|
4118 |
|
4119 |
|
4120 |
|
4121 |
|
4122 | var genGuard = function (condition) { return ("if(" + condition + ")return null;"); };
|
4123 |
|
4124 | var modifierCode = {
|
4125 | stop: '$event.stopPropagation();',
|
4126 | prevent: '$event.preventDefault();',
|
4127 | self: genGuard("$event.target !== $event.currentTarget"),
|
4128 | ctrl: genGuard("!$event.ctrlKey"),
|
4129 | shift: genGuard("!$event.shiftKey"),
|
4130 | alt: genGuard("!$event.altKey"),
|
4131 | meta: genGuard("!$event.metaKey"),
|
4132 | left: genGuard("'button' in $event && $event.button !== 0"),
|
4133 | middle: genGuard("'button' in $event && $event.button !== 1"),
|
4134 | right: genGuard("'button' in $event && $event.button !== 2")
|
4135 | };
|
4136 |
|
4137 | function genHandlers (
|
4138 | events,
|
4139 | isNative
|
4140 | ) {
|
4141 | var prefix = isNative ? 'nativeOn:' : 'on:';
|
4142 | var staticHandlers = "";
|
4143 | var dynamicHandlers = "";
|
4144 | for (var name in events) {
|
4145 | var handlerCode = genHandler(events[name]);
|
4146 | if (events[name] && events[name].dynamic) {
|
4147 | dynamicHandlers += name + "," + handlerCode + ",";
|
4148 | } else {
|
4149 | staticHandlers += "\"" + name + "\":" + handlerCode + ",";
|
4150 | }
|
4151 | }
|
4152 | staticHandlers = "{" + (staticHandlers.slice(0, -1)) + "}";
|
4153 | if (dynamicHandlers) {
|
4154 | return prefix + "_d(" + staticHandlers + ",[" + (dynamicHandlers.slice(0, -1)) + "])"
|
4155 | } else {
|
4156 | return prefix + staticHandlers
|
4157 | }
|
4158 | }
|
4159 |
|
4160 | function genHandler (handler) {
|
4161 | if (!handler) {
|
4162 | return 'function(){}'
|
4163 | }
|
4164 |
|
4165 | if (Array.isArray(handler)) {
|
4166 | return ("[" + (handler.map(function (handler) { return genHandler(handler); }).join(',')) + "]")
|
4167 | }
|
4168 |
|
4169 | var isMethodPath = simplePathRE.test(handler.value);
|
4170 | var isFunctionExpression = fnExpRE.test(handler.value);
|
4171 | var isFunctionInvocation = simplePathRE.test(handler.value.replace(fnInvokeRE, ''));
|
4172 |
|
4173 | if (!handler.modifiers) {
|
4174 | if (isMethodPath || isFunctionExpression) {
|
4175 | return handler.value
|
4176 | }
|
4177 | return ("function($event){" + (isFunctionInvocation ? ("return " + (handler.value)) : handler.value) + "}")
|
4178 | } else {
|
4179 | var code = '';
|
4180 | var genModifierCode = '';
|
4181 | var keys = [];
|
4182 | for (var key in handler.modifiers) {
|
4183 | if (modifierCode[key]) {
|
4184 | genModifierCode += modifierCode[key];
|
4185 |
|
4186 | if (keyCodes[key]) {
|
4187 | keys.push(key);
|
4188 | }
|
4189 | } else if (key === 'exact') {
|
4190 | var modifiers = (handler.modifiers);
|
4191 | genModifierCode += genGuard(
|
4192 | ['ctrl', 'shift', 'alt', 'meta']
|
4193 | .filter(function (keyModifier) { return !modifiers[keyModifier]; })
|
4194 | .map(function (keyModifier) { return ("$event." + keyModifier + "Key"); })
|
4195 | .join('||')
|
4196 | );
|
4197 | } else {
|
4198 | keys.push(key);
|
4199 | }
|
4200 | }
|
4201 | if (keys.length) {
|
4202 | code += genKeyFilter(keys);
|
4203 | }
|
4204 |
|
4205 | if (genModifierCode) {
|
4206 | code += genModifierCode;
|
4207 | }
|
4208 | var handlerCode = isMethodPath
|
4209 | ? ("return " + (handler.value) + "($event)")
|
4210 | : isFunctionExpression
|
4211 | ? ("return (" + (handler.value) + ")($event)")
|
4212 | : isFunctionInvocation
|
4213 | ? ("return " + (handler.value))
|
4214 | : handler.value;
|
4215 | return ("function($event){" + code + handlerCode + "}")
|
4216 | }
|
4217 | }
|
4218 |
|
4219 | function genKeyFilter (keys) {
|
4220 | return (
|
4221 |
|
4222 |
|
4223 |
|
4224 | "if(!$event.type.indexOf('key')&&" +
|
4225 | (keys.map(genFilterCode).join('&&')) + ")return null;"
|
4226 | )
|
4227 | }
|
4228 |
|
4229 | function genFilterCode (key) {
|
4230 | var keyVal = parseInt(key, 10);
|
4231 | if (keyVal) {
|
4232 | return ("$event.keyCode!==" + keyVal)
|
4233 | }
|
4234 | var keyCode = keyCodes[key];
|
4235 | var keyName = keyNames[key];
|
4236 | return (
|
4237 | "_k($event.keyCode," +
|
4238 | (JSON.stringify(key)) + "," +
|
4239 | (JSON.stringify(keyCode)) + "," +
|
4240 | "$event.key," +
|
4241 | "" + (JSON.stringify(keyName)) +
|
4242 | ")"
|
4243 | )
|
4244 | }
|
4245 |
|
4246 |
|
4247 |
|
4248 | function on (el, dir) {
|
4249 | if (dir.modifiers) {
|
4250 | warn("v-on without argument does not support modifiers.");
|
4251 | }
|
4252 | el.wrapListeners = function (code) { return ("_g(" + code + "," + (dir.value) + ")"); };
|
4253 | }
|
4254 |
|
4255 |
|
4256 |
|
4257 | function bind$1 (el, dir) {
|
4258 | el.wrapData = function (code) {
|
4259 | return ("_b(" + code + ",'" + (el.tag) + "'," + (dir.value) + "," + (dir.modifiers && dir.modifiers.prop ? 'true' : 'false') + (dir.modifiers && dir.modifiers.sync ? ',true' : '') + ")")
|
4260 | };
|
4261 | }
|
4262 |
|
4263 |
|
4264 |
|
4265 | var baseDirectives = {
|
4266 | on: on,
|
4267 | bind: bind$1,
|
4268 | cloak: noop
|
4269 | };
|
4270 |
|
4271 |
|
4272 |
|
4273 |
|
4274 |
|
4275 |
|
4276 |
|
4277 | var CodegenState = function CodegenState (options) {
|
4278 | this.options = options;
|
4279 | this.warn = options.warn || baseWarn;
|
4280 | this.transforms = pluckModuleFunction(options.modules, 'transformCode');
|
4281 | this.dataGenFns = pluckModuleFunction(options.modules, 'genData');
|
4282 | this.directives = extend(extend({}, baseDirectives), options.directives);
|
4283 | var isReservedTag = options.isReservedTag || no;
|
4284 | this.maybeComponent = function (el) { return !!el.component || !isReservedTag(el.tag); };
|
4285 | this.onceId = 0;
|
4286 | this.staticRenderFns = [];
|
4287 | this.pre = false;
|
4288 | };
|
4289 |
|
4290 |
|
4291 |
|
4292 | function generate (
|
4293 | ast,
|
4294 | options
|
4295 | ) {
|
4296 | var state = new CodegenState(options);
|
4297 | var code = ast ? genElement(ast, state) : '_c("div")';
|
4298 | return {
|
4299 | render: ("with(this){return " + code + "}"),
|
4300 | staticRenderFns: state.staticRenderFns
|
4301 | }
|
4302 | }
|
4303 |
|
4304 | function genElement (el, state) {
|
4305 | if (el.parent) {
|
4306 | el.pre = el.pre || el.parent.pre;
|
4307 | }
|
4308 |
|
4309 | if (el.staticRoot && !el.staticProcessed) {
|
4310 | return genStatic(el, state)
|
4311 | } else if (el.once && !el.onceProcessed) {
|
4312 | return genOnce(el, state)
|
4313 | } else if (el.for && !el.forProcessed) {
|
4314 | return genFor(el, state)
|
4315 | } else if (el.if && !el.ifProcessed) {
|
4316 | return genIf(el, state)
|
4317 | } else if (el.tag === 'template' && !el.slotTarget && !state.pre) {
|
4318 | return genChildren(el, state) || 'void 0'
|
4319 | } else if (el.tag === 'slot') {
|
4320 | return genSlot(el, state)
|
4321 | } else {
|
4322 |
|
4323 | var code;
|
4324 | if (el.component) {
|
4325 | code = genComponent(el.component, el, state);
|
4326 | } else {
|
4327 | var data;
|
4328 | if (!el.plain || (el.pre && state.maybeComponent(el))) {
|
4329 | data = genData$2(el, state);
|
4330 | }
|
4331 |
|
4332 | var children = el.inlineTemplate ? null : genChildren(el, state, true);
|
4333 | code = "_c('" + (el.tag) + "'" + (data ? ("," + data) : '') + (children ? ("," + children) : '') + ")";
|
4334 | }
|
4335 |
|
4336 | for (var i = 0; i < state.transforms.length; i++) {
|
4337 | code = state.transforms[i](el, code);
|
4338 | }
|
4339 | return code
|
4340 | }
|
4341 | }
|
4342 |
|
4343 |
|
4344 | function genStatic (el, state) {
|
4345 | el.staticProcessed = true;
|
4346 |
|
4347 |
|
4348 |
|
4349 | var originalPreState = state.pre;
|
4350 | if (el.pre) {
|
4351 | state.pre = el.pre;
|
4352 | }
|
4353 | state.staticRenderFns.push(("with(this){return " + (genElement(el, state)) + "}"));
|
4354 | state.pre = originalPreState;
|
4355 | return ("_m(" + (state.staticRenderFns.length - 1) + (el.staticInFor ? ',true' : '') + ")")
|
4356 | }
|
4357 |
|
4358 |
|
4359 | function genOnce (el, state) {
|
4360 | el.onceProcessed = true;
|
4361 | if (el.if && !el.ifProcessed) {
|
4362 | return genIf(el, state)
|
4363 | } else if (el.staticInFor) {
|
4364 | var key = '';
|
4365 | var parent = el.parent;
|
4366 | while (parent) {
|
4367 | if (parent.for) {
|
4368 | key = parent.key;
|
4369 | break
|
4370 | }
|
4371 | parent = parent.parent;
|
4372 | }
|
4373 | if (!key) {
|
4374 | state.warn(
|
4375 | "v-once can only be used inside v-for that is keyed. ",
|
4376 | el.rawAttrsMap['v-once']
|
4377 | );
|
4378 | return genElement(el, state)
|
4379 | }
|
4380 | return ("_o(" + (genElement(el, state)) + "," + (state.onceId++) + "," + key + ")")
|
4381 | } else {
|
4382 | return genStatic(el, state)
|
4383 | }
|
4384 | }
|
4385 |
|
4386 | function genIf (
|
4387 | el,
|
4388 | state,
|
4389 | altGen,
|
4390 | altEmpty
|
4391 | ) {
|
4392 | el.ifProcessed = true;
|
4393 | return genIfConditions(el.ifConditions.slice(), state, altGen, altEmpty)
|
4394 | }
|
4395 |
|
4396 | function genIfConditions (
|
4397 | conditions,
|
4398 | state,
|
4399 | altGen,
|
4400 | altEmpty
|
4401 | ) {
|
4402 | if (!conditions.length) {
|
4403 | return altEmpty || '_e()'
|
4404 | }
|
4405 |
|
4406 | var condition = conditions.shift();
|
4407 | if (condition.exp) {
|
4408 | return ("(" + (condition.exp) + ")?" + (genTernaryExp(condition.block)) + ":" + (genIfConditions(conditions, state, altGen, altEmpty)))
|
4409 | } else {
|
4410 | return ("" + (genTernaryExp(condition.block)))
|
4411 | }
|
4412 |
|
4413 |
|
4414 | function genTernaryExp (el) {
|
4415 | return altGen
|
4416 | ? altGen(el, state)
|
4417 | : el.once
|
4418 | ? genOnce(el, state)
|
4419 | : genElement(el, state)
|
4420 | }
|
4421 | }
|
4422 |
|
4423 | function genFor (
|
4424 | el,
|
4425 | state,
|
4426 | altGen,
|
4427 | altHelper
|
4428 | ) {
|
4429 | var exp = el.for;
|
4430 | var alias = el.alias;
|
4431 | var iterator1 = el.iterator1 ? ("," + (el.iterator1)) : '';
|
4432 | var iterator2 = el.iterator2 ? ("," + (el.iterator2)) : '';
|
4433 |
|
4434 | if (state.maybeComponent(el) &&
|
4435 | el.tag !== 'slot' &&
|
4436 | el.tag !== 'template' &&
|
4437 | !el.key
|
4438 | ) {
|
4439 | state.warn(
|
4440 | "<" + (el.tag) + " v-for=\"" + alias + " in " + exp + "\">: component lists rendered with " +
|
4441 | "v-for should have explicit keys. " +
|
4442 | "See https://vuejs.org/guide/list.html#key for more info.",
|
4443 | el.rawAttrsMap['v-for'],
|
4444 | true
|
4445 | );
|
4446 | }
|
4447 |
|
4448 | el.forProcessed = true;
|
4449 | return (altHelper || '_l') + "((" + exp + ")," +
|
4450 | "function(" + alias + iterator1 + iterator2 + "){" +
|
4451 | "return " + ((altGen || genElement)(el, state)) +
|
4452 | '})'
|
4453 | }
|
4454 |
|
4455 | function genData$2 (el, state) {
|
4456 | var data = '{';
|
4457 |
|
4458 |
|
4459 |
|
4460 | var dirs = genDirectives(el, state);
|
4461 | if (dirs) { data += dirs + ','; }
|
4462 |
|
4463 |
|
4464 | if (el.key) {
|
4465 | data += "key:" + (el.key) + ",";
|
4466 | }
|
4467 |
|
4468 | if (el.ref) {
|
4469 | data += "ref:" + (el.ref) + ",";
|
4470 | }
|
4471 | if (el.refInFor) {
|
4472 | data += "refInFor:true,";
|
4473 | }
|
4474 |
|
4475 | if (el.pre) {
|
4476 | data += "pre:true,";
|
4477 | }
|
4478 |
|
4479 | if (el.component) {
|
4480 | data += "tag:\"" + (el.tag) + "\",";
|
4481 | }
|
4482 |
|
4483 | for (var i = 0; i < state.dataGenFns.length; i++) {
|
4484 | data += state.dataGenFns[i](el);
|
4485 | }
|
4486 |
|
4487 | if (el.attrs) {
|
4488 | data += "attrs:" + (genProps(el.attrs)) + ",";
|
4489 | }
|
4490 |
|
4491 | if (el.props) {
|
4492 | data += "domProps:" + (genProps(el.props)) + ",";
|
4493 | }
|
4494 |
|
4495 | if (el.events) {
|
4496 | data += (genHandlers(el.events, false)) + ",";
|
4497 | }
|
4498 | if (el.nativeEvents) {
|
4499 | data += (genHandlers(el.nativeEvents, true)) + ",";
|
4500 | }
|
4501 |
|
4502 |
|
4503 | if (el.slotTarget && !el.slotScope) {
|
4504 | data += "slot:" + (el.slotTarget) + ",";
|
4505 | }
|
4506 |
|
4507 | if (el.scopedSlots) {
|
4508 | data += (genScopedSlots(el, el.scopedSlots, state)) + ",";
|
4509 | }
|
4510 |
|
4511 | if (el.model) {
|
4512 | data += "model:{value:" + (el.model.value) + ",callback:" + (el.model.callback) + ",expression:" + (el.model.expression) + "},";
|
4513 | }
|
4514 |
|
4515 | if (el.inlineTemplate) {
|
4516 | var inlineTemplate = genInlineTemplate(el, state);
|
4517 | if (inlineTemplate) {
|
4518 | data += inlineTemplate + ",";
|
4519 | }
|
4520 | }
|
4521 | data = data.replace(/,$/, '') + '}';
|
4522 |
|
4523 |
|
4524 |
|
4525 | if (el.dynamicAttrs) {
|
4526 | data = "_b(" + data + ",\"" + (el.tag) + "\"," + (genProps(el.dynamicAttrs)) + ")";
|
4527 | }
|
4528 |
|
4529 | if (el.wrapData) {
|
4530 | data = el.wrapData(data);
|
4531 | }
|
4532 |
|
4533 | if (el.wrapListeners) {
|
4534 | data = el.wrapListeners(data);
|
4535 | }
|
4536 | return data
|
4537 | }
|
4538 |
|
4539 | function genDirectives (el, state) {
|
4540 | var dirs = el.directives;
|
4541 | if (!dirs) { return }
|
4542 | var res = 'directives:[';
|
4543 | var hasRuntime = false;
|
4544 | var i, l, dir, needRuntime;
|
4545 | for (i = 0, l = dirs.length; i < l; i++) {
|
4546 | dir = dirs[i];
|
4547 | needRuntime = true;
|
4548 | var gen = state.directives[dir.name];
|
4549 | if (gen) {
|
4550 |
|
4551 |
|
4552 | needRuntime = !!gen(el, dir, state.warn);
|
4553 | }
|
4554 | if (needRuntime) {
|
4555 | hasRuntime = true;
|
4556 | res += "{name:\"" + (dir.name) + "\",rawName:\"" + (dir.rawName) + "\"" + (dir.value ? (",value:(" + (dir.value) + "),expression:" + (JSON.stringify(dir.value))) : '') + (dir.arg ? (",arg:" + (dir.isDynamicArg ? dir.arg : ("\"" + (dir.arg) + "\""))) : '') + (dir.modifiers ? (",modifiers:" + (JSON.stringify(dir.modifiers))) : '') + "},";
|
4557 | }
|
4558 | }
|
4559 | if (hasRuntime) {
|
4560 | return res.slice(0, -1) + ']'
|
4561 | }
|
4562 | }
|
4563 |
|
4564 | function genInlineTemplate (el, state) {
|
4565 | var ast = el.children[0];
|
4566 | if (el.children.length !== 1 || ast.type !== 1) {
|
4567 | state.warn(
|
4568 | 'Inline-template components must have exactly one child element.',
|
4569 | { start: el.start }
|
4570 | );
|
4571 | }
|
4572 | if (ast && ast.type === 1) {
|
4573 | var inlineRenderFns = generate(ast, state.options);
|
4574 | return ("inlineTemplate:{render:function(){" + (inlineRenderFns.render) + "},staticRenderFns:[" + (inlineRenderFns.staticRenderFns.map(function (code) { return ("function(){" + code + "}"); }).join(',')) + "]}")
|
4575 | }
|
4576 | }
|
4577 |
|
4578 | function genScopedSlots (
|
4579 | el,
|
4580 | slots,
|
4581 | state
|
4582 | ) {
|
4583 |
|
4584 |
|
4585 |
|
4586 |
|
4587 | var needsForceUpdate = el.for || Object.keys(slots).some(function (key) {
|
4588 | var slot = slots[key];
|
4589 | return (
|
4590 | slot.slotTargetDynamic ||
|
4591 | slot.if ||
|
4592 | slot.for ||
|
4593 | containsSlotChild(slot)
|
4594 | )
|
4595 | });
|
4596 |
|
4597 |
|
4598 |
|
4599 |
|
4600 |
|
4601 | var needsKey = !!el.if;
|
4602 |
|
4603 |
|
4604 |
|
4605 |
|
4606 |
|
4607 |
|
4608 | if (!needsForceUpdate) {
|
4609 | var parent = el.parent;
|
4610 | while (parent) {
|
4611 | if (
|
4612 | (parent.slotScope && parent.slotScope !== emptySlotScopeToken) ||
|
4613 | parent.for
|
4614 | ) {
|
4615 | needsForceUpdate = true;
|
4616 | break
|
4617 | }
|
4618 | if (parent.if) {
|
4619 | needsKey = true;
|
4620 | }
|
4621 | parent = parent.parent;
|
4622 | }
|
4623 | }
|
4624 |
|
4625 | var generatedSlots = Object.keys(slots)
|
4626 | .map(function (key) { return genScopedSlot(slots[key], state); })
|
4627 | .join(',');
|
4628 |
|
4629 | return ("scopedSlots:_u([" + generatedSlots + "]" + (needsForceUpdate ? ",null,true" : "") + (!needsForceUpdate && needsKey ? (",null,false," + (hash(generatedSlots))) : "") + ")")
|
4630 | }
|
4631 |
|
4632 | function hash(str) {
|
4633 | var hash = 5381;
|
4634 | var i = str.length;
|
4635 | while(i) {
|
4636 | hash = (hash * 33) ^ str.charCodeAt(--i);
|
4637 | }
|
4638 | return hash >>> 0
|
4639 | }
|
4640 |
|
4641 | function containsSlotChild (el) {
|
4642 | if (el.type === 1) {
|
4643 | if (el.tag === 'slot') {
|
4644 | return true
|
4645 | }
|
4646 | return el.children.some(containsSlotChild)
|
4647 | }
|
4648 | return false
|
4649 | }
|
4650 |
|
4651 | function genScopedSlot (
|
4652 | el,
|
4653 | state
|
4654 | ) {
|
4655 | var isLegacySyntax = el.attrsMap['slot-scope'];
|
4656 | if (el.if && !el.ifProcessed && !isLegacySyntax) {
|
4657 | return genIf(el, state, genScopedSlot, "null")
|
4658 | }
|
4659 | if (el.for && !el.forProcessed) {
|
4660 | return genFor(el, state, genScopedSlot)
|
4661 | }
|
4662 | var slotScope = el.slotScope === emptySlotScopeToken
|
4663 | ? ""
|
4664 | : String(el.slotScope);
|
4665 | var fn = "function(" + slotScope + "){" +
|
4666 | "return " + (el.tag === 'template'
|
4667 | ? el.if && isLegacySyntax
|
4668 | ? ("(" + (el.if) + ")?" + (genChildren(el, state) || 'undefined') + ":undefined")
|
4669 | : genChildren(el, state) || 'undefined'
|
4670 | : genElement(el, state)) + "}";
|
4671 |
|
4672 | var reverseProxy = slotScope ? "" : ",proxy:true";
|
4673 | return ("{key:" + (el.slotTarget || "\"default\"") + ",fn:" + fn + reverseProxy + "}")
|
4674 | }
|
4675 |
|
4676 | function genChildren (
|
4677 | el,
|
4678 | state,
|
4679 | checkSkip,
|
4680 | altGenElement,
|
4681 | altGenNode
|
4682 | ) {
|
4683 | var children = el.children;
|
4684 | if (children.length) {
|
4685 | var el$1 = children[0];
|
4686 |
|
4687 | if (children.length === 1 &&
|
4688 | el$1.for &&
|
4689 | el$1.tag !== 'template' &&
|
4690 | el$1.tag !== 'slot'
|
4691 | ) {
|
4692 | var normalizationType = checkSkip
|
4693 | ? state.maybeComponent(el$1) ? ",1" : ",0"
|
4694 | : "";
|
4695 | return ("" + ((altGenElement || genElement)(el$1, state)) + normalizationType)
|
4696 | }
|
4697 | var normalizationType$1 = checkSkip
|
4698 | ? getNormalizationType(children, state.maybeComponent)
|
4699 | : 0;
|
4700 | var gen = altGenNode || genNode;
|
4701 | return ("[" + (children.map(function (c) { return gen(c, state); }).join(',')) + "]" + (normalizationType$1 ? ("," + normalizationType$1) : ''))
|
4702 | }
|
4703 | }
|
4704 |
|
4705 |
|
4706 |
|
4707 |
|
4708 |
|
4709 | function getNormalizationType (
|
4710 | children,
|
4711 | maybeComponent
|
4712 | ) {
|
4713 | var res = 0;
|
4714 | for (var i = 0; i < children.length; i++) {
|
4715 | var el = children[i];
|
4716 | if (el.type !== 1) {
|
4717 | continue
|
4718 | }
|
4719 | if (needsNormalization(el) ||
|
4720 | (el.ifConditions && el.ifConditions.some(function (c) { return needsNormalization(c.block); }))) {
|
4721 | res = 2;
|
4722 | break
|
4723 | }
|
4724 | if (maybeComponent(el) ||
|
4725 | (el.ifConditions && el.ifConditions.some(function (c) { return maybeComponent(c.block); }))) {
|
4726 | res = 1;
|
4727 | }
|
4728 | }
|
4729 | return res
|
4730 | }
|
4731 |
|
4732 | function needsNormalization (el) {
|
4733 | return el.for !== undefined || el.tag === 'template' || el.tag === 'slot'
|
4734 | }
|
4735 |
|
4736 | function genNode (node, state) {
|
4737 | if (node.type === 1) {
|
4738 | return genElement(node, state)
|
4739 | } else if (node.type === 3 && node.isComment) {
|
4740 | return genComment(node)
|
4741 | } else {
|
4742 | return genText(node)
|
4743 | }
|
4744 | }
|
4745 |
|
4746 | function genText (text) {
|
4747 | return ("_v(" + (text.type === 2
|
4748 | ? text.expression
|
4749 | : transformSpecialNewlines(JSON.stringify(text.text))) + ")")
|
4750 | }
|
4751 |
|
4752 | function genComment (comment) {
|
4753 | return ("_e(" + (JSON.stringify(comment.text)) + ")")
|
4754 | }
|
4755 |
|
4756 | function genSlot (el, state) {
|
4757 | var slotName = el.slotName || '"default"';
|
4758 | var children = genChildren(el, state);
|
4759 | var res = "_t(" + slotName + (children ? ("," + children) : '');
|
4760 | var attrs = el.attrs || el.dynamicAttrs
|
4761 | ? genProps((el.attrs || []).concat(el.dynamicAttrs || []).map(function (attr) { return ({
|
4762 |
|
4763 | name: camelize(attr.name),
|
4764 | value: attr.value,
|
4765 | dynamic: attr.dynamic
|
4766 | }); }))
|
4767 | : null;
|
4768 | var bind$$1 = el.attrsMap['v-bind'];
|
4769 | if ((attrs || bind$$1) && !children) {
|
4770 | res += ",null";
|
4771 | }
|
4772 | if (attrs) {
|
4773 | res += "," + attrs;
|
4774 | }
|
4775 | if (bind$$1) {
|
4776 | res += (attrs ? '' : ',null') + "," + bind$$1;
|
4777 | }
|
4778 | return res + ')'
|
4779 | }
|
4780 |
|
4781 |
|
4782 | function genComponent (
|
4783 | componentName,
|
4784 | el,
|
4785 | state
|
4786 | ) {
|
4787 | var children = el.inlineTemplate ? null : genChildren(el, state, true);
|
4788 | return ("_c(" + componentName + "," + (genData$2(el, state)) + (children ? ("," + children) : '') + ")")
|
4789 | }
|
4790 |
|
4791 | function genProps (props) {
|
4792 | var staticProps = "";
|
4793 | var dynamicProps = "";
|
4794 | for (var i = 0; i < props.length; i++) {
|
4795 | var prop = props[i];
|
4796 | var value = transformSpecialNewlines(prop.value);
|
4797 | if (prop.dynamic) {
|
4798 | dynamicProps += (prop.name) + "," + value + ",";
|
4799 | } else {
|
4800 | staticProps += "\"" + (prop.name) + "\":" + value + ",";
|
4801 | }
|
4802 | }
|
4803 | staticProps = "{" + (staticProps.slice(0, -1)) + "}";
|
4804 | if (dynamicProps) {
|
4805 | return ("_d(" + staticProps + ",[" + (dynamicProps.slice(0, -1)) + "])")
|
4806 | } else {
|
4807 | return staticProps
|
4808 | }
|
4809 | }
|
4810 |
|
4811 |
|
4812 | function transformSpecialNewlines (text) {
|
4813 | return text
|
4814 | .replace(/\u2028/g, '\\u2028')
|
4815 | .replace(/\u2029/g, '\\u2029')
|
4816 | }
|
4817 |
|
4818 |
|
4819 |
|
4820 |
|
4821 |
|
4822 |
|
4823 |
|
4824 | var prohibitedKeywordRE = new RegExp('\\b' + (
|
4825 | 'do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +
|
4826 | 'super,throw,while,yield,delete,export,import,return,switch,default,' +
|
4827 | 'extends,finally,continue,debugger,function,arguments'
|
4828 | ).split(',').join('\\b|\\b') + '\\b');
|
4829 |
|
4830 |
|
4831 | var unaryOperatorsRE = new RegExp('\\b' + (
|
4832 | 'delete,typeof,void'
|
4833 | ).split(',').join('\\s*\\([^\\)]*\\)|\\b') + '\\s*\\([^\\)]*\\)');
|
4834 |
|
4835 |
|
4836 | var stripStringRE = /'(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"|`(?:[^`\\]|\\.)*\$\{|\}(?:[^`\\]|\\.)*`|`(?:[^`\\]|\\.)*`/g;
|
4837 |
|
4838 |
|
4839 | function detectErrors (ast, warn) {
|
4840 | if (ast) {
|
4841 | checkNode(ast, warn);
|
4842 | }
|
4843 | }
|
4844 |
|
4845 | function checkNode (node, warn) {
|
4846 | if (node.type === 1) {
|
4847 | for (var name in node.attrsMap) {
|
4848 | if (dirRE.test(name)) {
|
4849 | var value = node.attrsMap[name];
|
4850 | if (value) {
|
4851 | var range = node.rawAttrsMap[name];
|
4852 | if (name === 'v-for') {
|
4853 | checkFor(node, ("v-for=\"" + value + "\""), warn, range);
|
4854 | } else if (name === 'v-slot' || name[0] === '#') {
|
4855 | checkFunctionParameterExpression(value, (name + "=\"" + value + "\""), warn, range);
|
4856 | } else if (onRE.test(name)) {
|
4857 | checkEvent(value, (name + "=\"" + value + "\""), warn, range);
|
4858 | } else {
|
4859 | checkExpression(value, (name + "=\"" + value + "\""), warn, range);
|
4860 | }
|
4861 | }
|
4862 | }
|
4863 | }
|
4864 | if (node.children) {
|
4865 | for (var i = 0; i < node.children.length; i++) {
|
4866 | checkNode(node.children[i], warn);
|
4867 | }
|
4868 | }
|
4869 | } else if (node.type === 2) {
|
4870 | checkExpression(node.expression, node.text, warn, node);
|
4871 | }
|
4872 | }
|
4873 |
|
4874 | function checkEvent (exp, text, warn, range) {
|
4875 | var stripped = exp.replace(stripStringRE, '');
|
4876 | var keywordMatch = stripped.match(unaryOperatorsRE);
|
4877 | if (keywordMatch && stripped.charAt(keywordMatch.index - 1) !== '$') {
|
4878 | warn(
|
4879 | "avoid using JavaScript unary operator as property name: " +
|
4880 | "\"" + (keywordMatch[0]) + "\" in expression " + (text.trim()),
|
4881 | range
|
4882 | );
|
4883 | }
|
4884 | checkExpression(exp, text, warn, range);
|
4885 | }
|
4886 |
|
4887 | function checkFor (node, text, warn, range) {
|
4888 | checkExpression(node.for || '', text, warn, range);
|
4889 | checkIdentifier(node.alias, 'v-for alias', text, warn, range);
|
4890 | checkIdentifier(node.iterator1, 'v-for iterator', text, warn, range);
|
4891 | checkIdentifier(node.iterator2, 'v-for iterator', text, warn, range);
|
4892 | }
|
4893 |
|
4894 | function checkIdentifier (
|
4895 | ident,
|
4896 | type,
|
4897 | text,
|
4898 | warn,
|
4899 | range
|
4900 | ) {
|
4901 | if (typeof ident === 'string') {
|
4902 | try {
|
4903 | new Function(("var " + ident + "=_"));
|
4904 | } catch (e) {
|
4905 | warn(("invalid " + type + " \"" + ident + "\" in expression: " + (text.trim())), range);
|
4906 | }
|
4907 | }
|
4908 | }
|
4909 |
|
4910 | function checkExpression (exp, text, warn, range) {
|
4911 | try {
|
4912 | new Function(("return " + exp));
|
4913 | } catch (e) {
|
4914 | var keywordMatch = exp.replace(stripStringRE, '').match(prohibitedKeywordRE);
|
4915 | if (keywordMatch) {
|
4916 | warn(
|
4917 | "avoid using JavaScript keyword as property name: " +
|
4918 | "\"" + (keywordMatch[0]) + "\"\n Raw expression: " + (text.trim()),
|
4919 | range
|
4920 | );
|
4921 | } else {
|
4922 | warn(
|
4923 | "invalid expression: " + (e.message) + " in\n\n" +
|
4924 | " " + exp + "\n\n" +
|
4925 | " Raw expression: " + (text.trim()) + "\n",
|
4926 | range
|
4927 | );
|
4928 | }
|
4929 | }
|
4930 | }
|
4931 |
|
4932 | function checkFunctionParameterExpression (exp, text, warn, range) {
|
4933 | try {
|
4934 | new Function(exp, '');
|
4935 | } catch (e) {
|
4936 | warn(
|
4937 | "invalid function parameter expression: " + (e.message) + " in\n\n" +
|
4938 | " " + exp + "\n\n" +
|
4939 | " Raw expression: " + (text.trim()) + "\n",
|
4940 | range
|
4941 | );
|
4942 | }
|
4943 | }
|
4944 |
|
4945 |
|
4946 |
|
4947 | var range = 2;
|
4948 |
|
4949 | function generateCodeFrame (
|
4950 | source,
|
4951 | start,
|
4952 | end
|
4953 | ) {
|
4954 | if ( start === void 0 ) start = 0;
|
4955 | if ( end === void 0 ) end = source.length;
|
4956 |
|
4957 | var lines = source.split(/\r?\n/);
|
4958 | var count = 0;
|
4959 | var res = [];
|
4960 | for (var i = 0; i < lines.length; i++) {
|
4961 | count += lines[i].length + 1;
|
4962 | if (count >= start) {
|
4963 | for (var j = i - range; j <= i + range || end > count; j++) {
|
4964 | if (j < 0 || j >= lines.length) { continue }
|
4965 | res.push(("" + (j + 1) + (repeat$1(" ", 3 - String(j + 1).length)) + "| " + (lines[j])));
|
4966 | var lineLength = lines[j].length;
|
4967 | if (j === i) {
|
4968 |
|
4969 | var pad = start - (count - lineLength) + 1;
|
4970 | var length = end > count ? lineLength - pad : end - start;
|
4971 | res.push(" | " + repeat$1(" ", pad) + repeat$1("^", length));
|
4972 | } else if (j > i) {
|
4973 | if (end > count) {
|
4974 | var length$1 = Math.min(end - count, lineLength);
|
4975 | res.push(" | " + repeat$1("^", length$1));
|
4976 | }
|
4977 | count += lineLength + 1;
|
4978 | }
|
4979 | }
|
4980 | break
|
4981 | }
|
4982 | }
|
4983 | return res.join('\n')
|
4984 | }
|
4985 |
|
4986 | function repeat$1 (str, n) {
|
4987 | var result = '';
|
4988 | if (n > 0) {
|
4989 | while (true) {
|
4990 | if (n & 1) { result += str; }
|
4991 | n >>>= 1;
|
4992 | if (n <= 0) { break }
|
4993 | str += str;
|
4994 | }
|
4995 | }
|
4996 | return result
|
4997 | }
|
4998 |
|
4999 |
|
5000 |
|
5001 |
|
5002 |
|
5003 | function createFunction (code, errors) {
|
5004 | try {
|
5005 | return new Function(code)
|
5006 | } catch (err) {
|
5007 | errors.push({ err: err, code: code });
|
5008 | return noop
|
5009 | }
|
5010 | }
|
5011 |
|
5012 | function createCompileToFunctionFn (compile) {
|
5013 | var cache = Object.create(null);
|
5014 |
|
5015 | return function compileToFunctions (
|
5016 | template,
|
5017 | options,
|
5018 | vm
|
5019 | ) {
|
5020 | options = extend({}, options);
|
5021 | var warn$$1 = options.warn || warn;
|
5022 | delete options.warn;
|
5023 |
|
5024 |
|
5025 | {
|
5026 |
|
5027 | try {
|
5028 | new Function('return 1');
|
5029 | } catch (e) {
|
5030 | if (e.toString().match(/unsafe-eval|CSP/)) {
|
5031 | warn$$1(
|
5032 | 'It seems you are using the standalone build of Vue.js in an ' +
|
5033 | 'environment with Content Security Policy that prohibits unsafe-eval. ' +
|
5034 | 'The template compiler cannot work in this environment. Consider ' +
|
5035 | 'relaxing the policy to allow unsafe-eval or pre-compiling your ' +
|
5036 | 'templates into render functions.'
|
5037 | );
|
5038 | }
|
5039 | }
|
5040 | }
|
5041 |
|
5042 |
|
5043 | var key = options.delimiters
|
5044 | ? String(options.delimiters) + template
|
5045 | : template;
|
5046 | if (cache[key]) {
|
5047 | return cache[key]
|
5048 | }
|
5049 |
|
5050 |
|
5051 | var compiled = compile(template, options);
|
5052 |
|
5053 |
|
5054 | {
|
5055 | if (compiled.errors && compiled.errors.length) {
|
5056 | if (options.outputSourceRange) {
|
5057 | compiled.errors.forEach(function (e) {
|
5058 | warn$$1(
|
5059 | "Error compiling template:\n\n" + (e.msg) + "\n\n" +
|
5060 | generateCodeFrame(template, e.start, e.end),
|
5061 | vm
|
5062 | );
|
5063 | });
|
5064 | } else {
|
5065 | warn$$1(
|
5066 | "Error compiling template:\n\n" + template + "\n\n" +
|
5067 | compiled.errors.map(function (e) { return ("- " + e); }).join('\n') + '\n',
|
5068 | vm
|
5069 | );
|
5070 | }
|
5071 | }
|
5072 | if (compiled.tips && compiled.tips.length) {
|
5073 | if (options.outputSourceRange) {
|
5074 | compiled.tips.forEach(function (e) { return tip(e.msg, vm); });
|
5075 | } else {
|
5076 | compiled.tips.forEach(function (msg) { return tip(msg, vm); });
|
5077 | }
|
5078 | }
|
5079 | }
|
5080 |
|
5081 |
|
5082 | var res = {};
|
5083 | var fnGenErrors = [];
|
5084 | res.render = createFunction(compiled.render, fnGenErrors);
|
5085 | res.staticRenderFns = compiled.staticRenderFns.map(function (code) {
|
5086 | return createFunction(code, fnGenErrors)
|
5087 | });
|
5088 |
|
5089 |
|
5090 |
|
5091 |
|
5092 |
|
5093 | {
|
5094 | if ((!compiled.errors || !compiled.errors.length) && fnGenErrors.length) {
|
5095 | warn$$1(
|
5096 | "Failed to generate render function:\n\n" +
|
5097 | fnGenErrors.map(function (ref) {
|
5098 | var err = ref.err;
|
5099 | var code = ref.code;
|
5100 |
|
5101 | return ((err.toString()) + " in\n\n" + code + "\n");
|
5102 | }).join('\n'),
|
5103 | vm
|
5104 | );
|
5105 | }
|
5106 | }
|
5107 |
|
5108 | return (cache[key] = res)
|
5109 | }
|
5110 | }
|
5111 |
|
5112 |
|
5113 |
|
5114 | function createCompilerCreator (baseCompile) {
|
5115 | return function createCompiler (baseOptions) {
|
5116 | function compile (
|
5117 | template,
|
5118 | options
|
5119 | ) {
|
5120 | var finalOptions = Object.create(baseOptions);
|
5121 | var errors = [];
|
5122 | var tips = [];
|
5123 |
|
5124 | var warn = function (msg, range, tip) {
|
5125 | (tip ? tips : errors).push(msg);
|
5126 | };
|
5127 |
|
5128 | if (options) {
|
5129 | if (options.outputSourceRange) {
|
5130 |
|
5131 | var leadingSpaceLength = template.match(/^\s*/)[0].length;
|
5132 |
|
5133 | warn = function (msg, range, tip) {
|
5134 | var data = { msg: msg };
|
5135 | if (range) {
|
5136 | if (range.start != null) {
|
5137 | data.start = range.start + leadingSpaceLength;
|
5138 | }
|
5139 | if (range.end != null) {
|
5140 | data.end = range.end + leadingSpaceLength;
|
5141 | }
|
5142 | }
|
5143 | (tip ? tips : errors).push(data);
|
5144 | };
|
5145 | }
|
5146 |
|
5147 | if (options.modules) {
|
5148 | finalOptions.modules =
|
5149 | (baseOptions.modules || []).concat(options.modules);
|
5150 | }
|
5151 |
|
5152 | if (options.directives) {
|
5153 | finalOptions.directives = extend(
|
5154 | Object.create(baseOptions.directives || null),
|
5155 | options.directives
|
5156 | );
|
5157 | }
|
5158 |
|
5159 | for (var key in options) {
|
5160 | if (key !== 'modules' && key !== 'directives') {
|
5161 | finalOptions[key] = options[key];
|
5162 | }
|
5163 | }
|
5164 | }
|
5165 |
|
5166 | finalOptions.warn = warn;
|
5167 |
|
5168 | var compiled = baseCompile(template.trim(), finalOptions);
|
5169 | {
|
5170 | detectErrors(compiled.ast, warn);
|
5171 | }
|
5172 | compiled.errors = errors;
|
5173 | compiled.tips = tips;
|
5174 | return compiled
|
5175 | }
|
5176 |
|
5177 | return {
|
5178 | compile: compile,
|
5179 | compileToFunctions: createCompileToFunctionFn(compile)
|
5180 | }
|
5181 | }
|
5182 | }
|
5183 |
|
5184 |
|
5185 |
|
5186 |
|
5187 |
|
5188 |
|
5189 | var createCompiler = createCompilerCreator(function baseCompile (
|
5190 | template,
|
5191 | options
|
5192 | ) {
|
5193 | var ast = parse(template.trim(), options);
|
5194 | if (options.optimize !== false) {
|
5195 | optimize(ast, options);
|
5196 | }
|
5197 | var code = generate(ast, options);
|
5198 | return {
|
5199 | ast: ast,
|
5200 | render: code.render,
|
5201 | staticRenderFns: code.staticRenderFns
|
5202 | }
|
5203 | });
|
5204 |
|
5205 |
|
5206 |
|
5207 | var ref = createCompiler(baseOptions);
|
5208 | var compile = ref.compile;
|
5209 | var compileToFunctions = ref.compileToFunctions;
|
5210 |
|
5211 |
|
5212 |
|
5213 | var isAttr = makeMap(
|
5214 | 'accept,accept-charset,accesskey,action,align,alt,async,autocomplete,' +
|
5215 | 'autofocus,autoplay,autosave,bgcolor,border,buffered,challenge,charset,' +
|
5216 | 'checked,cite,class,code,codebase,color,cols,colspan,content,' +
|
5217 | 'contenteditable,contextmenu,controls,coords,data,datetime,default,' +
|
5218 | 'defer,dir,dirname,disabled,download,draggable,dropzone,enctype,for,' +
|
5219 | 'form,formaction,headers,height,hidden,high,href,hreflang,http-equiv,' +
|
5220 | 'icon,id,ismap,itemprop,keytype,kind,label,lang,language,list,loop,low,' +
|
5221 | 'manifest,max,maxlength,media,method,GET,POST,min,multiple,email,file,' +
|
5222 | 'muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,' +
|
5223 | 'preload,radiogroup,readonly,rel,required,reversed,rows,rowspan,sandbox,' +
|
5224 | 'scope,scoped,seamless,selected,shape,size,type,text,password,sizes,span,' +
|
5225 | 'spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,' +
|
5226 | 'target,title,usemap,value,width,wrap'
|
5227 | );
|
5228 |
|
5229 |
|
5230 | var isRenderableAttr = function (name) {
|
5231 | return (
|
5232 | isAttr(name) ||
|
5233 | name.indexOf('data-') === 0 ||
|
5234 | name.indexOf('aria-') === 0
|
5235 | )
|
5236 | };
|
5237 |
|
5238 | var propsToAttrMap = {
|
5239 | acceptCharset: 'accept-charset',
|
5240 | className: 'class',
|
5241 | htmlFor: 'for',
|
5242 | httpEquiv: 'http-equiv'
|
5243 | };
|
5244 |
|
5245 | var ESC = {
|
5246 | '<': '<',
|
5247 | '>': '>',
|
5248 | '"': '"',
|
5249 | '&': '&'
|
5250 | };
|
5251 |
|
5252 | function escape (s) {
|
5253 | return s.replace(/[<>"&]/g, escapeChar)
|
5254 | }
|
5255 |
|
5256 | function escapeChar (a) {
|
5257 | return ESC[a] || a
|
5258 | }
|
5259 |
|
5260 |
|
5261 |
|
5262 |
|
5263 |
|
5264 |
|
5265 | var plainStringRE = /^"(?:[^"\\]|\\.)*"$|^'(?:[^'\\]|\\.)*'$/;
|
5266 |
|
5267 |
|
5268 |
|
5269 | function applyModelTransform (el, state) {
|
5270 | if (el.directives) {
|
5271 | for (var i = 0; i < el.directives.length; i++) {
|
5272 | var dir = el.directives[i];
|
5273 | if (dir.name === 'model') {
|
5274 | state.directives.model(el, dir, state.warn);
|
5275 |
|
5276 | if (el.tag === 'textarea' && el.props) {
|
5277 | el.props = el.props.filter(function (p) { return p.name !== 'value'; });
|
5278 | }
|
5279 | break
|
5280 | }
|
5281 | }
|
5282 | }
|
5283 | }
|
5284 |
|
5285 | function genAttrSegments (
|
5286 | attrs
|
5287 | ) {
|
5288 | return attrs.map(function (ref) {
|
5289 | var name = ref.name;
|
5290 | var value = ref.value;
|
5291 |
|
5292 | return genAttrSegment(name, value);
|
5293 | })
|
5294 | }
|
5295 |
|
5296 | function genDOMPropSegments (
|
5297 | props,
|
5298 | attrs
|
5299 | ) {
|
5300 | var segments = [];
|
5301 | props.forEach(function (ref) {
|
5302 | var name = ref.name;
|
5303 | var value = ref.value;
|
5304 |
|
5305 | name = propsToAttrMap[name] || name.toLowerCase();
|
5306 | if (isRenderableAttr(name) &&
|
5307 | !(attrs && attrs.some(function (a) { return a.name === name; }))
|
5308 | ) {
|
5309 | segments.push(genAttrSegment(name, value));
|
5310 | }
|
5311 | });
|
5312 | return segments
|
5313 | }
|
5314 |
|
5315 | function genAttrSegment (name, value) {
|
5316 | if (plainStringRE.test(value)) {
|
5317 |
|
5318 | value = value.replace(/^'|'$/g, '"');
|
5319 |
|
5320 | if (isEnumeratedAttr(name) && value !== "\"false\"") {
|
5321 | value = "\"true\"";
|
5322 | }
|
5323 | return {
|
5324 | type: RAW,
|
5325 | value: isBooleanAttr(name)
|
5326 | ? (" " + name + "=\"" + name + "\"")
|
5327 | : value === '""'
|
5328 | ? (" " + name)
|
5329 | : (" " + name + "=\"" + (JSON.parse(value)) + "\"")
|
5330 | }
|
5331 | } else {
|
5332 | return {
|
5333 | type: EXPRESSION,
|
5334 | value: ("_ssrAttr(" + (JSON.stringify(name)) + "," + value + ")")
|
5335 | }
|
5336 | }
|
5337 | }
|
5338 |
|
5339 | function genClassSegments (
|
5340 | staticClass,
|
5341 | classBinding
|
5342 | ) {
|
5343 | if (staticClass && !classBinding) {
|
5344 | return [{ type: RAW, value: (" class=\"" + (JSON.parse(staticClass)) + "\"") }]
|
5345 | } else {
|
5346 | return [{
|
5347 | type: EXPRESSION,
|
5348 | value: ("_ssrClass(" + (staticClass || 'null') + "," + (classBinding || 'null') + ")")
|
5349 | }]
|
5350 | }
|
5351 | }
|
5352 |
|
5353 | function genStyleSegments (
|
5354 | staticStyle,
|
5355 | parsedStaticStyle,
|
5356 | styleBinding,
|
5357 | vShowExpression
|
5358 | ) {
|
5359 | if (staticStyle && !styleBinding && !vShowExpression) {
|
5360 | return [{ type: RAW, value: (" style=" + (JSON.stringify(staticStyle))) }]
|
5361 | } else {
|
5362 | return [{
|
5363 | type: EXPRESSION,
|
5364 | value: ("_ssrStyle(" + (parsedStaticStyle || 'null') + "," + (styleBinding || 'null') + ", " + (vShowExpression
|
5365 | ? ("{ display: (" + vShowExpression + ") ? '' : 'none' }")
|
5366 | : 'null') + ")")
|
5367 | }]
|
5368 | }
|
5369 | }
|
5370 |
|
5371 |
|
5372 |
|
5373 |
|
5374 | var optimizability = {
|
5375 | FALSE: 0,
|
5376 | FULL: 1,
|
5377 | SELF: 2,
|
5378 | CHILDREN: 3,
|
5379 | PARTIAL: 4
|
5380 | };
|
5381 |
|
5382 | var isPlatformReservedTag$1;
|
5383 |
|
5384 | function optimize$1 (root, options) {
|
5385 | if (!root) { return }
|
5386 | isPlatformReservedTag$1 = options.isReservedTag || no;
|
5387 | walk(root, true);
|
5388 | }
|
5389 |
|
5390 | function walk (node, isRoot) {
|
5391 | if (isUnOptimizableTree(node)) {
|
5392 | node.ssrOptimizability = optimizability.FALSE;
|
5393 | return
|
5394 | }
|
5395 |
|
5396 | var selfUnoptimizable = isRoot || hasCustomDirective(node);
|
5397 | var check = function (child) {
|
5398 | if (child.ssrOptimizability !== optimizability.FULL) {
|
5399 | node.ssrOptimizability = selfUnoptimizable
|
5400 | ? optimizability.PARTIAL
|
5401 | : optimizability.SELF;
|
5402 | }
|
5403 | };
|
5404 | if (selfUnoptimizable) {
|
5405 | node.ssrOptimizability = optimizability.CHILDREN;
|
5406 | }
|
5407 | if (node.type === 1) {
|
5408 | for (var i = 0, l = node.children.length; i < l; i++) {
|
5409 | var child = node.children[i];
|
5410 | walk(child);
|
5411 | check(child);
|
5412 | }
|
5413 | if (node.ifConditions) {
|
5414 | for (var i$1 = 1, l$1 = node.ifConditions.length; i$1 < l$1; i$1++) {
|
5415 | var block = node.ifConditions[i$1].block;
|
5416 | walk(block, isRoot);
|
5417 | check(block);
|
5418 | }
|
5419 | }
|
5420 | if (node.ssrOptimizability == null ||
|
5421 | (!isRoot && (node.attrsMap['v-html'] || node.attrsMap['v-text']))
|
5422 | ) {
|
5423 | node.ssrOptimizability = optimizability.FULL;
|
5424 | } else {
|
5425 | node.children = optimizeSiblings(node);
|
5426 | }
|
5427 | } else {
|
5428 | node.ssrOptimizability = optimizability.FULL;
|
5429 | }
|
5430 | }
|
5431 |
|
5432 | function optimizeSiblings (el) {
|
5433 | var children = el.children;
|
5434 | var optimizedChildren = [];
|
5435 |
|
5436 | var currentOptimizableGroup = [];
|
5437 | var pushGroup = function () {
|
5438 | if (currentOptimizableGroup.length) {
|
5439 | optimizedChildren.push({
|
5440 | type: 1,
|
5441 | parent: el,
|
5442 | tag: 'template',
|
5443 | attrsList: [],
|
5444 | attrsMap: {},
|
5445 | rawAttrsMap: {},
|
5446 | children: currentOptimizableGroup,
|
5447 | ssrOptimizability: optimizability.FULL
|
5448 | });
|
5449 | }
|
5450 | currentOptimizableGroup = [];
|
5451 | };
|
5452 |
|
5453 | for (var i = 0; i < children.length; i++) {
|
5454 | var c = children[i];
|
5455 | if (c.ssrOptimizability === optimizability.FULL) {
|
5456 | currentOptimizableGroup.push(c);
|
5457 | } else {
|
5458 |
|
5459 |
|
5460 | pushGroup();
|
5461 | optimizedChildren.push(c);
|
5462 | }
|
5463 | }
|
5464 | pushGroup();
|
5465 | return optimizedChildren
|
5466 | }
|
5467 |
|
5468 | function isUnOptimizableTree (node) {
|
5469 | if (node.type === 2 || node.type === 3) {
|
5470 | return false
|
5471 | }
|
5472 | return (
|
5473 | isBuiltInTag(node.tag) ||
|
5474 | !isPlatformReservedTag$1(node.tag) ||
|
5475 | !!node.component ||
|
5476 | isSelectWithModel(node)
|
5477 | )
|
5478 | }
|
5479 |
|
5480 | var isBuiltInDir = makeMap('text,html,show,on,bind,model,pre,cloak,once');
|
5481 |
|
5482 | function hasCustomDirective (node) {
|
5483 | return (
|
5484 | node.type === 1 &&
|
5485 | node.directives &&
|
5486 | node.directives.some(function (d) { return !isBuiltInDir(d.name); })
|
5487 | )
|
5488 | }
|
5489 |
|
5490 |
|
5491 |
|
5492 | function isSelectWithModel (node) {
|
5493 | return (
|
5494 | node.type === 1 &&
|
5495 | node.tag === 'select' &&
|
5496 | node.directives != null &&
|
5497 | node.directives.some(function (d) { return d.name === 'model'; })
|
5498 | )
|
5499 | }
|
5500 |
|
5501 |
|
5502 |
|
5503 |
|
5504 |
|
5505 |
|
5506 |
|
5507 | var RAW = 0;
|
5508 | var INTERPOLATION = 1;
|
5509 | var EXPRESSION = 2;
|
5510 |
|
5511 | function generate$1 (
|
5512 | ast,
|
5513 | options
|
5514 | ) {
|
5515 | var state = new CodegenState(options);
|
5516 | var code = ast ? genSSRElement(ast, state) : '_c("div")';
|
5517 | return {
|
5518 | render: ("with(this){return " + code + "}"),
|
5519 | staticRenderFns: state.staticRenderFns
|
5520 | }
|
5521 | }
|
5522 |
|
5523 | function genSSRElement (el, state) {
|
5524 | if (el.for && !el.forProcessed) {
|
5525 | return genFor(el, state, genSSRElement)
|
5526 | } else if (el.if && !el.ifProcessed) {
|
5527 | return genIf(el, state, genSSRElement)
|
5528 | } else if (el.tag === 'template' && !el.slotTarget) {
|
5529 | return el.ssrOptimizability === optimizability.FULL
|
5530 | ? genChildrenAsStringNode(el, state)
|
5531 | : genSSRChildren(el, state) || 'void 0'
|
5532 | }
|
5533 |
|
5534 | switch (el.ssrOptimizability) {
|
5535 | case optimizability.FULL:
|
5536 |
|
5537 | return genStringElement(el, state)
|
5538 | case optimizability.SELF:
|
5539 |
|
5540 | return genStringElementWithChildren(el, state)
|
5541 | case optimizability.CHILDREN:
|
5542 |
|
5543 | return genNormalElement(el, state, true)
|
5544 | case optimizability.PARTIAL:
|
5545 |
|
5546 | return genNormalElement(el, state, false)
|
5547 | default:
|
5548 |
|
5549 | return genElement(el, state)
|
5550 | }
|
5551 | }
|
5552 |
|
5553 | function genNormalElement (el, state, stringifyChildren) {
|
5554 | var data = el.plain ? undefined : genData$2(el, state);
|
5555 | var children = stringifyChildren
|
5556 | ? ("[" + (genChildrenAsStringNode(el, state)) + "]")
|
5557 | : genSSRChildren(el, state, true);
|
5558 | return ("_c('" + (el.tag) + "'" + (data ? ("," + data) : '') + (children ? ("," + children) : '') + ")")
|
5559 | }
|
5560 |
|
5561 | function genSSRChildren (el, state, checkSkip) {
|
5562 | return genChildren(el, state, checkSkip, genSSRElement, genSSRNode)
|
5563 | }
|
5564 |
|
5565 | function genSSRNode (el, state) {
|
5566 | return el.type === 1
|
5567 | ? genSSRElement(el, state)
|
5568 | : genText(el)
|
5569 | }
|
5570 |
|
5571 | function genChildrenAsStringNode (el, state) {
|
5572 | return el.children.length
|
5573 | ? ("_ssrNode(" + (flattenSegments(childrenToSegments(el, state))) + ")")
|
5574 | : ''
|
5575 | }
|
5576 |
|
5577 | function genStringElement (el, state) {
|
5578 | return ("_ssrNode(" + (elementToString(el, state)) + ")")
|
5579 | }
|
5580 |
|
5581 | function genStringElementWithChildren (el, state) {
|
5582 | var children = genSSRChildren(el, state, true);
|
5583 | return ("_ssrNode(" + (flattenSegments(elementToOpenTagSegments(el, state))) + ",\"</" + (el.tag) + ">\"" + (children ? ("," + children) : '') + ")")
|
5584 | }
|
5585 |
|
5586 | function elementToString (el, state) {
|
5587 | return ("(" + (flattenSegments(elementToSegments(el, state))) + ")")
|
5588 | }
|
5589 |
|
5590 | function elementToSegments (el, state) {
|
5591 |
|
5592 | if (el.for && !el.forProcessed) {
|
5593 | el.forProcessed = true;
|
5594 | return [{
|
5595 | type: EXPRESSION,
|
5596 | value: genFor(el, state, elementToString, '_ssrList')
|
5597 | }]
|
5598 | } else if (el.if && !el.ifProcessed) {
|
5599 | el.ifProcessed = true;
|
5600 | return [{
|
5601 | type: EXPRESSION,
|
5602 | value: genIf(el, state, elementToString, '"<!---->"')
|
5603 | }]
|
5604 | } else if (el.tag === 'template') {
|
5605 | return childrenToSegments(el, state)
|
5606 | }
|
5607 |
|
5608 | var openSegments = elementToOpenTagSegments(el, state);
|
5609 | var childrenSegments = childrenToSegments(el, state);
|
5610 | var ref = state.options;
|
5611 | var isUnaryTag = ref.isUnaryTag;
|
5612 | var close = (isUnaryTag && isUnaryTag(el.tag))
|
5613 | ? []
|
5614 | : [{ type: RAW, value: ("</" + (el.tag) + ">") }];
|
5615 | return openSegments.concat(childrenSegments, close)
|
5616 | }
|
5617 |
|
5618 | function elementToOpenTagSegments (el, state) {
|
5619 | applyModelTransform(el, state);
|
5620 | var binding;
|
5621 | var segments = [{ type: RAW, value: ("<" + (el.tag)) }];
|
5622 |
|
5623 | if (el.attrs) {
|
5624 | segments.push.apply(segments, genAttrSegments(el.attrs));
|
5625 | }
|
5626 |
|
5627 | if (el.props) {
|
5628 | segments.push.apply(segments, genDOMPropSegments(el.props, el.attrs));
|
5629 | }
|
5630 |
|
5631 | if ((binding = el.attrsMap['v-bind'])) {
|
5632 | segments.push({ type: EXPRESSION, value: ("_ssrAttrs(" + binding + ")") });
|
5633 | }
|
5634 |
|
5635 | if ((binding = el.attrsMap['v-bind.prop'])) {
|
5636 | segments.push({ type: EXPRESSION, value: ("_ssrDOMProps(" + binding + ")") });
|
5637 | }
|
5638 |
|
5639 | if (el.staticClass || el.classBinding) {
|
5640 | segments.push.apply(
|
5641 | segments,
|
5642 | genClassSegments(el.staticClass, el.classBinding)
|
5643 | );
|
5644 | }
|
5645 |
|
5646 | if (el.staticStyle || el.styleBinding || el.attrsMap['v-show']) {
|
5647 | segments.push.apply(
|
5648 | segments,
|
5649 | genStyleSegments(
|
5650 | el.attrsMap.style,
|
5651 | el.staticStyle,
|
5652 | el.styleBinding,
|
5653 | el.attrsMap['v-show']
|
5654 | )
|
5655 | );
|
5656 | }
|
5657 |
|
5658 | if (state.options.scopeId) {
|
5659 | segments.push({ type: RAW, value: (" " + (state.options.scopeId)) });
|
5660 | }
|
5661 | segments.push({ type: RAW, value: ">" });
|
5662 | return segments
|
5663 | }
|
5664 |
|
5665 | function childrenToSegments (el, state) {
|
5666 | var binding;
|
5667 | if ((binding = el.attrsMap['v-html'])) {
|
5668 | return [{ type: EXPRESSION, value: ("_s(" + binding + ")") }]
|
5669 | }
|
5670 | if ((binding = el.attrsMap['v-text'])) {
|
5671 | return [{ type: INTERPOLATION, value: ("_s(" + binding + ")") }]
|
5672 | }
|
5673 | if (el.tag === 'textarea' && (binding = el.attrsMap['v-model'])) {
|
5674 | return [{ type: INTERPOLATION, value: ("_s(" + binding + ")") }]
|
5675 | }
|
5676 | return el.children
|
5677 | ? nodesToSegments(el.children, state)
|
5678 | : []
|
5679 | }
|
5680 |
|
5681 | function nodesToSegments (
|
5682 | children,
|
5683 | state
|
5684 | ) {
|
5685 | var segments = [];
|
5686 | for (var i = 0; i < children.length; i++) {
|
5687 | var c = children[i];
|
5688 | if (c.type === 1) {
|
5689 | segments.push.apply(segments, elementToSegments(c, state));
|
5690 | } else if (c.type === 2) {
|
5691 | segments.push({ type: INTERPOLATION, value: c.expression });
|
5692 | } else if (c.type === 3) {
|
5693 | var text = escape(c.text);
|
5694 | if (c.isComment) {
|
5695 | text = '<!--' + text + '-->';
|
5696 | }
|
5697 | segments.push({ type: RAW, value: text });
|
5698 | }
|
5699 | }
|
5700 | return segments
|
5701 | }
|
5702 |
|
5703 | function flattenSegments (segments) {
|
5704 | var mergedSegments = [];
|
5705 | var textBuffer = '';
|
5706 |
|
5707 | var pushBuffer = function () {
|
5708 | if (textBuffer) {
|
5709 | mergedSegments.push(JSON.stringify(textBuffer));
|
5710 | textBuffer = '';
|
5711 | }
|
5712 | };
|
5713 |
|
5714 | for (var i = 0; i < segments.length; i++) {
|
5715 | var s = segments[i];
|
5716 | if (s.type === RAW) {
|
5717 | textBuffer += s.value;
|
5718 | } else if (s.type === INTERPOLATION) {
|
5719 | pushBuffer();
|
5720 | mergedSegments.push(("_ssrEscape(" + (s.value) + ")"));
|
5721 | } else if (s.type === EXPRESSION) {
|
5722 | pushBuffer();
|
5723 | mergedSegments.push(("(" + (s.value) + ")"));
|
5724 | }
|
5725 | }
|
5726 | pushBuffer();
|
5727 |
|
5728 | return mergedSegments.join('+')
|
5729 | }
|
5730 |
|
5731 |
|
5732 |
|
5733 | var createCompiler$1 = createCompilerCreator(function baseCompile (
|
5734 | template,
|
5735 | options
|
5736 | ) {
|
5737 | var ast = parse(template.trim(), options);
|
5738 | optimize$1(ast, options);
|
5739 | var code = generate$1(ast, options);
|
5740 | return {
|
5741 | ast: ast,
|
5742 | render: code.render,
|
5743 | staticRenderFns: code.staticRenderFns
|
5744 | }
|
5745 | });
|
5746 |
|
5747 |
|
5748 |
|
5749 | var ref$1 = createCompiler$1(baseOptions);
|
5750 | var compile$1 = ref$1.compile;
|
5751 | var compileToFunctions$1 = ref$1.compileToFunctions;
|
5752 |
|
5753 |
|
5754 |
|
5755 | exports.parseComponent = parseComponent;
|
5756 | exports.compile = compile;
|
5757 | exports.compileToFunctions = compileToFunctions;
|
5758 | exports.ssrCompile = compile$1;
|
5759 | exports.ssrCompileToFunctions = compileToFunctions$1;
|
5760 | exports.generateCodeFrame = generateCodeFrame;
|
5761 |
|
5762 | Object.defineProperty(exports, '__esModule', { value: true });
|
5763 |
|
5764 | }));
|