text: /*! CSS Critic - v1.0.0 - 2015-04-01
  * http://www.github.com/cburgmer/csscritic
  * Copyright (c) 2015 Christoph Burgmer, Copyright (c) 2012, 2013 ThoughtWorks, Inc.; Licensed MIT */
  /* Integrated dependencies:
   * imagediff.js (MIT License),
   * ayepromise (BSD License & WTFPL),
   * url (MIT License),
   * CSSOM (MIT License),
   * xmlserializer (MIT License),
   * css-font-face-src (BSD License),
   * inlineresources (MIT License),
   * rasterizeHTML.js (MIT License) */
  
  (function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.csscritic = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
  var css='.cssCriticNiceReporter{font-family:sans-serif;font-size:16px}.cssCriticNiceReporter a{text-decoration:none;color:inherit}.cssCriticNiceReporter .comparison .title .titleLink:hover,.cssCriticNiceReporter .componentLabel:hover,.cssCriticNiceReporter .errorText a{text-decoration:underline}.cssCriticNiceReporter button{padding:2px 10px;border-radius:3px;border:none;background-color:#00c04e;font-size:inherit;font-family:inherit}.cssCriticNiceReporter button[disabled]{background-color:#ddd}.cssCriticNiceReporter button:hover{background-color:#24d66c}.cssCriticNiceReporter button:not([disabled]):active{background-color:#4cec8d}.cssCriticNiceReporter .errorText{color:#591100;margin-bottom:1em}.cssCriticNiceReporter .errorText:not(:empty)::before{content:"⚠";color:#591100;font-size:1.2rem;padding-right:5px;vertical-align:middle}.cssCriticNiceReporter .errorText ul{margin:.2em 0}.cssCriticNiceReporter .header{padding:15px;transition:background-color 1s}.cssCriticNiceReporter .header.pass{background-color:#00c04e}.cssCriticNiceReporter .header.fail{background-color:#ff3100}.cssCriticNiceReporter .timeTaken{float:right;padding:.5em 0 0 1em}.cssCriticNiceReporter .statusText{display:inline-block}.cssCriticNiceReporter .statusText .runAll{display:block;margin-top:.5em;text-decoration:underline}.cssCriticNiceReporter .acceptAll{display:none;margin:-4px 0 -4px 1em}.cssCriticNiceReporter .acceptAll.active{display:inline-block}.cssCriticNiceReporter .cssCriticVersion{font-size:.7rem}.cssCriticNiceReporter .progressBar{margin:.4em 0;list-style:none;padding:0}.cssCriticNiceReporter .progressBar:empty::after{content:\'\';width:0;height:0;border:.63rem solid;border-radius:50%;display:inline-block;opacity:.15}.cssCriticNiceReporter .progressBar li{display:inline-block;margin-right:-.4rem;transition:color 1s}.cssCriticNiceReporter .progressBar a{width:0;height:0;border:.63rem solid;border-radius:50%;display:block}.cssCriticNiceReporter .progressBar .pending{color:grey}.cssCriticNiceReporter .progressBar .passed{color:#048337}.cssCriticNiceReporter .progressBar .failed{color:#b62705}.cssCriticNiceReporter .progressBar .error{color:#591100}.cssCriticNiceReporter .progressBar .referenceMissing{color:#ff0}.cssCriticNiceReporter .progressBar a:focus{outline:0}.cssCriticNiceReporter .progressBar .hasRenderErrors{position:relative}.cssCriticNiceReporter .progressBar .hasRenderErrors a::after{content:\'!\';color:#000;line-height:1.26rem;text-align:center;position:absolute;top:0;left:0;right:0;bottom:0}.cssCriticNiceReporter .componentLabel{margin:1.8em 0 .5em 15px;font-size:1.15rem}.cssCriticNiceReporter .comparison{background-color:#f5f5f5;padding:15px;margin:4px 0}.cssCriticNiceReporter .comparison .title{font-weight:400}.cssCriticNiceReporter .comparison.fakeTarget .title,.cssCriticNiceReporter .comparison:target .title{font-weight:700}.cssCriticNiceReporter .comparison .title .externalLink{vertical-align:top;font-size:.8rem;line-height:.6em;color:#888;display:inline-block}.cssCriticNiceReporter .comparison .title .externalLink:hover{transform:scale(1.1);transform-origin:bottom left}.cssCriticNiceReporter .comparison .parameters,.cssCriticNiceReporter .comparison .parameters dd,.cssCriticNiceReporter .comparison .parameters dt{display:inline-block;margin:0}.cssCriticNiceReporter .comparison .parameters{margin-left:1.5em;color:#444}.cssCriticNiceReporter .comparison .parameters dt{font-style:italic}.cssCriticNiceReporter .comparison .parameters dt::after{content:":"}.cssCriticNiceReporter .comparison .parameters dd{margin-left:.5em;margin-right:.7em}.cssCriticNiceReporter .comparison .parameters dd::after{content:","}.cssCriticNiceReporter .comparison .parameters dd:last-child::after{content:""}.cssCriticNiceReporter .running.comparison .imageContainer{opacity:.2}.cssCriticNiceReporter .comparison .imageContainer:empty{display:none}.cssCriticNiceReporter .comparison .imageWrapper{background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAKUlEQVQ4jWNYt27df2Lwo0ePiMIMowaOGjgsDSRWIbEWjxo4auCwNBAAenk4PB4atggAAAAASUVORK5CYII=)-5px -5px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.cssCriticNiceReporter .comparison canvas,.cssCriticNiceReporter .comparison img{display:block}.cssCriticNiceReporter .comparison .changedImageContainer,.cssCriticNiceReporter .comparison .imageContainer{border:1px solid #000}.cssCriticNiceReporter .comparison .outerChangedImageContainer{margin-top:4px;display:inline-block;position:relative}.cssCriticNiceReporter .comparison .imageContainer{display:inline-block}.cssCriticNiceReporter .comparison .imageContainer .diff{max-height:0;max-width:0;opacity:0}.cssCriticNiceReporter .failed.comparison .imageContainer:hover .diff{max-height:none;max-width:none;opacity:1;transition:opacity 1s}.cssCriticNiceReporter .failed.comparison .imageContainer:hover .imageWrapper{opacity:.5;transition:opacity 1s;position:absolute;top:0;left:0;right:0;bottom:0}.cssCriticNiceReporter .comparison iframe{border:none;display:block;background:0 0}.cssCriticNiceReporter .comparison .realView{border-style:dashed}.cssCriticNiceReporter .comparison .accept{vertical-align:top;position:absolute;top:0;bottom:0;right:-65px;width:50px;font-size:.7rem}.cssCriticNiceReporter .accepted.comparison .accept{font-size:1.4rem}.cssCriticNiceReporter .comparison button span{transform:rotate(-90deg);display:block}.cssCriticNiceReporter .comparison .imageContainer{opacity:1;max-height:1000000px;position:relative}.cssCriticNiceReporter .accepted.comparison .imageContainer{opacity:0;max-height:0;border-width:0;transition:max-height .001s ease 1s,opacity 1s,border-width .001s ease 1s}.cssCriticNiceReporter .comparison:hover .imageContainer::after{position:absolute;top:0;right:0;transform:translateX(100%);margin-right:-8px;padding:4px;white-space:nowrap;background-color:#000;opacity:.55;color:#fff;font-size:.9rem;border-radius:5px}.cssCriticNiceReporter .failed.comparison:hover .imageContainer::after{content:"< Hover over the reference image to highlight changes"}.cssCriticNiceReporter .failed.comparison .imageContainer:hover::after{display:none}.cssCriticNiceReporter .passed.comparison .imageContainer:not(.realView):hover::after{content:"< Double click the image to expose the DOM of the underlying page"}.cssCriticNiceReporter .browserWarning::before{content:"⚠";font-size:1.2rem;padding-right:5px;vertical-align:middle}.cssCriticNiceReporter .browserWarning{position:fixed;top:0;left:0;width:100%;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box;background-color:rgba(182,39,5,.85);color:#fff;font-size:1.2rem;border:2px solid #000;padding:20px}';require("./../node_modules/cssify")(css),module.exports=css;
  },{"./../node_modules/cssify":4}],2:[function(require,module,exports){
  !function(e,t){"function"==typeof define&&define.amd?define(["ayepromise","imagediff","rasterizeHTML"],function(r,n,a){return e.csscritic=t(r,n,a)}):"object"==typeof exports?module.exports=t(require("ayepromise"),require("imagediff"),require("rasterizehtml"),require("../build/csscritic.concat.css")):e.csscritic=t(ayepromise,imagediff,rasterizeHTML)}(this,function(e,t,r){var n={};n.main=function(e,t,r,n,a){"use strict";var o,i={},s=[];i.component=function(e){o=e};var c=function(e){return"string"==typeof e?{url:e}:e};i.add=function(e){var t=r.clone(c(e));o&&void 0===t.component&&(t.component=o),s.push(t)};var u=function(e){return r.all(e.map(function(e){return n.readReferenceImage(e).then(function(t){return{testCase:e,referenceImage:t.image,viewport:t.viewport}},function(){return{testCase:e}})}))},l=function(e){return e.map(function(e){return{configuredComparison:e,selected:!a||a.isComparisonSelected(e)}})},d=function(e){return r.all(e.map(function(e){var r=e.selected;return t.doReportConfiguredComparison(e.configuredComparison,r)}))},f=function(r){return e.compare(r).then(function(e){return t.doReportComparison(e).then(function(){return e})})};return i.execute=function(){var e,n;return u(s).then(function(t){return e=l(t),d(e)}).then(function(){var t=e.filter(function(e){return e.selected}).map(function(e){return e.configuredComparison});return r.all(t.map(f))}).then(function(e){n=r.hasTestSuitePassed(e)}).then(function(){return t.doReportTestSuite(n)}).then(function(){return n})},i},n.regression=function(e,t,r){"use strict";var n={},a=1,o=function(e,t){t&&r.diff(e,t)},i=function(e,r){return o(e,r),t.workAroundTransparencyIssueInFirefox(e)},s=function(e,t){var n;return i(e,t).then(function(e){return t?(n=r.equal(e,t,a),n?"passed":"failed"):"referenceMissing"})},c=function(e,r,n,a,o,i){var s={status:e,testCase:r,viewport:t.clone(n),renderErrors:a};return o&&(s.pageImage=o),i&&(s.referenceImage=i),s},u=function(t,r,n){return e.render({url:t.url,hover:t.hover,active:t.active,width:r.width,height:r.height}).then(function(e){return s(e.image,n).then(function(a){return c(a,t,r,e.errors,e.image,n)})},function(){return c("error",t,r,[])})},l=function(e){var t=800,r=100;return{width:e.width||t,height:e.height||r}};return n.compare=function(e){var t=e.viewport;return void 0===e.referenceImage&&(t=l(e.testCase)),u(e.testCase,t,e.referenceImage)},n},n.reporting=function(e,t,r){"use strict";var n={},a=[];n.addReporter=function(e){a.push(e)};var o=function(e){return void 0===e.width&&void 0===e.height},i=function(r){var n,a;r.pageImage&&(n=r.viewport.width,a=r.viewport.height,o(r.testCase)&&(r.resizePageImage=function(t,o){return n=t,a=o,e.render({url:r.testCase.url,hover:r.testCase.hover,active:r.testCase.active,width:t,height:o}).then(function(e){return r.pageImage=e.image,e.image})}),r.acceptPage=function(){t.storeReferenceImage(r.testCase,r.pageImage,{width:n,height:a})})},s=function(e,t){return t?e.reportSelectedComparison:e.reportDeselectedComparison};return n.doReportConfiguredComparison=function(e,t){return r.all(a.map(function(r){var n=s(r,t);return n?n(e):void 0}))},n.doReportComparison=function(e){var t=r.clone(e);return i(t),r.all(a.map(function(e){return e.reportComparison?e.reportComparison(t):void 0}))},n.doReportTestSuite=function(e){return r.all(a.map(function(t){return t.reportTestSuite?t.reportTestSuite({success:e}):void 0}))},n},n.util=function(){"use strict";var t={};t.getDataURIForImage=function(e){var t=window.document.createElement("canvas"),r=t.getContext("2d");return t.width=e.naturalWidth,t.height=e.naturalHeight,r.drawImage(e,0,0),t.toDataURL("image/png")},t.getImageForUrl=function(t){var r=e.defer(),n=new window.Image;return n.onload=function(){r.resolve(n)},n.onerror=function(){r.reject()},n.src=t,r.promise};var r=function(e){var t;return t=e.indexOf("?")<0?"?":"&",e+t+"_="+Date.now()};t.ajax=function(t){var n=e.defer(),a=new XMLHttpRequest;a.onload=function(){200===a.status||0===a.status?n.resolve(a.response):n.reject()},a.onerror=function(){n.reject()};try{a.open("get",r(t),!0),a.send()}catch(o){n.reject()}return n.promise},t.loadAsBlob=function(t){var n=e.defer(),a=new XMLHttpRequest;a.onload=function(){200===a.status||0===a.status?n.resolve(a.response):n.reject()},a.onerror=function(){n.reject()};try{a.open("get",r(t),!0),a.responseType="blob",a.send()}catch(o){n.reject()}return n.promise},t.loadBlobAsText=function(t){var r=e.defer(),n=new FileReader;return n.onload=function(e){r.resolve(e.target.result)},n.onerror=function(){r.reject()},n.readAsText(t),r.promise},t.loadBlobAsDataURI=function(t){var r=e.defer(),n=new FileReader;return n.onload=function(e){r.resolve(e.target.result)},n.onerror=function(){r.reject()},n.readAsDataURL(t),r.promise},t.excludeKeys=function(e){var t=Array.prototype.slice.call(arguments,1),r={};return Object.keys(e).forEach(function(n){-1===t.indexOf(n)&&(r[n]=e[n])}),r},t.serializeMap=function(e){var t=[],r=Object.keys(e);return r.sort(),r.forEach(function(r){t.push(r+"="+e[r])}),t.join(",")},t.clone=function(e){var t,r={};for(t in e)e.hasOwnProperty(t)&&(r[t]=e[t]);return r};var n=function(t){var r=e.defer();return r.resolve(t),r.promise};return t.workAroundTransparencyIssueInFirefox=function(e){var r;try{r=t.getDataURIForImage(e)}catch(a){return n(e)}return t.getImageForUrl(r)},t.hasTestSuitePassed=function(e){var t=e.filter(function(e){return"passed"!==e.status}),r=0===t.length,n=e.length>0;return n&&r},t.all=function(t){var r=e.defer(),n=t.length,a=[],o=function(e,t){n-=1,a[t]=e,0===n&&r.resolve(a)};return 0===t.length?(r.resolve([]),r.promise):(t.forEach(function(e,t){e&&e.then?e.then(function(e){o(e,t)},function(e){r.reject(e)}):o(e,t)}),r.promise)},t},n.browserRenderer=function(e,t,r){"use strict";var n,a={},o={},i=function(){return n||(n=t()),n},s=function(e){return e.map(function(e){return e.msg})},c=function(e){throw console.error(e),e},u=function(e){var t={cache:"repeated",cacheBucket:o,width:e.width,height:e.height,executeJs:!0,executeJsTimeout:50,baseUrl:e.baseUrl};return e.hover&&(t.hover=e.hover),e.active&&(t.active=e.active),r.drawHTML(e.html,t).then(function(e){var t=s(e.errors);return{image:e.image,errors:t}},c)},l=function(t,r){return e.loadBlobAsText(t).then(function(e){return u({html:e,baseUrl:r.url,width:r.width,height:r.height,hover:r.hover,active:r.active})})},d=function(t,r){return e.loadBlobAsDataURI(t).then(e.getImageForUrl).then(function(e){return{image:e,errors:[]}},function(){return l(t,r)})};return a.render=function(t){return i().execute(function(){return e.loadAsBlob(t.url).then(function(e){return d(e,t)})})},a},n.fallbackFilter=function(e){"use strict";var t={},r="csscriticFallbackFilter",n=function(e){return e.component?e.component+" "+e.desc:e.desc};return t.isComparisonSelected=function(e){var t=sessionStorage.getItem(r);return t?e.testCase.desc&&n(e.testCase)===t?!0:e.testCase.component&&e.testCase.component===t?!0:!t||e.testCase.url===t:!0},t.filterFor=function(t){var a;a=t.desc?n(t):t.url,sessionStorage.setItem(r,a),e.reload()},t.filterForComponent=function(t){sessionStorage.setItem(r,t),e.reload()},t.clearFilter=function(){sessionStorage.removeItem(r),e.reload()},t},n.indexeddbstorage=function(t){"use strict";var r={},n=function(e){e.createObjectStore("references",{keyPath:"testCase"})},a=function(){var t=e.defer(),r=indexedDB.open("csscritic",1);return r.onsuccess=function(e){var r=e.target.result;t.resolve(r)},r.onupgradeneeded=function(e){var t=e.target.result;n(t)},t.promise},o=function(e){var r=t.excludeKeys(e,"url"),n=t.serializeMap(r),a=e.url;return n&&(a+=","+n),a};return r.storeReferenceImage=function(r,n,i){var s,c=e.defer();s=t.getDataURIForImage(n);var u=o(r);return a().then(function(e){var t=e.transaction(["references"],"readwrite").objectStore("references").put({testCase:u,reference:{imageUri:s,viewport:i}});t.onsuccess=function(){e.close(),c.resolve()}}),c.promise},r.readReferenceImage=function(r){var n=e.defer(),i=o(r);return a().then(function(e){var r=e.transaction(["references"]).objectStore("references").get(i);r.onsuccess=function(){if(e.close(),void 0===r.result||void 0===r.result.reference||void 0===r.result.reference.imageUri)return void n.reject();var a=r.result.reference;t.getImageForUrl(a.imageUri).then(function(e){var t=a.viewport||{width:e.width,height:e.height};n.resolve({image:e,viewport:t})},n.reject)}}),n.promise},r},n.jobQueue=function(){"use strict";var t={},r=[],n=!1,a=function(e){var t=e.func();return e.resolve(t),t},o=function(){var e;r.length>0?(n=!0,e=r.shift(),a(e).then(o,o)):n=!1},i=function(t){var r=e.defer();return{func:t,resolve:r.resolve,promise:r.promise}};return t.execute=function(e){var t=i(e);return r.push(t),n||o(),t.promise},t},n.niceReporter=function(e,r,n,a,o){"use strict";var i,s={},c=function(e){return e.toString().replace(/&/g,"&amp;").replace(new RegExp("<"),"&lt;","g").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")},u=function(e,t){return e.replace(/\{\{(\w+)\}\}/g,function(e,r){var n=void 0!==t[r]?t[r]:"";return c(n)})},l=function(e){var t=document.createElement("body");return t.insertAdjacentHTML("beforeend",e),t.firstChild},d=function(e,t){return e.querySelector("."+t)},f=function(e){return e.replace(" ","_","g")},p="header",h="timeTaken",m="progressBar",g="statusText",v=function(e){var t=l('<div class="cssCriticNiceReporter"></div>');return C(t),e.appendChild(t),t},C=function(e){var t=l(u('<header class="{{headerClassName}}"><a href="http://cburgmer.github.io/csscritic/" class="cssCriticVersion">CSS Critic {{packageVersion}}</a><span class="{{timeTakenClassName}}"></span><ul class="{{progressBarClassName}}"></ul><div class="{{statusTextClassName}}" class="statusText"></div></header>',{headerClassName:p,timeTakenClassName:h,progressBarClassName:m,statusTextClassName:g,packageVersion:o}));e.appendChild(t)},w=function(e,t){void 0===i&&(i=document.title),document.title="("+t+"/"+e+") "+i},y=function(e,t){for(e+="";e.length<t;)e="0"+e;return e},b=function(e){var t=Math.floor(e/1e3),r=e%1e3;return t+"."+y(r,3)},I=function(e,t){var r=d(e,h);r.textContent="finished in "+b(t)+"s"},k=function(e,t){var r=d(e,p);r.classList.add(t?"pass":"fail")},x="pending",S=function(e){var t;return e.desc?(t=e.component?e.component+" ":"",t+e.desc):H(e)},F=function(e,t,r){var a=d(e,m),o='<li><a href="#{{linkTarget}}" title="{{title}}"></a></li>',i='<li><a title="{{title}}"></a></li>',s=r?o:i,c=l(u(s,{linkTarget:r?f(r):"",title:S(t)}));return c.classList.add(x),a.appendChild(c),n&&n.install(c.querySelector("a")),c},R=function(e,t,r){r.classList.remove(x),r.classList.add(e),t>0&&r.classList.add("hasRenderErrors")},T=function(e,t,r){return 1===e?t:r},U=function(e,t){var r="{{total}} "+T(e,"entry","entries")+", ";return e>t&&(r="{{selected}} of "+r),u("<span>"+r+"</span>",{total:e,selected:t})},L=function(e,t,r){var n,a="{{issues}} "+T(e,"needs","need")+" some love",o="all good",i="nothing here yet",s=t===r&&0===e;return n=0===t?i:s?o:a,u("<span>"+n+"</span>",{issues:e})},N="acceptAll",j=function(){return l(u('<button class="{{acceptAllClassName}}">... accept all (I know what I\'m doing)</button>',{acceptAllClassName:N}))},q=function(e,t){var r=d(e,g),n=r.querySelector("."+N);t.length>2&&(n.classList.add("active"),n.onclick=function(){t.forEach(function(e){e.acceptPage(),ee(e.entry)}),n.setAttribute("disabled","disabled")})},A=function(e){r.clearFilter&&(e.onclick=function(e){r.clearFilter(),e.preventDefault()})},E=function(e,t,n,a,o){var i=r.clearFilterUrl?r.clearFilterUrl():"#",s=l(u('<a class="runAll" href="{{url}}">Run all</a>',{url:i})),c=d(e,g);c.innerHTML="",c.appendChild(l(U(t,n))),c.appendChild(l(L(a,n,o))),c.appendChild(j()),t>n&&(A(s),c.appendChild(s))},D=function(e,t){r.filterForComponent&&(e.onclick=function(e){r.filterForComponent(t),e.preventDefault()})},M=function(e,t){var n=r.filterUrlForComponent?r.filterUrlForComponent(t):"#",a=l(u('<h2 class="componentLabel"><a href="{{filterUrl}}">{{headline}}</a></h2>',{headline:t,filterUrl:n}));D(a,t),e.appendChild(a)},H=function(t){var r=e.excludeKeys(t,"url"),n=e.serializeMap(r),a=t.url;return n?a+","+n:a},B="running",P="imageContainer",O="errorText",z=function(e){var t=l('<div class="imageWrapper"></div>');return t.appendChild(e),t},V=function(e){return"string"==typeof e?"'"+e+"'":e},W=function(t){var r=e.excludeKeys(t,"url","desc","component"),n=Object.keys(r);return n.length?(n.sort(),'<dl class="parameters">'+n.map(function(e){return u("<dt>{{key}}</dt><dd>{{value}}</dd>",{key:e,value:V(r[e])})}).join("\n")+"</dl>"):""},K=function(e,t){r.filterFor&&(e.onclick=function(e){r.filterFor(t),e.preventDefault()})},Q=function(e,t,n,a){var o="titleLink",i=r.filterUrlFor?r.filterUrlFor(t):"#",s=l(u('<section class="comparison {{runningComparisonClassName}}" id="{{id}}"><h3 class="title"><a class="{{titleLinkClassName}}" href="{{filterUrl}}">{{title}}</a> <a class="externalLink" href="{{url}}">↗</a>'+W(t)+'</h3><div class="{{errorContainerClassName}}"></div><div><div class="{{imageContainerClassName}}"></div></div></section>',{url:t.url,title:t.desc?t.desc:t.url,filterUrl:i,id:f(a),runningComparisonClassName:B,errorContainerClassName:O,imageContainerClassName:P,titleLinkClassName:o})),c=s.querySelector("."+P),d=s.querySelector("."+o);return n&&c.appendChild(z(n)),K(d,t),e.appendChild(s),s},_=function(e){var t,r=document.createElement("canvas");return r.height=e.height,r.width=e.width,t=r.getContext("2d"),t.putImageData(e,0,0),r},J=function(e,r){return t.diff(e,r,{align:"top"})},X=function(e){var t,r=e.data;for(t=0;t<r.length;t+=4)0===r[t]&&0===r[t+1]&&0===r[t+2]?r[t+3]=0:(r[t]=0,r[t+1]=0,r[t+2]=255,r[t+3]=255);return e},Y=function(e,t){var r=J(e,t),n=_(X(r));return n.classList.add("diff"),n},G=function(e){var t,r=document.createElement("canvas"),n=e.naturalWidth,a=e.naturalHeight;return r.width=n,r.height=a,t=r.getContext("2d"),t.drawImage(e,0,0,n,a),r.style.width=n+"px",r.style.height=a+"px",r},Z=function(e,t,r){var n=r.querySelector("."+P);n.appendChild(Y(e,t))},$="accept",ee=function(e){var t=e.querySelector("."+$);t.setAttribute("disabled","disabled"),t.textContent="✓",e.classList.add("accepted")},te=function(e,t,r){var n="changedImageContainer",a=l(u('<div class="outerChangedImageContainer"><div class="{{changedImageContainerClassName}}"></div><button class="{{acceptClassName}}"><span>Accept</span></button></div>',{changedImageContainerClassName:n,acceptClassName:$})),o=a.querySelector("."+n),i=a.querySelector("button");return o.appendChild(z(e)),i.onclick=function(){t(),ee(r)},a},re=function(e,t,r,n){Z(t,e,n),n.appendChild(te(G(e),r,n))},ne=function(e,t){var r=document.createElement("iframe");return r.width=e.width,r.height=e.height,r.src=t,r.scrolling="no",r},ae=function(e,t,r){var n=r.querySelector("."+P);n.innerHTML="",n.appendChild(z(G(e))),n.addEventListener("dblclick",function(){n.innerHTML="",n.appendChild(z(ne(e,t))),n.classList.add("realView")},!1)},oe=function(e,t,r){r.appendChild(te(G(e),t,r))},ie='Make sure the path lies within the <a href="https://developer.mozilla.org/en-US/docs/Web/Security/Same-origin_policy">same origin</a> as this document.',se=function(e,t){var r=l(u('<span>The page "{{url}}" could not be rendered. '+ie+"</span>",{url:e})),n=t.querySelector("."+O);n.appendChild(r)},ce=function(e,t){var r=l(u("<span>Had the following errors rendering the page:<ul></ul>"+ie+"</span>")),n=r.querySelector("ul"),a=t.querySelector("."+O);e.map(function(e){return l(u("<li>{{msg}}</li>",{msg:e}))}).forEach(function(e){n.appendChild(e)}),a.appendChild(r)},ue=function(e,t){t.classList.remove(B),t.classList.add(e)},le=function(){return a.drawHTML("<b></b>").then(function(e){var t=document.createElement("canvas"),r=t.getContext("2d");try{return r.drawImage(e.image,0,0),t.toDataURL("image/png"),!0}catch(n){return!1}})},de=!1,fe=function(e){de||(de=!0,le().then(function(t){t||e.appendChild(l('<div class="browserWarning">Your browser is currently not supported, as it does not support reading rendered HTML from the canvas (<a href="https://code.google.com/p/chromium/issues/detail?id=294129">Chrome #294129</a>, <a href="https://bugs.webkit.org/show_bug.cgi?id=17352">Safari #17352</a>). How about trying Firefox?</div>'))}))};return s.NiceReporter=function(e){var t,r,n,a=0,o=0,i=0,s=0,c={},u={},l=[],d=function(){return t||(t=v(e||document.body)),t},f=function(){a+=1,r||(r=Date.now()),fe(d()),w(a,i),E(d(),a,o,s)};return{reportDeselectedComparison:function(e){f(),F(d(),e.testCase)},reportSelectedComparison:function(e){var t=H(e.testCase);o+=1,e.testCase.component&&e.testCase.component!==n&&(n=e.testCase.component,M(d(),e.testCase.component)),f();var r=F(d(),e.testCase,t);c[t]=r;var a=Q(d(),e.testCase,e.referenceImage,t);u[t]=a},reportComparison:function(e){var t=H(e.testCase),r=c[t],n=u[t];i+=1,"passed"!==e.status&&(s+=1),w(a,i),E(d(),a,o,s,i),R(e.status,e.renderErrors.length,r),"failed"===e.status?(re(e.pageImage,e.referenceImage,e.acceptPage,n),l.push(e)):"referenceMissing"===e.status?(oe(e.pageImage,e.acceptPage,n),l.push(e)):"passed"===e.status?ae(e.pageImage,e.testCase.url,n):"error"===e.status&&se(e.testCase.url,n),e.renderErrors.length>0&&ce(e.renderErrors,n),ue(e.status,n)},reportTestSuite:function(e){var t=l.map(function(e){var t=H(e.testCase);return{acceptPage:e.acceptPage,entry:u[t]}});w(a,i),E(d(),a,o,s,i),I(d(),r?Date.now()-r:0),k(d(),e.success),q(d(),t)}}},s},n.pageNavigationHandlingFallback=function(){"use strict";var e={},t="fakeTarget",r=function(){var e=Array.prototype.slice.call(document.querySelectorAll("."+t));e.forEach(function(e){e.classList.remove(t)})},n=function(e){e.classList.add(t)},a=function(e){var t;r(),e?(t=document.getElementById(e),t.scrollIntoView(),n(t)):window.scrollTo(0,0)},o=!1,i=function(){o||(o=!0,window.onpopstate=function(e){a(e.state)})};return e.install=function(e){i(),e.onclick=function(e){var t=e.target.href,r=t.substr(t.indexOf("#")+1);a(r),history.pushState(r,r),e.preventDefault()}},e},n.urlQueryFilter=function(e){"use strict";var t={},r="filter",n=function(e){var t=e.replace(/^\?/,"");return t?t.split("&").map(function(e){var t,r,n=e.indexOf("=");return n>=0?(t=e.substr(0,n),r=e.substr(n+1)):t=e,{key:t,value:r}}):[]},a=function(e){return e.value?e.key+"="+e.value:e.key},o=function(){var t=n(e.search).filter(function(e){return e.key===r}).pop();return t?decodeURIComponent(t.value):void 0},i=function(e){return e.component?e.component+" "+e.desc:e.desc},s=o(),c=n(e.search);t.isComparisonSelected=function(e){return s?e.testCase.desc&&i(e.testCase)===s?!0:e.testCase.component&&e.testCase.component===s?!0:e.testCase.url===s:!0};var u=function(e){var t=c.filter(function(e){return e.key!==r});return e&&t.push({key:r,value:encodeURIComponent(e)}),"?"+t.map(a).join("&")};return t.filterUrlForComponent=function(e){return u(e)},t.filterUrlFor=function(e){return u(e.desc?i(e):e.url)},t.clearFilterUrl=function(){return u()},t},n.packageVersion="1.0.0";var a=function(){"use strict";var e=function(e,t){return function(){return e.apply(null,arguments),t}},a=function(e,t){return e.substr(0,t.length)===t},o=function(){return a(window.location.href,"file://")},i=n.packageVersion||"dev",s=n.util(),c=n.indexeddbstorage(s),u=n.browserRenderer(s,n.jobQueue,r),l=n.reporting(u,c,s),d=n.regression(u,s,t),f=n.urlQueryFilter(window.location),p=n.fallbackFilter(window.location),h=o()?p:f,m=n.main(d,l,s,c,h),g=n.pageNavigationHandlingFallback(window.location),v=n.niceReporter(s,h,o()?g:void 0,r,i),C={};return C.add=e(m.add,C),C.component=e(m.component,C),C.execute=m.execute,C.addReporter=e(l.addReporter,C),C.NiceReporter=v.NiceReporter,C}();return a});
  },{"../build/csscritic.concat.css":1,"ayepromise":3,"imagediff":16,"rasterizehtml":45}],3:[function(require,module,exports){
  !function(n,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e():n.ayepromise=e()}(this,function(){"use strict";var n={},e=function(){var n=!1;return function(e){return function(){n||(n=!0,e.apply(null,arguments))}}},t=function(n){var e=n&&n.then;return"object"==typeof n&&"function"==typeof e?function(){return e.apply(n,arguments)}:void 0},r=function(e,t){var r=n.defer(),o=function(n,e){setTimeout(function(){var t;try{t=n(e)}catch(o){return void r.reject(o)}t===r.promise?r.reject(new TypeError("Cannot resolve promise with itself")):r.resolve(t)},1)},i=function(n){e&&e.call?o(e,n):r.resolve(n)},c=function(n){t&&t.call?o(t,n):r.reject(n)};return{promise:r.promise,handle:function(n,e){n===u?i(e):c(e)}}},o=0,u=1,i=2;return n.defer=function(){var n,c=o,f=[],a=function(e,t){c=e,n=t,f.forEach(function(e){e.handle(c,n)}),f=null},l=function(n){a(u,n)},s=function(n){a(i,n)},p=function(e,t){var u=r(e,t);return c===o?f.push(u):u.handle(c,n),u.promise},v=function(n){var t=e();try{n(t(d),t(s))}catch(r){t(s)(r)}},d=function(n){var e;try{e=t(n)}catch(r){return void s(r)}e?v(e):l(n)},h=e();return{resolve:h(d),reject:h(s),promise:{then:p,fail:function(n){return p(null,n)}}}},n});
  },{}],4:[function(require,module,exports){
  module.exports=function(e,t){var r=t||document;if(r.createStyleSheet){var n=r.createStyleSheet();return n.cssText=e,n.ownerNode}var a=r.getElementsByTagName("head")[0],l=r.createElement("style");return l.type="text/css",l.styleSheet?l.styleSheet.cssText=e:l.appendChild(r.createTextNode(e)),a.appendChild(l),l},module.exports.byUrl=function(e){if(document.createStyleSheet)return document.createStyleSheet(e).ownerNode;var t=document.getElementsByTagName("head")[0],r=document.createElement("link");return r.rel="stylesheet",r.href=e,t.appendChild(r),r};
  },{}],5:[function(require,module,exports){
  
  },{}],6:[function(require,module,exports){
  function Buffer(t,e){var r=this;if(!(r instanceof Buffer))return new Buffer(t,e);var n,i=typeof t;if("number"===i)n=+t;else if("string"===i)n=Buffer.byteLength(t,e);else{if("object"!==i||null===t)throw new TypeError("must start with number, buffer, array or string");"Buffer"===t.type&&isArray(t.data)&&(t=t.data),n=+t.length}if(n>kMaxLength)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+kMaxLength.toString(16)+" bytes");0>n?n=0:n>>>=0,Buffer.TYPED_ARRAY_SUPPORT?r=Buffer._augment(new Uint8Array(n)):(r.length=n,r._isBuffer=!0);var f;if(Buffer.TYPED_ARRAY_SUPPORT&&"number"==typeof t.byteLength)r._set(t);else if(isArrayish(t))if(Buffer.isBuffer(t))for(f=0;n>f;f++)r[f]=t.readUInt8(f);else for(f=0;n>f;f++)r[f]=(t[f]%256+256)%256;else if("string"===i)r.write(t,0,e);else if("number"===i&&!Buffer.TYPED_ARRAY_SUPPORT)for(f=0;n>f;f++)r[f]=0;return n>0&&n<=Buffer.poolSize&&(r.parent=rootParent),r}function SlowBuffer(t,e){if(!(this instanceof SlowBuffer))return new SlowBuffer(t,e);var r=new Buffer(t,e);return delete r.parent,r}function hexWrite(t,e,r,n){r=Number(r)||0;var i=t.length-r;n?(n=Number(n),n>i&&(n=i)):n=i;var f=e.length;if(f%2!==0)throw new Error("Invalid hex string");n>f/2&&(n=f/2);for(var o=0;n>o;o++){var u=parseInt(e.substr(2*o,2),16);if(isNaN(u))throw new Error("Invalid hex string");t[r+o]=u}return o}function utf8Write(t,e,r,n){var i=blitBuffer(utf8ToBytes(e,t.length-r),t,r,n);return i}function asciiWrite(t,e,r,n){var i=blitBuffer(asciiToBytes(e),t,r,n);return i}function binaryWrite(t,e,r,n){return asciiWrite(t,e,r,n)}function base64Write(t,e,r,n){var i=blitBuffer(base64ToBytes(e),t,r,n);return i}function utf16leWrite(t,e,r,n){var i=blitBuffer(utf16leToBytes(e,t.length-r),t,r,n);return i}function base64Slice(t,e,r){return base64.fromByteArray(0===e&&r===t.length?t:t.slice(e,r))}function utf8Slice(t,e,r){var n="",i="";r=Math.min(t.length,r);for(var f=e;r>f;f++)t[f]<=127?(n+=decodeUtf8Char(i)+String.fromCharCode(t[f]),i=""):i+="%"+t[f].toString(16);return n+decodeUtf8Char(i)}function asciiSlice(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;r>i;i++)n+=String.fromCharCode(127&t[i]);return n}function binarySlice(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;r>i;i++)n+=String.fromCharCode(t[i]);return n}function hexSlice(t,e,r){var n=t.length;(!e||0>e)&&(e=0),(!r||0>r||r>n)&&(r=n);for(var i="",f=e;r>f;f++)i+=toHex(t[f]);return i}function utf16leSlice(t,e,r){for(var n=t.slice(e,r),i="",f=0;f<n.length;f+=2)i+=String.fromCharCode(n[f]+256*n[f+1]);return i}function checkOffset(t,e,r){if(t%1!==0||0>t)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function checkInt(t,e,r,n,i,f){if(!Buffer.isBuffer(t))throw new TypeError("buffer must be a Buffer instance");if(e>i||f>e)throw new RangeError("value is out of bounds");if(r+n>t.length)throw new RangeError("index out of range")}function objectWriteUInt16(t,e,r,n){0>e&&(e=65535+e+1);for(var i=0,f=Math.min(t.length-r,2);f>i;i++)t[r+i]=(e&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function objectWriteUInt32(t,e,r,n){0>e&&(e=4294967295+e+1);for(var i=0,f=Math.min(t.length-r,4);f>i;i++)t[r+i]=e>>>8*(n?i:3-i)&255}function checkIEEE754(t,e,r,n,i,f){if(e>i||f>e)throw new RangeError("value is out of bounds");if(r+n>t.length)throw new RangeError("index out of range");if(0>r)throw new RangeError("index out of range")}function writeFloat(t,e,r,n,i){return i||checkIEEE754(t,e,r,4,3.4028234663852886e38,-3.4028234663852886e38),ieee754.write(t,e,r,n,23,4),r+4}function writeDouble(t,e,r,n,i){return i||checkIEEE754(t,e,r,8,1.7976931348623157e308,-1.7976931348623157e308),ieee754.write(t,e,r,n,52,8),r+8}function base64clean(t){if(t=stringtrim(t).replace(INVALID_BASE64_RE,""),t.length<2)return"";for(;t.length%4!==0;)t+="=";return t}function stringtrim(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function isArrayish(t){return isArray(t)||Buffer.isBuffer(t)||t&&"object"==typeof t&&"number"==typeof t.length}function toHex(t){return 16>t?"0"+t.toString(16):t.toString(16)}function utf8ToBytes(t,e){e=e||1/0;for(var r,n=t.length,i=null,f=[],o=0;n>o;o++){if(r=t.charCodeAt(o),r>55295&&57344>r){if(!i){if(r>56319){(e-=3)>-1&&f.push(239,191,189);continue}if(o+1===n){(e-=3)>-1&&f.push(239,191,189);continue}i=r;continue}if(56320>r){(e-=3)>-1&&f.push(239,191,189),i=r;continue}r=i-55296<<10|r-56320|65536,i=null}else i&&((e-=3)>-1&&f.push(239,191,189),i=null);if(128>r){if((e-=1)<0)break;f.push(r)}else if(2048>r){if((e-=2)<0)break;f.push(r>>6|192,63&r|128)}else if(65536>r){if((e-=3)<0)break;f.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(2097152>r))throw new Error("Invalid code point");if((e-=4)<0)break;f.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return f}function asciiToBytes(t){for(var e=[],r=0;r<t.length;r++)e.push(255&t.charCodeAt(r));return e}function utf16leToBytes(t,e){for(var r,n,i,f=[],o=0;o<t.length&&!((e-=2)<0);o++)r=t.charCodeAt(o),n=r>>8,i=r%256,f.push(i),f.push(n);return f}function base64ToBytes(t){return base64.toByteArray(base64clean(t))}function blitBuffer(t,e,r,n){for(var i=0;n>i&&!(i+r>=e.length||i>=t.length);i++)e[i+r]=t[i];return i}function decodeUtf8Char(t){try{return decodeURIComponent(t)}catch(e){return String.fromCharCode(65533)}}var base64=require("base64-js"),ieee754=require("ieee754"),isArray=require("is-array");exports.Buffer=Buffer,exports.SlowBuffer=SlowBuffer,exports.INSPECT_MAX_BYTES=50,Buffer.poolSize=8192;var kMaxLength=1073741823,rootParent={};Buffer.TYPED_ARRAY_SUPPORT=function(){try{var t=new ArrayBuffer(0),e=new Uint8Array(t);return e.foo=function(){return 42},42===e.foo()&&"function"==typeof e.subarray&&0===new Uint8Array(1).subarray(1,1).byteLength}catch(r){return!1}}(),Buffer.isBuffer=function(t){return!(null==t||!t._isBuffer)},Buffer.compare=function(t,e){if(!Buffer.isBuffer(t)||!Buffer.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,i=0,f=Math.min(r,n);f>i&&t[i]===e[i];i++);return i!==f&&(r=t[i],n=e[i]),n>r?-1:r>n?1:0},Buffer.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},Buffer.concat=function(t,e){if(!isArray(t))throw new TypeError("list argument must be an Array of Buffers.");if(0===t.length)return new Buffer(0);if(1===t.length)return t[0];var r;if(void 0===e)for(e=0,r=0;r<t.length;r++)e+=t[r].length;var n=new Buffer(e),i=0;for(r=0;r<t.length;r++){var f=t[r];f.copy(n,i),i+=f.length}return n},Buffer.byteLength=function(t,e){var r;switch(t+="",e||"utf8"){case"ascii":case"binary":case"raw":r=t.length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":r=2*t.length;break;case"hex":r=t.length>>>1;break;case"utf8":case"utf-8":r=utf8ToBytes(t).length;break;case"base64":r=base64ToBytes(t).length;break;default:r=t.length}return r},Buffer.prototype.length=void 0,Buffer.prototype.parent=void 0,Buffer.prototype.toString=function(t,e,r){var n=!1;if(e>>>=0,r=void 0===r||r===1/0?this.length:r>>>0,t||(t="utf8"),0>e&&(e=0),r>this.length&&(r=this.length),e>=r)return"";for(;;)switch(t){case"hex":return hexSlice(this,e,r);case"utf8":case"utf-8":return utf8Slice(this,e,r);case"ascii":return asciiSlice(this,e,r);case"binary":return binarySlice(this,e,r);case"base64":return base64Slice(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}},Buffer.prototype.equals=function(t){if(!Buffer.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t?!0:0===Buffer.compare(this,t)},Buffer.prototype.inspect=function(){var t="",e=exports.INSPECT_MAX_BYTES;return this.length>0&&(t=this.toString("hex",0,e).match(/.{2}/g).join(" "),this.length>e&&(t+=" ... ")),"<Buffer "+t+">"},Buffer.prototype.compare=function(t){if(!Buffer.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t?0:Buffer.compare(this,t)},Buffer.prototype.indexOf=function(t,e){function r(t,e,r){for(var n=-1,i=0;r+i<t.length;i++)if(t[r+i]===e[-1===n?0:i-n]){if(-1===n&&(n=i),i-n+1===e.length)return r+n}else n=-1;return-1}if(e>2147483647?e=2147483647:-2147483648>e&&(e=-2147483648),e>>=0,0===this.length)return-1;if(e>=this.length)return-1;if(0>e&&(e=Math.max(this.length+e,0)),"string"==typeof t)return 0===t.length?-1:String.prototype.indexOf.call(this,t,e);if(Buffer.isBuffer(t))return r(this,t,e);if("number"==typeof t)return Buffer.TYPED_ARRAY_SUPPORT&&"function"===Uint8Array.prototype.indexOf?Uint8Array.prototype.indexOf.call(this,t,e):r(this,[t],e);throw new TypeError("val must be string, number or Buffer")},Buffer.prototype.get=function(t){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(t)},Buffer.prototype.set=function(t,e){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(t,e)},Buffer.prototype.write=function(t,e,r,n){if(isFinite(e))isFinite(r)||(n=r,r=void 0);else{var i=n;n=e,e=r,r=i}if(e=Number(e)||0,0>r||0>e||e>this.length)throw new RangeError("attempt to write outside buffer bounds");var f=this.length-e;r?(r=Number(r),r>f&&(r=f)):r=f,n=String(n||"utf8").toLowerCase();var o;switch(n){case"hex":o=hexWrite(this,t,e,r);break;case"utf8":case"utf-8":o=utf8Write(this,t,e,r);break;case"ascii":o=asciiWrite(this,t,e,r);break;case"binary":o=binaryWrite(this,t,e,r);break;case"base64":o=base64Write(this,t,e,r);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":o=utf16leWrite(this,t,e,r);break;default:throw new TypeError("Unknown encoding: "+n)}return o},Buffer.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},Buffer.prototype.slice=function(t,e){var r=this.length;t=~~t,e=void 0===e?r:~~e,0>t?(t+=r,0>t&&(t=0)):t>r&&(t=r),0>e?(e+=r,0>e&&(e=0)):e>r&&(e=r),t>e&&(e=t);var n;if(Buffer.TYPED_ARRAY_SUPPORT)n=Buffer._augment(this.subarray(t,e));else{var i=e-t;n=new Buffer(i,void 0);for(var f=0;i>f;f++)n[f]=this[f+t]}return n.length&&(n.parent=this.parent||this),n},Buffer.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||checkOffset(t,e,this.length);for(var n=this[t],i=1,f=0;++f<e&&(i*=256);)n+=this[t+f]*i;return n},Buffer.prototype.readUIntBE=function(t,e,r){t>>>=0,e>>>=0,r||checkOffset(t,e,this.length);for(var n=this[t+--e],i=1;e>0&&(i*=256);)n+=this[t+--e]*i;return n},Buffer.prototype.readUInt8=function(t,e){return e||checkOffset(t,1,this.length),this[t]},Buffer.prototype.readUInt16LE=function(t,e){return e||checkOffset(t,2,this.length),this[t]|this[t+1]<<8},Buffer.prototype.readUInt16BE=function(t,e){return e||checkOffset(t,2,this.length),this[t]<<8|this[t+1]},Buffer.prototype.readUInt32LE=function(t,e){return e||checkOffset(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},Buffer.prototype.readUInt32BE=function(t,e){return e||checkOffset(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},Buffer.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||checkOffset(t,e,this.length);for(var n=this[t],i=1,f=0;++f<e&&(i*=256);)n+=this[t+f]*i;return i*=128,n>=i&&(n-=Math.pow(2,8*e)),n},Buffer.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||checkOffset(t,e,this.length);for(var n=e,i=1,f=this[t+--n];n>0&&(i*=256);)f+=this[t+--n]*i;return i*=128,f>=i&&(f-=Math.pow(2,8*e)),f},Buffer.prototype.readInt8=function(t,e){return e||checkOffset(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},Buffer.prototype.readInt16LE=function(t,e){e||checkOffset(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},Buffer.prototype.readInt16BE=function(t,e){e||checkOffset(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},Buffer.prototype.readInt32LE=function(t,e){return e||checkOffset(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},Buffer.prototype.readInt32BE=function(t,e){return e||checkOffset(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},Buffer.prototype.readFloatLE=function(t,e){return e||checkOffset(t,4,this.length),ieee754.read(this,t,!0,23,4)},Buffer.prototype.readFloatBE=function(t,e){return e||checkOffset(t,4,this.length),ieee754.read(this,t,!1,23,4)},Buffer.prototype.readDoubleLE=function(t,e){return e||checkOffset(t,8,this.length),ieee754.read(this,t,!0,52,8)},Buffer.prototype.readDoubleBE=function(t,e){return e||checkOffset(t,8,this.length),ieee754.read(this,t,!1,52,8)},Buffer.prototype.writeUIntLE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||checkInt(this,t,e,r,Math.pow(2,8*r),0);var i=1,f=0;for(this[e]=255&t;++f<r&&(i*=256);)this[e+f]=t/i>>>0&255;return e+r},Buffer.prototype.writeUIntBE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||checkInt(this,t,e,r,Math.pow(2,8*r),0);var i=r-1,f=1;for(this[e+i]=255&t;--i>=0&&(f*=256);)this[e+i]=t/f>>>0&255;return e+r},Buffer.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,1,255,0),Buffer.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=t,e+1},Buffer.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,2,65535,0),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8):objectWriteUInt16(this,t,e,!0),e+2},Buffer.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,2,65535,0),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t):objectWriteUInt16(this,t,e,!1),e+2},Buffer.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,4,4294967295,0),Buffer.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=t):objectWriteUInt32(this,t,e,!0),e+4},Buffer.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,4,4294967295,0),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t):objectWriteUInt32(this,t,e,!1),e+4},Buffer.prototype.writeIntLE=function(t,e,r,n){t=+t,e>>>=0,n||checkInt(this,t,e,r,Math.pow(2,8*r-1)-1,-Math.pow(2,8*r-1));var i=0,f=1,o=0>t?1:0;for(this[e]=255&t;++i<r&&(f*=256);)this[e+i]=(t/f>>0)-o&255;return e+r},Buffer.prototype.writeIntBE=function(t,e,r,n){t=+t,e>>>=0,n||checkInt(this,t,e,r,Math.pow(2,8*r-1)-1,-Math.pow(2,8*r-1));var i=r-1,f=1,o=0>t?1:0;for(this[e+i]=255&t;--i>=0&&(f*=256);)this[e+i]=(t/f>>0)-o&255;return e+r},Buffer.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,1,127,-128),Buffer.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),0>t&&(t=255+t+1),this[e]=t,e+1},Buffer.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,2,32767,-32768),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8):objectWriteUInt16(this,t,e,!0),e+2},Buffer.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,2,32767,-32768),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t):objectWriteUInt16(this,t,e,!1),e+2},Buffer.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,4,2147483647,-2147483648),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):objectWriteUInt32(this,t,e,!0),e+4},Buffer.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||checkInt(this,t,e,4,2147483647,-2147483648),0>t&&(t=4294967295+t+1),Buffer.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t):objectWriteUInt32(this,t,e,!1),e+4},Buffer.prototype.writeFloatLE=function(t,e,r){return writeFloat(this,t,e,!0,r)},Buffer.prototype.writeFloatBE=function(t,e,r){return writeFloat(this,t,e,!1,r)},Buffer.prototype.writeDoubleLE=function(t,e,r){return writeDouble(this,t,e,!0,r)},Buffer.prototype.writeDoubleBE=function(t,e,r){return writeDouble(this,t,e,!1,r)},Buffer.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&r>n&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(0>e)throw new RangeError("targetStart out of bounds");if(0>r||r>=this.length)throw new RangeError("sourceStart out of bounds");if(0>n)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var i=n-r;if(1e3>i||!Buffer.TYPED_ARRAY_SUPPORT)for(var f=0;i>f;f++)t[f+e]=this[f+r];else t._set(this.subarray(r,r+i),e);return i},Buffer.prototype.fill=function(t,e,r){if(t||(t=0),e||(e=0),r||(r=this.length),e>r)throw new RangeError("end < start");if(r!==e&&0!==this.length){if(0>e||e>=this.length)throw new RangeError("start out of bounds");if(0>r||r>this.length)throw new RangeError("end out of bounds");var n;if("number"==typeof t)for(n=e;r>n;n++)this[n]=t;else{var i=utf8ToBytes(t.toString()),f=i.length;for(n=e;r>n;n++)this[n]=i[n%f]}return this}},Buffer.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(Buffer.TYPED_ARRAY_SUPPORT)return new Buffer(this).buffer;for(var t=new Uint8Array(this.length),e=0,r=t.length;r>e;e+=1)t[e]=this[e];return t.buffer}throw new TypeError("Buffer.toArrayBuffer not supported in this browser")};var BP=Buffer.prototype;Buffer._augment=function(t){return t.constructor=Buffer,t._isBuffer=!0,t._set=t.set,t.get=BP.get,t.set=BP.set,t.write=BP.write,t.toString=BP.toString,t.toLocaleString=BP.toString,t.toJSON=BP.toJSON,t.equals=BP.equals,t.compare=BP.compare,t.indexOf=BP.indexOf,t.copy=BP.copy,t.slice=BP.slice,t.readUIntLE=BP.readUIntLE,t.readUIntBE=BP.readUIntBE,t.readUInt8=BP.readUInt8,t.readUInt16LE=BP.readUInt16LE,t.readUInt16BE=BP.readUInt16BE,t.readUInt32LE=BP.readUInt32LE,t.readUInt32BE=BP.readUInt32BE,t.readIntLE=BP.readIntLE,t.readIntBE=BP.readIntBE,t.readInt8=BP.readInt8,t.readInt16LE=BP.readInt16LE,t.readInt16BE=BP.readInt16BE,t.readInt32LE=BP.readInt32LE,t.readInt32BE=BP.readInt32BE,t.readFloatLE=BP.readFloatLE,t.readFloatBE=BP.readFloatBE,t.readDoubleLE=BP.readDoubleLE,t.readDoubleBE=BP.readDoubleBE,t.writeUInt8=BP.writeUInt8,t.writeUIntLE=BP.writeUIntLE,t.writeUIntBE=BP.writeUIntBE,t.writeUInt16LE=BP.writeUInt16LE,t.writeUInt16BE=BP.writeUInt16BE,t.writeUInt32LE=BP.writeUInt32LE,t.writeUInt32BE=BP.writeUInt32BE,t.writeIntLE=BP.writeIntLE,t.writeIntBE=BP.writeIntBE,t.writeInt8=BP.writeInt8,t.writeInt16LE=BP.writeInt16LE,t.writeInt16BE=BP.writeInt16BE,t.writeInt32LE=BP.writeInt32LE,t.writeInt32BE=BP.writeInt32BE,t.writeFloatLE=BP.writeFloatLE,t.writeFloatBE=BP.writeFloatBE,t.writeDoubleLE=BP.writeDoubleLE,t.writeDoubleBE=BP.writeDoubleBE,t.fill=BP.fill,t.inspect=BP.inspect,t.toArrayBuffer=BP.toArrayBuffer,t};var INVALID_BASE64_RE=/[^+\/0-9A-z\-]/g;
  },{"base64-js":7,"ieee754":8,"is-array":9}],7:[function(require,module,exports){
  var lookup="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(t){"use strict";function r(t){var r=t.charCodeAt(0);return r===h||r===u?62:r===c||r===f?63:o>r?-1:o+10>r?r-o+26+26:i+26>r?r-i:A+26>r?r-A+26:void 0}function e(t){function e(t){i[f++]=t}var n,h,c,o,A,i;if(t.length%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var u=t.length;A="="===t.charAt(u-2)?2:"="===t.charAt(u-1)?1:0,i=new a(3*t.length/4-A),c=A>0?t.length-4:t.length;var f=0;for(n=0,h=0;c>n;n+=4,h+=3)o=r(t.charAt(n))<<18|r(t.charAt(n+1))<<12|r(t.charAt(n+2))<<6|r(t.charAt(n+3)),e((16711680&o)>>16),e((65280&o)>>8),e(255&o);return 2===A?(o=r(t.charAt(n))<<2|r(t.charAt(n+1))>>4,e(255&o)):1===A&&(o=r(t.charAt(n))<<10|r(t.charAt(n+1))<<4|r(t.charAt(n+2))>>2,e(o>>8&255),e(255&o)),i}function n(t){function r(t){return lookup.charAt(t)}function e(t){return r(t>>18&63)+r(t>>12&63)+r(t>>6&63)+r(63&t)}var n,a,h,c=t.length%3,o="";for(n=0,h=t.length-c;h>n;n+=3)a=(t[n]<<16)+(t[n+1]<<8)+t[n+2],o+=e(a);switch(c){case 1:a=t[t.length-1],o+=r(a>>2),o+=r(a<<4&63),o+="==";break;case 2:a=(t[t.length-2]<<8)+t[t.length-1],o+=r(a>>10),o+=r(a>>4&63),o+=r(a<<2&63),o+="="}return o}var a="undefined"!=typeof Uint8Array?Uint8Array:Array,h="+".charCodeAt(0),c="/".charCodeAt(0),o="0".charCodeAt(0),A="a".charCodeAt(0),i="A".charCodeAt(0),u="-".charCodeAt(0),f="_".charCodeAt(0);t.toByteArray=e,t.fromByteArray=n}("undefined"==typeof exports?this.base64js={}:exports);
  },{}],8:[function(require,module,exports){
  exports.read=function(o,t,a,r,h){var M,p,w=8*h-r-1,f=(1<<w)-1,e=f>>1,i=-7,n=a?h-1:0,s=a?-1:1,N=o[t+n];for(n+=s,M=N&(1<<-i)-1,N>>=-i,i+=w;i>0;M=256*M+o[t+n],n+=s,i-=8);for(p=M&(1<<-i)-1,M>>=-i,i+=r;i>0;p=256*p+o[t+n],n+=s,i-=8);if(0===M)M=1-e;else{if(M===f)return p?0/0:(N?-1:1)*(1/0);p+=Math.pow(2,r),M-=e}return(N?-1:1)*p*Math.pow(2,M-r)},exports.write=function(o,t,a,r,h,M){var p,w,f,e=8*M-h-1,i=(1<<e)-1,n=i>>1,s=23===h?Math.pow(2,-24)-Math.pow(2,-77):0,N=r?0:M-1,u=r?1:-1,l=0>t||0===t&&0>1/t?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(w=isNaN(t)?1:0,p=i):(p=Math.floor(Math.log(t)/Math.LN2),t*(f=Math.pow(2,-p))<1&&(p--,f*=2),t+=p+n>=1?s/f:s*Math.pow(2,1-n),t*f>=2&&(p++,f/=2),p+n>=i?(w=0,p=i):p+n>=1?(w=(t*f-1)*Math.pow(2,h),p+=n):(w=t*Math.pow(2,n-1)*Math.pow(2,h),p=0));h>=8;o[a+N]=255&w,N+=u,w/=256,h-=8);for(p=p<<h|w,e+=h;e>0;o[a+N]=255&p,N+=u,p/=256,e-=8);o[a+N-u]|=128*l};
  },{}],9:[function(require,module,exports){
  var isArray=Array.isArray,str=Object.prototype.toString;module.exports=isArray||function(r){return!!r&&"[object Array]"==str.call(r)};
  },{}],10:[function(require,module,exports){
  (function (global){
  !function(o){function e(o){throw RangeError(L[o])}function n(o,e){for(var n=o.length;n--;)o[n]=e(o[n]);return o}function t(o,e){return n(o.split(S),e).join(".")}function r(o){for(var e,n,t=[],r=0,u=o.length;u>r;)e=o.charCodeAt(r++),e>=55296&&56319>=e&&u>r?(n=o.charCodeAt(r++),56320==(64512&n)?t.push(((1023&e)<<10)+(1023&n)+65536):(t.push(e),r--)):t.push(e);return t}function u(o){return n(o,function(o){var e="";return o>65535&&(o-=65536,e+=R(o>>>10&1023|55296),o=56320|1023&o),e+=R(o)}).join("")}function i(o){return 10>o-48?o-22:26>o-65?o-65:26>o-97?o-97:x}function f(o,e){return o+22+75*(26>o)-((0!=e)<<5)}function c(o,e,n){var t=0;for(o=n?P(o/m):o>>1,o+=P(o/e);o>M*C>>1;t+=x)o=P(o/M);return P(t+(M+1)*o/(o+j))}function l(o){var n,t,r,f,l,d,s,a,p,h,v=[],g=o.length,w=0,j=I,m=A;for(t=o.lastIndexOf(F),0>t&&(t=0),r=0;t>r;++r)o.charCodeAt(r)>=128&&e("not-basic"),v.push(o.charCodeAt(r));for(f=t>0?t+1:0;g>f;){for(l=w,d=1,s=x;f>=g&&e("invalid-input"),a=i(o.charCodeAt(f++)),(a>=x||a>P((b-w)/d))&&e("overflow"),w+=a*d,p=m>=s?y:s>=m+C?C:s-m,!(p>a);s+=x)h=x-p,d>P(b/h)&&e("overflow"),d*=h;n=v.length+1,m=c(w-l,n,0==l),P(w/n)>b-j&&e("overflow"),j+=P(w/n),w%=n,v.splice(w++,0,j)}return u(v)}function d(o){var n,t,u,i,l,d,s,a,p,h,v,g,w,j,m,E=[];for(o=r(o),g=o.length,n=I,t=0,l=A,d=0;g>d;++d)v=o[d],128>v&&E.push(R(v));for(u=i=E.length,i&&E.push(F);g>u;){for(s=b,d=0;g>d;++d)v=o[d],v>=n&&s>v&&(s=v);for(w=u+1,s-n>P((b-t)/w)&&e("overflow"),t+=(s-n)*w,n=s,d=0;g>d;++d)if(v=o[d],n>v&&++t>b&&e("overflow"),v==n){for(a=t,p=x;h=l>=p?y:p>=l+C?C:p-l,!(h>a);p+=x)m=a-h,j=x-h,E.push(R(f(h+m%j,0))),a=P(m/j);E.push(R(f(a,0))),l=c(t,w,u==i),t=0,++u}++t,++n}return E.join("")}function s(o){return t(o,function(o){return E.test(o)?l(o.slice(4).toLowerCase()):o})}function a(o){return t(o,function(o){return O.test(o)?"xn--"+d(o):o})}var p="object"==typeof exports&&exports,h="object"==typeof module&&module&&module.exports==p&&module,v="object"==typeof global&&global;(v.global===v||v.window===v)&&(o=v);var g,w,b=2147483647,x=36,y=1,C=26,j=38,m=700,A=72,I=128,F="-",E=/^xn--/,O=/[^ -~]/,S=/\x2E|\u3002|\uFF0E|\uFF61/g,L={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},M=x-y,P=Math.floor,R=String.fromCharCode;if(g={version:"1.2.4",ucs2:{decode:r,encode:u},decode:l,encode:d,toASCII:a,toUnicode:s},"function"==typeof define&&"object"==typeof define.amd&&define.amd)define("punycode",function(){return g});else if(p&&!p.nodeType)if(h)h.exports=g;else for(w in g)g.hasOwnProperty(w)&&(p[w]=g[w]);else o.punycode=g}(this);
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  
  },{}],11:[function(require,module,exports){
  "use strict";function hasOwnProperty(r,e){return Object.prototype.hasOwnProperty.call(r,e)}module.exports=function(r,e,t,n){e=e||"&",t=t||"=";var o={};if("string"!=typeof r||0===r.length)return o;var a=/\+/g;r=r.split(e);var s=1e3;n&&"number"==typeof n.maxKeys&&(s=n.maxKeys);var p=r.length;s>0&&p>s&&(p=s);for(var y=0;p>y;++y){var u,c,i,l,f=r[y].replace(a,"%20"),v=f.indexOf(t);v>=0?(u=f.substr(0,v),c=f.substr(v+1)):(u=f,c=""),i=decodeURIComponent(u),l=decodeURIComponent(c),hasOwnProperty(o,i)?isArray(o[i])?o[i].push(l):o[i]=[o[i],l]:o[i]=l}return o};var isArray=Array.isArray||function(r){return"[object Array]"===Object.prototype.toString.call(r)};
  },{}],12:[function(require,module,exports){
  "use strict";function map(r,e){if(r.map)return r.map(e);for(var t=[],n=0;n<r.length;n++)t.push(e(r[n],n));return t}var stringifyPrimitive=function(r){switch(typeof r){case"string":return r;case"boolean":return r?"true":"false";case"number":return isFinite(r)?r:"";default:return""}};module.exports=function(r,e,t,n){return e=e||"&",t=t||"=",null===r&&(r=void 0),"object"==typeof r?map(objectKeys(r),function(n){var i=encodeURIComponent(stringifyPrimitive(n))+t;return isArray(r[n])?map(r[n],function(r){return i+encodeURIComponent(stringifyPrimitive(r))}).join(e):i+encodeURIComponent(stringifyPrimitive(r[n]))}).join(e):n?encodeURIComponent(stringifyPrimitive(n))+t+encodeURIComponent(stringifyPrimitive(r)):""};var isArray=Array.isArray||function(r){return"[object Array]"===Object.prototype.toString.call(r)},objectKeys=Object.keys||function(r){var e=[];for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&e.push(t);return e};
  },{}],13:[function(require,module,exports){
  "use strict";exports.decode=exports.parse=require("./decode"),exports.encode=exports.stringify=require("./encode");
  },{"./decode":11,"./encode":12}],14:[function(require,module,exports){
  function Url(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}function urlParse(t,s,e){if(t&&isObject(t)&&t instanceof Url)return t;var h=new Url;return h.parse(t,s,e),h}function urlFormat(t){return isString(t)&&(t=urlParse(t)),t instanceof Url?t.format():Url.prototype.format.call(t)}function urlResolve(t,s){return urlParse(t,!1,!0).resolve(s)}function urlResolveObject(t,s){return t?urlParse(t,!1,!0).resolveObject(s):s}function isString(t){return"string"==typeof t}function isObject(t){return"object"==typeof t&&null!==t}function isNull(t){return null===t}function isNullOrUndefined(t){return null==t}var punycode=require("punycode");exports.parse=urlParse,exports.resolve=urlResolve,exports.resolveObject=urlResolveObject,exports.format=urlFormat,exports.Url=Url;var protocolPattern=/^([a-z0-9.+-]+:)/i,portPattern=/:[0-9]*$/,delims=["<",">",'"',"`"," ","\r","\n","	"],unwise=["{","}","|","\\","^","`"].concat(delims),autoEscape=["'"].concat(unwise),nonHostChars=["%","/","?",";","#"].concat(autoEscape),hostEndingChars=["/","?","#"],hostnameMaxLen=255,hostnamePartPattern=/^[a-z0-9A-Z_-]{0,63}$/,hostnamePartStart=/^([a-z0-9A-Z_-]{0,63})(.*)$/,unsafeProtocol={javascript:!0,"javascript:":!0},hostlessProtocol={javascript:!0,"javascript:":!0},slashedProtocol={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},querystring=require("querystring");Url.prototype.parse=function(t,s,e){if(!isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var h=t;h=h.trim();var r=protocolPattern.exec(h);if(r){r=r[0];var o=r.toLowerCase();this.protocol=o,h=h.substr(r.length)}if(e||r||h.match(/^\/\/[^@\/]+@[^@\/]+/)){var a="//"===h.substr(0,2);!a||r&&hostlessProtocol[r]||(h=h.substr(2),this.slashes=!0)}if(!hostlessProtocol[r]&&(a||r&&!slashedProtocol[r])){for(var n=-1,i=0;i<hostEndingChars.length;i++){var l=h.indexOf(hostEndingChars[i]);-1!==l&&(-1===n||n>l)&&(n=l)}var c,u;u=-1===n?h.lastIndexOf("@"):h.lastIndexOf("@",n),-1!==u&&(c=h.slice(0,u),h=h.slice(u+1),this.auth=decodeURIComponent(c)),n=-1;for(var i=0;i<nonHostChars.length;i++){var l=h.indexOf(nonHostChars[i]);-1!==l&&(-1===n||n>l)&&(n=l)}-1===n&&(n=h.length),this.host=h.slice(0,n),h=h.slice(n),this.parseHost(),this.hostname=this.hostname||"";var p="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!p)for(var f=this.hostname.split(/\./),i=0,m=f.length;m>i;i++){var v=f[i];if(v&&!v.match(hostnamePartPattern)){for(var g="",y=0,d=v.length;d>y;y++)g+=v.charCodeAt(y)>127?"x":v[y];if(!g.match(hostnamePartPattern)){var P=f.slice(0,i),b=f.slice(i+1),j=v.match(hostnamePartStart);j&&(P.push(j[1]),b.unshift(j[2])),b.length&&(h="/"+b.join(".")+h),this.hostname=P.join(".");break}}}if(this.hostname=this.hostname.length>hostnameMaxLen?"":this.hostname.toLowerCase(),!p){for(var O=this.hostname.split("."),q=[],i=0;i<O.length;++i){var x=O[i];q.push(x.match(/[^A-Za-z0-9_-]/)?"xn--"+punycode.encode(x):x)}this.hostname=q.join(".")}var U=this.port?":"+this.port:"",C=this.hostname||"";this.host=C+U,this.href+=this.host,p&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==h[0]&&(h="/"+h))}if(!unsafeProtocol[o])for(var i=0,m=autoEscape.length;m>i;i++){var A=autoEscape[i],E=encodeURIComponent(A);E===A&&(E=escape(A)),h=h.split(A).join(E)}var w=h.indexOf("#");-1!==w&&(this.hash=h.substr(w),h=h.slice(0,w));var R=h.indexOf("?");if(-1!==R?(this.search=h.substr(R),this.query=h.substr(R+1),s&&(this.query=querystring.parse(this.query)),h=h.slice(0,R)):s&&(this.search="",this.query={}),h&&(this.pathname=h),slashedProtocol[o]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var U=this.pathname||"",x=this.search||"";this.path=U+x}return this.href=this.format(),this},Url.prototype.format=function(){var t=this.auth||"";t&&(t=encodeURIComponent(t),t=t.replace(/%3A/i,":"),t+="@");var s=this.protocol||"",e=this.pathname||"",h=this.hash||"",r=!1,o="";this.host?r=t+this.host:this.hostname&&(r=t+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(r+=":"+this.port)),this.query&&isObject(this.query)&&Object.keys(this.query).length&&(o=querystring.stringify(this.query));var a=this.search||o&&"?"+o||"";return s&&":"!==s.substr(-1)&&(s+=":"),this.slashes||(!s||slashedProtocol[s])&&r!==!1?(r="//"+(r||""),e&&"/"!==e.charAt(0)&&(e="/"+e)):r||(r=""),h&&"#"!==h.charAt(0)&&(h="#"+h),a&&"?"!==a.charAt(0)&&(a="?"+a),e=e.replace(/[?#]/g,function(t){return encodeURIComponent(t)}),a=a.replace("#","%23"),s+r+e+a+h},Url.prototype.resolve=function(t){return this.resolveObject(urlParse(t,!1,!0)).format()},Url.prototype.resolveObject=function(t){if(isString(t)){var s=new Url;s.parse(t,!1,!0),t=s}var e=new Url;if(Object.keys(this).forEach(function(t){e[t]=this[t]},this),e.hash=t.hash,""===t.href)return e.href=e.format(),e;if(t.slashes&&!t.protocol)return Object.keys(t).forEach(function(s){"protocol"!==s&&(e[s]=t[s])}),slashedProtocol[e.protocol]&&e.hostname&&!e.pathname&&(e.path=e.pathname="/"),e.href=e.format(),e;if(t.protocol&&t.protocol!==e.protocol){if(!slashedProtocol[t.protocol])return Object.keys(t).forEach(function(s){e[s]=t[s]}),e.href=e.format(),e;if(e.protocol=t.protocol,t.host||hostlessProtocol[t.protocol])e.pathname=t.pathname;else{for(var h=(t.pathname||"").split("/");h.length&&!(t.host=h.shift()););t.host||(t.host=""),t.hostname||(t.hostname=""),""!==h[0]&&h.unshift(""),h.length<2&&h.unshift(""),e.pathname=h.join("/")}if(e.search=t.search,e.query=t.query,e.host=t.host||"",e.auth=t.auth,e.hostname=t.hostname||t.host,e.port=t.port,e.pathname||e.search){var r=e.pathname||"",o=e.search||"";e.path=r+o}return e.slashes=e.slashes||t.slashes,e.href=e.format(),e}var a=e.pathname&&"/"===e.pathname.charAt(0),n=t.host||t.pathname&&"/"===t.pathname.charAt(0),i=n||a||e.host&&t.pathname,l=i,c=e.pathname&&e.pathname.split("/")||[],h=t.pathname&&t.pathname.split("/")||[],u=e.protocol&&!slashedProtocol[e.protocol];if(u&&(e.hostname="",e.port=null,e.host&&(""===c[0]?c[0]=e.host:c.unshift(e.host)),e.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(""===h[0]?h[0]=t.host:h.unshift(t.host)),t.host=null),i=i&&(""===h[0]||""===c[0])),n)e.host=t.host||""===t.host?t.host:e.host,e.hostname=t.hostname||""===t.hostname?t.hostname:e.hostname,e.search=t.search,e.query=t.query,c=h;else if(h.length)c||(c=[]),c.pop(),c=c.concat(h),e.search=t.search,e.query=t.query;else if(!isNullOrUndefined(t.search)){if(u){e.hostname=e.host=c.shift();var p=e.host&&e.host.indexOf("@")>0?e.host.split("@"):!1;p&&(e.auth=p.shift(),e.host=e.hostname=p.shift())}return e.search=t.search,e.query=t.query,isNull(e.pathname)&&isNull(e.search)||(e.path=(e.pathname?e.pathname:"")+(e.search?e.search:"")),e.href=e.format(),e}if(!c.length)return e.pathname=null,e.path=e.search?"/"+e.search:null,e.href=e.format(),e;for(var f=c.slice(-1)[0],m=(e.host||t.host)&&("."===f||".."===f)||""===f,v=0,g=c.length;g>=0;g--)f=c[g],"."==f?c.splice(g,1):".."===f?(c.splice(g,1),v++):v&&(c.splice(g,1),v--);if(!i&&!l)for(;v--;v)c.unshift("..");!i||""===c[0]||c[0]&&"/"===c[0].charAt(0)||c.unshift(""),m&&"/"!==c.join("/").substr(-1)&&c.push("");var y=""===c[0]||c[0]&&"/"===c[0].charAt(0);if(u){e.hostname=e.host=y?"":c.length?c.shift():"";var p=e.host&&e.host.indexOf("@")>0?e.host.split("@"):!1;p&&(e.auth=p.shift(),e.host=e.hostname=p.shift())}return i=i||e.host&&c.length,i&&!y&&c.unshift(""),c.length?e.pathname=c.join("/"):(e.pathname=null,e.path=null),isNull(e.pathname)&&isNull(e.search)||(e.path=(e.pathname?e.pathname:"")+(e.search?e.search:"")),e.auth=t.auth||e.auth,e.slashes=e.slashes||t.slashes,e.href=e.format(),e},Url.prototype.parseHost=function(){var t=this.host,s=portPattern.exec(t);s&&(s=s[0],":"!==s&&(this.port=s.substr(1)),t=t.substr(0,t.length-s.length)),t&&(this.hostname=t)};
  },{"punycode":10,"querystring":13}],15:[function(require,module,exports){
  "use strict";module.exports=function(){return document.createElement("canvas")};
  },{}],16:[function(require,module,exports){
  (function (Buffer){
  !function(t,e){var a=this;if("undefined"!=typeof module){try{var n=require("canvas")}catch(i){throw new Error(i.message+"\nPlease see https://github.com/HumbleSoftware/js-imagediff#cannot-find-module-canvas\n")}module.exports=e(a,t,n)}else"function"==typeof define&&"object"==typeof define.amd?define(e):a[t]=e(a,t)}("imagediff",function(t,e,a){function n(t,e){var n=a?new a:document.createElement("canvas");return t&&(n.width=t),e&&(n.height=e),n}function i(t,e){return F.width=t,F.height=e,P.clearRect(0,0,t,e),P.createImageData(t,e)}function r(){return a}function o(t){return c(t,L)}function h(t){return c(t,R)}function u(t){return c(t,H)}function f(t){return!(!t||!c(t,S)||typeof t.width===B||typeof t.height===B||typeof t.data===B)}function d(t){return o(t)||h(t)||u(t)||f(t)}function c(t,e){return"object"==typeof t&&!!Object.prototype.toString.apply(t).match(e)}function g(t){var e,a,n,i=t.height,r=t.width,o=t.data;for(F.width=r,F.height=i,e=P.getImageData(0,0,r,i),a=e.data,n=t.data.length;n--;)a[n]=o[n];return e}function s(t){return o(t)?l(t):h(t)?m(t):u(t)?v(t):f(t)?t:void 0}function l(t){var e=t.height,a=t.width;return F.width=a,F.height=e,P.clearRect(0,0,a,e),P.drawImage(t,0,0),P.getImageData(0,0,a,e)}function m(t){var e=t.height,a=t.width,n=t.getContext("2d");return n.getImageData(0,0,a,e)}function v(t){var e=t.canvas,a=e.height,n=e.width;return t.getImageData(0,0,n,a)}function p(t){var e=s(t),a=n(e.width,e.height),i=a.getContext("2d");return i.putImageData(e,0,0),a}function w(t,e){return t.width===e.width}function b(t,e){return t.height===e.height}function I(t,e){return b(t,e)&&w(t,e)}function C(t,e,a){var n,i=t.data,r=e.data,o=i.length;if(a=a||0,!I(t,e))return!1;for(n=o;n--;)if(i[n]!==r[n]&&Math.abs(i[n]-r[n])>a)return!1;return!0}function y(t,e,a){return(I(t,e)?D:M)(t,e,a)}function D(t,e,a){var n,r=t.height,o=t.width,h=i(o,r),u=t.data,f=e.data,d=h.data,c=d.length;for(n=0;c>n;n+=4)d[n]=Math.abs(u[n]-f[n]),d[n+1]=Math.abs(u[n+1]-f[n+1]),d[n+2]=Math.abs(u[n+2]-f[n+2]),d[n+3]=Math.abs(255-Math.abs(u[n+3]-f[n+3]));return h}function M(t,e,a){function n(t){"top"===p?(r=0,o=0):(r=Math.floor((c-t.height)/2),o=Math.floor((g-t.width)/2))}var r,o,h,u,f,d,c=Math.max(t.height,e.height),g=Math.max(t.width,e.width),s=i(g,c),l=t.data,m=e.data,v=s.data,p=a&&a.align;for(f=v.length-1;f>0;f-=4)v[f]=255;for(n(t),h=t.height;h--;)for(u=t.width;u--;)f=4*((h+r)*g+(u+o)),d=4*(h*t.width+u),v[f+0]=l[d+0],v[f+1]=l[d+1],v[f+2]=l[d+2];for(n(e),h=e.height;h--;)for(u=e.width;u--;)f=4*((h+r)*g+(u+o)),d=4*(h*e.width+u),v[f+0]=Math.abs(v[f+0]-m[d+0]),v[f+1]=Math.abs(v[f+1]-m[d+1]),v[f+2]=Math.abs(v[f+2]-m[d+2]);return s}function x(){var t;for(t=0;t<arguments.length;t++)if(!d(arguments[t]))throw{name:"ImageTypeError",message:"Submitted object was not an image."}}function j(t,e){return t=document.createElement(t),t&&e&&(t.innerHTML=e),t}function E(t,e,a){var n,i,r=p(t);a=a||Function,n=r.toDataURL().replace(/^data:image\/\w+;base64,/,""),i=new Buffer(n,"base64"),require("fs").writeFile(e,i,a)}var q,T,R=/\[object (Canvas|HTMLCanvasElement)\]/i,H=/\[object CanvasRenderingContext2D\]/i,L=/\[object (Image|HTMLImageElement)\]/i,S=/\[object ImageData\]/i,B="undefined",F=n(),P=F.getContext("2d"),A=t[e];return T={toBeImageData:function(){return q.isImageData(this.actual)},toImageDiffEqual:function(t,e){return typeof document!==B&&(this.message=function(){var e,a=j("div"),i=j("div","<div>Actual:</div>"),r=j("div","<div>Expected:</div>"),o=j("div","<div>Diff:</div>"),h=q.diff(this.actual,t),u=n();return u.height=h.height,u.width=h.width,a.style.overflow="hidden",i.style["float"]="left",r.style["float"]="left",o.style["float"]="left",e=u.getContext("2d"),e.putImageData(h,0,0),i.appendChild(p(this.actual)),r.appendChild(p(t)),o.appendChild(u),a.appendChild(i),a.appendChild(r),a.appendChild(o),[a,"Expected not to be equal."]}),q.equal(this.actual,t,e)}},q={createCanvas:n,createImageData:i,getCanvasRef:r,isImage:o,isCanvas:h,isContext:u,isImageData:f,isImageType:d,toImageData:function(t){return x(t),f(t)?g(t):s(t)},equal:function(t,e,a){return x(t,e),t=s(t),e=s(e),C(t,e,a)},diff:function(t,e,a){return x(t,e),t=s(t),e=s(e),y(t,e,a)},jasmine:T,noConflict:function(){return t[e]=A,q}},"undefined"!=typeof module&&(q.imageDataToPNG=E),q});
  }).call(this,require("buffer").Buffer)
  
  },{"buffer":6,"canvas":15,"fs":5}],17:[function(require,module,exports){
  module.exports=function(){function r(r,t){function n(){this.constructor=r}n.prototype=t.prototype,r.prototype=new n}function t(r,t,n,e,u,o){this.message=r,this.expected=t,this.found=n,this.offset=e,this.line=u,this.column=o,this.name="SyntaxError"}function n(r){function n(t){function n(t,n,e){var u,o;for(u=n;e>u;u++)o=r.charAt(u),"\n"===o?(t.seenCR||t.line++,t.column=1,t.seenCR=!1):"\r"===o||"\u2028"===o||"\u2029"===o?(t.line++,t.column=1,t.seenCR=!0):(t.column++,t.seenCR=!1)}return O!==t&&(O>t&&(O=0,P={line:1,column:1,seenCR:!1}),n(P,O,t),O=t),P}function e(r){Q>M||(M>Q&&(Q=M,T=[]),T.push(r))}function u(e,u,o){function i(r){var t=1;for(r.sort(function(r,t){return r.description<t.description?-1:r.description>t.description?1:0});t<r.length;)r[t-1]===r[t]?r.splice(t,1):t++}function c(r,t){function n(r){function t(r){return r.charCodeAt(0).toString(16).toUpperCase()}return r.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\x08/g,"\\b").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\f/g,"\\f").replace(/\r/g,"\\r").replace(/[\x00-\x07\x0B\x0E\x0F]/g,function(r){return"\\x0"+t(r)}).replace(/[\x10-\x1F\x80-\xFF]/g,function(r){return"\\x"+t(r)}).replace(/[\u0180-\u0FFF]/g,function(r){return"\\u0"+t(r)}).replace(/[\u1080-\uFFFF]/g,function(r){return"\\u"+t(r)})}var e,u,o,i=new Array(r.length);for(o=0;o<r.length;o++)i[o]=r[o].description;return e=r.length>1?i.slice(0,-1).join(", ")+" or "+i[r.length-1]:i[0],u=t?'"'+n(t)+'"':"end of input","Expected "+e+" but "+u+" found."}var l=n(o),a=o<r.length?r.charAt(o):null;return null!==u&&i(u),new t(null!==e?e:c(u,a),u,a,o,l.line,l.column)}function o(){var r,t;return r=i(),r===v&&(r=M,t=[],t!==v&&(N=r,t=y()),r=t),r}function i(){var t,n,u,o,l,a;if(t=M,n=c(),n!==v){for(u=[],o=h();o!==v;)u.push(o),o=h();if(u!==v)if(44===r.charCodeAt(M)?(o=C,M++):(o=v,0===W&&e(F)),o!==v){for(l=[],a=h();a!==v;)l.push(a),a=h();l!==v?(a=i(),a!==v?(N=t,n=R(n,a),t=n):(M=t,t=A)):(M=t,t=A)}else M=t,t=A;else M=t,t=A}else M=t,t=A;return t===v&&(t=M,n=c(),n!==v&&(N=t,n=w(n)),t=n),t}function c(){var r;return r=l(),r===v&&(r=f()),r}function l(){var r,t,n,e;if(r=M,t=a(),t!==v){if(n=[],e=h(),e!==v)for(;e!==v;)n.push(e),e=h();else n=A;n!==v?(e=s(),e!==v?(N=r,t=E(t,e),r=t):(M=r,r=A)):(M=r,r=A)}else M=r,r=A;return r===v&&(r=M,t=a(),t!==v&&(N=r,t=b(t)),r=t),r}function a(){var t,n,u,o;return t=M,r.substr(M,4)===S?(n=S,M+=4):(n=v,0===W&&e(j)),n!==v?(u=p(),u!==v?(41===r.charCodeAt(M)?(o=q,M++):(o=v,0===W&&e(B)),o!==v?(N=t,n=U(u),t=n):(M=t,t=A)):(M=t,t=A)):(M=t,t=A),t}function s(){var t,n,u,o;return t=M,r.substr(M,7)===V?(n=V,M+=7):(n=v,0===W&&e(k)),n!==v?(u=p(),u!==v?(41===r.charCodeAt(M)?(o=q,M++):(o=v,0===W&&e(B)),o!==v?(N=t,n=U(u),t=n):(M=t,t=A)):(M=t,t=A)):(M=t,t=A),t}function f(){var t,n,u,o;return t=M,r.substr(M,6)===z?(n=z,M+=6):(n=v,0===W&&e(D)),n!==v?(u=p(),u!==v?(41===r.charCodeAt(M)?(o=q,M++):(o=v,0===W&&e(B)),o!==v?(N=t,n=G(u),t=n):(M=t,t=A)):(M=t,t=A)):(M=t,t=A),t}function p(){var t,n,u;if(t=M,n=[],H.test(r.charAt(M))?(u=r.charAt(M),M++):(u=v,0===W&&e(I)),u!==v)for(;u!==v;)n.push(u),H.test(r.charAt(M))?(u=r.charAt(M),M++):(u=v,0===W&&e(I));else n=A;return n!==v&&(N=t,n=J(n)),t=n}function h(){var t;return K.test(r.charAt(M))?(t=r.charAt(M),M++):(t=v,0===W&&e(L)),t}var d,g=arguments.length>1?arguments[1]:{},v={},x={start:o},m=o,y=function(){return[]},A=v,C=",",F={type:"literal",value:",",description:'","'},R=function(r,t){return[r].concat(t)},w=function(r){return[r]},E=function(r,t){return{url:r,format:t}},b=function(r){return{url:r}},S="url(",j={type:"literal",value:"url(",description:'"url("'},q=")",B={type:"literal",value:")",description:'")"'},U=function(r){return r},V="format(",k={type:"literal",value:"format(",description:'"format("'},z="local(",D={type:"literal",value:"local(",description:'"local("'},G=function(r){return{local:r}},H=/^[^)]/,I={type:"class",value:"[^)]",description:"[^)]"},J=function(r){return X.extractValue(r.join(""))},K=/^[ \t\r\n\f]/,L={type:"class",value:"[ \\t\\r\\n\\f]",description:"[ \\t\\r\\n\\f]"},M=0,N=0,O=0,P={line:1,column:1,seenCR:!1},Q=0,T=[],W=0;if("startRule"in g){if(!(g.startRule in x))throw new Error("Can't start parsing from rule \""+g.startRule+'".');m=x[g.startRule]}var X=require("../util");if(d=m(),d!==v&&M===r.length)return d;throw d!==v&&M<r.length&&e({type:"end",description:"end of input"}),u(null,T,Q)}return r(t,Error),{SyntaxError:t,parse:n}}();
  },{"../util":19}],18:[function(require,module,exports){
  var grammar=require("./grammar");exports.SyntaxError=function(r,t){this.message=r,this.offset=t},exports.parse=function(r){try{return grammar.parse(r)}catch(t){throw new exports.SyntaxError(t.message,t.offset)}},exports.serialize=function(r){return r.map(function(r){var t;return r.url?(t='url("'+r.url+'")',r.format&&(t+=' format("'+r.format+'")')):t='local("'+r.local+'")',t}).join(", ")};
  },{"./grammar":17}],19:[function(require,module,exports){
  var trimCSSWhitespace=function(t){var e=/^[\t\r\f\n ]*(.+?)[\t\r\f\n ]*$/;return t.replace(e,"$1")},unquoteString=function(t){var e=/^"(.*)"$/,r=/^'(.*)'$/;return e.test(t)?t.replace(e,"$1"):r.test(t)?t.replace(r,"$1"):t};exports.extractValue=function(t){return unquoteString(trimCSSWhitespace(t))};
  },{}],20:[function(require,module,exports){
  var CSSOM={CSSRule:require("./CSSRule").CSSRule,MatcherList:require("./MatcherList").MatcherList};CSSOM.CSSDocumentRule=function(){CSSOM.CSSRule.call(this),this.matcher=new CSSOM.MatcherList,this.cssRules=[]},CSSOM.CSSDocumentRule.prototype=new CSSOM.CSSRule,CSSOM.CSSDocumentRule.prototype.constructor=CSSOM.CSSDocumentRule,CSSOM.CSSDocumentRule.prototype.type=10,Object.defineProperty(CSSOM.CSSDocumentRule.prototype,"cssText",{get:function(){for(var e=[],t=0,S=this.cssRules.length;S>t;t++)e.push(this.cssRules[t].cssText);return"@-moz-document "+this.matcher.matcherText+" {"+e.join("")+"}"}}),exports.CSSDocumentRule=CSSOM.CSSDocumentRule;
  },{"./CSSRule":26,"./MatcherList":32}],21:[function(require,module,exports){
  var CSSOM={CSSStyleDeclaration:require("./CSSStyleDeclaration").CSSStyleDeclaration,CSSRule:require("./CSSRule").CSSRule};CSSOM.CSSFontFaceRule=function(){CSSOM.CSSRule.call(this),this.style=new CSSOM.CSSStyleDeclaration,this.style.parentRule=this},CSSOM.CSSFontFaceRule.prototype=new CSSOM.CSSRule,CSSOM.CSSFontFaceRule.prototype.constructor=CSSOM.CSSFontFaceRule,CSSOM.CSSFontFaceRule.prototype.type=5,Object.defineProperty(CSSOM.CSSFontFaceRule.prototype,"cssText",{get:function(){return"@font-face {"+this.style.cssText+"}"}}),exports.CSSFontFaceRule=CSSOM.CSSFontFaceRule;
  },{"./CSSRule":26,"./CSSStyleDeclaration":27}],22:[function(require,module,exports){
  var CSSOM={CSSRule:require("./CSSRule").CSSRule,CSSStyleSheet:require("./CSSStyleSheet").CSSStyleSheet,MediaList:require("./MediaList").MediaList};CSSOM.CSSImportRule=function(){CSSOM.CSSRule.call(this),this.href="",this.media=new CSSOM.MediaList,this.styleSheet=new CSSOM.CSSStyleSheet},CSSOM.CSSImportRule.prototype=new CSSOM.CSSRule,CSSOM.CSSImportRule.prototype.constructor=CSSOM.CSSImportRule,CSSOM.CSSImportRule.prototype.type=3,Object.defineProperty(CSSOM.CSSImportRule.prototype,"cssText",{get:function(){var e=this.media.mediaText;return"@import url("+this.href+")"+(e?" "+e:"")+";"},set:function(e){for(var t,S,r=0,i="",a="";S=e.charAt(r);r++)switch(S){case" ":case"	":case"\r":case"\n":case"\f":"after-import"===i?i="url":a+=S;break;case"@":i||e.indexOf("@import",r)!==r||(i="after-import",r+="import".length,a="");break;case"u":if("url"===i&&e.indexOf("url(",r)===r){if(t=e.indexOf(")",r+1),-1===t)throw r+': ")" not found';r+="url(".length;var o=e.slice(r,t);o[0]===o[o.length-1]&&('"'===o[0]||"'"===o[0])&&(o=o.slice(1,-1)),this.href=o,r=t,i="media"}break;case'"':if("url"===i){if(t=e.indexOf('"',r+1),!t)throw r+": '\"' not found";this.href=e.slice(r+1,t),r=t,i="media"}break;case"'":if("url"===i){if(t=e.indexOf("'",r+1),!t)throw r+': "\'" not found';this.href=e.slice(r+1,t),r=t,i="media"}break;case";":"media"===i&&a&&(this.media.mediaText=a.trim());break;default:"media"===i&&(a+=S)}}}),exports.CSSImportRule=CSSOM.CSSImportRule;
  },{"./CSSRule":26,"./CSSStyleSheet":29,"./MediaList":33}],23:[function(require,module,exports){
  var CSSOM={CSSRule:require("./CSSRule").CSSRule,CSSStyleDeclaration:require("./CSSStyleDeclaration").CSSStyleDeclaration};CSSOM.CSSKeyframeRule=function(){CSSOM.CSSRule.call(this),this.keyText="",this.style=new CSSOM.CSSStyleDeclaration,this.style.parentRule=this},CSSOM.CSSKeyframeRule.prototype=new CSSOM.CSSRule,CSSOM.CSSKeyframeRule.prototype.constructor=CSSOM.CSSKeyframeRule,CSSOM.CSSKeyframeRule.prototype.type=9,Object.defineProperty(CSSOM.CSSKeyframeRule.prototype,"cssText",{get:function(){return this.keyText+" {"+this.style.cssText+"} "}}),exports.CSSKeyframeRule=CSSOM.CSSKeyframeRule;
  },{"./CSSRule":26,"./CSSStyleDeclaration":27}],24:[function(require,module,exports){
  var CSSOM={CSSRule:require("./CSSRule").CSSRule};CSSOM.CSSKeyframesRule=function(){CSSOM.CSSRule.call(this),this.name="",this.cssRules=[]},CSSOM.CSSKeyframesRule.prototype=new CSSOM.CSSRule,CSSOM.CSSKeyframesRule.prototype.constructor=CSSOM.CSSKeyframesRule,CSSOM.CSSKeyframesRule.prototype.type=8,Object.defineProperty(CSSOM.CSSKeyframesRule.prototype,"cssText",{get:function(){for(var e=[],S=0,s=this.cssRules.length;s>S;S++)e.push("  "+this.cssRules[S].cssText);return"@"+(this._vendorPrefix||"")+"keyframes "+this.name+" { \n"+e.join("\n")+"\n}"}}),exports.CSSKeyframesRule=CSSOM.CSSKeyframesRule;
  },{"./CSSRule":26}],25:[function(require,module,exports){
  var CSSOM={CSSRule:require("./CSSRule").CSSRule,MediaList:require("./MediaList").MediaList};CSSOM.CSSMediaRule=function(){CSSOM.CSSRule.call(this),this.media=new CSSOM.MediaList,this.cssRules=[]},CSSOM.CSSMediaRule.prototype=new CSSOM.CSSRule,CSSOM.CSSMediaRule.prototype.constructor=CSSOM.CSSMediaRule,CSSOM.CSSMediaRule.prototype.type=4,Object.defineProperty(CSSOM.CSSMediaRule.prototype,"cssText",{get:function(){for(var e=[],S=0,i=this.cssRules.length;i>S;S++)e.push(this.cssRules[S].cssText);return"@media "+this.media.mediaText+" {"+e.join("")+"}"}}),exports.CSSMediaRule=CSSOM.CSSMediaRule;
  },{"./CSSRule":26,"./MediaList":33}],26:[function(require,module,exports){
  var CSSOM={};CSSOM.CSSRule=function(){this.parentRule=null,this.parentStyleSheet=null},CSSOM.CSSRule.STYLE_RULE=1,CSSOM.CSSRule.IMPORT_RULE=3,CSSOM.CSSRule.MEDIA_RULE=4,CSSOM.CSSRule.FONT_FACE_RULE=5,CSSOM.CSSRule.PAGE_RULE=6,CSSOM.CSSRule.WEBKIT_KEYFRAMES_RULE=8,CSSOM.CSSRule.WEBKIT_KEYFRAME_RULE=9,CSSOM.CSSRule.prototype={constructor:CSSOM.CSSRule},exports.CSSRule=CSSOM.CSSRule;
  },{}],27:[function(require,module,exports){
  var CSSOM={};CSSOM.CSSStyleDeclaration=function(){this.length=0,this.parentRule=null,this._importants={}},CSSOM.CSSStyleDeclaration.prototype={constructor:CSSOM.CSSStyleDeclaration,getPropertyValue:function(t){return this[t]||""},setProperty:function(t,r,e){if(this[t]){var i=Array.prototype.indexOf.call(this,t);0>i&&(this[this.length]=t,this.length++)}else this[this.length]=t,this.length++;this[t]=r,this._importants[t]=e},removeProperty:function(t){if(!(t in this))return"";var r=Array.prototype.indexOf.call(this,t);if(0>r)return"";var e=this[t];return this[t]="",Array.prototype.splice.call(this,r,1),e},getPropertyCSSValue:function(){},getPropertyPriority:function(t){return this._importants[t]||""},getPropertyShorthand:function(){},isPropertyImplicit:function(){},get cssText(){for(var t=[],r=0,e=this.length;e>r;++r){var i=this[r],o=this.getPropertyValue(i),s=this.getPropertyPriority(i);s&&(s=" !"+s),t[r]=i+": "+o+s+";"}return t.join(" ")},set cssText(t){var r,e;for(r=this.length;r--;)e=this[r],this[e]="";Array.prototype.splice.call(this,0,this.length),this._importants={};var i=CSSOM.parse("#bogus{"+t+"}").cssRules[0].style,o=i.length;for(r=0;o>r;++r)e=i[r],this.setProperty(i[r],i.getPropertyValue(e),i.getPropertyPriority(e))}},exports.CSSStyleDeclaration=CSSOM.CSSStyleDeclaration,CSSOM.parse=require("./parse").parse;
  },{"./parse":37}],28:[function(require,module,exports){
  var CSSOM={CSSStyleDeclaration:require("./CSSStyleDeclaration").CSSStyleDeclaration,CSSRule:require("./CSSRule").CSSRule};CSSOM.CSSStyleRule=function(){CSSOM.CSSRule.call(this),this.selectorText="",this.style=new CSSOM.CSSStyleDeclaration,this.style.parentRule=this},CSSOM.CSSStyleRule.prototype=new CSSOM.CSSRule,CSSOM.CSSStyleRule.prototype.constructor=CSSOM.CSSStyleRule,CSSOM.CSSStyleRule.prototype.type=1,Object.defineProperty(CSSOM.CSSStyleRule.prototype,"cssText",{get:function(){var e;return e=this.selectorText?this.selectorText+" {"+this.style.cssText+"}":""},set:function(e){var t=CSSOM.CSSStyleRule.parse(e);this.style=t.style,this.selectorText=t.selectorText}}),CSSOM.CSSStyleRule.parse=function(e){for(var t,S,r,s=0,l="selector",a=s,i="",c={selector:!0,value:!0},o=new CSSOM.CSSStyleRule,n="";r=e.charAt(s);s++)switch(r){case" ":case"	":case"\r":case"\n":case"\f":if(c[l])switch(e.charAt(s-1)){case" ":case"	":case"\r":case"\n":case"\f":break;default:i+=" "}break;case'"':if(a=s+1,t=e.indexOf('"',a)+1,!t)throw'" is missing';i+=e.slice(s,t),s=t-1;break;case"'":if(a=s+1,t=e.indexOf("'",a)+1,!t)throw"' is missing";i+=e.slice(s,t),s=t-1;break;case"/":if("*"===e.charAt(s+1)){if(s+=2,t=e.indexOf("*/",s),-1===t)throw new SyntaxError("Missing */");s=t+1}else i+=r;break;case"{":"selector"===l&&(o.selectorText=i.trim(),i="",l="name");break;case":":"name"===l?(S=i.trim(),i="",l="value"):i+=r;break;case"!":"value"===l&&e.indexOf("!important",s)===s?(n="important",s+="important".length):i+=r;break;case";":"value"===l?(o.style.setProperty(S,i.trim(),n),n="",i="",l="name"):i+=r;break;case"}":if("value"===l)o.style.setProperty(S,i.trim(),n),n="",i="";else{if("name"===l)break;i+=r}l="selector";break;default:i+=r}return o},exports.CSSStyleRule=CSSOM.CSSStyleRule;
  },{"./CSSRule":26,"./CSSStyleDeclaration":27}],29:[function(require,module,exports){
  var CSSOM={StyleSheet:require("./StyleSheet").StyleSheet,CSSStyleRule:require("./CSSStyleRule").CSSStyleRule};CSSOM.CSSStyleSheet=function(){CSSOM.StyleSheet.call(this),this.cssRules=[]},CSSOM.CSSStyleSheet.prototype=new CSSOM.StyleSheet,CSSOM.CSSStyleSheet.prototype.constructor=CSSOM.CSSStyleSheet,CSSOM.CSSStyleSheet.prototype.insertRule=function(e,S){if(0>S||S>this.cssRules.length)throw new RangeError("INDEX_SIZE_ERR");var t=CSSOM.parse(e).cssRules[0];return t.parentStyleSheet=this,this.cssRules.splice(S,0,t),S},CSSOM.CSSStyleSheet.prototype.deleteRule=function(e){if(0>e||e>=this.cssRules.length)throw new RangeError("INDEX_SIZE_ERR");this.cssRules.splice(e,1)},CSSOM.CSSStyleSheet.prototype.toString=function(){for(var e="",S=this.cssRules,t=0;t<S.length;t++)e+=S[t].cssText+"\n";return e},exports.CSSStyleSheet=CSSOM.CSSStyleSheet,CSSOM.parse=require("./parse").parse;
  },{"./CSSStyleRule":28,"./StyleSheet":34,"./parse":37}],30:[function(require,module,exports){
  var CSSOM={};CSSOM.CSSValue=function(){},CSSOM.CSSValue.prototype={constructor:CSSOM.CSSValue,set cssText(t){var e=this._getConstructorName();throw new Exception('DOMException: property "cssText" of "'+e+'" is readonly!')},get cssText(){var t=this._getConstructorName();throw new Exception('getter "cssText" of "'+t+'" is not implemented!')},_getConstructorName:function(){var t=this.constructor.toString(),e=t.match(/function\s([^\(]+)/),o=e[1];return o}},exports.CSSValue=CSSOM.CSSValue;
  },{}],31:[function(require,module,exports){
  var CSSOM={CSSValue:require("./CSSValue").CSSValue};CSSOM.CSSValueExpression=function(e,r){this._token=e,this._idx=r},CSSOM.CSSValueExpression.prototype=new CSSOM.CSSValue,CSSOM.CSSValueExpression.prototype.constructor=CSSOM.CSSValueExpression,CSSOM.CSSValueExpression.prototype.parse=function(){for(var e,r=this._token,s=this._idx,n="",t="",i="",S=[];;++s){if(n=r.charAt(s),""==n){i="css expression error: unfinished expression!";break}switch(n){case"(":S.push(n),t+=n;break;case")":S.pop(n),t+=n;break;case"/":(e=this._parseJSComment(r,s))?e.error?i="css expression error: unfinished comment in expression!":s=e.idx:(e=this._parseJSRexExp(r,s))?(s=e.idx,t+=e.text):t+=n;break;case"'":case'"':e=this._parseJSString(r,s,n),e?(s=e.idx,t+=e.text):t+=n;break;default:t+=n}if(i)break;if(0==S.length)break}var o;return o=i?{error:i}:{idx:s,expression:t}},CSSOM.CSSValueExpression.prototype._parseJSComment=function(e,r){var s,n=e.charAt(r+1);if("/"==n||"*"==n){var t,i,S=r;return"/"==n?i="\n":"*"==n&&(i="*/"),t=e.indexOf(i,S+1+1),-1!==t?(t=t+i.length-1,s=e.substring(r,t+1),{idx:t,text:s}):(error="css expression error: unfinished comment in expression!",{error:error})}return!1},CSSOM.CSSValueExpression.prototype._parseJSString=function(e,r,s){var n,t=this._findMatchedIdx(e,r,s);return-1===t?!1:(n=e.substring(r,t+s.length),{idx:t,text:n})},CSSOM.CSSValueExpression.prototype._parseJSRexExp=function(e,r){var s=e.substring(0,r).replace(/\s+$/,""),n=[/^$/,/\($/,/\[$/,/\!$/,/\+$/,/\-$/,/\*$/,/\/\s+/,/\%$/,/\=$/,/\>$/,/\<$/,/\&$/,/\|$/,/\^$/,/\~$/,/\?$/,/\,$/,/delete$/,/in$/,/instanceof$/,/new$/,/typeof$/,/void$/],t=n.some(function(e){return e.test(s)});if(t){var i="/";return this._parseJSString(e,r,i)}return!1},CSSOM.CSSValueExpression.prototype._findMatchedIdx=function(e,r,s){for(var n,t=r,i=-1;;){if(n=e.indexOf(s,t+1),-1===n){n=i;break}var S=e.substring(r+1,n),o=S.match(/\\+$/);if(!o||o[0]%2==0)break;t=n}var a=e.indexOf("\n",r+1);return n>a&&(n=i),n},exports.CSSValueExpression=CSSOM.CSSValueExpression;
  },{"./CSSValue":30}],32:[function(require,module,exports){
  var CSSOM={};CSSOM.MatcherList=function(){this.length=0},CSSOM.MatcherList.prototype={constructor:CSSOM.MatcherList,get matcherText(){return Array.prototype.join.call(this,", ")},set matcherText(t){for(var e=t.split(","),r=this.length=e.length,i=0;r>i;i++)this[i]=e[i].trim()},appendMatcher:function(t){-1===Array.prototype.indexOf.call(this,t)&&(this[this.length]=t,this.length++)},deleteMatcher:function(t){var e=Array.prototype.indexOf.call(this,t);-1!==e&&Array.prototype.splice.call(this,e,1)}},exports.MatcherList=CSSOM.MatcherList;
  },{}],33:[function(require,module,exports){
  var CSSOM={};CSSOM.MediaList=function(){this.length=0},CSSOM.MediaList.prototype={constructor:CSSOM.MediaList,get mediaText(){return Array.prototype.join.call(this,", ")},set mediaText(t){for(var i=t.split(","),e=this.length=i.length,r=0;e>r;r++)this[r]=i[r].trim()},appendMedium:function(t){-1===Array.prototype.indexOf.call(this,t)&&(this[this.length]=t,this.length++)},deleteMedium:function(t){var i=Array.prototype.indexOf.call(this,t);-1!==i&&Array.prototype.splice.call(this,i,1)}},exports.MediaList=CSSOM.MediaList;
  },{}],34:[function(require,module,exports){
  var CSSOM={};CSSOM.StyleSheet=function(){this.parentStyleSheet=null},exports.StyleSheet=CSSOM.StyleSheet;
  },{}],35:[function(require,module,exports){
  var CSSOM={CSSStyleSheet:require("./CSSStyleSheet").CSSStyleSheet,CSSStyleRule:require("./CSSStyleRule").CSSStyleRule,CSSMediaRule:require("./CSSMediaRule").CSSMediaRule,CSSStyleDeclaration:require("./CSSStyleDeclaration").CSSStyleDeclaration,CSSKeyframeRule:require("./CSSKeyframeRule").CSSKeyframeRule,CSSKeyframesRule:require("./CSSKeyframesRule").CSSKeyframesRule};CSSOM.clone=function e(S){var r=new CSSOM.CSSStyleSheet,t=S.cssRules;if(!t)return r;for(var l={1:CSSOM.CSSStyleRule,4:CSSOM.CSSMediaRule,8:CSSOM.CSSKeyframesRule,9:CSSOM.CSSKeyframeRule},a=0,C=t.length;C>a;a++){var y=t[a],s=r.cssRules[a]=new l[y.type],u=y.style;if(u){for(var i=s.style=new CSSOM.CSSStyleDeclaration,n=0,o=u.length;o>n;n++){var R=i[n]=u[n];i[R]=u[R],i._importants[R]=u.getPropertyPriority(R)}i.length=u.length}y.hasOwnProperty("keyText")&&(s.keyText=y.keyText),y.hasOwnProperty("selectorText")&&(s.selectorText=y.selectorText),y.hasOwnProperty("mediaText")&&(s.mediaText=y.mediaText),y.hasOwnProperty("cssRules")&&(s.cssRules=e(y).cssRules)}return r},exports.clone=CSSOM.clone;
  },{"./CSSKeyframeRule":23,"./CSSKeyframesRule":24,"./CSSMediaRule":25,"./CSSStyleDeclaration":27,"./CSSStyleRule":28,"./CSSStyleSheet":29}],36:[function(require,module,exports){
  "use strict";exports.CSSStyleDeclaration=require("./CSSStyleDeclaration").CSSStyleDeclaration,exports.CSSRule=require("./CSSRule").CSSRule,exports.CSSStyleRule=require("./CSSStyleRule").CSSStyleRule,exports.MediaList=require("./MediaList").MediaList,exports.CSSMediaRule=require("./CSSMediaRule").CSSMediaRule,exports.CSSImportRule=require("./CSSImportRule").CSSImportRule,exports.CSSFontFaceRule=require("./CSSFontFaceRule").CSSFontFaceRule,exports.StyleSheet=require("./StyleSheet").StyleSheet,exports.CSSStyleSheet=require("./CSSStyleSheet").CSSStyleSheet,exports.CSSKeyframesRule=require("./CSSKeyframesRule").CSSKeyframesRule,exports.CSSKeyframeRule=require("./CSSKeyframeRule").CSSKeyframeRule,exports.MatcherList=require("./MatcherList").MatcherList,exports.CSSDocumentRule=require("./CSSDocumentRule").CSSDocumentRule,exports.CSSValue=require("./CSSValue").CSSValue,exports.CSSValueExpression=require("./CSSValueExpression").CSSValueExpression,exports.parse=require("./parse").parse,exports.clone=require("./clone").clone;
  },{"./CSSDocumentRule":20,"./CSSFontFaceRule":21,"./CSSImportRule":22,"./CSSKeyframeRule":23,"./CSSKeyframesRule":24,"./CSSMediaRule":25,"./CSSRule":26,"./CSSStyleDeclaration":27,"./CSSStyleRule":28,"./CSSStyleSheet":29,"./CSSValue":30,"./CSSValueExpression":31,"./MatcherList":32,"./MediaList":33,"./StyleSheet":34,"./clone":35,"./parse":37}],37:[function(require,module,exports){
  var CSSOM={};CSSOM.parse=function(e){for(var r,t,a,S,l,s,n,i,u,o,c=0,m="before-selector",f="",C={selector:!0,value:!0,atRule:!0,"importRule-begin":!0,importRule:!0,atBlock:!0,"documentRule-begin":!0},R=new CSSOM.CSSStyleSheet,b=R,p="",h=/@(-(?:\w+-)+)?keyframes/g,y=function(r){var t=e.substring(0,c).split("\n"),a=t.length,S=t.pop().length+1,l=new Error(r+" (line "+a+", char "+S+")");throw l.line=a,l["char"]=S,l.styleSheet=R,l};o=e.charAt(c);c++)switch(o){case" ":case"	":case"\r":case"\n":case"\f":C[m]&&(f+=o);break;case'"':r=c+1;do r=e.indexOf('"',r)+1,r||y('Unmatched "');while("\\"===e[r-2]);switch(f+=e.slice(c,r),c=r-1,m){case"before-value":m="value";break;case"importRule-begin":m="importRule"}break;case"'":r=c+1;do r=e.indexOf("'",r)+1,r||y("Unmatched '");while("\\"===e[r-2]);switch(f+=e.slice(c,r),c=r-1,m){case"before-value":m="value";break;case"importRule-begin":m="importRule"}break;case"/":"*"===e.charAt(c+1)?(c+=2,r=e.indexOf("*/",c),-1===r?y("Missing */"):c=r+1):f+=o,"importRule-begin"===m&&(f+=" ",m="importRule");break;case"@":if(e.indexOf("@-moz-document",c)===c){m="documentRule-begin",u=new CSSOM.CSSDocumentRule,u.__starts=c,c+="-moz-document".length,f="";break}if(e.indexOf("@media",c)===c){m="atBlock",l=new CSSOM.CSSMediaRule,l.__starts=c,c+="media".length,f="";break}if(e.indexOf("@import",c)===c){m="importRule-begin",c+="import".length,f+="@import";break}if(e.indexOf("@font-face",c)===c){m="fontFaceRule-begin",c+="font-face".length,n=new CSSOM.CSSFontFaceRule,n.__starts=c,f="";break}h.lastIndex=c;var d=h.exec(e);if(d&&d.index===c){m="keyframesRule-begin",i=new CSSOM.CSSKeyframesRule,i.__starts=c,i._vendorPrefix=d[1],c+=d[0].length-1,f="";break}"selector"==m&&(m="atRule"),f+=o;break;case"{":"selector"===m||"atRule"===m?(S.selectorText=f.trim(),S.style.__starts=c,f="",m="before-name"):"atBlock"===m?(l.media.mediaText=f.trim(),b=t=l,l.parentStyleSheet=R,f="",m="before-selector"):"fontFaceRule-begin"===m?(t&&(n.parentRule=t),n.parentStyleSheet=R,S=n,f="",m="before-name"):"keyframesRule-begin"===m?(i.name=f.trim(),t&&(i.parentRule=t),i.parentStyleSheet=R,b=t=i,f="",m="keyframeRule-begin"):"keyframeRule-begin"===m?(S=new CSSOM.CSSKeyframeRule,S.keyText=f.trim(),S.__starts=c,f="",m="before-name"):"documentRule-begin"===m&&(u.matcher.matcherText=f.trim(),t&&(u.parentRule=t),b=t=u,u.parentStyleSheet=R,f="",m="before-selector");break;case":":"name"===m?(a=f.trim(),f="",m="before-value"):f+=o;break;case"(":if("value"===m)if("expression"==f.trim()){var k=new CSSOM.CSSValueExpression(e,c).parse();k.error?y(k.error):(f+=k.expression,c=k.idx)}else r=e.indexOf(")",c+1),-1===r&&y('Unmatched "("'),f+=e.slice(c,r+1),c=r;else f+=o;break;case"!":"value"===m&&e.indexOf("!important",c)===c?(p="important",c+="important".length):f+=o;break;case";":switch(m){case"value":S.style.setProperty(a,f.trim(),p),p="",f="",m="before-name";break;case"atRule":f="",m="before-selector";break;case"importRule":s=new CSSOM.CSSImportRule,s.parentStyleSheet=s.styleSheet.parentStyleSheet=R,s.cssText=f+o,R.cssRules.push(s),f="",m="before-selector";break;default:f+=o}break;case"}":switch(m){case"value":S.style.setProperty(a,f.trim(),p),p="";case"before-name":case"name":S.__ends=c+1,t&&(S.parentRule=t),S.parentStyleSheet=R,b.cssRules.push(S),f="",m=b.constructor===CSSOM.CSSKeyframesRule?"keyframeRule-begin":"before-selector";break;case"keyframeRule-begin":case"before-selector":case"selector":t||y("Unexpected }"),b.__ends=c+1,R.cssRules.push(b),b=R,t=null,f="",m="before-selector"}break;default:switch(m){case"before-selector":m="selector",S=new CSSOM.CSSStyleRule,S.__starts=c;break;case"before-name":m="name";break;case"before-value":m="value";break;case"importRule-begin":m="importRule"}f+=o}return R},exports.parse=CSSOM.parse,CSSOM.CSSStyleSheet=require("./CSSStyleSheet").CSSStyleSheet,CSSOM.CSSStyleRule=require("./CSSStyleRule").CSSStyleRule,CSSOM.CSSImportRule=require("./CSSImportRule").CSSImportRule,CSSOM.CSSMediaRule=require("./CSSMediaRule").CSSMediaRule,CSSOM.CSSFontFaceRule=require("./CSSFontFaceRule").CSSFontFaceRule,CSSOM.CSSStyleDeclaration=require("./CSSStyleDeclaration").CSSStyleDeclaration,CSSOM.CSSKeyframeRule=require("./CSSKeyframeRule").CSSKeyframeRule,CSSOM.CSSKeyframesRule=require("./CSSKeyframesRule").CSSKeyframesRule,CSSOM.CSSValueExpression=require("./CSSValueExpression").CSSValueExpression,CSSOM.CSSDocumentRule=require("./CSSDocumentRule").CSSDocumentRule;
  },{"./CSSDocumentRule":20,"./CSSFontFaceRule":21,"./CSSImportRule":22,"./CSSKeyframeRule":23,"./CSSKeyframesRule":24,"./CSSMediaRule":25,"./CSSStyleDeclaration":27,"./CSSStyleRule":28,"./CSSStyleSheet":29,"./CSSValueExpression":31}],38:[function(require,module,exports){
  "use strict";var cssSupport=require("./cssSupport"),trimCSSWhitespace=function(r){var e=/^[\t\r\f\n ]*(.+?)[\t\r\f\n ]*$/;return r.replace(e,"$1")};exports.extractCssUrl=function(r){var e,t=/^url\(([^\)]+)\)/;if(!t.test(r))throw new Error("Invalid url");return e=t.exec(r)[1],cssSupport.unquoteString(trimCSSWhitespace(e))};var sliceBackgroundDeclaration=function(r){var e,t="\\s*(?:\"[^\"]*\"|'[^']*'|[^\\(]+)\\s*",n="(url\\("+t+"\\)|[^,\\s]+)",u="(?:\\s*"+n+")+",s="^\\s*("+u+")(?:\\s*,\\s*("+u+"))*\\s*$",c=new RegExp(u,"g"),a=[],o=function(r){var e,t=new RegExp(n,"g"),u=[];for(e=t.exec(r);e;)u.push(e[1]),e=t.exec(r);return u};if(r.match(new RegExp(s))){for(e=c.exec(r);e;)a.push(o(e[0])),e=c.exec(r);return a}return[]},findBackgroundImageUrlInValues=function(r){var e,t;for(e=0;e<r.length;e++)try{return t=exports.extractCssUrl(r[e]),{url:t,idx:e}}catch(n){}};exports.parse=function(r){var e=sliceBackgroundDeclaration(r);return e.map(function(r){var e=findBackgroundImageUrlInValues(r);return e?{preUrl:r.slice(0,e.idx),url:e.url,postUrl:r.slice(e.idx+1)}:{preUrl:r}})},exports.serialize=function(r){var e=r.map(function(r){var e=[].concat(r.preUrl);return r.url&&e.push('url("'+r.url+'")'),r.postUrl&&(e=e.concat(r.postUrl)),e.join(" ")});return e.join(", ")};
  },{"./cssSupport":39}],39:[function(require,module,exports){
  "use strict";var cssom=require("cssom");exports.unquoteString=function(e){var t=/^"(.*)"$/,r=/^'(.*)'$/;return t.test(e)?e.replace(t,"$1"):r.test(e)?e.replace(r,"$1"):e};var rulesForCssTextFromBrowser=function(e){var t,r=document.implementation.createHTMLDocument(""),s=document.createElement("style");return s.textContent=e,r.body.appendChild(s),t=s.sheet.cssRules,Array.prototype.slice.call(t)},browserHasBackgroundImageUrlIssue=function(){var e=rulesForCssTextFromBrowser("a{background:url(i)}");return!e.length||e[0].cssText.indexOf("url()")>=0}();exports.rulesForCssText=function(e){return browserHasBackgroundImageUrlIssue&&cssom.parse?cssom.parse(e).cssRules:rulesForCssTextFromBrowser(e)},exports.cssRulesToText=function(e){return e.reduce(function(e,t){return e+t.cssText},"")},exports.exchangeRule=function(e,t,r){var s=e.indexOf(t),o=t.parentStyleSheet;o.insertRule(r,s+1),o.deleteRule(s),e[s]=o.cssRules[s]},exports.changeFontFaceRuleSrc=function(e,t,r){var s="@font-face { font-family: "+t.style.getPropertyValue("font-family")+"; ";t.style.getPropertyValue("font-style")&&(s+="font-style: "+t.style.getPropertyValue("font-style")+"; "),t.style.getPropertyValue("font-weight")&&(s+="font-weight: "+t.style.getPropertyValue("font-weight")+"; "),s+="src: "+r+"}",exports.exchangeRule(e,t,s)};
  },{"cssom":36}],40:[function(require,module,exports){
  "use strict";var util=require("./util"),inlineImage=require("./inlineImage"),inlineScript=require("./inlineScript"),inlineCss=require("./inlineCss"),cssSupport=require("./cssSupport"),getUrlBasePath=function(e){return util.joinUrl(e,".")},parameterHashFunction=function(e){var n=e.map(function(n,t){return t===e.length-1&&(n={baseUrl:getUrlBasePath(n.baseUrl)}),JSON.stringify(n)});return n},memoizeFunctionOnCaching=function(e,n){return n.cache!==!1&&"none"!==n.cache&&n.cacheBucket?util.memoize(e,parameterHashFunction,n.cacheBucket):e},requestExternalsForStylesheet=function(e,n,t){var r=cssSupport.rulesForCssText(e);return inlineCss.loadCSSImportsForRules(r,n,t).then(function(n){return inlineCss.loadAndInlineCSSResourcesForRules(r,t).then(function(t){var s=n.errors.concat(t.errors),o=n.hasChanges||t.hasChanges;return o&&(e=cssSupport.cssRulesToText(r)),{hasChanges:o,content:e,errors:s}})})},loadAndInlineCssForStyle=function(e,n,t){var r=e.textContent,s=memoizeFunctionOnCaching(requestExternalsForStylesheet,n);return s(r,t,n).then(function(n){return n.hasChanges&&(e.childNodes[0].nodeValue=n.content),util.cloneArray(n.errors)})},getCssStyleElements=function(e){var n=e.getElementsByTagName("style");return Array.prototype.filter.call(n,function(e){return!e.attributes.type||"text/css"===e.attributes.type.nodeValue})};exports.loadAndInlineStyles=function(e,n){var t,r=getCssStyleElements(e),s=[],o=[];return t=util.clone(n),t.baseUrl=t.baseUrl||util.getDocumentBaseUrl(e),util.all(r.map(function(e){return loadAndInlineCssForStyle(e,t,o).then(function(e){s=s.concat(e)})})).then(function(){return s})};var substituteLinkWithInlineStyle=function(e,n){var t,r=e.parentNode;n=n.trim(),n&&(t=e.ownerDocument.createElement("style"),t.type="text/css",t.appendChild(e.ownerDocument.createTextNode(n)),r.insertBefore(t,e)),r.removeChild(e)},requestStylesheetAndInlineResources=function(e,n){return util.ajax(e,n).then(function(e){var n=cssSupport.rulesForCssText(e);return{content:e,cssRules:n}}).then(function(n){var t=inlineCss.adjustPathsOfCssResources(e,n.cssRules);return{content:n.content,cssRules:n.cssRules,hasChanges:t}}).then(function(e){return inlineCss.loadCSSImportsForRules(e.cssRules,[],n).then(function(n){return{content:e.content,cssRules:e.cssRules,hasChanges:e.hasChanges||n.hasChanges,errors:n.errors}})}).then(function(e){return inlineCss.loadAndInlineCSSResourcesForRules(e.cssRules,n).then(function(n){return{content:e.content,cssRules:e.cssRules,hasChanges:e.hasChanges||n.hasChanges,errors:e.errors.concat(n.errors)}})}).then(function(e){var n=e.content;return e.hasChanges&&(n=cssSupport.cssRulesToText(e.cssRules)),{content:n,errors:e.errors}})},loadLinkedCSS=function(e,n){var t=e.attributes.href.nodeValue,r=util.getDocumentBaseUrl(e.ownerDocument),s=util.clone(n);!s.baseUrl&&r&&(s.baseUrl=r);var o=memoizeFunctionOnCaching(requestStylesheetAndInlineResources,n);return o(t,s).then(function(e){return{content:e.content,errors:util.cloneArray(e.errors)}})},getCssStylesheetLinks=function(e){var n=e.getElementsByTagName("link");return Array.prototype.filter.call(n,function(e){return e.attributes.rel&&"stylesheet"===e.attributes.rel.nodeValue&&(!e.attributes.type||"text/css"===e.attributes.type.nodeValue)})};exports.loadAndInlineCssLinks=function(e,n){var t=getCssStylesheetLinks(e),r=[];return util.all(t.map(function(e){return loadLinkedCSS(e,n).then(function(n){substituteLinkWithInlineStyle(e,n.content+"\n"),r=r.concat(n.errors)},function(e){r.push({resourceType:"stylesheet",url:e.url,msg:"Unable to load stylesheet "+e.url})})})).then(function(){return r})},exports.loadAndInlineImages=inlineImage.inline,exports.loadAndInlineScript=inlineScript.inline,exports.inlineReferences=function(e,n){var t=[],r=[exports.loadAndInlineImages,exports.loadAndInlineStyles,exports.loadAndInlineCssLinks];return n.inlineScripts!==!1&&r.push(exports.loadAndInlineScript),util.all(r.map(function(r){return r(e,n).then(function(e){t=t.concat(e)})})).then(function(){return t})};
  },{"./cssSupport":39,"./inlineCss":41,"./inlineImage":42,"./inlineScript":43,"./util":44}],41:[function(require,module,exports){
  "use strict";var ayepromise=require("ayepromise"),util=require("./util"),cssSupport=require("./cssSupport"),backgroundValueParser=require("./backgroundValueParser"),fontFaceSrcValueParser=require("css-font-face-src"),updateCssPropertyValue=function(r,e,n){r.style.setProperty(e,n,r.style.getPropertyPriority(e))},findBackgroundImageRules=function(r){return r.filter(function(r){return r.type===window.CSSRule.STYLE_RULE&&(r.style.getPropertyValue("background-image")||r.style.getPropertyValue("background"))})},findBackgroundDeclarations=function(r){var e=[];return r.forEach(function(r){r.style.getPropertyValue("background-image")?e.push({property:"background-image",value:r.style.getPropertyValue("background-image"),rule:r}):r.style.getPropertyValue("background")&&e.push({property:"background",value:r.style.getPropertyValue("background"),rule:r})}),e},findFontFaceRules=function(r){return r.filter(function(r){return r.type===window.CSSRule.FONT_FACE_RULE&&r.style.getPropertyValue("src")})},findCSSImportRules=function(r){return r.filter(function(r){return r.type===window.CSSRule.IMPORT_RULE&&r.href})},findExternalBackgroundUrls=function(r){var e=[];return r.forEach(function(r,n){r.url&&!util.isDataUri(r.url)&&e.push(n)}),e},findExternalFontFaceUrls=function(r){var e=[];return r.forEach(function(r,n){r.url&&!util.isDataUri(r.url)&&e.push(n)}),e};exports.adjustPathsOfCssResources=function(r,e){var n=findBackgroundImageRules(e),t=findBackgroundDeclarations(n),u=!1;return t.forEach(function(e){var n,t=backgroundValueParser.parse(e.value),a=findExternalBackgroundUrls(t);a.length>0&&(a.forEach(function(e){var n=t[e].url,u=util.joinUrl(r,n);t[e].url=u}),n=backgroundValueParser.serialize(t),updateCssPropertyValue(e.rule,e.property,n),u=!0)}),findFontFaceRules(e).forEach(function(n){var t,a,o=n.style.getPropertyValue("src");try{t=fontFaceSrcValueParser.parse(o)}catch(l){return}a=findExternalFontFaceUrls(t),a.length>0&&(a.forEach(function(e){var n=t[e].url,u=util.joinUrl(r,n);t[e].url=u}),cssSupport.changeFontFaceRuleSrc(e,n,fontFaceSrcValueParser.serialize(t)),u=!0)}),findCSSImportRules(e).forEach(function(n){var t=n.href,a=util.joinUrl(r,t);cssSupport.exchangeRule(e,n,"@import url("+a+");"),u=!0}),u};var substituteRule=function(r,e,n){var t=r.indexOf(e);r.splice(t,1),n.forEach(function(e,n){r.splice(t+n,0,e)})},fulfilledPromise=function(r){var e=ayepromise.defer();return e.resolve(r),e.promise},loadAndInlineCSSImport=function(r,e,n,t){var u,a=e.href;return a=cssSupport.unquoteString(a),u=util.joinUrl(t.baseUrl,a),n.indexOf(u)>=0?(substituteRule(r,e,[]),fulfilledPromise([])):(n.push(u),util.ajax(a,t).then(function(u){var o=cssSupport.rulesForCssText(u);return exports.loadCSSImportsForRules(o,n,t).then(function(n){return exports.adjustPathsOfCssResources(a,o),substituteRule(r,e,o),n.errors})},function(r){throw{resourceType:"stylesheet",url:r.url,msg:"Unable to load stylesheet "+r.url}}))};exports.loadCSSImportsForRules=function(r,e,n){var t=findCSSImportRules(r),u=[],a=!1;return util.all(t.map(function(t){return loadAndInlineCSSImport(r,t,e,n).then(function(r){u=u.concat(r),a=!0},function(r){u.push(r)})})).then(function(){return{hasChanges:a,errors:u}})};var loadAndInlineBackgroundImages=function(r,e){var n=backgroundValueParser.parse(r),t=findExternalBackgroundUrls(n),u=!1;return util.collectAndReportErrors(t.map(function(r){var t=n[r].url;return util.getDataURIForImageURL(t,e).then(function(e){n[r].url=e,u=!0},function(r){throw{resourceType:"backgroundImage",url:r.url,msg:"Unable to load background-image "+r.url}})})).then(function(r){return{backgroundValue:backgroundValueParser.serialize(n),hasChanges:u,errors:r}})},iterateOverRulesAndInlineBackgroundImages=function(r,e){var n=findBackgroundImageRules(r),t=findBackgroundDeclarations(n),u=[],a=!1;return util.all(t.map(function(r){return loadAndInlineBackgroundImages(r.value,e).then(function(e){e.hasChanges&&(updateCssPropertyValue(r.rule,r.property,e.backgroundValue),a=!0),u=u.concat(e.errors)})})).then(function(){return{hasChanges:a,errors:u}})},loadAndInlineFontFace=function(r,e){var n,t,u=!1;try{n=fontFaceSrcValueParser.parse(r)}catch(a){n=[]}return t=findExternalFontFaceUrls(n),util.collectAndReportErrors(t.map(function(r){var t=n[r],a=t.format||"woff";return util.binaryAjax(t.url,e).then(function(r){var e=btoa(r);t.url="data:font/"+a+";base64,"+e,u=!0},function(r){throw{resourceType:"fontFace",url:r.url,msg:"Unable to load font-face "+r.url}})})).then(function(r){return{srcDeclarationValue:fontFaceSrcValueParser.serialize(n),hasChanges:u,errors:r}})},iterateOverRulesAndInlineFontFace=function(r,e){var n=findFontFaceRules(r),t=[],u=!1;return util.all(n.map(function(n){var a=n.style.getPropertyValue("src");return loadAndInlineFontFace(a,e).then(function(e){e.hasChanges&&(cssSupport.changeFontFaceRuleSrc(r,n,e.srcDeclarationValue),u=!0),t=t.concat(e.errors)})})).then(function(){return{hasChanges:u,errors:t}})};exports.loadAndInlineCSSResourcesForRules=function(r,e){var n=!1,t=[];return util.all([iterateOverRulesAndInlineBackgroundImages,iterateOverRulesAndInlineFontFace].map(function(u){return u(r,e).then(function(r){n=n||r.hasChanges,t=t.concat(r.errors)})})).then(function(){return{hasChanges:n,errors:t}})};
  },{"./backgroundValueParser":38,"./cssSupport":39,"./util":44,"ayepromise":3,"css-font-face-src":18}],42:[function(require,module,exports){
  "use strict";var util=require("./util"),encodeImageAsDataURI=function(t,e){var r=t.attributes.src?t.attributes.src.nodeValue:null,n=util.getDocumentBaseUrl(t.ownerDocument),a=util.clone(e);return!a.baseUrl&&n&&(a.baseUrl=n),util.getDataURIForImageURL(r,a).then(function(t){return t},function(t){throw{resourceType:"image",url:t.url,msg:"Unable to load image "+t.url}})},filterExternalImages=function(t){return t.filter(function(t){var e=t.attributes.src?t.attributes.src.nodeValue:null;return null!==e&&!util.isDataUri(e)})},filterInputsForImageType=function(t){return Array.prototype.filter.call(t,function(t){return"image"===t.type})},toArray=function(t){return Array.prototype.slice.call(t)};exports.inline=function(t,e){var r=toArray(t.getElementsByTagName("img")),n=filterInputsForImageType(t.getElementsByTagName("input")),a=filterExternalImages(r.concat(n));return util.collectAndReportErrors(a.map(function(t){return encodeImageAsDataURI(t,e).then(function(e){t.attributes.src.nodeValue=e})}))};
  },{"./util":44}],43:[function(require,module,exports){
  "use strict";var util=require("./util"),loadLinkedScript=function(t,e){var r=t.attributes.src.nodeValue,n=util.getDocumentBaseUrl(t.ownerDocument),i=util.clone(e);return!i.baseUrl&&n&&(i.baseUrl=n),util.ajax(r,i).fail(function(t){throw{resourceType:"script",url:t.url,msg:"Unable to load script "+t.url}})},escapeClosingTags=function(t){return t.replace(/<\//g,"<\\/")},substituteExternalScriptWithInline=function(t,e){t.attributes.removeNamedItem("src"),t.textContent=escapeClosingTags(e)},getScripts=function(t){var e=t.getElementsByTagName("script");return Array.prototype.filter.call(e,function(t){return!!t.attributes.src})};exports.inline=function(t,e){var r=getScripts(t);return util.collectAndReportErrors(r.map(function(t){return loadLinkedScript(t,e).then(function(e){substituteExternalScriptWithInline(t,e)})}))};
  },{"./util":44}],44:[function(require,module,exports){
  "use strict";var url=require("url"),ayepromise=require("ayepromise");exports.getDocumentBaseUrl=function(e){return"about:blank"!==e.baseURI?e.baseURI:null},exports.clone=function(e){var r,t={};for(r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);return t},exports.cloneArray=function(e){return Array.prototype.slice.apply(e,[0])},exports.joinUrl=function(e,r){return e?url.resolve(e,r):r},exports.isDataUri=function(e){return/^data:/.test(e)},exports.all=function(e){var r=ayepromise.defer(),t=e.length,n=[];return 0===e.length?(r.resolve([]),r.promise):(e.forEach(function(e,o){e.then(function(e){t-=1,n[o]=e,0===t&&r.resolve(n)},function(e){r.reject(e)})}),r.promise)},exports.collectAndReportErrors=function(e){var r=[];return exports.all(e.map(function(e){return e.fail(function(e){r.push(e)})})).then(function(){return r})};var lastCacheDate=null,getUncachableURL=function(e,r){return r===!1||"none"===r||"repeated"===r?((null===lastCacheDate||"repeated"!==r)&&(lastCacheDate=Date.now()),e+"?_="+lastCacheDate):e};exports.ajax=function(e,r){var t,n=new window.XMLHttpRequest,o=ayepromise.defer(),a=exports.joinUrl(r.baseUrl,e),u=function(){o.reject({msg:"Unable to load url",url:a})};t=getUncachableURL(a,r.cache),n.addEventListener("load",function(){200===n.status||0===n.status?o.resolve(n.response):u()},!1),n.addEventListener("error",u,!1);try{n.open("GET",t,!0),n.overrideMimeType(r.mimeType),n.send(null)}catch(i){u()}return o.promise},exports.binaryAjax=function(e,r){var t=exports.clone(r);return t.mimeType="text/plain; charset=x-user-defined",exports.ajax(e,t).then(function(e){for(var r="",t=0;t<e.length;t++)r+=String.fromCharCode(255&e.charCodeAt(t));return r})};var detectMimeType=function(e){var r=function(e,r){return e.substring(0,r.length)===r};return r(e,"<?xml")||r(e,"<svg")?"image/svg+xml":"image/png"};exports.getDataURIForImageURL=function(e,r){return exports.binaryAjax(e,r).then(function(e){var r=btoa(e),t=detectMimeType(e);return"data:"+t+";base64,"+r})};var uniqueIdList=[],constantUniqueIdFor=function(e){return uniqueIdList.indexOf(e)<0&&uniqueIdList.push(e),uniqueIdList.indexOf(e)};exports.memoize=function(e,r,t){if("object"!=typeof t)throw new Error("cacheBucket is not an object");return function(){var n,o=Array.prototype.slice.call(arguments),a=r(o),u=constantUniqueIdFor(e);return t[u]&&t[u][a]?t[u][a]:(n=e.apply(null,o),t[u]=t[u]||{},t[u][a]=n,n)}};
  },{"ayepromise":3,"url":14}],45:[function(require,module,exports){
  !function(e,t){"function"==typeof define&&define.amd?define(["url","cssMediaQuery","xmlserializer","ayepromise","inlineresources"],function(n,r,o,i,u){return e.rasterizeHTML=t(n,r,o,i,u)}):"object"==typeof exports?module.exports=t(require("url"),require("css-mediaquery"),require("xmlserializer"),require("ayepromise"),require("inlineresources")):e.rasterizeHTML=t(url,cssMediaQuery,xmlserializer,ayepromise,inlineresources)}(this,function(e,t,n,r,o){var i=function(e){"use strict";var t={},n=[];t.joinUrl=function(t,n){return t?e.resolve(t,n):n},t.getConstantUniqueIdFor=function(e){return n.indexOf(e)<0&&n.push(e),n.indexOf(e)},t.clone=function(e){var t,n={};for(t in e)e.hasOwnProperty(t)&&(n[t]=e[t]);return n};var r=function(e){return"object"==typeof e&&null!==e},o=function(e){return r(e)&&Object.prototype.toString.apply(e).match(/\[object (Canvas|HTMLCanvasElement)\]/i)};return t.parseOptionalParameters=function(e){var n={canvas:null,options:{}};return null==e[0]||o(e[0])?(n.canvas=e[0]||null,n.options=t.clone(e[1])):n.options=t.clone(e[0]),n},t}(e),u=function(e,t){"use strict";var n={},r=function(e,t,n){var r=e[t];return e[t]=function(){var e=Array.prototype.slice.call(arguments);return n.apply(this,[e,r])},r};return n.baseUrlRespectingXhr=function(t,n){var o=function(){var o=new t;return r(o,"open",function(t,r){var o=t.shift(),i=t.shift(),u=e.joinUrl(n,i);return r.apply(this,[o,u].concat(t))}),o};return o},n.finishNotifyingXhr=function(e){var n=0,o=0,i=!1,u=t.defer(),c=function(){var e=n-o;0>=e&&i&&u.resolve({totalCount:n})},a=function(){var t=new e;return r(t,"send",function(e,t){return n+=1,t.apply(this,arguments)}),t.addEventListener("load",function(){o+=1,c()}),t};return a.waitForRequestsToFinish=function(){return i=!0,c(),u.promise},a},n}(i,r),c=function(){"use strict";var e={},t=function(e){return Array.prototype.slice.call(e)};e.addClassNameRecursively=function(t,n){t.className+=" "+n,t.parentNode!==t.ownerDocument&&e.addClassNameRecursively(t.parentNode,n)};var n=function(e,n){var r=e.parentStyleSheet,o=t(r.cssRules).indexOf(e);r.insertRule(n,o+1),r.deleteRule(o)},r=function(e,t){var r=e.cssText.replace(/^[^\{]+/,""),o=t+" "+r;n(e,o)},o=function(e){return t(e).reduce(function(e,t){return e+t.cssText},"")},i=function(e){e.textContent=o(e.sheet.cssRules)},u=function(e){return"((?:^|[^.#:\\w])|(?=\\W))("+e.join("|")+")(?=\\W|$)"},c=function(e,n,o){var c=u(n);t(e.querySelectorAll("style")).forEach(function(e){var n=t(e.sheet.cssRules).filter(function(e){return e.selectorText&&new RegExp(c,"i").test(e.selectorText)});n.length&&(n.forEach(function(e){var t=e.selectorText.replace(new RegExp(c,"gi"),function(e,t,n){return t+o(n)});t!==e.selectorText&&r(e,t)}),i(e))})};return e.rewriteCssSelectorWith=function(e,t,n){c(e,[t],function(){return n})},e.lowercaseCssTypeSelectors=function(e,t){c(e,t,function(e){return e.toLowerCase()})},e.findHtmlOnlyNodeNames=function(e){for(var t,n=e.createTreeWalker(e,NodeFilter.SHOW_ELEMENT),r={},o={};n.nextNode();)t=n.currentNode.tagName.toLowerCase(),"http://www.w3.org/1999/xhtml"===n.currentNode.namespaceURI?r[t]=!0:o[t]=!0;return Object.keys(r).filter(function(e){return!o[e]})},e}(),a=function(e){"use strict";var t={},n=function(e){return Array.prototype.slice.call(e)};return t.fakeHover=function(t,n){var r=t.querySelector(n),o="rasterizehtmlhover";r&&(e.addClassNameRecursively(r,o),e.rewriteCssSelectorWith(t,":hover","."+o))},t.fakeActive=function(t,n){var r=t.querySelector(n),o="rasterizehtmlactive";r&&(e.addClassNameRecursively(r,o),e.rewriteCssSelectorWith(t,":active","."+o))},t.fakeFocus=function(t,n){var r=t.querySelector(n),o="rasterizehtmlfocus";r&&(e.addClassNameRecursively(r,o),e.rewriteCssSelectorWith(t,":focus","."+o))},t.persistInputValues=function(e){var t=e.querySelectorAll("input"),r=e.querySelectorAll("textarea"),o=function(e){return"checkbox"===e.type||"radio"===e.type};n(t).filter(o).forEach(function(e){e.checked?e.setAttribute("checked",""):e.removeAttribute("checked")}),n(t).filter(function(e){return!o(e)}).forEach(function(e){e.setAttribute("value",e.value)}),n(r).forEach(function(e){e.textContent=e.value})},t.rewriteTagNameSelectorsToLowerCase=function(t){e.lowercaseCssTypeSelectors(t,e.findHtmlOnlyNodeNames(t))},t}(c),s=function(e){"use strict";var t,n={},o=function(){var e='<svg id="svg" xmlns="http://www.w3.org/2000/svg" width="10" height="10"><style>@media (max-width: 1em) { svg { background: #00f; } }</style></svg>',t="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(e),n=document.createElement("img");return n.src=t,n},i=function(e,t,n,r){var o=document.createElement("canvas");o.width=e.width,o.height=e.height;var i,u=o.getContext("2d");return u.drawImage(e,0,0),i=u.getImageData(0,0,1,1).data,i[0]===t&&i[1]===n&&i[2]===r},u=function(){var e=o(),t=r.defer();return document.querySelector("body").appendChild(e),e.onload=function(){document.querySelector("body").removeChild(e);try{t.resolve(!i(e,0,0,255))}catch(n){t.resolve(!0)}},e.onerror=function(){t.reject()},t.promise};n.needsEmWorkaround=function(){return void 0===t&&(t=u()),t};var c=function(e){return Array.prototype.slice.call(e)},a=function(e){return c(e).map(function(e){return e.cssText}).join("\n")},s=function(e,t){return"@media "+e.join(", ")+"{"+a(t)+"}"},l=function(e,t,n){try{e.insertRule(n,t+1)}catch(r){return}e.deleteRule(t)},f=function(e,t){var n=e.parentStyleSheet,r=c(n.cssRules).indexOf(e);l(n,r,t)},d=function(e){e.textContent=a(e.sheet.cssRules)},m=function(e){var t=e.modifier?e.modifier+"-"+e.feature:e.feature;return e.value?"("+t+": "+e.value+")":"("+t+")"},h=function(e){var t=[];return e.inverse&&t.push("not"),t.push(e.type),e.expressions.length>0&&t.push("and "+e.expressions.map(m).join(" and ")),t.join(" ")};n.serializeQuery=function(e){var t=e.map(h);return t.join(", ")};var v=function(e){return 16*e},p=function(e){var t=/^((?:\d+\.)?\d+)em/.exec(e);return t?v(parseFloat(t[1]))+"px":e},g=function(t){var r=e.parse(t),o=!1;return r.forEach(function(e){e.expressions.forEach(function(e){var t=p(e.value);o|=t!==e.value,e.value=t})}),o&&(t=n.serializeQuery(r)),t},y=function(e){var t=!1;return e.forEach(function(e){var n=!1,r=c(e.media).map(function(e){var t=g(e);return n|=t!==e,t});n&&f(e,s(r,e.cssRules)),t|=n}),t};return n.workAroundWebKitEmSizeIssue=function(e){var t=e.querySelectorAll("style");c(t).forEach(function(e){var t=c(e.sheet.cssRules).filter(function(e){return e.type===window.CSSRule.MEDIA_RULE}),n=y(t);n&&d(e)})},n}(t),l=function(e,t,n,r){"use strict";var o={},i=function(e,t,n,r){var o=e.createElement(t);return o.style.visibility="hidden",o.style.width=n+"px",o.style.height=r+"px",o.style.position="absolute",o.style.top=-1e4-r+"px",o.style.left=-1e4-n+"px",e.getElementsByTagName("body")[0].appendChild(o),o};o.executeJavascript=function(e,o){var u=i(r.document,"iframe",o.width,o.height),c=e.documentElement.outerHTML,a=[],s=n.defer(),l=o.executeJsTimeout||0,f=function(){var e=u.contentDocument;r.document.getElementsByTagName("body")[0].removeChild(u),s.resolve({document:e,errors:a})},d=function(){var e=n.defer();return l>0?setTimeout(e.resolve,l):e.resolve(),e.promise};u.onload=function(){d().then(h.waitForRequestsToFinish).then(f)};var m=u.contentWindow.XMLHttpRequest,h=t.finishNotifyingXhr(m),v=t.baseUrlRespectingXhr(h,o.baseUrl);return u.contentDocument.open(),u.contentWindow.XMLHttpRequest=v,u.contentWindow.onerror=function(e){a.push({resourceType:"scriptExecution",msg:e})},u.contentDocument.write("<!DOCTYPE html>"),u.contentDocument.write(c),u.contentDocument.close(),s.promise};var u=function(e,t,n){var r=e.createElement("iframe");return r.style.width=t+"px",r.style.height=n+"px",r.style.visibility="hidden",r.style.position="absolute",r.style.top=-1e4-n+"px",r.style.left=-1e4-t+"px",r.sandbox="allow-same-origin",r.scrolling="no",r},c=function(e,t,n){var o=Math.floor(e/n),i=Math.floor(t/n);return u(r.document,o,i)},a=function(e,t,n,r){return{width:Math.max(e.width*r,t),height:Math.max(e.height*r,n)}},s=function(e,t,n,o,i){var u,c,s,l,f,d,m,h,v=Math.max(e.documentElement.scrollWidth,e.body.clientWidth),p=Math.max(e.documentElement.scrollHeight,e.body.scrollHeight,e.body.clientHeight);if(t){if(d=e.querySelector(t),!d)throw{message:"Clipping selector not found"};m=d.getBoundingClientRect(),u=m.top,c=m.left,s=m.width,l=m.height}else u=0,c=0,s=v,l=p;return h=a({width:s,height:l},n,o,i),f=r.getComputedStyle(e.documentElement).fontSize,{left:c,top:u,width:h.width,height:h.height,viewportWidth:v,viewportHeight:p,rootFontSize:f}};o.calculateDocumentContentSize=function(e,t){var o,i=e.documentElement.outerHTML,u=n.defer(),a=t.zoom||1;return o=c(t.width,t.height,a),r.document.getElementsByTagName("body")[0].appendChild(o),o.onload=function(){var e,n=o.contentDocument;try{e=s(n,t.clip,t.width,t.height,a),u.resolve(e)}catch(i){u.reject(i)}finally{r.document.getElementsByTagName("body")[0].removeChild(o)}},o.contentDocument.open(),o.contentDocument.write("<!DOCTYPE html>"),o.contentDocument.write(i),o.contentDocument.close(),u.promise};var l=function(e,t){var n,o,i,u,c=/<html((?:\s+[^>]*)?)>/im.exec(t),a=r.document.implementation.createHTMLDocument("");if(c)for(n="<div"+c[1]+"></div>",a.documentElement.innerHTML=n,i=a.querySelector("div"),o=0;o<i.attributes.length;o++)u=i.attributes[o],e.documentElement.setAttribute(u.name,u.value)};o.parseHTML=function(e){var t=r.document.implementation.createHTMLDocument("");return t.documentElement.innerHTML=e,l(t,e),t};var f=function(e){var t=new DOMParser,n=t.parseFromString("<","text/xml"),r=n.getElementsByTagName("parsererror")[0].namespaceURI;return"http://www.w3.org/1999/xhtml"===r?e.getElementsByTagName("parsererror").length>0:e.getElementsByTagNameNS(r,"parsererror").length>0},d=function(e){if(null===e||f(e))throw{message:"Invalid source"}};o.validateXHTML=function(e){var t=new DOMParser,n=t.parseFromString(e,"application/xml");d(n)};var m=null,h=function(e,t){return"none"===t||"repeated"===t?((null===m||"repeated"!==t)&&(m=Date.now()),e+"?_="+m):e},v=function(t,r){var o=new window.XMLHttpRequest,i=e.joinUrl(r.baseUrl,t),u=h(i,r.cache),c=n.defer(),a=function(){c.reject({message:"Unable to load page"})};o.addEventListener("load",function(){200===o.status||0===o.status?c.resolve(o.responseXML):a()},!1),o.addEventListener("error",function(){a()},!1);try{o.open("GET",u,!0),o.responseType="document",o.send(null)}catch(s){a()}return c.promise};return o.loadDocument=function(e,t){return v(e,t).then(function(e){return d(e),e})},o}(i,u,r,window),f=function(e,t){"use strict";var n,r={},o=function(e,t){return t?URL.createObjectURL(new Blob([e],{type:"image/svg+xml"})):"data:image/svg+xml;charset=utf-8,"+encodeURIComponent(e)},i=function(e){e instanceof Blob&&URL.revokeObjectURL(e)},u='<svg xmlns="http://www.w3.org/2000/svg" width="1" height="1"><foreignObject></foreignObject></svg>',c=function(t){var n=document.createElement("canvas"),r=new Image,o=e.defer();return r.onload=function(){var e=n.getContext("2d");try{e.drawImage(r,0,0),n.toDataURL("image/png"),o.resolve(!0)}catch(t){o.resolve(!1)}},r.onerror=o.reject,r.src=t,o.promise},a=function(){var e=o(u,!0);return c(e).then(function(t){return i(e),t?!1:c(o(u,!1)).then(function(e){return e})},function(){return!1})},s=function(){if(t.Blob)try{return new Blob(["<b></b>"],{type:"text/xml"}),!0}catch(e){}return!1},l=function(){var n=e.defer();return s&&t.URL?a().then(function(e){n.resolve(!e)},function(){n.reject()}):n.resolve(!1),n.promise},f=function(){return void 0===n&&(n=l()),n},d=function(e){return f().then(function(t){return o(e,t)})};return r.renderSvg=function(t){var n,r,o=e.defer(),u=function(){r.onload=null,r.onerror=null},c=function(){n&&i(n)};return r=new Image,r.onload=function(){u(),c(),o.resolve(r)},r.onerror=function(){c(),o.reject()},d(t).then(function(e){n=e,r.src=n},o.reject),o.promise},r}(r,window),d=function(e,t,n,r,o){"use strict";var i={},u=function(e,t){var n,r,o,i;t=t||1,n=Math.round(e.viewportWidth),r=Math.round(e.viewportHeight),o=-e.left,i=-e.top;var u={x:o,y:i,width:n,height:r};return 1!==t&&(u.transform="scale("+t+")"),u},c=function(e){var t=e.style||"";e.style=t+"float: left;"},a=function(e){e.externalResourcesRequired=!0},s=function(){return'<style scoped="">html::-webkit-scrollbar { display: none; }</style>'},l=function(e){var t=Object.keys(e);return t.length?" "+t.map(function(t){return t+'="'+e[t]+'"'}).join(" "):""},f=function(e,n,r){var i=o.serializeToString(e);t.validateXHTML(i);var f=u(n,r);return c(f),a(f),'<svg xmlns="http://www.w3.org/2000/svg" width="'+n.width+'" height="'+n.height+'" font-size="'+n.rootFontSize+'">'+s()+"<foreignObject"+l(f)+">"+i+"</foreignObject></svg>"};return i.getSvgForDocument=function(e,t,o){return n.rewriteTagNameSelectorsToLowerCase(e),r.needsEmWorkaround().then(function(n){return n&&r.workAroundWebKitEmSizeIssue(e),f(e,t,o)})},i.drawDocumentAsSvg=function(e,r){return r.hover&&n.fakeHover(e,r.hover),r.active&&n.fakeActive(e,r.active),r.focus&&n.fakeFocus(e,r.focus),t.calculateDocumentContentSize(e,r).then(function(t){return i.getSvgForDocument(e,t,r.zoom)})},i}(i,l,a,s,n),m=function(e,t,n,r,o,i){"use strict";var u={},c=function(){return{message:"Error rendering page"}},a=function(e){return o.renderSvg(e).then(function(t){return{image:t,svg:e}},function(){throw c()})},s=function(e,t){try{t.getContext("2d").drawImage(e,0,0)}catch(n){throw c()}},l=function(e,t,n){return r.drawDocumentAsSvg(e,n).then(a).then(function(e){return t&&s(e.image,t),e})},f=function(e,r){return t.executeJavascript(e,r).then(function(e){var t=e.document;return n.persistInputValues(t),{document:t,errors:e.errors}})};return u.rasterize=function(t,n,r){var o;return o=e.clone(r),o.inlineScripts=r.executeJs===!0,i.inlineReferences(t,o).then(function(e){return r.executeJs?f(t,r).then(function(t){return{document:t.document,errors:e.concat(t.errors)}}):{document:t,errors:e}}).then(function(e){return l(e.document,n,r).then(function(t){return{image:t.image,svg:t.svg,errors:e.errors}})})},u}(i,l,a,d,f,o),h=function(e,t,n){"use strict";var r={},o=function(e,t){var n=300,r=200,o=e?e.width:n,i=e?e.height:r,u=void 0!==t.width?t.width:o,c=void 0!==t.height?t.height:i;return{width:u,height:c}},i=function(t){var n,r=o(t.canvas,t.options);return n=e.clone(t.options),n.width=r.width,n.height=r.height,n};r.drawDocument=function(){var t=arguments[0],r=Array.prototype.slice.call(arguments,1),o=e.parseOptionalParameters(r);return n.rasterize(t,o.canvas,i(o))};var u=function(e,n,o){var i=t.parseHTML(e);return r.drawDocument(i,n,o)};r.drawHTML=function(){var t=arguments[0],n=Array.prototype.slice.call(arguments,1),r=e.parseOptionalParameters(n);return u(t,r.canvas,r.options)};var c=function(t,n,r){var o=document.implementation.createHTMLDocument("");o.replaceChild(t.documentElement,o.documentElement);var i=r?e.clone(r):{};return r.baseUrl||(i.baseUrl=n),{document:o,options:i}},a=function(e,n,o){return t.loadDocument(e,o).then(function(t){var i=c(t,e,o);return r.drawDocument(i.document,n,i.options)})};return r.drawURL=function(){var t=arguments[0],n=Array.prototype.slice.call(arguments,1),r=e.parseOptionalParameters(n);return a(t,r.canvas,r.options)},r}(i,l,m);return h});
  },{"ayepromise":3,"css-mediaquery":46,"inlineresources":40,"url":14,"xmlserializer":47}],46:[function(require,module,exports){
  "use strict";function matchQuery(e,r){return parseQuery(e).some(function(e){var t=e.inverse,a="all"===e.type||r.type===e.type;if(a&&t||!a&&!t)return!1;var s=e.expressions.every(function(e){var t=e.feature,a=e.modifier,s=e.value,c=r[t];if(!c)return!1;switch(t){case"orientation":case"scan":return c.toLowerCase()===s.toLowerCase();case"width":case"height":case"device-width":case"device-height":s=toPx(s),c=toPx(c);break;case"resolution":s=toDpi(s),c=toDpi(c);break;case"aspect-ratio":case"device-aspect-ratio":case"device-pixel-ratio":s=toDecimal(s),c=toDecimal(c);break;case"grid":case"color":case"color-index":case"monochrome":s=parseInt(s,10)||1,c=parseInt(c,10)||0}switch(a){case"min":return c>=s;case"max":return s>=c;default:return c===s}});return s&&!t||!s&&t})}function parseQuery(e){return e.split(",").map(function(e){e=e.trim();var r=e.match(RE_MEDIA_QUERY),t=r[1],a=r[2],s=r[3]||"",c={};return c.inverse=!!t&&"not"===t.toLowerCase(),c.type=a?a.toLowerCase():"all",s=s.match(/\([^\)]+\)/g)||[],c.expressions=s.map(function(e){var r=e.match(RE_MQ_EXPRESSION),t=r[1].toLowerCase().match(RE_MQ_FEATURE);return{modifier:t[1],feature:t[2],value:r[2]}}),c})}function toDecimal(e){var r,t=Number(e);return t||(r=e.match(/^(\d+)\s*\/\s*(\d+)$/),t=r[1]/r[2]),t}function toDpi(e){var r=parseFloat(e),t=String(e).match(RE_RESOLUTION_UNIT)[1];switch(t){case"dpcm":return r/2.54;case"dppx":return 96*r;default:return r}}function toPx(e){var r=parseFloat(e),t=String(e).match(RE_LENGTH_UNIT)[1];switch(t){case"em":return 16*r;case"rem":return 16*r;case"cm":return 96*r/2.54;case"mm":return 96*r/2.54/10;case"in":return 96*r;case"pt":return 72*r;case"pc":return 72*r/12;default:return r}}exports.match=matchQuery,exports.parse=parseQuery;var RE_MEDIA_QUERY=/(?:(only|not)?\s*([^\s\(\)]+)(?:\s*and)?\s*)?(.+)?/i,RE_MQ_EXPRESSION=/\(\s*([^\s\:\)]+)\s*(?:\:\s*([^\s\)]+))?\s*\)/,RE_MQ_FEATURE=/^(?:(min|max)-)?(.+)/,RE_LENGTH_UNIT=/(em|rem|px|cm|mm|in|pt|pc)?$/,RE_RESOLUTION_UNIT=/(dpi|dpcm|dppx)?$/;
  },{}],47:[function(require,module,exports){
  var removeInvalidCharacters=function(e){return e.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F]/g,"")},serializeAttributeValue=function(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")},serializeTextContent=function(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")},serializeAttribute=function(e){var a=e.value;return" "+e.name+'="'+serializeAttributeValue(a)+'"'},getTagName=function(e){var a=e.tagName;return"http://www.w3.org/1999/xhtml"===e.namespaceURI&&(a=a.toLowerCase()),a},serializeNamespace=function(e){var a=Array.prototype.map.call(e.attributes||e.attrs,function(e){return e.name}).indexOf("xmlns")>=0;return a||e.parentNode&&e.namespaceURI===e.parentNode.namespaceURI&&"html"!==getTagName(e)?"":' xmlns="'+e.namespaceURI+'"'},serializeChildren=function(e){return Array.prototype.map.call(e.childNodes,function(e){return nodeTreeToXHTML(e)}).join("")},serializeTag=function(e){var a="<"+getTagName(e);return a+=serializeNamespace(e),Array.prototype.forEach.call(e.attributes||e.attrs,function(e){a+=serializeAttribute(e)}),e.childNodes.length>0?(a+=">",a+=serializeChildren(e),a+="</"+getTagName(e)+">"):a+="/>",a},serializeText=function(e){var a=e.nodeValue||e.value||"";return serializeTextContent(a)},serializeComment=function(e){return"<!--"+e.data.replace(/-/g,"&#45;")+"-->"},serializeCDATA=function(e){return"<![CDATA["+e.nodeValue+"]]>"},nodeTreeToXHTML=function(e){return"#document"===e.nodeName||"#document-fragment"===e.nodeName?serializeChildren(e):e.tagName?serializeTag(e):"#text"===e.nodeName?serializeText(e):"#comment"===e.nodeName?serializeComment(e):"#cdata-section"===e.nodeName?serializeCDATA(e):void 0};exports.serializeToString=function(e){return removeInvalidCharacters(nodeTreeToXHTML(e))};
  },{}]},{},[2])(2)
  });
  
  
  //# sourceMappingURL=csscritic.allinone.js.map