/*! highlight.js 0.1.0
 * (c) 2012-2013 Jony Zhang <zj86@live.cn>, MIT Licensed
 * https://github.com/niceue/highlight.js/
 */

!function(e){var Root;$("script[src*=highlight]").each(function(){var e=this.src;if(e.match(/highlight[^\/]*\.js/i)){Root=e.replace(/[\?#].*$/,"").replace(/(^|[\/\\])[^\/]*$/,"$1");return false}});var css=Root+"highlight.css";$("head").append('<link rel="stylesheet" type="text/css" href="'+css+'" />');function t(e,t){switch(typeof e){case"undefined":case"object":n(e||document);break;case"string":return s(e,t)}}function n(e){function t(e){for(var t,a,r=0;r<e.length;r++)t=e[r],t.className&&!t.getAttribute("data-highlight")&&(a=n.exec(t.className),a&&(a=a[1],t.innerHTML=s(t.innerHTML,a),t.setAttribute("data-highlight",1)))}if(e.getElementsByTagName){var n=/\s?lang-([a-z]+)\s?/;t(e.getElementsByTagName("pre")),t(e.getElementsByTagName("code"))}}function a(){for(var e=[],t=0;t<this.length;t++)e.push(this[t].exp);return e.join("|")}function s(e,t){var n,a,s,l="";t=t||"js",n=p[t],a=e.replace(/\r?\n$/,"").replace(RegExp(n,"g"),function(){for(var e,t=0,a=1;e=n[t++];){if(arguments[a]){if(e.replacement){for(var s=e.replacement.replace("$0",e.className),r=1;r<=e.length-1;r++)s=s.replace("$"+r,arguments[a+r]);return s}return'<span class="'+e.className+'">'+arguments[0]+"</span>"}a+=e.length}}),s=a.split(/\r?\n/),a="<div>"+s.join("</div><div>")+"</div>",r&&(a=a.replace(/\s{4}|\t/g,"&nbsp;&nbsp;&nbsp;&nbsp;"));for(var i=1;i<=s.length;i++)l+="<span>"+i+"</span>";return a='<div class="code-wrap"><table><tr><td class="line-nums">'+l+'</td><td class="line-code">'+a+"</td></tr></table></div>"}var r=!document.querySelector,p={};t.add=function(e,t){var n,s;p[e]=[],p[e].toString=a;for(var r in t)s=t[r],n="string"!=typeof s.exp?(s.exp+"").substr(1,(s.exp+"").length-2):s.exp,p[e].push({className:r,exp:"("+n+")",length:(n.match(/(^|[^\\])\([^?]/g)||"").length+1,replacement:s.replacement||null})},e.highlight=t}(this),highlight.add("html",{comment:{exp:/&lt;!\s*(--([^\-]|[\r\n]|-[^\-])*--\s*)&gt;/},tags:{exp:/(&lt;\/?)([a-zA-Z]+\s?)/,replacement:'$1<span class="$0">$2</span>'},string:{exp:/'[^']*'|"[^"]*"/},attribute:{exp:/\b([a-zA-Z\-:]+)(=)/,replacement:'<span class="$0">$1</span>$2'},data:{exp:/\s(data-[a-zA-z\-]+)/},doctype:{exp:/&lt;!DOCTYPE([^&]|&[^g]|&g[^t])*&gt;/}}),highlight.add("js",{comment:{exp:/(\/\/[^\n]*(\n|$))|(\/\*[^*]*\*+([^\/][^*]*\*+)*\/)/},string:{exp:/'[^'\\]*(\\.[^'\\]*)*'|"[^"\\]*(\\.[^"\\]*)*"/},number:{exp:/([^"'][+\-]?)(\d+)([^"'])/,replacement:'$1<span class="$0">$2</span>$3'},regex:{exp:/(\/[^\/].+\/)(?=[;,\s\n])/},keywords:{exp:/\b(arguments|break|case|continue|default|delete|do|else|false|for|function|if|in|instanceof|new|null|return|switch|this|true|typeof|var|void|while|with)\b/},global:{exp:/\b(toString|valueOf|window|element|prototype|constructor|document|escape|unescape|parseInt|parseFloat|setTimeout|clearTimeout|setInterval|clearInterval|NaN|isNaN|Infinity)\b/}}),highlight.add("css",{comment:{exp:/\/\*[^*]*\*+([^\/][^*]*\*+)*\//},keywords:{exp:/@\w[\w\s]*/},selectors:{exp:"([\\w-:\\[.#][^{};>]*)(?={)"},properties:{exp:"([\\w-]+)(?=\\s*:)"},units:{exp:/([0-9])(px|em|en|%|pt|rem)\b/,replacement:'$1<span class="$0">$2</span>'},colors:{exp:/#[A-Za-z0-9]{3,6}/},urls:{exp:/url\(([^\)]*)\)/,replacement:'url(<span class="$0">$1</span>)'},important:{exp:/!important/}});