text: /**
   * @license almond 0.3.1 Copyright (c) 2011-2014, The Dojo Foundation All Rights Reserved.
   * Available via the MIT or new BSD license.
   * see: http://github.com/jrburke/almond for details
   */
  
  /*
  Copyright © 2013 Adobe Systems Incorporated.
  
  Licensed under the Apache License, Version 2.0 (the “License”);
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
  
  http://www.apache.org/licenses/LICENSE-2.0
  
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an “AS IS” BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
  */
  
  /**
   * @fileOverview accessibleMegaMenu plugin
   *
   *<p>Licensed under the Apache License, Version 2.0 (the “License”)
   *<br />Copyright © 2013 Adobe Systems Incorporated.
   *<br />Project page <a href="https://github.com/adobe-accessibility/Accessible-Mega-Menu">https://github.com/adobe-accessibility/Accessible-Mega-Menu</a>
   * @version 0.1
   * @author Michael Jordan
   * @requires jquery
   */
  
  /*!
   * Salvattore 1.0.9 by @rnmp and @ppold
   * https://github.com/rnmp/salvattore
   */
  
  /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. Dual MIT/BSD license */
  
  /*! matchMedia() polyfill addListener/removeListener extension. Author & copyright (c) 2012: Scott Jehl. Dual MIT/BSD license */
  
  /*!
   * Chart.js
   * http://chartjs.org/
   * Version: 1.0.1
   *
   * Copyright 2015 Nick Downie
   * Released under the MIT license
   * https://github.com/nnnick/Chart.js/blob/master/LICENSE.md
   */
  
  var requirejs,require,define;!function(t){function e(t,e){return v.call(t,e)}function i(t,e){var i,n,s,a,o,l,r,h,c,u,d,f=e&&e.split("/"),p=g.map,m=p&&p["*"]||{};if(t&&"."===t.charAt(0))if(e){for(t=t.split("/"),o=t.length-1,g.nodeIdCompat&&C.test(t[o])&&(t[o]=t[o].replace(C,"")),t=f.slice(0,f.length-1).concat(t),c=0;c<t.length;c+=1)if(d=t[c],"."===d)t.splice(c,1),c-=1;else if(".."===d){if(1===c&&(".."===t[2]||".."===t[0]))break;c>0&&(t.splice(c-1,2),c-=2)}t=t.join("/")}else 0===t.indexOf("./")&&(t=t.substring(2));if((f||m)&&p){for(i=t.split("/"),c=i.length;c>0;c-=1){if(n=i.slice(0,c).join("/"),f)for(u=f.length;u>0;u-=1)if(s=p[f.slice(0,u).join("/")],s&&(s=s[n])){a=s,l=c;break}if(a)break;!r&&m&&m[n]&&(r=m[n],h=c)}!a&&r&&(a=r,l=h),a&&(i.splice(0,l,a),t=i.join("/"))}return t}function n(e,i){return function(){var n=b.call(arguments,0);return"string"!=typeof n[0]&&1===n.length&&n.push(null),c.apply(t,n.concat([e,i]))}}function s(t){return function(e){return i(e,t)}}function a(t){return function(e){f[t]=e}}function o(i){if(e(p,i)){var n=p[i];delete p[i],m[i]=!0,h.apply(t,n)}if(!e(f,i)&&!e(m,i))throw new Error("No "+i);return f[i]}function l(t){var e,i=t?t.indexOf("!"):-1;return i>-1&&(e=t.substring(0,i),t=t.substring(i+1,t.length)),[e,t]}function r(t){return function(){return g&&g.config&&g.config[t]||{}}}var h,c,u,d,f={},p={},g={},m={},v=Object.prototype.hasOwnProperty,b=[].slice,C=/\.js$/;u=function(t,e){var n,a=l(t),r=a[0];return t=a[1],r&&(r=i(r,e),n=o(r)),r?t=n&&n.normalize?n.normalize(t,s(e)):i(t,e):(t=i(t,e),a=l(t),r=a[0],t=a[1],r&&(n=o(r))),{f:r?r+"!"+t:t,n:t,pr:r,p:n}},d={require:function(t){return n(t)},exports:function(t){var e=f[t];return"undefined"!=typeof e?e:f[t]={}},module:function(t){return{id:t,uri:"",exports:f[t],config:r(t)}}},h=function(i,s,l,r){var h,c,g,v,b,C,w=[],y=typeof l;if(r=r||i,"undefined"===y||"function"===y){for(s=!s.length&&l.length?["require","exports","module"]:s,b=0;b<s.length;b+=1)if(v=u(s[b],r),c=v.f,"require"===c)w[b]=d.require(i);else if("exports"===c)w[b]=d.exports(i),C=!0;else if("module"===c)h=w[b]=d.module(i);else if(e(f,c)||e(p,c)||e(m,c))w[b]=o(c);else{if(!v.p)throw new Error(i+" missing "+c);v.p.load(v.n,n(r,!0),a(c),{}),w[b]=f[c]}g=l?l.apply(f[i],w):void 0,i&&(h&&h.exports!==t&&h.exports!==f[i]?f[i]=h.exports:g===t&&C||(f[i]=g))}else i&&(f[i]=l)},requirejs=require=c=function(e,i,n,s,a){if("string"==typeof e)return d[e]?d[e](i):o(u(e,i).f);if(!e.splice){if(g=e,g.deps&&c(g.deps,g.callback),!i)return;i.splice?(e=i,i=n,n=null):e=t}return i=i||function(){},"function"==typeof n&&(n=s,s=a),s?h(t,e,i,n):setTimeout(function(){h(t,e,i,n)},4),c},c.config=function(t){return c(t)},requirejs._defined=f,define=function(t,i,n){if("string"!=typeof t)throw new Error("See almond README: incorrect module build, no module name");i.splice||(n=i,i=[]),e(f,t)||e(p,t)||(p[t]=[t,i,n])},define.amd={jQuery:!0}}(),define("plugins/almond.js",function(){}),define("skipLinks",[],function(){"use strict";var t={},e=$("#js-skip-links"),i=$("html, body");t={init:function(){t.bindEvents()},bindEvents:function(){e.on("click","a",function(){var e=$(this),i=e.attr("href");i=i.substring(i.indexOf("#")+1),t.goToSelectedAnchor("#"+i)})},goToSelectedAnchor:function(t){var e=$(t);i.animate({scrollTop:e.offset().top-80},300,function(){e.attr("tabindex",0),e.focus()})}},e.length&&t.init()}),function(t,e,i){"use strict";function n(e,i){this.element=e,this.settings=t.extend({},l,i),this._defaults=l,this._name=o,this.mouseTimeoutID=null,this.focusTimeoutID=null,this.mouseFocused=!1,this.justFocused=!1,this.init()}function s(e){return t.expr.filters.visible(e)&&!t(e).parents().addBack().filter(function(){return"hidden"===t.css(this,"visibility")}).length}function a(e,i){var n,a,o,l=e.nodeName.toLowerCase();return"area"===l?(n=e.parentNode,a=n.name,e.href&&a&&"map"===n.nodeName.toLowerCase()?(o=t("img[usemap=#"+a+"]")[0],!!o&&s(o)):!1):(/input|select|textarea|button|object/.test(l)?!e.disabled:"a"===l?e.href||i:i)&&s(e)}var o="accessibleMegaMenu",l={uuidPrefix:"accessible-megamenu",menuClass:"accessible-megamenu",topNavItemClass:"accessible-megamenu-top-nav-item",panelClass:"accessible-megamenu-panel",panelGroupClass:"accessible-megamenu-panel-group",hoverClass:"hover",focusClass:"focus",openClass:"open"},r={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38,keyMap:{48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",190:"."}};n.prototype=function(){var s,a,l,h,c,u,d,f,p,g,m,v,b,C=0,w=1e3,y="",x="function"==typeof e.hasOwnProperty&&!!e.hasOwnProperty("ontouchstart");return s=function(e){return t(e).closest(":data(plugin_"+o+")").data("plugin_"+o)},a=function(e){e=t(e);var i=this.settings;e.attr("id")||e.attr("id",i.uuidPrefix+"-"+(new Date).getTime()+"-"+ ++C)},l=function(e,n){var s,a=t(e.target),o=this,l=this.settings,h=this.menu,c=a.closest("."+l.topNavItemClass),u=a.hasClass(l.panelClass)?a:a.closest("."+l.panelClass);if(b.call(this,!0),n)if(c=h.find("."+l.topNavItemClass+" ."+l.openClass+":first").closest("."+l.topNavItemClass),c.is(e.relatedTarget)||c.has(e.relatedTarget).length>0)0===c.length&&h.find("[aria-expanded=true]").attr("aria-expanded","false").removeClass(l.openClass).filter("."+l.panelClass).attr("aria-hidden","true");else{if(("mouseout"===e.type||"focusout"===e.type)&&c.has(i.activeElement).length>0)return;c.find("[aria-expanded]").attr("aria-expanded","false").removeClass(l.openClass).filter("."+l.panelClass).attr("aria-hidden","true"),("keydown"===e.type&&e.keyCode===r.ESCAPE||"DOMAttrModified"===e.type)&&(s=c.find(":tabbable:first"),setTimeout(function(){h.find("[aria-expanded]."+o.settings.panelClass).off("DOMAttrModified.accessible-megamenu"),s.focus(),o.justFocused=!1},99))}else clearTimeout(o.focusTimeoutID),c.siblings().find("[aria-expanded]").attr("aria-expanded","false").removeClass(l.openClass).filter("."+l.panelClass).attr("aria-hidden","true"),c.find("[aria-expanded]").attr("aria-expanded","true").addClass(l.openClass).filter("."+l.panelClass).attr("aria-hidden","false"),"mouseover"===e.type&&a.is(":tabbable")&&1===c.length&&0===u.length&&h.has(i.activeElement).length>0&&(a.focus(),o.justFocused=!1),b.call(o)},h=function(e){var i=t(e.currentTarget),n=i.closest("."+this.settings.topNavItemClass),s=i.closest("."+this.settings.panelClass);1===n.length&&0===s.length&&1===n.find("."+this.settings.panelClass).length&&(i.hasClass(this.settings.openClass)?this.justFocused?(e.preventDefault(),e.stopPropagation(),this.justFocused=!1):x&&(e.preventDefault(),e.stopPropagation(),l.call(this,e,i.hasClass(this.settings.openClass))):(e.preventDefault(),e.stopPropagation(),l.call(this,e),this.justFocused=!1))},c=function(e){0===t(e.target).closest(this.menu).length&&(e.preventDefault(),e.stopPropagation(),l.call(this,e,!0))},u=function(e){"aria-expanded"===e.originalEvent.attrName&&"false"===e.originalEvent.newValue&&t(e.target).hasClass(this.settings.openClass)&&(e.preventDefault(),e.stopPropagation(),l.call(this,e,!0))},d=function(e){clearTimeout(this.focusTimeoutID);var i=t(e.target),n=i.closest("."+this.settings.panelClass);i.addClass(this.settings.focusClass).on("click.accessible-megamenu",t.proxy(h,this)),this.justFocused=!this.mouseFocused,this.mouseFocused=!1,this.panels.not(n).filter("."+this.settings.openClass).length&&l.call(this,e)},f=function(i){this.justFocused=!1;var n=this,s=t(i.target),a=s.closest("."+this.settings.topNavItemClass);s.removeClass(this.settings.focusClass).off("click.accessible-megamenu"),e.cvox?n.focusTimeoutID=setTimeout(function(){e.cvox.Api.getCurrentNode(function(t){a.has(t).length?clearTimeout(n.focusTimeoutID):n.focusTimeoutID=setTimeout(function(t,e,i){l.call(t,e,i)},275,n,i,!0)})},25):n.focusTimeoutID=setTimeout(function(){l.call(n,i,!0)},300)},p=function(i){var a,o,c,u,d,f,p=this.constructor===n?this:s(this),g=p.settings,m=t(t(this).is("."+g.hoverClass+":tabbable")?this:i.target),v=p.menu,b=p.topnavitems,C=m.closest("."+g.topNavItemClass),x=v.find(":tabbable"),S=m.hasClass(g.panelClass)?m:m.closest("."+g.panelClass),k=S.find("."+g.panelGroupClass),P=m.closest("."+g.panelGroupClass),L=i.keyCode||i.which,T=!1,F=r.keyMap[i.keyCode]||"",A=1===C.length&&0===S.length;if(!m.is("input:focus, select:focus, textarea:focus, button:focus")){switch(m.is("."+g.hoverClass+":tabbable")&&t("html").off("keydown.accessible-megamenu"),L){case r.ESCAPE:l.call(p,i,!0);break;case r.DOWN:i.preventDefault(),A?(l.call(p,i),T=1===C.find("."+g.panelClass+" :tabbable:first").focus().length):T=1===x.filter(":gt("+x.index(m)+"):first").focus().length,!T&&e.opera&&"[object Opera]"===opera.toString()&&(i.ctrlKey||i.metaKey)&&(x=t(":tabbable"),c=x.index(m),T=1===t(":tabbable:gt("+t(":tabbable").index(m)+"):first").focus().length);break;case r.UP:i.preventDefault(),A&&m.hasClass(g.openClass)?(l.call(p,i,!0),a=b.filter(":lt("+b.index(C)+"):last"),a.children("."+g.panelClass).length&&(T=1===a.children().attr("aria-expanded","true").addClass(g.openClass).filter("."+g.panelClass).attr("aria-hidden","false").find(":tabbable:last").focus())):A||(T=1===x.filter(":lt("+x.index(m)+"):last").focus().length),!T&&e.opera&&"[object Opera]"===opera.toString()&&(i.ctrlKey||i.metaKey)&&(x=t(":tabbable"),c=x.index(m),T=1===t(":tabbable:lt("+t(":tabbable").index(m)+"):first").focus().length);break;case r.RIGHT:i.preventDefault(),A?T=1===b.filter(":gt("+b.index(C)+"):first").find(":tabbable:first").focus().length:(k.length&&P.length&&(T=1===k.filter(":gt("+k.index(P)+"):first").find(":tabbable:first").focus().length),T||(T=1===C.find(":tabbable:first").focus().length));break;case r.LEFT:i.preventDefault(),A?T=1===b.filter(":lt("+b.index(C)+"):last").find(":tabbable:first").focus().length:(k.length&&P.length&&(T=1===k.filter(":lt("+k.index(P)+"):last").find(":tabbable:first").focus().length),T||(T=1===C.find(":tabbable:first").focus().length));break;case r.TAB:c=x.index(m),i.shiftKey&&A&&m.hasClass(g.openClass)?(l.call(p,i,!0),a=b.filter(":lt("+b.index(C)+"):last"),a.children("."+g.panelClass).length&&(T=a.children().attr("aria-expanded","true").addClass(g.openClass).filter("."+g.panelClass).attr("aria-hidden","false").find(":tabbable:last").focus())):i.shiftKey&&c>0?T=1===x.filter(":lt("+c+"):last").focus().length:!i.shiftKey&&c<x.length-1?T=1===x.filter(":gt("+c+"):first").focus().length:e.opera&&"[object Opera]"===opera.toString()&&(x=t(":tabbable"),c=x.index(m),T=i.shiftKey?1===t(":tabbable:lt("+t(":tabbable").index(m)+"):last").focus().length:1===t(":tabbable:gt("+t(":tabbable").index(m)+"):first").focus().length),T&&i.preventDefault();break;case r.SPACE:if(!A)return!0;i.preventDefault(),h.call(p,i);break;case r.ENTER:return!0;default:if(clearTimeout(this.keydownTimeoutID),y+=F!==y?F:"",0===y.length)return;for(this.keydownTimeoutID=setTimeout(function(){y=""},w),x=A&&!m.hasClass(g.openClass)?x.filter(":not(."+g.panelClass+" :tabbable)"):C.find(":tabbable"),i.shiftKey&&(x=t(x.get().reverse())),c=0;c<x.length;c++)if(u=x.eq(c),u.is(m)){o=1===y.length?c+1:c;break}for(f=new RegExp("^"+y.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),"i"),c=o;c<x.length;c++)if(u=x.eq(c),d=t.trim(u.text()),f.test(d)){T=!0,u.focus();break}if(!T)for(c=0;o>c;c++)if(u=x.eq(c),d=t.trim(u.text()),f.test(d)){u.focus();break}}p.justFocused=!1}},g=function(e){(t(e.target).is(this.settings.panelClass)||t(e.target).closest(":focusable").length)&&(this.mouseFocused=!0),this.mouseTimeoutID=setTimeout(function(){clearTimeout(this.focusTimeoutID)},1)},m=function(e){clearTimeout(this.mouseTimeoutID),t(e.target).addClass(this.settings.hoverClass),l.call(this,e),t(e.target).is(":tabbable")&&t("html").on("keydown.accessible-megamenu",t.proxy(p,e.target))},v=function(e){var i=this;t(e.target).removeClass(i.settings.hoverClass),i.mouseTimeoutID=setTimeout(function(){l.call(i,e,!0)},250),t(e.target).is(":tabbable")&&t("html").off("keydown.accessible-megamenu")},b=function(e){var i=this.menu;e?(t("html").off("mouseup.outside-accessible-megamenu, touchend.outside-accessible-megamenu, mspointerup.outside-accessible-megamenu,  pointerup.outside-accessible-megamenu"),i.find("[aria-expanded]."+this.settings.panelClass).off("DOMAttrModified.accessible-megamenu")):(t("html").on("mouseup.outside-accessible-megamenu, touchend.outside-accessible-megamenu, mspointerup.outside-accessible-megamenu,  pointerup.outside-accessible-megamenu",t.proxy(c,this)),i.find("[aria-expanded=true]."+this.settings.panelClass).on("DOMAttrModified.accessible-megamenu",t.proxy(u,this)))},{constructor:n,init:function(){var e=this.settings,i=t(this.element),n=i.children().first(),s=n.children();this.start(e,i,n,s)},start:function(e,n,s,o){var l=this;this.settings=e,this.menu=s,this.topnavitems=o,n.attr("role","navigation"),s.addClass(e.menuClass),o.each(function(i,n){var s,o;n=t(n),n.addClass(e.topNavItemClass),s=n.find(":tabbable:first"),o=n.children(":not(:tabbable):last"),a.call(l,s),o.length&&(a.call(l,o),s.attr({"aria-haspopup":!0,"aria-controls":o.attr("id"),"aria-expanded":!1}),o.attr({role:"group","aria-expanded":!1,"aria-hidden":!0}).addClass(e.panelClass).not("[aria-labelledby]").attr("aria-labelledby",s.attr("id")))}),this.panels=s.find("."+e.panelClass),s.on("focusin.accessible-megamenu",":focusable, ."+e.panelClass,t.proxy(d,this)).on("focusout.accessible-megamenu",":focusable, ."+e.panelClass,t.proxy(f,this)).on("keydown.accessible-megamenu",t.proxy(p,this)).on("mouseover.accessible-megamenu",t.proxy(m,this)).on("mouseout.accessible-megamenu",t.proxy(v,this)).on("mousedown.accessible-megamenu",t.proxy(g,this)),x&&s.on("touchstart.accessible-megamenu",t.proxy(h,this)),s.find("hr").attr("role","separator"),t(i.activeElement).closest(s).length&&t(i.activeElement).trigger("focusin.accessible-megamenu")},getDefaults:function(){return this._defaults},getOption:function(t){return this.settings[t]},getAllOptions:function(){return this.settings},setOption:function(t,e,i){this.settings[t]=e,i&&this.init()}}}(),t.fn[o]=function(e){return this.each(function(){t.data(this,"plugin_"+o)||t.data(this,"plugin_"+o,new t.fn[o].AccessibleMegaMenu(this,e))})},t.fn[o].AccessibleMegaMenu=n,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,n){return!!t.data(e,n[3])},focusable:function(e){return a(e,!isNaN(t.attr(e,"tabindex")))},tabbable:function(e){var i=t.attr(e,"tabindex"),n=isNaN(i);return(n||i>=0)&&a(e,!n)}})}(jQuery,window,document),define("acessibleMenu",function(){}),function(t,e){function i(t){if(9===t.keyCode){var e=!!t.shiftKey;n(this,t.target,e)&&(t.preventDefault(),t.stopPropagation())}}function n(t,e,i){var n,s,a,o,r=l(t),h=e;do{switch(n=r.index(h),s=n+1,a=n-1,o=r.length-1,n){case-1:return!1;case 0:a=o;break;case o:s=0}i&&(s=a),h=r.get(s);try{h.focus()}catch(c){}}while(e===e.ownerDocument.activeElement);return!0}function s(){return this.tabIndex>0}function a(){return!this.tabIndex}function o(t,e){return t.t-e.t||t.i-e.i}function l(e){var i=t(e),n=[],l=0;return d.enable&&d.enable(),i.find("a[href], link[href], [draggable=true], [contenteditable=true], :input:enabled, [tabindex=0]").filter(":visible").filter(a).each(function(t,e){n.push({v:e,t:0,i:l++})}),i.find("[tabindex]").filter(":visible").filter(s).each(function(t,e){n.push({v:e,t:e.tabIndex,i:l++})}),d.disable&&d.disable(),n=t.map(n.sort(o),function(t){return t.v}),t(n)}function r(){return this.keydown(i),this.data(u,!0),this}function h(){return this.unbind("keydown",i),this.removeData(u),this}function c(){return!!this.data(u)}var u="trap.isTrapping";t.fn.extend({trap:r,untrap:h,isTrapping:c});var d={};t.find.find&&t.find.attr!==t.attr&&function(){function i(t){var i=t.getAttributeNode(a);return i&&i.specified?parseInt(i.value,10):e}function n(){o[a]=o.tabIndex=i}function s(){delete o[a],delete o.tabIndex}var a="tabindex",o=t.expr.attrHandle;d={enable:n,disable:s}}()}(jQuery),define("trap",function(){}),define("navigation",["acessibleMenu","trap"],function(){"use strict";var t={},e=$("#js-navigation"),i=$("#js-navigation-toogler"),n=($("html, body"),{menuIsOpen:!1}),s=document.documentElement.clientWidth||window.innerWidth,a=1024>=s?!0:!1;t={init:function(){a?t.bindEvents():t.loadAcessibleNavigation()},loadAcessibleNavigation:function(){e.accessibleMegaMenu({openClass:"is-open"})},bindEvents:function(){i.on("click",function(){t.verifyMenuButton()}),$(document).keyup(function(e){27===e.keyCode&&n.menuIsOpen&&t.closeMenu()}),e.on("click",".navigation-list__anchor",function(e){var i=$(this);i.data("external")||e.preventDefault(),t.expandMenuItens(i)})},verifyMenuButton:function(){n.menuIsOpen?t.closeMenu():t.openMenu()},closeMenu:function(){i.removeClass("is-open"),e.removeClass("is-open"),n.menuIsOpen=!1,$(document.body).off("click.openMenu"),i.attr("aria-expanded","false"),i.focus()},openMenu:function(){i.addClass("is-open"),e.addClass("is-open"),n.menuIsOpen=!0,i.attr("aria-expanded","true"),e.trap(),t.outsideClickCloseMenu()},expandMenuItens:function(t){t.toggleClass("is-expanded"),t.next(".navigation-sub-list:first").toggleClass("is-expanded")},outsideClickCloseMenu:function(){setTimeout(function(){$(document.body).on("click.openMenu",function(i){$(i.target).is(e)&&n.menuIsOpen&&t.closeMenu()})},0)}},e.length&&t.init()}),define("aboutPlatform",[],function(){"use strict";var t={},e=$("#js-about-platform");t={init:function(){t.verifyVisibility()},verifyVisibility:function(){t.bindEvents()},bindEvents:function(){e.on("click",".about-platform__close:first",function(){var e=$(this);t.closeConcepts(e)})},closeConcepts:function(){console.log("vou deletar")}},e.length&&t.init()}),define("cards",[],function(){"use strict";var t={},e=$(".article-cards__list");t={init:function(){t.bindEvents()},bindEvents:function(){e.on("click",".article-cards__connections-toggler",function(){t.toggleCard($(this))})},toggleCard:function(t){t.parent(".article-cards__card:first").toggleClass("is-flipped")}},e.length&&t.init()}),!function(t,e){"function"==typeof define&&define.amd?define("salvattore",[],e):"object"==typeof exports?module.exports=e():t.salvattore=e()}(this,function(){window.matchMedia||(window.matchMedia=function(){"use strict";var t=window.styleMedia||window.media;if(!t){var e=document.createElement("style"),i=document.getElementsByTagName("script")[0],n=null;e.type="text/css",e.id="matchmediajs-test",i.parentNode.insertBefore(e,i),n="getComputedStyle"in window&&window.getComputedStyle(e,null)||e.currentStyle,t={matchMedium:function(t){var i="@media "+t+"{ #matchmediajs-test { width: 1px; } }";return e.styleSheet?e.styleSheet.cssText=i:e.textContent=i,"1px"===n.width}}}return function(e){return{matches:t.matchMedium(e||"all"),media:e||"all"}}}()),function(){"use strict";if(window.matchMedia&&window.matchMedia("all").addListener)return!1;var t=window.matchMedia,e=t("only all").matches,i=!1,n=0,s=[],a=function(e){clearTimeout(n),n=setTimeout(function(){for(var e=0,i=s.length;i>e;e++){var n=s[e].mql,a=s[e].listeners||[],o=t(n.media).matches;if(o!==n.matches){n.matches=o;for(var l=0,r=a.length;r>l;l++)a[l].call(window,n)}}},30)};window.matchMedia=function(n){var o=t(n),l=[],r=0;return o.addListener=function(t){e&&(i||(i=!0,window.addEventListener("resize",a,!0)),0===r&&(r=s.push({mql:o,listeners:l})),l.push(t))},o.removeListener=function(t){for(var e=0,i=l.length;i>e;e++)l[e]===t&&l.splice(e,1)},o}}(),function(){"use strict";for(var t=0,e=["ms","moz","webkit","o"],i=0;i<e.length&&!window.requestAnimationFrame;++i)window.requestAnimationFrame=window[e[i]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[e[i]+"CancelAnimationFrame"]||window[e[i]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(e,i){var n=(new Date).getTime(),s=Math.max(0,16-(n-t)),a=window.setTimeout(function(){e(n+s)},s);return t=n+s,a}),window.cancelAnimationFrame||(window.cancelAnimationFrame=function(t){clearTimeout(t)})}(),"function"!=typeof window.CustomEvent&&!function(){"use strict";function t(t,e){e=e||{bubbles:!1,cancelable:!1,detail:void 0};var i=document.createEvent("CustomEvent");return i.initCustomEvent(t,e.bubbles,e.cancelable,e.detail),i}t.prototype=window.Event.prototype,window.CustomEvent=t}();var t=function(t,e,i){"use strict";var n={},s=[],a=[],o=[],l=function(t,e,i){t.dataset?t.dataset[e]=i:t.setAttribute("data-"+e,i)};return n.obtainGridSettings=function(e){var i=t.getComputedStyle(e,":before"),n=i.getPropertyValue("content").slice(1,-1),s=n.match(/^\s*(\d+)(?:\s?\.(.+))?\s*$/),a=1,o=[];return s?(a=s[1],o=s[2],o=o?o.split("."):["column"]):(s=n.match(/^\s*\.(.+)\s+(\d+)\s*$/),s&&(o=s[1],a=s[2],a&&(a=a.split(".")))),{numberOfColumns:a,columnClasses:o}},n.addColumns=function(t,i){for(var s,a=n.obtainGridSettings(t),o=a.numberOfColumns,r=a.columnClasses,h=new Array(+o),c=e.createDocumentFragment(),u=o;0!==u--;)s="[data-columns] > *:nth-child("+o+"n-"+u+")",h.push(i.querySelectorAll(s));h.forEach(function(t){var i=e.createElement("div"),n=e.createDocumentFragment();i.className=r.join(" "),Array.prototype.forEach.call(t,function(t){n.appendChild(t)}),i.appendChild(n),c.appendChild(i)}),t.appendChild(c),l(t,"columns",o)},n.removeColumns=function(i){var n=e.createRange();n.selectNodeContents(i);var s=Array.prototype.filter.call(n.extractContents().childNodes,function(e){return e instanceof t.HTMLElement}),a=s.length,o=s[0].childNodes.length,r=new Array(o*a);Array.prototype.forEach.call(s,function(t,e){Array.prototype.forEach.call(t.children,function(t,i){r[i*a+e]=t})});var h=e.createElement("div");return l(h,"columns",0),r.filter(function(t){return!!t}).forEach(function(t){h.appendChild(t)}),h},n.recreateColumns=function(e){t.requestAnimationFrame(function(){n.addColumns(e,n.removeColumns(e));var t=new CustomEvent("columnsChange");e.dispatchEvent(t)})},n.mediaQueryChange=function(t){t.matches&&Array.prototype.forEach.call(s,n.recreateColumns)},n.getCSSRules=function(t){var e;try{e=t.sheet.cssRules||t.sheet.rules}catch(i){return[]}return e||[]},n.getStylesheets=function(){var t=Array.prototype.slice.call(e.querySelectorAll("style"));return t.forEach(function(e,i){"text/css"!==e.type&&""!==e.type&&t.splice(i,1)}),Array.prototype.concat.call(t,Array.prototype.slice.call(e.querySelectorAll("link[rel='stylesheet']")))},n.mediaRuleHasColumnsSelector=function(t){var e,i;try{e=t.length}catch(n){e=0}for(;e--;)if(i=t[e],i.selectorText&&i.selectorText.match(/\[data-columns\](.*)::?before$/))return!0;return!1},n.scanMediaQueries=function(){var e=[];if(t.matchMedia){n.getStylesheets().forEach(function(t){Array.prototype.forEach.call(n.getCSSRules(t),function(t){try{t.media&&t.cssRules&&n.mediaRuleHasColumnsSelector(t.cssRules)&&e.push(t)}catch(i){}})});var i=a.filter(function(t){return-1===e.indexOf(t)});o.filter(function(t){return-1!==i.indexOf(t.rule)}).forEach(function(t){t.mql.removeListener(n.mediaQueryChange)}),o=o.filter(function(t){return-1===i.indexOf(t.rule)}),e.filter(function(t){return-1==a.indexOf(t)}).forEach(function(e){var i=t.matchMedia(e.media.mediaText);i.addListener(n.mediaQueryChange),o.push({rule:e,mql:i})}),a.length=0,a=e}},n.rescanMediaQueries=function(){n.scanMediaQueries(),Array.prototype.forEach.call(s,n.recreateColumns)},n.nextElementColumnIndex=function(t,e){var i,n,s,a=t.children,o=a.length,l=0,r=0;for(s=0;o>s;s++)i=a[s],n=i.children.length+(e[s].children||e[s].childNodes).length,0===l&&(l=n),l>n&&(r=s,l=n);return r},n.createFragmentsList=function(t){for(var i=new Array(t),n=0;n!==t;)i[n]=e.createDocumentFragment(),n++;return i},n.appendElements=function(t,e){var i=t.children,s=i.length,a=n.createFragmentsList(s);Array.prototype.forEach.call(e,function(e){var i=n.nextElementColumnIndex(t,a);a[i].appendChild(e)}),Array.prototype.forEach.call(i,function(t,e){t.appendChild(a[e])})},n.prependElements=function(t,i){var s=t.children,a=s.length,o=n.createFragmentsList(a),l=a-1;i.forEach(function(t){var e=o[l];e.insertBefore(t,e.firstChild),0===l?l=a-1:l--}),Array.prototype.forEach.call(s,function(t,e){t.insertBefore(o[e],t.firstChild)});for(var r=e.createDocumentFragment(),h=i.length%a;0!==h--;)r.appendChild(t.lastChild);t.insertBefore(r,t.firstChild)},n.registerGrid=function(i){if("none"!==t.getComputedStyle(i).display){var a=e.createRange();a.selectNodeContents(i);var o=e.createElement("div");o.appendChild(a.extractContents()),l(o,"columns",0),n.addColumns(i,o),s.push(i)}},n.init=function(){var t=e.createElement("style");t.innerHTML="[data-columns]::before{display:block;visibility:hidden;position:absolute;font-size:1px;}",e.head.appendChild(t);var i=e.querySelectorAll("[data-columns]");Array.prototype.forEach.call(i,n.registerGrid),n.scanMediaQueries()},n.init(),{appendElements:n.appendElements,prependElements:n.prependElements,registerGrid:n.registerGrid,recreateColumns:n.recreateColumns,rescanMediaQueries:n.rescanMediaQueries,init:n.init,append_elements:n.appendElements,prepend_elements:n.prependElements,register_grid:n.registerGrid,recreate_columns:n.recreateColumns,rescan_media_queries:n.rescanMediaQueries}}(window,window.document);return t}),define("linkedDataToggler",[],function(){"use strict";var t={},e={on:"on",off:"off"},i=$("#js-article-cards__list"),n=$("#js-linked-data-toggler__toggler"),s=n.find(".linked-data-toggler__toggler-text:first");t={init:function(){t.bindEvents()},bindEvents:function(){n.on("click",function(){t.verifyStatus($(this))})},verifyStatus:function(i){"true"===i.attr("data-linked-data-on")?(t.unloadLinkedData(i),s.text(e.off),i.attr("data-linked-data-on",!1)):(t.loadLinkedData(i),s.text(e.on),i.attr("data-linked-data-on",!0)),t.toggleData(i)},toggleData:function(t){t.toggleClass("is-active")},unloadLinkedData:function(){$.ajax({url:"js/ajax/linked-news.html",success:function(t){i.html(t)}})},loadLinkedData:function(){$.ajax({url:"js/ajax/linked-data.html",success:function(t){i.html(t)}})}},n.length&&t.init()}),define("facebookLikeBox",[],function(){"use strict";var t={},e=$("#js-facebook-like-box");t={init:function(){t.loadLikeBox()},loadLikeBox:function(){e.html('<div class="fb-page" data-href="https://www.facebook.com/opendata4dev" data-width="300" data-hide-cover="false" data-show-facepile="true" data-show-posts="false"><div class="fb-xfbml-parse-ignore"><blockquote cite="https://www.facebook.com/opendata4dev"><a href="https://www.facebook.com/opendata4dev">opendata4dev</a></blockquote></div></div>')}},e.length&&t.init()}),!function(t,e){"function"==typeof define&&define.amd?define("twitterFetcher",[],e):"object"==typeof exports?module.exports=e():e()}(this,function(){function t(t){if(null===g){for(var e=t.length,i=0,n=document.getElementById(a),s="<ul>";e>i;)s+="<li>"+t[i]+"</li>",i++;s+="</ul>",n.innerHTML=s}else g(t)}function e(t){return t.replace(/<b[^>]*>(.*?)<\/b>/gi,function(t,e){return e}).replace(/class=".*?"|data-query-source=".*?"|dir=".*?"|rel=".*?"/gi,"")}function i(t){for(var e=t.getElementsByTagName("a"),i=e.length-1;i>=0;i--)e[i].setAttribute("target","_blank")}function n(t,e){for(var i=[],n=new RegExp("(^| )"+e+"( |$)"),s=t.getElementsByTagName("*"),a=0,o=s.length;o>a;a++)n.test(s[a].className)&&i.push(s[a]);return i}function s(t){if(void 0!==t){var e=t.innerHTML.match(/data-srcset="([A-z0-9%_\.-]+)/i)[0];return decodeURIComponent(e).split('"')[1]}}var a="",o=20,l=!0,r=[],h=!1,c=!0,u=!0,d=null,f=!0,p=!0,g=null,m=!0,v=!1,b=!0,C="en",w=!0,y=!1,x=null,S={fetch:function(t){if(void 0===t.maxTweets&&(t.maxTweets=20),void 0===t.enableLinks&&(t.enableLinks=!0),void 0===t.showUser&&(t.showUser=!0),void 0===t.showTime&&(t.showTime=!0),void 0===t.dateFunction&&(t.dateFunction="default"),void 0===t.showRetweet&&(t.showRetweet=!0),void 0===t.customCallback&&(t.customCallback=null),void 0===t.showInteraction&&(t.showInteraction=!0),void 0===t.showImages&&(t.showImages=!1),void 0===t.linksInNewWindow&&(t.linksInNewWindow=!0),void 0===t.showPermalinks&&(t.showPermalinks=!0),void 0===t.dataOnly&&(t.dataOnly=!1),h)r.push(t);else{h=!0,a=t.domId,o=t.maxTweets,l=t.enableLinks,u=t.showUser,c=t.showTime,p=t.showRetweet,d=t.dateFunction,g=t.customCallback,m=t.showInteraction,v=t.showImages,b=t.linksInNewWindow,w=t.showPermalinks,y=t.dataOnly;var e=document.getElementsByTagName("head")[0];null!==x&&e.removeChild(x),x=document.createElement("script"),x.type="text/javascript",x.src="https://cdn.syndication.twimg.com/widgets/timelines/"+t.id+"?&lang="+(t.lang||C)+"&callback=twitterFetcher.callback&suppress_response_codes=true&rnd="+Math.random(),e.appendChild(x)}},callback:function(a){function g(t){var e=t.getElementsByTagName("img")[0];return e.src=e.dataset["src-2x"],t}var C=document.createElement("div");C.innerHTML=a.body,"undefined"==typeof C.getElementsByClassName&&(f=!1);var x=[],k=[],P=[],L=[],T=[],F=[],A=[],E=0;if(f)for(var M=C.getElementsByClassName("tweet");E<M.length;)M[E].getElementsByClassName("retweet-credit").length>0?T.push(!0):T.push(!1),(!T[E]||T[E]&&p)&&(x.push(M[E].getElementsByClassName("e-entry-title")[0]),F.push(M[E].getAttribute("data-tweet-id")),k.push(g(M[E].getElementsByClassName("p-author")[0])),P.push(M[E].getElementsByClassName("dt-updated")[0]),A.push(M[E].getElementsByClassName("permalink")[0]),void 0!==M[E].getElementsByClassName("inline-media")[0]?L.push(M[E].getElementsByClassName("inline-media")[0]):L.push(void 0)),E++;else for(var M=n(C,"tweet");E<M.length;)x.push(n(M[E],"e-entry-title")[0]),F.push(M[E].getAttribute("data-tweet-id")),k.push(g(n(M[E],"p-author")[0])),P.push(n(M[E],"dt-updated")[0]),A.push(n(M[E],"permalink")[0]),void 0!==n(M[E],"inline-media")[0]?L.push(n(M[E],"inline-media")[0]):L.push(void 0),n(M[E],"retweet-credit").length>0?T.push(!0):T.push(!1),E++;x.length>o&&(x.splice(o,x.length-o),k.splice(o,k.length-o),P.splice(o,P.length-o),T.splice(o,T.length-o),L.splice(o,L.length-o),A.splice(o,A.length-o));var R=[],E=x.length,D=0;if(y)for(;E>D;)R.push({tweet:x[D].innerHTML,author:k[D].innerHTML,time:P[D].innerText,image:s(L[D]),rt:T[D],tid:F[D],permalinkURL:A[D].href}),D++;else for(;E>D;){if("string"!=typeof d){var I=P[D].getAttribute("datetime"),B=new Date(P[D].getAttribute("datetime").replace(/-/g,"/").replace("T"," ").split("+")[0]),W=d(B,I);if(P[D].setAttribute("aria-label",W),x[D].innerText)if(f)P[D].innerText=W;else{var z=document.createElement("p"),O=document.createTextNode(W);z.appendChild(O),z.setAttribute("aria-label",W),P[D]=z}else P[D].textContent=W}var _="";l?(b&&(i(x[D]),u&&i(k[D])),u&&(_+='<div class="user">'+e(k[D].innerHTML)+"</div>"),_+='<p class="tweet">'+e(x[D].innerHTML)+"</p>",c&&(_+=w?'<p class="timePosted"><a href="'+A[D]+'">'+P[D].getAttribute("aria-label")+"</a></p>":'<p class="timePosted">'+P[D].getAttribute("aria-label")+"</p>")):x[D].innerText?(u&&(_+='<p class="user">'+k[D].innerText+"</p>"),_+='<p class="tweet">'+x[D].innerText+"</p>",c&&(_+='<p class="timePosted">'+P[D].innerText+"</p>")):(u&&(_+='<p class="user">'+k[D].textContent+"</p>"),_+='<p class="tweet">'+x[D].textContent+"</p>",c&&(_+='<p class="timePosted">'+P[D].textContent+"</p>")),m&&(_+='<p class="interact"><a href="https://twitter.com/intent/tweet?in_reply_to='+F[D]+'" class="twitter_reply_icon"'+(b?' target="_blank">':">")+'Reply</a><a href="https://twitter.com/intent/retweet?tweet_id='+F[D]+'" class="twitter_retweet_icon"'+(b?' target="_blank">':">")+'Retweet</a><a href="https://twitter.com/intent/favorite?tweet_id='+F[D]+'" class="twitter_fav_icon"'+(b?' target="_blank">':">")+"Favorite</a></p>"),v&&void 0!==L[D]&&(_+='<div class="media"><img src="'+s(L[D])+'" alt="Image from tweet" /></div>'),R.push(_),D++}t(R),h=!1,r.length>0&&(S.fetch(r[0]),r.splice(0,1))}};return window.twitterFetcher=S,S}),define("twitterList",["twitterFetcher"],function(t){"use strict";
  var e={id:"483257072985726976",domId:"js-twitter-list",showTime:!1,maxTweets:2,enableLinks:!0,showRetweet:!1,showInteraction:!1};t.fetch(e)}),define("pinterestBoard",["pinterest"],function(){}),define("listCardExhibition",[],function(){var t={},e=$("#js-list-card-exhibition"),i=$("#js-list-card-wrapper"),n={};t={init:function(){t.findCurrentView(),t.bindEvents()},findCurrentView:function(){e.find("button").each(function(){$(this).attr("disabled")&&(n.currentViewButton=$(this))}),void 0===n.currentViewButton&&(n.currentViewButton=e.find("button:first"),n.currentViewButton.prop("disabled",!0)),t.changeListView()},bindEvents:function(){e.on("click","button",function(){t.toggleView($(this))})},toggleView:function(e){n.currentViewButton.prop("disabled",!1),n.currentViewButton=e,t.changeListView(),i.attr("tabindex",-1).focus()},changeListView:function(){i.attr("data-list-current-view",n.currentViewButton.data("list-view")),n.currentViewButton.prop("disabled",!0)}},e.length&&t.init()}),function(){"use strict";var t=this,e=t.Chart,i=function(t){this.canvas=t.canvas,this.ctx=t;var e=function(t,e){return t["offset"+e]?t["offset"+e]:document.defaultView.getComputedStyle(t).getPropertyValue(e)},i=this.width=e(t.canvas,"Width"),s=this.height=e(t.canvas,"Height");t.canvas.width=i,t.canvas.height=s;var i=this.width=t.canvas.width,s=this.height=t.canvas.height;return this.aspectRatio=this.width/this.height,n.retinaScale(this),this};i.defaults={global:{animation:!0,animationSteps:60,animationEasing:"easeOutQuart",showScale:!0,scaleOverride:!1,scaleSteps:null,scaleStepWidth:null,scaleStartValue:null,scaleLineColor:"rgba(0,0,0,.1)",scaleLineWidth:1,scaleShowLabels:!0,scaleLabel:"<%=value%>",scaleIntegersOnly:!0,scaleBeginAtZero:!1,scaleFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",scaleFontSize:12,scaleFontStyle:"normal",scaleFontColor:"#666",responsive:!1,maintainAspectRatio:!0,showTooltips:!0,customTooltips:!1,tooltipEvents:["mousemove","touchstart","touchmove","mouseout"],tooltipFillColor:"rgba(0,0,0,0.8)",tooltipFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",tooltipFontSize:14,tooltipFontStyle:"normal",tooltipFontColor:"#fff",tooltipTitleFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",tooltipTitleFontSize:14,tooltipTitleFontStyle:"bold",tooltipTitleFontColor:"#fff",tooltipYPadding:6,tooltipXPadding:6,tooltipCaretSize:8,tooltipCornerRadius:6,tooltipXOffset:10,tooltipTemplate:"<%if (label){%><%=label%>: <%}%><%= value %>",multiTooltipTemplate:"<%= value %>",multiTooltipKeyBackground:"#fff",onAnimationProgress:function(){},onAnimationComplete:function(){}}},i.types={};var n=i.helpers={},s=n.each=function(t,e,i){var n=Array.prototype.slice.call(arguments,3);if(t)if(t.length===+t.length){var s;for(s=0;s<t.length;s++)e.apply(i,[t[s],s].concat(n))}else for(var a in t)e.apply(i,[t[a],a].concat(n))},a=n.clone=function(t){var e={};return s(t,function(i,n){t.hasOwnProperty(n)&&(e[n]=i)}),e},o=n.extend=function(t){return s(Array.prototype.slice.call(arguments,1),function(e){s(e,function(i,n){e.hasOwnProperty(n)&&(t[n]=i)})}),t},l=n.merge=function(){var t=Array.prototype.slice.call(arguments,0);return t.unshift({}),o.apply(null,t)},r=n.indexOf=function(t,e){if(Array.prototype.indexOf)return t.indexOf(e);for(var i=0;i<t.length;i++)if(t[i]===e)return i;return-1},h=(n.where=function(t,e){var i=[];return n.each(t,function(t){e(t)&&i.push(t)}),i},n.findNextWhere=function(t,e,i){i||(i=-1);for(var n=i+1;n<t.length;n++){var s=t[n];if(e(s))return s}},n.findPreviousWhere=function(t,e,i){i||(i=t.length);for(var n=i-1;n>=0;n--){var s=t[n];if(e(s))return s}},n.inherits=function(t){var e=this,i=t&&t.hasOwnProperty("constructor")?t.constructor:function(){return e.apply(this,arguments)},n=function(){this.constructor=i};return n.prototype=e.prototype,i.prototype=new n,i.extend=h,t&&o(i.prototype,t),i.__super__=e.prototype,i}),c=n.noop=function(){},u=n.uid=function(){var t=0;return function(){return"chart-"+t++}}(),d=n.warn=function(t){window.console&&"function"==typeof window.console.warn&&console.warn(t)},f=n.amd="function"==typeof define&&define.amd,p=n.isNumber=function(t){return!isNaN(parseFloat(t))&&isFinite(t)},g=n.max=function(t){return Math.max.apply(Math,t)},m=n.min=function(t){return Math.min.apply(Math,t)},v=(n.cap=function(t,e,i){if(p(e)){if(t>e)return e}else if(p(i)&&i>t)return i;return t},n.getDecimalPlaces=function(t){return t%1!==0&&p(t)?t.toString().split(".")[1].length:0}),b=n.radians=function(t){return t*(Math.PI/180)},C=(n.getAngleFromPoint=function(t,e){var i=e.x-t.x,n=e.y-t.y,s=Math.sqrt(i*i+n*n),a=2*Math.PI+Math.atan2(n,i);return 0>i&&0>n&&(a+=2*Math.PI),{angle:a,distance:s}},n.aliasPixel=function(t){return t%2===0?0:.5}),w=(n.splineCurve=function(t,e,i,n){var s=Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)),a=Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2)),o=n*s/(s+a),l=n*a/(s+a);return{inner:{x:e.x-o*(i.x-t.x),y:e.y-o*(i.y-t.y)},outer:{x:e.x+l*(i.x-t.x),y:e.y+l*(i.y-t.y)}}},n.calculateOrderOfMagnitude=function(t){return Math.floor(Math.log(t)/Math.LN10)}),y=(n.calculateScaleRange=function(t,e,i,n,s){var a=2,o=Math.floor(e/(1.5*i)),l=a>=o,r=g(t),h=m(t);r===h&&(r+=.5,h>=.5&&!n?h-=.5:r+=.5);for(var c=Math.abs(r-h),u=w(c),d=Math.ceil(r/(1*Math.pow(10,u)))*Math.pow(10,u),f=n?0:Math.floor(h/(1*Math.pow(10,u)))*Math.pow(10,u),p=d-f,v=Math.pow(10,u),b=Math.round(p/v);(b>o||o>2*b)&&!l;)if(b>o)v*=2,b=Math.round(p/v),b%1!==0&&(l=!0);else if(s&&u>=0){if(v/2%1!==0)break;v/=2,b=Math.round(p/v)}else v/=2,b=Math.round(p/v);return l&&(b=a,v=p/b),{steps:b,stepValue:v,min:f,max:f+b*v}},n.template=function(t,e){function i(t,e){var i=/\W/.test(t)?new Function("obj","var p=[],print=function(){p.push.apply(p,arguments);};with(obj){p.push('"+t.replace(/[\r\t\n]/g," ").split("<%").join("	").replace(/((^|%>)[^\t]*)'/g,"$1\r").replace(/\t=(.*?)%>/g,"',$1,'").split("	").join("');").split("%>").join("p.push('").split("\r").join("\\'")+"');}return p.join('');"):n[t]=n[t];return e?i(e):i}if(t instanceof Function)return t(e);var n={};return i(t,e)}),x=(n.generateLabels=function(t,e,i,n){var a=new Array(e);return labelTemplateString&&s(a,function(e,s){a[s]=y(t,{value:i+n*(s+1)})}),a},n.easingEffects={linear:function(t){return t},easeInQuad:function(t){return t*t},easeOutQuad:function(t){return-1*t*(t-2)},easeInOutQuad:function(t){return(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1)},easeInCubic:function(t){return t*t*t},easeOutCubic:function(t){return 1*((t=t/1-1)*t*t+1)},easeInOutCubic:function(t){return(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},easeInQuart:function(t){return t*t*t*t},easeOutQuart:function(t){return-1*((t=t/1-1)*t*t*t-1)},easeInOutQuart:function(t){return(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},easeInQuint:function(t){return 1*(t/=1)*t*t*t*t},easeOutQuint:function(t){return 1*((t=t/1-1)*t*t*t*t+1)},easeInOutQuint:function(t){return(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},easeInSine:function(t){return-1*Math.cos(t/1*(Math.PI/2))+1},easeOutSine:function(t){return 1*Math.sin(t/1*(Math.PI/2))},easeInOutSine:function(t){return-.5*(Math.cos(Math.PI*t/1)-1)},easeInExpo:function(t){return 0===t?1:1*Math.pow(2,10*(t/1-1))},easeOutExpo:function(t){return 1===t?1:1*(-Math.pow(2,-10*t/1)+1)},easeInOutExpo:function(t){return 0===t?0:1===t?1:(t/=.5)<1?.5*Math.pow(2,10*(t-1)):.5*(-Math.pow(2,-10*--t)+2)},easeInCirc:function(t){return t>=1?t:-1*(Math.sqrt(1-(t/=1)*t)-1)},easeOutCirc:function(t){return 1*Math.sqrt(1-(t=t/1-1)*t)},easeInOutCirc:function(t){return(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},easeInElastic:function(t){var e=1.70158,i=0,n=1;return 0===t?0:1==(t/=1)?1:(i||(i=.3),n<Math.abs(1)?(n=1,e=i/4):e=i/(2*Math.PI)*Math.asin(1/n),-(n*Math.pow(2,10*(t-=1))*Math.sin(2*(1*t-e)*Math.PI/i)))},easeOutElastic:function(t){var e=1.70158,i=0,n=1;return 0===t?0:1==(t/=1)?1:(i||(i=.3),n<Math.abs(1)?(n=1,e=i/4):e=i/(2*Math.PI)*Math.asin(1/n),n*Math.pow(2,-10*t)*Math.sin(2*(1*t-e)*Math.PI/i)+1)},easeInOutElastic:function(t){var e=1.70158,i=0,n=1;return 0===t?0:2==(t/=.5)?1:(i||(i=.3*1.5),n<Math.abs(1)?(n=1,e=i/4):e=i/(2*Math.PI)*Math.asin(1/n),1>t?-.5*n*Math.pow(2,10*(t-=1))*Math.sin(2*(1*t-e)*Math.PI/i):n*Math.pow(2,-10*(t-=1))*Math.sin(2*(1*t-e)*Math.PI/i)*.5+1)},easeInBack:function(t){var e=1.70158;return 1*(t/=1)*t*((e+1)*t-e)},easeOutBack:function(t){var e=1.70158;return 1*((t=t/1-1)*t*((e+1)*t+e)+1)},easeInOutBack:function(t){var e=1.70158;return(t/=.5)<1?.5*t*t*(((e*=1.525)+1)*t-e):.5*((t-=2)*t*(((e*=1.525)+1)*t+e)+2)},easeInBounce:function(t){return 1-x.easeOutBounce(1-t)},easeOutBounce:function(t){return(t/=1)<1/2.75?7.5625*t*t:2/2.75>t?1*(7.5625*(t-=1.5/2.75)*t+.75):2.5/2.75>t?1*(7.5625*(t-=2.25/2.75)*t+.9375):1*(7.5625*(t-=2.625/2.75)*t+.984375)},easeInOutBounce:function(t){return.5>t?.5*x.easeInBounce(2*t):.5*x.easeOutBounce(2*t-1)+.5}}),S=n.requestAnimFrame=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return window.setTimeout(t,1e3/60)}}(),k=n.cancelAnimFrame=function(){return window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.oCancelAnimationFrame||window.msCancelAnimationFrame||function(t){return window.clearTimeout(t,1e3/60)}}(),P=(n.animationLoop=function(t,e,i,n,s,a){var o=0,l=x[i]||x.linear,r=function(){o++;var i=o/e,h=l(i);t.call(a,h,i,o),n.call(a,h,i),e>o?a.animationFrame=S(r):s.apply(a)};S(r)},n.getRelativePosition=function(t){var e,i,n=t.originalEvent||t,s=t.currentTarget||t.srcElement,a=s.getBoundingClientRect();return n.touches?(e=n.touches[0].clientX-a.left,i=n.touches[0].clientY-a.top):(e=n.clientX-a.left,i=n.clientY-a.top),{x:e,y:i}},n.addEvent=function(t,e,i){t.addEventListener?t.addEventListener(e,i):t.attachEvent?t.attachEvent("on"+e,i):t["on"+e]=i}),L=n.removeEvent=function(t,e,i){t.removeEventListener?t.removeEventListener(e,i,!1):t.detachEvent?t.detachEvent("on"+e,i):t["on"+e]=c},T=(n.bindEvents=function(t,e,i){t.events||(t.events={}),s(e,function(e){t.events[e]=function(){i.apply(t,arguments)},P(t.chart.canvas,e,t.events[e])})},n.unbindEvents=function(t,e){s(e,function(e,i){L(t.chart.canvas,i,e)})}),F=n.getMaximumWidth=function(t){var e=t.parentNode;return e.clientWidth},A=n.getMaximumHeight=function(t){var e=t.parentNode;return e.clientHeight},E=(n.getMaximumSize=n.getMaximumWidth,n.retinaScale=function(t){var e=t.ctx,i=t.canvas.width,n=t.canvas.height;window.devicePixelRatio&&(e.canvas.style.width=i+"px",e.canvas.style.height=n+"px",e.canvas.height=n*window.devicePixelRatio,e.canvas.width=i*window.devicePixelRatio,e.scale(window.devicePixelRatio,window.devicePixelRatio))}),M=n.clear=function(t){t.ctx.clearRect(0,0,t.width,t.height)},R=n.fontString=function(t,e,i){return e+" "+t+"px "+i},D=n.longestText=function(t,e,i){t.font=e;var n=0;return s(i,function(e){var i=t.measureText(e).width;n=i>n?i:n}),n},I=n.drawRoundedRectangle=function(t,e,i,n,s,a){t.beginPath(),t.moveTo(e+a,i),t.lineTo(e+n-a,i),t.quadraticCurveTo(e+n,i,e+n,i+a),t.lineTo(e+n,i+s-a),t.quadraticCurveTo(e+n,i+s,e+n-a,i+s),t.lineTo(e+a,i+s),t.quadraticCurveTo(e,i+s,e,i+s-a),t.lineTo(e,i+a),t.quadraticCurveTo(e,i,e+a,i),t.closePath()};i.instances={},i.Type=function(t,e,n){this.options=e,this.chart=n,this.id=u(),i.instances[this.id]=this,e.responsive&&this.resize(),this.initialize.call(this,t)},o(i.Type.prototype,{initialize:function(){return this},clear:function(){return M(this.chart),this},stop:function(){return k(this.animationFrame),this},resize:function(t){this.stop();var e=this.chart.canvas,i=F(this.chart.canvas),n=this.options.maintainAspectRatio?i/this.chart.aspectRatio:A(this.chart.canvas);return e.width=this.chart.width=i,e.height=this.chart.height=n,E(this.chart),"function"==typeof t&&t.apply(this,Array.prototype.slice.call(arguments,1)),this},reflow:c,render:function(t){return t&&this.reflow(),this.options.animation&&!t?n.animationLoop(this.draw,this.options.animationSteps,this.options.animationEasing,this.options.onAnimationProgress,this.options.onAnimationComplete,this):(this.draw(),this.options.onAnimationComplete.call(this)),this},generateLegend:function(){return y(this.options.legendTemplate,this)},destroy:function(){this.clear(),T(this,this.events);var t=this.chart.canvas;t.width=this.chart.width,t.height=this.chart.height,t.style.removeProperty?(t.style.removeProperty("width"),t.style.removeProperty("height")):(t.style.removeAttribute("width"),t.style.removeAttribute("height")),delete i.instances[this.id]},showTooltip:function(t,e){"undefined"==typeof this.activeElements&&(this.activeElements=[]);var a=function(t){var e=!1;return t.length!==this.activeElements.length?e=!0:(s(t,function(t,i){t!==this.activeElements[i]&&(e=!0)},this),e)}.call(this,t);if(a||e){if(this.activeElements=t,this.draw(),this.options.customTooltips&&this.options.customTooltips(!1),t.length>0)if(this.datasets&&this.datasets.length>1){for(var o,l,h=this.datasets.length-1;h>=0&&(o=this.datasets[h].points||this.datasets[h].bars||this.datasets[h].segments,l=r(o,t[0]),-1===l);h--);var c=[],u=[],d=function(){var t,e,i,s,a,o=[],r=[],h=[];return n.each(this.datasets,function(e){t=e.points||e.bars||e.segments,t[l]&&t[l].hasValue()&&o.push(t[l])}),n.each(o,function(t){r.push(t.x),h.push(t.y),c.push(n.template(this.options.multiTooltipTemplate,t)),u.push({fill:t._saved.fillColor||t.fillColor,stroke:t._saved.strokeColor||t.strokeColor})},this),a=m(h),i=g(h),s=m(r),e=g(r),{x:s>this.chart.width/2?s:e,y:(a+i)/2}}.call(this,l);new i.MultiTooltip({x:d.x,y:d.y,xPadding:this.options.tooltipXPadding,yPadding:this.options.tooltipYPadding,xOffset:this.options.tooltipXOffset,fillColor:this.options.tooltipFillColor,textColor:this.options.tooltipFontColor,fontFamily:this.options.tooltipFontFamily,fontStyle:this.options.tooltipFontStyle,fontSize:this.options.tooltipFontSize,titleTextColor:this.options.tooltipTitleFontColor,titleFontFamily:this.options.tooltipTitleFontFamily,titleFontStyle:this.options.tooltipTitleFontStyle,titleFontSize:this.options.tooltipTitleFontSize,cornerRadius:this.options.tooltipCornerRadius,labels:c,legendColors:u,legendColorBackground:this.options.multiTooltipKeyBackground,title:t[0].label,chart:this.chart,ctx:this.chart.ctx,custom:this.options.customTooltips}).draw()}else s(t,function(t){var e=t.tooltipPosition();new i.Tooltip({x:Math.round(e.x),y:Math.round(e.y),xPadding:this.options.tooltipXPadding,yPadding:this.options.tooltipYPadding,fillColor:this.options.tooltipFillColor,textColor:this.options.tooltipFontColor,fontFamily:this.options.tooltipFontFamily,fontStyle:this.options.tooltipFontStyle,fontSize:this.options.tooltipFontSize,caretHeight:this.options.tooltipCaretSize,cornerRadius:this.options.tooltipCornerRadius,text:y(this.options.tooltipTemplate,t),chart:this.chart,custom:this.options.customTooltips}).draw()},this);return this}},toBase64Image:function(){return this.chart.canvas.toDataURL.apply(this.chart.canvas,arguments)}}),i.Type.extend=function(t){var e=this,n=function(){return e.apply(this,arguments)};if(n.prototype=a(e.prototype),o(n.prototype,t),n.extend=i.Type.extend,t.name||e.prototype.name){var s=t.name||e.prototype.name,r=i.defaults[e.prototype.name]?a(i.defaults[e.prototype.name]):{};i.defaults[s]=o(r,t.defaults),i.types[s]=n,i.prototype[s]=function(t,e){var a=l(i.defaults.global,i.defaults[s],e||{});return new n(t,a,this)}}else d("Name not provided for this chart, so it hasn't been registered");return e},i.Element=function(t){o(this,t),this.initialize.apply(this,arguments),this.save()},o(i.Element.prototype,{initialize:function(){},restore:function(t){return t?s(t,function(t){this[t]=this._saved[t]},this):o(this,this._saved),this},save:function(){return this._saved=a(this),delete this._saved._saved,this},update:function(t){return s(t,function(t,e){this._saved[e]=this[e],this[e]=t},this),this},transition:function(t,e){return s(t,function(t,i){this[i]=(t-this._saved[i])*e+this._saved[i]},this),this},tooltipPosition:function(){return{x:this.x,y:this.y}},hasValue:function(){return p(this.value)}}),i.Element.extend=h,i.Point=i.Element.extend({display:!0,inRange:function(t,e){var i=this.hitDetectionRadius+this.radius;return Math.pow(t-this.x,2)+Math.pow(e-this.y,2)<Math.pow(i,2)},draw:function(){if(this.display){var t=this.ctx;t.beginPath(),t.arc(this.x,this.y,this.radius,0,2*Math.PI),t.closePath(),t.strokeStyle=this.strokeColor,t.lineWidth=this.strokeWidth,t.fillStyle=this.fillColor,t.fill(),t.stroke()}}}),i.Arc=i.Element.extend({inRange:function(t,e){var i=n.getAngleFromPoint(this,{x:t,y:e}),s=i.angle>=this.startAngle&&i.angle<=this.endAngle,a=i.distance>=this.innerRadius&&i.distance<=this.outerRadius;return s&&a},tooltipPosition:function(){var t=this.startAngle+(this.endAngle-this.startAngle)/2,e=(this.outerRadius-this.innerRadius)/2+this.innerRadius;return{x:this.x+Math.cos(t)*e,y:this.y+Math.sin(t)*e}},draw:function(t){var e=this.ctx;e.beginPath(),e.arc(this.x,this.y,this.outerRadius,this.startAngle,this.endAngle),e.arc(this.x,this.y,this.innerRadius,this.endAngle,this.startAngle,!0),e.closePath(),e.strokeStyle=this.strokeColor,e.lineWidth=this.strokeWidth,e.fillStyle=this.fillColor,e.fill(),e.lineJoin="bevel",this.showStroke&&e.stroke()}}),i.Rectangle=i.Element.extend({draw:function(){var t=this.ctx,e=this.width/2,i=this.x-e,n=this.x+e,s=this.base-(this.base-this.y),a=this.strokeWidth/2;this.showStroke&&(i+=a,n-=a,s+=a),t.beginPath(),t.fillStyle=this.fillColor,t.strokeStyle=this.strokeColor,t.lineWidth=this.strokeWidth,t.moveTo(i,this.base),t.lineTo(i,s),t.lineTo(n,s),t.lineTo(n,this.base),t.fill(),this.showStroke&&t.stroke()},height:function(){return this.base-this.y},inRange:function(t,e){return t>=this.x-this.width/2&&t<=this.x+this.width/2&&e>=this.y&&e<=this.base}}),i.Tooltip=i.Element.extend({draw:function(){var t=this.chart.ctx;t.font=R(this.fontSize,this.fontStyle,this.fontFamily),this.xAlign="center",this.yAlign="above";var e=this.caretPadding=2,i=t.measureText(this.text).width+2*this.xPadding,n=this.fontSize+2*this.yPadding,s=n+this.caretHeight+e;this.x+i/2>this.chart.width?this.xAlign="left":this.x-i/2<0&&(this.xAlign="right"),this.y-s<0&&(this.yAlign="below");var a=this.x-i/2,o=this.y-s;if(t.fillStyle=this.fillColor,this.custom)this.custom(this);else{switch(this.yAlign){case"above":t.beginPath(),t.moveTo(this.x,this.y-e),t.lineTo(this.x+this.caretHeight,this.y-(e+this.caretHeight)),t.lineTo(this.x-this.caretHeight,this.y-(e+this.caretHeight)),t.closePath(),t.fill();break;case"below":o=this.y+e+this.caretHeight,t.beginPath(),t.moveTo(this.x,this.y+e),t.lineTo(this.x+this.caretHeight,this.y+e+this.caretHeight),t.lineTo(this.x-this.caretHeight,this.y+e+this.caretHeight),t.closePath(),t.fill()}switch(this.xAlign){case"left":a=this.x-i+(this.cornerRadius+this.caretHeight);break;case"right":a=this.x-(this.cornerRadius+this.caretHeight)}I(t,a,o,i,n,this.cornerRadius),t.fill(),t.fillStyle=this.textColor,t.textAlign="center",t.textBaseline="middle",t.fillText(this.text,a+i/2,o+n/2)}}}),i.MultiTooltip=i.Element.extend({initialize:function(){this.font=R(this.fontSize,this.fontStyle,this.fontFamily),this.titleFont=R(this.titleFontSize,this.titleFontStyle,this.titleFontFamily),this.height=this.labels.length*this.fontSize+(this.labels.length-1)*(this.fontSize/2)+2*this.yPadding+1.5*this.titleFontSize,this.ctx.font=this.titleFont;var t=this.ctx.measureText(this.title).width,e=D(this.ctx,this.font,this.labels)+this.fontSize+3,i=g([e,t]);this.width=i+2*this.xPadding;var n=this.height/2;this.y-n<0?this.y=n:this.y+n>this.chart.height&&(this.y=this.chart.height-n),this.x>this.chart.width/2?this.x-=this.xOffset+this.width:this.x+=this.xOffset},getLineHeight:function(t){var e=this.y-this.height/2+this.yPadding,i=t-1;return 0===t?e+this.titleFontSize/2:e+(1.5*this.fontSize*i+this.fontSize/2)+1.5*this.titleFontSize},draw:function(){if(this.custom)this.custom(this);else{I(this.ctx,this.x,this.y-this.height/2,this.width,this.height,this.cornerRadius);var t=this.ctx;t.fillStyle=this.fillColor,t.fill(),t.closePath(),t.textAlign="left",t.textBaseline="middle",t.fillStyle=this.titleTextColor,t.font=this.titleFont,t.fillText(this.title,this.x+this.xPadding,this.getLineHeight(0)),t.font=this.font,n.each(this.labels,function(e,i){t.fillStyle=this.textColor,t.fillText(e,this.x+this.xPadding+this.fontSize+3,this.getLineHeight(i+1)),t.fillStyle=this.legendColorBackground,t.fillRect(this.x+this.xPadding,this.getLineHeight(i+1)-this.fontSize/2,this.fontSize,this.fontSize),t.fillStyle=this.legendColors[i].fill,t.fillRect(this.x+this.xPadding,this.getLineHeight(i+1)-this.fontSize/2,this.fontSize,this.fontSize)},this)}}}),i.Scale=i.Element.extend({initialize:function(){this.fit()},buildYLabels:function(){this.yLabels=[];for(var t=v(this.stepValue),e=0;e<=this.steps;e++)this.yLabels.push(y(this.templateString,{value:(this.min+e*this.stepValue).toFixed(t)}));this.yLabelWidth=this.display&&this.showLabels?D(this.ctx,this.font,this.yLabels):0},addXLabel:function(t){this.xLabels.push(t),this.valuesCount++,this.fit()},removeXLabel:function(){this.xLabels.shift(),this.valuesCount--,this.fit()},fit:function(){this.startPoint=this.display?this.fontSize:0,this.endPoint=this.display?this.height-1.5*this.fontSize-5:this.height,this.startPoint+=this.padding,this.endPoint-=this.padding;var t,e=this.endPoint-this.startPoint;for(this.calculateYRange(e),this.buildYLabels(),this.calculateXLabelRotation();e>this.endPoint-this.startPoint;)e=this.endPoint-this.startPoint,t=this.yLabelWidth,this.calculateYRange(e),this.buildYLabels(),t<this.yLabelWidth&&this.calculateXLabelRotation()},calculateXLabelRotation:function(){this.ctx.font=this.font;var t,e,i=this.ctx.measureText(this.xLabels[0]).width,n=this.ctx.measureText(this.xLabels[this.xLabels.length-1]).width;if(this.xScalePaddingRight=n/2+3,this.xScalePaddingLeft=i/2>this.yLabelWidth+10?i/2:this.yLabelWidth+10,this.xLabelRotation=0,this.display){var s,a=D(this.ctx,this.font,this.xLabels);this.xLabelWidth=a;for(var o=Math.floor(this.calculateX(1)-this.calculateX(0))-6;this.xLabelWidth>o&&0===this.xLabelRotation||this.xLabelWidth>o&&this.xLabelRotation<=90&&this.xLabelRotation>0;)s=Math.cos(b(this.xLabelRotation)),t=s*i,e=s*n,t+this.fontSize/2>this.yLabelWidth+8&&(this.xScalePaddingLeft=t+this.fontSize/2),this.xScalePaddingRight=this.fontSize/2,this.xLabelRotation++,this.xLabelWidth=s*a;this.xLabelRotation>0&&(this.endPoint-=Math.sin(b(this.xLabelRotation))*a+3)}else this.xLabelWidth=0,this.xScalePaddingRight=this.padding,this.xScalePaddingLeft=this.padding},calculateYRange:c,drawingArea:function(){return this.startPoint-this.endPoint},calculateY:function(t){var e=this.drawingArea()/(this.min-this.max);return this.endPoint-e*(t-this.min)},calculateX:function(t){var e=(this.xLabelRotation>0,this.width-(this.xScalePaddingLeft+this.xScalePaddingRight)),i=e/Math.max(this.valuesCount-(this.offsetGridLines?0:1),1),n=i*t+this.xScalePaddingLeft;return this.offsetGridLines&&(n+=i/2),Math.round(n)},update:function(t){n.extend(this,t),this.fit()},draw:function(){var t=this.ctx,e=(this.endPoint-this.startPoint)/this.steps,i=Math.round(this.xScalePaddingLeft);this.display&&(t.fillStyle=this.textColor,t.font=this.font,s(this.yLabels,function(s,a){var o=this.endPoint-e*a,l=Math.round(o),r=this.showHorizontalLines;t.textAlign="right",t.textBaseline="middle",this.showLabels&&t.fillText(s,i-10,o),0!==a||r||(r=!0),r&&t.beginPath(),a>0?(t.lineWidth=this.gridLineWidth,t.strokeStyle=this.gridLineColor):(t.lineWidth=this.lineWidth,t.strokeStyle=this.lineColor),l+=n.aliasPixel(t.lineWidth),r&&(t.moveTo(i,l),t.lineTo(this.width,l),t.stroke(),t.closePath()),t.lineWidth=this.lineWidth,t.strokeStyle=this.lineColor,t.beginPath(),t.moveTo(i-5,l),t.lineTo(i,l),t.stroke(),t.closePath()},this),s(this.xLabels,function(e,i){var n=this.calculateX(i)+C(this.lineWidth),s=this.calculateX(i-(this.offsetGridLines?.5:0))+C(this.lineWidth),a=this.xLabelRotation>0,o=this.showVerticalLines;0!==i||o||(o=!0),o&&t.beginPath(),i>0?(t.lineWidth=this.gridLineWidth,t.strokeStyle=this.gridLineColor):(t.lineWidth=this.lineWidth,t.strokeStyle=this.lineColor),o&&(t.moveTo(s,this.endPoint),t.lineTo(s,this.startPoint-3),t.stroke(),t.closePath()),t.lineWidth=this.lineWidth,t.strokeStyle=this.lineColor,t.beginPath(),t.moveTo(s,this.endPoint),t.lineTo(s,this.endPoint+5),t.stroke(),t.closePath(),t.save(),t.translate(n,a?this.endPoint+12:this.endPoint+8),t.rotate(-1*b(this.xLabelRotation)),t.font=this.font,t.textAlign=a?"right":"center",t.textBaseline=a?"middle":"top",t.fillText(e,0,0),t.restore()},this))}}),i.RadialScale=i.Element.extend({initialize:function(){this.size=m([this.height,this.width]),this.drawingArea=this.display?this.size/2-(this.fontSize/2+this.backdropPaddingY):this.size/2},calculateCenterOffset:function(t){var e=this.drawingArea/(this.max-this.min);return(t-this.min)*e},update:function(){this.lineArc?this.drawingArea=this.display?this.size/2-(this.fontSize/2+this.backdropPaddingY):this.size/2:this.setScaleSize(),this.buildYLabels()},buildYLabels:function(){this.yLabels=[];for(var t=v(this.stepValue),e=0;e<=this.steps;e++)this.yLabels.push(y(this.templateString,{value:(this.min+e*this.stepValue).toFixed(t)}))},getCircumference:function(){return 2*Math.PI/this.valuesCount},setScaleSize:function(){var t,e,i,n,s,a,o,l,r,h,c,u,d=m([this.height/2-this.pointLabelFontSize-5,this.width/2]),f=this.width,g=0;for(this.ctx.font=R(this.pointLabelFontSize,this.pointLabelFontStyle,this.pointLabelFontFamily),e=0;e<this.valuesCount;e++)t=this.getPointPosition(e,d),i=this.ctx.measureText(y(this.templateString,{value:this.labels[e]})).width+5,0===e||e===this.valuesCount/2?(n=i/2,t.x+n>f&&(f=t.x+n,s=e),t.x-n<g&&(g=t.x-n,o=e)):e<this.valuesCount/2?t.x+i>f&&(f=t.x+i,s=e):e>this.valuesCount/2&&t.x-i<g&&(g=t.x-i,o=e);r=g,h=Math.ceil(f-this.width),a=this.getIndexAngle(s),l=this.getIndexAngle(o),c=h/Math.sin(a+Math.PI/2),u=r/Math.sin(l+Math.PI/2),c=p(c)?c:0,u=p(u)?u:0,this.drawingArea=d-(u+c)/2,this.setCenterPoint(u,c)},setCenterPoint:function(t,e){var i=this.width-e-this.drawingArea,n=t+this.drawingArea;this.xCenter=(n+i)/2,this.yCenter=this.height/2},getIndexAngle:function(t){var e=2*Math.PI/this.valuesCount;return t*e-Math.PI/2},getPointPosition:function(t,e){var i=this.getIndexAngle(t);return{x:Math.cos(i)*e+this.xCenter,y:Math.sin(i)*e+this.yCenter}},draw:function(){if(this.display){var t=this.ctx;if(s(this.yLabels,function(e,i){if(i>0){var n,s=i*(this.drawingArea/this.steps),a=this.yCenter-s;if(this.lineWidth>0)if(t.strokeStyle=this.lineColor,t.lineWidth=this.lineWidth,this.lineArc)t.beginPath(),t.arc(this.xCenter,this.yCenter,s,0,2*Math.PI),t.closePath(),t.stroke();else{t.beginPath();for(var o=0;o<this.valuesCount;o++)n=this.getPointPosition(o,this.calculateCenterOffset(this.min+i*this.stepValue)),0===o?t.moveTo(n.x,n.y):t.lineTo(n.x,n.y);t.closePath(),t.stroke()}if(this.showLabels){if(t.font=R(this.fontSize,this.fontStyle,this.fontFamily),this.showLabelBackdrop){var l=t.measureText(e).width;t.fillStyle=this.backdropColor,t.fillRect(this.xCenter-l/2-this.backdropPaddingX,a-this.fontSize/2-this.backdropPaddingY,l+2*this.backdropPaddingX,this.fontSize+2*this.backdropPaddingY)}t.textAlign="center",t.textBaseline="middle",t.fillStyle=this.fontColor,t.fillText(e,this.xCenter,a)}}},this),!this.lineArc){t.lineWidth=this.angleLineWidth,t.strokeStyle=this.angleLineColor;for(var e=this.valuesCount-1;e>=0;e--){if(this.angleLineWidth>0){var i=this.getPointPosition(e,this.calculateCenterOffset(this.max));t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(i.x,i.y),t.stroke(),t.closePath()}var n=this.getPointPosition(e,this.calculateCenterOffset(this.max)+5);t.font=R(this.pointLabelFontSize,this.pointLabelFontStyle,this.pointLabelFontFamily),t.fillStyle=this.pointLabelFontColor;var a=this.labels.length,o=this.labels.length/2,l=o/2,r=l>e||e>a-l,h=e===l||e===a-l;t.textAlign=0===e?"center":e===o?"center":o>e?"left":"right",t.textBaseline=h?"middle":r?"bottom":"top",t.fillText(this.labels[e],n.x,n.y)}}}}}),n.addEvent(window,"resize",function(){var t;return function(){clearTimeout(t),t=setTimeout(function(){s(i.instances,function(t){t.options.responsive&&t.resize(t.render,!0)})},50)}}()),f?define("chartJS",[],function(){return i}):"object"==typeof module&&module.exports&&(module.exports=i),t.Chart=i,i.noConflict=function(){return t.Chart=e,i}}.call(this),function(){"use strict";var t=this,e=t.Chart,i=e.helpers,n={scaleBeginAtZero:!0,scaleShowGridLines:!0,scaleGridLineColor:"rgba(0,0,0,.05)",scaleGridLineWidth:1,scaleShowHorizontalLines:!0,scaleShowVerticalLines:!0,barShowStroke:!0,barStrokeWidth:2,barValueSpacing:5,barDatasetSpacing:1,legendTemplate:'<ul class="<%=name.toLowerCase()%>-legend"><% for (var i=0; i<datasets.length; i++){%><li><span style="background-color:<%=datasets[i].fillColor%>"></span><%if(datasets[i].label){%><%=datasets[i].label%><%}%></li><%}%></ul>'};e.Type.extend({name:"Bar",defaults:n,initialize:function(t){var n=this.options;this.ScaleClass=e.Scale.extend({offsetGridLines:!0,calculateBarX:function(t,e,i){var s=this.calculateBaseWidth(),a=this.calculateX(i)-s/2,o=this.calculateBarWidth(t);return a+o*e+e*n.barDatasetSpacing+o/2},calculateBaseWidth:function(){return this.calculateX(1)-this.calculateX(0)-2*n.barValueSpacing},calculateBarWidth:function(t){var e=this.calculateBaseWidth()-(t-1)*n.barDatasetSpacing;return e/t}}),this.datasets=[],this.options.showTooltips&&i.bindEvents(this,this.options.tooltipEvents,function(t){var e="mouseout"!==t.type?this.getBarsAtEvent(t):[];this.eachBars(function(t){t.restore(["fillColor","strokeColor"])}),i.each(e,function(t){t.fillColor=t.highlightFill,t.strokeColor=t.highlightStroke}),this.showTooltip(e)}),this.BarClass=e.Rectangle.extend({strokeWidth:this.options.barStrokeWidth,showStroke:this.options.barShowStroke,ctx:this.chart.ctx}),i.each(t.datasets,function(e){var n={label:e.label||null,fillColor:e.fillColor,strokeColor:e.strokeColor,bars:[]};this.datasets.push(n),i.each(e.data,function(i,s){n.bars.push(new this.BarClass({value:i,label:t.labels[s],datasetLabel:e.label,strokeColor:e.strokeColor,fillColor:e.fillColor,highlightFill:e.highlightFill||e.fillColor,highlightStroke:e.highlightStroke||e.strokeColor}))},this)},this),this.buildScale(t.labels),this.BarClass.prototype.base=this.scale.endPoint,this.eachBars(function(t,e,n){i.extend(t,{width:this.scale.calculateBarWidth(this.datasets.length),x:this.scale.calculateBarX(this.datasets.length,n,e),y:this.scale.endPoint}),t.save()},this),this.render()},update:function(){this.scale.update(),i.each(this.activeElements,function(t){t.restore(["fillColor","strokeColor"])}),this.eachBars(function(t){t.save()}),this.render()},eachBars:function(t){i.each(this.datasets,function(e,n){i.each(e.bars,t,this,n)},this)},getBarsAtEvent:function(t){for(var e,n=[],s=i.getRelativePosition(t),a=function(t){n.push(t.bars[e])},o=0;o<this.datasets.length;o++)for(e=0;e<this.datasets[o].bars.length;e++)if(this.datasets[o].bars[e].inRange(s.x,s.y))return i.each(this.datasets,a),n;return n},buildScale:function(t){var e=this,n=function(){var t=[];return e.eachBars(function(e){t.push(e.value)}),t},s={templateString:this.options.scaleLabel,height:this.chart.height,width:this.chart.width,ctx:this.chart.ctx,textColor:this.options.scaleFontColor,fontSize:this.options.scaleFontSize,fontStyle:this.options.scaleFontStyle,fontFamily:this.options.scaleFontFamily,valuesCount:t.length,beginAtZero:this.options.scaleBeginAtZero,integersOnly:this.options.scaleIntegersOnly,calculateYRange:function(t){var e=i.calculateScaleRange(n(),t,this.fontSize,this.beginAtZero,this.integersOnly);i.extend(this,e)},xLabels:t,font:i.fontString(this.options.scaleFontSize,this.options.scaleFontStyle,this.options.scaleFontFamily),lineWidth:this.options.scaleLineWidth,lineColor:this.options.scaleLineColor,showHorizontalLines:this.options.scaleShowHorizontalLines,showVerticalLines:this.options.scaleShowVerticalLines,
  gridLineWidth:this.options.scaleShowGridLines?this.options.scaleGridLineWidth:0,gridLineColor:this.options.scaleShowGridLines?this.options.scaleGridLineColor:"rgba(0,0,0,0)",padding:this.options.showScale?0:this.options.barShowStroke?this.options.barStrokeWidth:0,showLabels:this.options.scaleShowLabels,display:this.options.showScale};this.options.scaleOverride&&i.extend(s,{calculateYRange:i.noop,steps:this.options.scaleSteps,stepValue:this.options.scaleStepWidth,min:this.options.scaleStartValue,max:this.options.scaleStartValue+this.options.scaleSteps*this.options.scaleStepWidth}),this.scale=new this.ScaleClass(s)},addData:function(t,e){i.each(t,function(t,i){this.datasets[i].bars.push(new this.BarClass({value:t,label:e,x:this.scale.calculateBarX(this.datasets.length,i,this.scale.valuesCount+1),y:this.scale.endPoint,width:this.scale.calculateBarWidth(this.datasets.length),base:this.scale.endPoint,strokeColor:this.datasets[i].strokeColor,fillColor:this.datasets[i].fillColor}))},this),this.scale.addXLabel(e),this.update()},removeData:function(){this.scale.removeXLabel(),i.each(this.datasets,function(t){t.bars.shift()},this),this.update()},reflow:function(){i.extend(this.BarClass.prototype,{y:this.scale.endPoint,base:this.scale.endPoint});var t=i.extend({height:this.chart.height,width:this.chart.width});this.scale.update(t)},draw:function(t){var e=t||1;this.clear(),this.chart.ctx,this.scale.draw(e),i.each(this.datasets,function(t,n){i.each(t.bars,function(t,i){t.hasValue()&&(t.base=this.scale.endPoint,t.transition({x:this.scale.calculateBarX(this.datasets.length,n,i),y:this.scale.calculateY(t.value),width:this.scale.calculateBarWidth(this.datasets.length)},e).draw())},this)},this)}})}.call(this),function(){"use strict";var t=this,e=t.Chart,i=e.helpers,n={segmentShowStroke:!0,segmentStrokeColor:"#fff",segmentStrokeWidth:2,percentageInnerCutout:50,animationSteps:100,animationEasing:"easeOutBounce",animateRotate:!0,animateScale:!1,legendTemplate:'<ul class="<%=name.toLowerCase()%>-legend"><% for (var i=0; i<segments.length; i++){%><li><span style="background-color:<%=segments[i].fillColor%>"></span><%if(segments[i].label){%><%=segments[i].label%><%}%></li><%}%></ul>'};e.Type.extend({name:"Doughnut",defaults:n,initialize:function(t){this.segments=[],this.outerRadius=(i.min([this.chart.width,this.chart.height])-this.options.segmentStrokeWidth/2)/2,this.SegmentArc=e.Arc.extend({ctx:this.chart.ctx,x:this.chart.width/2,y:this.chart.height/2}),this.options.showTooltips&&i.bindEvents(this,this.options.tooltipEvents,function(t){var e="mouseout"!==t.type?this.getSegmentsAtEvent(t):[];i.each(this.segments,function(t){t.restore(["fillColor"])}),i.each(e,function(t){t.fillColor=t.highlightColor}),this.showTooltip(e)}),this.calculateTotal(t),i.each(t,function(t,e){this.addData(t,e,!0)},this),this.render()},getSegmentsAtEvent:function(t){var e=[],n=i.getRelativePosition(t);return i.each(this.segments,function(t){t.inRange(n.x,n.y)&&e.push(t)},this),e},addData:function(t,e,i){var n=e||this.segments.length;this.segments.splice(n,0,new this.SegmentArc({value:t.value,outerRadius:this.options.animateScale?0:this.outerRadius,innerRadius:this.options.animateScale?0:this.outerRadius/100*this.options.percentageInnerCutout,fillColor:t.color,highlightColor:t.highlight||t.color,showStroke:this.options.segmentShowStroke,strokeWidth:this.options.segmentStrokeWidth,strokeColor:this.options.segmentStrokeColor,startAngle:1.5*Math.PI,circumference:this.options.animateRotate?0:this.calculateCircumference(t.value),label:t.label})),i||(this.reflow(),this.update())},calculateCircumference:function(t){return 2*Math.PI*(Math.abs(t)/this.total)},calculateTotal:function(t){this.total=0,i.each(t,function(t){this.total+=Math.abs(t.value)},this)},update:function(){this.calculateTotal(this.segments),i.each(this.activeElements,function(t){t.restore(["fillColor"])}),i.each(this.segments,function(t){t.save()}),this.render()},removeData:function(t){var e=i.isNumber(t)?t:this.segments.length-1;this.segments.splice(e,1),this.reflow(),this.update()},reflow:function(){i.extend(this.SegmentArc.prototype,{x:this.chart.width/2,y:this.chart.height/2}),this.outerRadius=(i.min([this.chart.width,this.chart.height])-this.options.segmentStrokeWidth/2)/2,i.each(this.segments,function(t){t.update({outerRadius:this.outerRadius,innerRadius:this.outerRadius/100*this.options.percentageInnerCutout})},this)},draw:function(t){var e=t?t:1;this.clear(),i.each(this.segments,function(t,i){t.transition({circumference:this.calculateCircumference(t.value),outerRadius:this.outerRadius,innerRadius:this.outerRadius/100*this.options.percentageInnerCutout},e),t.endAngle=t.startAngle+t.circumference,t.draw(),0===i&&(t.startAngle=1.5*Math.PI),i<this.segments.length-1&&(this.segments[i+1].startAngle=t.endAngle)},this)}}),e.types.Doughnut.extend({name:"Pie",defaults:i.merge(n,{percentageInnerCutout:0})})}.call(this),function(){"use strict";var t=this,e=t.Chart,i=e.helpers,n={scaleShowGridLines:!0,scaleGridLineColor:"rgba(0,0,0,.05)",scaleGridLineWidth:1,scaleShowHorizontalLines:!0,scaleShowVerticalLines:!0,bezierCurve:!0,bezierCurveTension:.4,pointDot:!0,pointDotRadius:4,pointDotStrokeWidth:1,pointHitDetectionRadius:20,datasetStroke:!0,datasetStrokeWidth:2,datasetFill:!0,legendTemplate:'<ul class="<%=name.toLowerCase()%>-legend"><% for (var i=0; i<datasets.length; i++){%><li><span style="background-color:<%=datasets[i].strokeColor%>"></span><%if(datasets[i].label){%><%=datasets[i].label%><%}%></li><%}%></ul>'};e.Type.extend({name:"Line",defaults:n,initialize:function(t){this.PointClass=e.Point.extend({strokeWidth:this.options.pointDotStrokeWidth,radius:this.options.pointDotRadius,display:this.options.pointDot,hitDetectionRadius:this.options.pointHitDetectionRadius,ctx:this.chart.ctx,inRange:function(t){return Math.pow(t-this.x,2)<Math.pow(this.radius+this.hitDetectionRadius,2)}}),this.datasets=[],this.options.showTooltips&&i.bindEvents(this,this.options.tooltipEvents,function(t){var e="mouseout"!==t.type?this.getPointsAtEvent(t):[];this.eachPoints(function(t){t.restore(["fillColor","strokeColor"])}),i.each(e,function(t){t.fillColor=t.highlightFill,t.strokeColor=t.highlightStroke}),this.showTooltip(e)}),i.each(t.datasets,function(e){var n={label:e.label||null,fillColor:e.fillColor,strokeColor:e.strokeColor,pointColor:e.pointColor,pointStrokeColor:e.pointStrokeColor,points:[]};this.datasets.push(n),i.each(e.data,function(i,s){n.points.push(new this.PointClass({value:i,label:t.labels[s],datasetLabel:e.label,strokeColor:e.pointStrokeColor,fillColor:e.pointColor,highlightFill:e.pointHighlightFill||e.pointColor,highlightStroke:e.pointHighlightStroke||e.pointStrokeColor}))},this),this.buildScale(t.labels),this.eachPoints(function(t,e){i.extend(t,{x:this.scale.calculateX(e),y:this.scale.endPoint}),t.save()},this)},this),this.render()},update:function(){this.scale.update(),i.each(this.activeElements,function(t){t.restore(["fillColor","strokeColor"])}),this.eachPoints(function(t){t.save()}),this.render()},eachPoints:function(t){i.each(this.datasets,function(e){i.each(e.points,t,this)},this)},getPointsAtEvent:function(t){var e=[],n=i.getRelativePosition(t);return i.each(this.datasets,function(t){i.each(t.points,function(t){t.inRange(n.x,n.y)&&e.push(t)})},this),e},buildScale:function(t){var n=this,s=function(){var t=[];return n.eachPoints(function(e){t.push(e.value)}),t},a={templateString:this.options.scaleLabel,height:this.chart.height,width:this.chart.width,ctx:this.chart.ctx,textColor:this.options.scaleFontColor,fontSize:this.options.scaleFontSize,fontStyle:this.options.scaleFontStyle,fontFamily:this.options.scaleFontFamily,valuesCount:t.length,beginAtZero:this.options.scaleBeginAtZero,integersOnly:this.options.scaleIntegersOnly,calculateYRange:function(t){var e=i.calculateScaleRange(s(),t,this.fontSize,this.beginAtZero,this.integersOnly);i.extend(this,e)},xLabels:t,font:i.fontString(this.options.scaleFontSize,this.options.scaleFontStyle,this.options.scaleFontFamily),lineWidth:this.options.scaleLineWidth,lineColor:this.options.scaleLineColor,showHorizontalLines:this.options.scaleShowHorizontalLines,showVerticalLines:this.options.scaleShowVerticalLines,gridLineWidth:this.options.scaleShowGridLines?this.options.scaleGridLineWidth:0,gridLineColor:this.options.scaleShowGridLines?this.options.scaleGridLineColor:"rgba(0,0,0,0)",padding:this.options.showScale?0:this.options.pointDotRadius+this.options.pointDotStrokeWidth,showLabels:this.options.scaleShowLabels,display:this.options.showScale};this.options.scaleOverride&&i.extend(a,{calculateYRange:i.noop,steps:this.options.scaleSteps,stepValue:this.options.scaleStepWidth,min:this.options.scaleStartValue,max:this.options.scaleStartValue+this.options.scaleSteps*this.options.scaleStepWidth}),this.scale=new e.Scale(a)},addData:function(t,e){i.each(t,function(t,i){this.datasets[i].points.push(new this.PointClass({value:t,label:e,x:this.scale.calculateX(this.scale.valuesCount+1),y:this.scale.endPoint,strokeColor:this.datasets[i].pointStrokeColor,fillColor:this.datasets[i].pointColor}))},this),this.scale.addXLabel(e),this.update()},removeData:function(){this.scale.removeXLabel(),i.each(this.datasets,function(t){t.points.shift()},this),this.update()},reflow:function(){var t=i.extend({height:this.chart.height,width:this.chart.width});this.scale.update(t)},draw:function(t){var e=t||1;this.clear();var n=this.chart.ctx,s=function(t){return null!==t.value},a=function(t,e,n){return i.findNextWhere(e,s,n)||t},o=function(t,e,n){return i.findPreviousWhere(e,s,n)||t};this.scale.draw(e),i.each(this.datasets,function(t){var l=i.where(t.points,s);i.each(t.points,function(t,i){t.hasValue()&&t.transition({y:this.scale.calculateY(t.value),x:this.scale.calculateX(i)},e)},this),this.options.bezierCurve&&i.each(l,function(t,e){var n=e>0&&e<l.length-1?this.options.bezierCurveTension:0;t.controlPoints=i.splineCurve(o(t,l,e),t,a(t,l,e),n),t.controlPoints.outer.y>this.scale.endPoint?t.controlPoints.outer.y=this.scale.endPoint:t.controlPoints.outer.y<this.scale.startPoint&&(t.controlPoints.outer.y=this.scale.startPoint),t.controlPoints.inner.y>this.scale.endPoint?t.controlPoints.inner.y=this.scale.endPoint:t.controlPoints.inner.y<this.scale.startPoint&&(t.controlPoints.inner.y=this.scale.startPoint)},this),n.lineWidth=this.options.datasetStrokeWidth,n.strokeStyle=t.strokeColor,n.beginPath(),i.each(l,function(t,e){if(0===e)n.moveTo(t.x,t.y);else if(this.options.bezierCurve){var i=o(t,l,e);n.bezierCurveTo(i.controlPoints.outer.x,i.controlPoints.outer.y,t.controlPoints.inner.x,t.controlPoints.inner.y,t.x,t.y)}else n.lineTo(t.x,t.y)},this),n.stroke(),this.options.datasetFill&&l.length>0&&(n.lineTo(l[l.length-1].x,this.scale.endPoint),n.lineTo(l[0].x,this.scale.endPoint),n.fillStyle=t.fillColor,n.closePath(),n.fill()),i.each(l,function(t){t.draw()})},this)}})}.call(this),function(){"use strict";var t=this,e=t.Chart,i=e.helpers,n={scaleShowLabelBackdrop:!0,scaleBackdropColor:"rgba(255,255,255,0.75)",scaleBeginAtZero:!0,scaleBackdropPaddingY:2,scaleBackdropPaddingX:2,scaleShowLine:!0,segmentShowStroke:!0,segmentStrokeColor:"#fff",segmentStrokeWidth:2,animationSteps:100,animationEasing:"easeOutBounce",animateRotate:!0,animateScale:!1,legendTemplate:'<ul class="<%=name.toLowerCase()%>-legend"><% for (var i=0; i<segments.length; i++){%><li><span style="background-color:<%=segments[i].fillColor%>"></span><%if(segments[i].label){%><%=segments[i].label%><%}%></li><%}%></ul>'};e.Type.extend({name:"PolarArea",defaults:n,initialize:function(t){this.segments=[],this.SegmentArc=e.Arc.extend({showStroke:this.options.segmentShowStroke,strokeWidth:this.options.segmentStrokeWidth,strokeColor:this.options.segmentStrokeColor,ctx:this.chart.ctx,innerRadius:0,x:this.chart.width/2,y:this.chart.height/2}),this.scale=new e.RadialScale({display:this.options.showScale,fontStyle:this.options.scaleFontStyle,fontSize:this.options.scaleFontSize,fontFamily:this.options.scaleFontFamily,fontColor:this.options.scaleFontColor,showLabels:this.options.scaleShowLabels,showLabelBackdrop:this.options.scaleShowLabelBackdrop,backdropColor:this.options.scaleBackdropColor,backdropPaddingY:this.options.scaleBackdropPaddingY,backdropPaddingX:this.options.scaleBackdropPaddingX,lineWidth:this.options.scaleShowLine?this.options.scaleLineWidth:0,lineColor:this.options.scaleLineColor,lineArc:!0,width:this.chart.width,height:this.chart.height,xCenter:this.chart.width/2,yCenter:this.chart.height/2,ctx:this.chart.ctx,templateString:this.options.scaleLabel,valuesCount:t.length}),this.updateScaleRange(t),this.scale.update(),i.each(t,function(t,e){this.addData(t,e,!0)},this),this.options.showTooltips&&i.bindEvents(this,this.options.tooltipEvents,function(t){var e="mouseout"!==t.type?this.getSegmentsAtEvent(t):[];i.each(this.segments,function(t){t.restore(["fillColor"])}),i.each(e,function(t){t.fillColor=t.highlightColor}),this.showTooltip(e)}),this.render()},getSegmentsAtEvent:function(t){var e=[],n=i.getRelativePosition(t);return i.each(this.segments,function(t){t.inRange(n.x,n.y)&&e.push(t)},this),e},addData:function(t,e,i){var n=e||this.segments.length;this.segments.splice(n,0,new this.SegmentArc({fillColor:t.color,highlightColor:t.highlight||t.color,label:t.label,value:t.value,outerRadius:this.options.animateScale?0:this.scale.calculateCenterOffset(t.value),circumference:this.options.animateRotate?0:this.scale.getCircumference(),startAngle:1.5*Math.PI})),i||(this.reflow(),this.update())},removeData:function(t){var e=i.isNumber(t)?t:this.segments.length-1;this.segments.splice(e,1),this.reflow(),this.update()},calculateTotal:function(t){this.total=0,i.each(t,function(t){this.total+=t.value},this),this.scale.valuesCount=this.segments.length},updateScaleRange:function(t){var e=[];i.each(t,function(t){e.push(t.value)});var n=this.options.scaleOverride?{steps:this.options.scaleSteps,stepValue:this.options.scaleStepWidth,min:this.options.scaleStartValue,max:this.options.scaleStartValue+this.options.scaleSteps*this.options.scaleStepWidth}:i.calculateScaleRange(e,i.min([this.chart.width,this.chart.height])/2,this.options.scaleFontSize,this.options.scaleBeginAtZero,this.options.scaleIntegersOnly);i.extend(this.scale,n,{size:i.min([this.chart.width,this.chart.height]),xCenter:this.chart.width/2,yCenter:this.chart.height/2})},update:function(){this.calculateTotal(this.segments),i.each(this.segments,function(t){t.save()}),this.reflow(),this.render()},reflow:function(){i.extend(this.SegmentArc.prototype,{x:this.chart.width/2,y:this.chart.height/2}),this.updateScaleRange(this.segments),this.scale.update(),i.extend(this.scale,{xCenter:this.chart.width/2,yCenter:this.chart.height/2}),i.each(this.segments,function(t){t.update({outerRadius:this.scale.calculateCenterOffset(t.value)})},this)},draw:function(t){var e=t||1;this.clear(),i.each(this.segments,function(t,i){t.transition({circumference:this.scale.getCircumference(),outerRadius:this.scale.calculateCenterOffset(t.value)},e),t.endAngle=t.startAngle+t.circumference,0===i&&(t.startAngle=1.5*Math.PI),i<this.segments.length-1&&(this.segments[i+1].startAngle=t.endAngle),t.draw()},this),this.scale.draw()}})}.call(this),function(){"use strict";var t=this,e=t.Chart,i=e.helpers;e.Type.extend({name:"Radar",defaults:{scaleShowLine:!0,angleShowLineOut:!0,scaleShowLabels:!1,scaleBeginAtZero:!0,angleLineColor:"rgba(0,0,0,.1)",angleLineWidth:1,pointLabelFontFamily:"'Arial'",pointLabelFontStyle:"normal",pointLabelFontSize:10,pointLabelFontColor:"#666",pointDot:!0,pointDotRadius:3,pointDotStrokeWidth:1,pointHitDetectionRadius:20,datasetStroke:!0,datasetStrokeWidth:2,datasetFill:!0,legendTemplate:'<ul class="<%=name.toLowerCase()%>-legend"><% for (var i=0; i<datasets.length; i++){%><li><span style="background-color:<%=datasets[i].strokeColor%>"></span><%if(datasets[i].label){%><%=datasets[i].label%><%}%></li><%}%></ul>'},initialize:function(t){this.PointClass=e.Point.extend({strokeWidth:this.options.pointDotStrokeWidth,radius:this.options.pointDotRadius,display:this.options.pointDot,hitDetectionRadius:this.options.pointHitDetectionRadius,ctx:this.chart.ctx}),this.datasets=[],this.buildScale(t),this.options.showTooltips&&i.bindEvents(this,this.options.tooltipEvents,function(t){var e="mouseout"!==t.type?this.getPointsAtEvent(t):[];this.eachPoints(function(t){t.restore(["fillColor","strokeColor"])}),i.each(e,function(t){t.fillColor=t.highlightFill,t.strokeColor=t.highlightStroke}),this.showTooltip(e)}),i.each(t.datasets,function(e){var n={label:e.label||null,fillColor:e.fillColor,strokeColor:e.strokeColor,pointColor:e.pointColor,pointStrokeColor:e.pointStrokeColor,points:[]};this.datasets.push(n),i.each(e.data,function(i,s){var a;this.scale.animation||(a=this.scale.getPointPosition(s,this.scale.calculateCenterOffset(i))),n.points.push(new this.PointClass({value:i,label:t.labels[s],datasetLabel:e.label,x:this.options.animation?this.scale.xCenter:a.x,y:this.options.animation?this.scale.yCenter:a.y,strokeColor:e.pointStrokeColor,fillColor:e.pointColor,highlightFill:e.pointHighlightFill||e.pointColor,highlightStroke:e.pointHighlightStroke||e.pointStrokeColor}))},this)},this),this.render()},eachPoints:function(t){i.each(this.datasets,function(e){i.each(e.points,t,this)},this)},getPointsAtEvent:function(t){var e=i.getRelativePosition(t),n=i.getAngleFromPoint({x:this.scale.xCenter,y:this.scale.yCenter},e),s=2*Math.PI/this.scale.valuesCount,a=Math.round((n.angle-1.5*Math.PI)/s),o=[];return(a>=this.scale.valuesCount||0>a)&&(a=0),n.distance<=this.scale.drawingArea&&i.each(this.datasets,function(t){o.push(t.points[a])}),o},buildScale:function(t){this.scale=new e.RadialScale({display:this.options.showScale,fontStyle:this.options.scaleFontStyle,fontSize:this.options.scaleFontSize,fontFamily:this.options.scaleFontFamily,fontColor:this.options.scaleFontColor,showLabels:this.options.scaleShowLabels,showLabelBackdrop:this.options.scaleShowLabelBackdrop,backdropColor:this.options.scaleBackdropColor,backdropPaddingY:this.options.scaleBackdropPaddingY,backdropPaddingX:this.options.scaleBackdropPaddingX,lineWidth:this.options.scaleShowLine?this.options.scaleLineWidth:0,lineColor:this.options.scaleLineColor,angleLineColor:this.options.angleLineColor,angleLineWidth:this.options.angleShowLineOut?this.options.angleLineWidth:0,pointLabelFontColor:this.options.pointLabelFontColor,pointLabelFontSize:this.options.pointLabelFontSize,pointLabelFontFamily:this.options.pointLabelFontFamily,pointLabelFontStyle:this.options.pointLabelFontStyle,height:this.chart.height,width:this.chart.width,xCenter:this.chart.width/2,yCenter:this.chart.height/2,ctx:this.chart.ctx,templateString:this.options.scaleLabel,labels:t.labels,valuesCount:t.datasets[0].data.length}),this.scale.setScaleSize(),this.updateScaleRange(t.datasets),this.scale.buildYLabels()},updateScaleRange:function(t){var e=function(){var e=[];return i.each(t,function(t){t.data?e=e.concat(t.data):i.each(t.points,function(t){e.push(t.value)})}),e}(),n=this.options.scaleOverride?{steps:this.options.scaleSteps,stepValue:this.options.scaleStepWidth,min:this.options.scaleStartValue,max:this.options.scaleStartValue+this.options.scaleSteps*this.options.scaleStepWidth}:i.calculateScaleRange(e,i.min([this.chart.width,this.chart.height])/2,this.options.scaleFontSize,this.options.scaleBeginAtZero,this.options.scaleIntegersOnly);i.extend(this.scale,n)},addData:function(t,e){this.scale.valuesCount++,i.each(t,function(t,i){var n=this.scale.getPointPosition(this.scale.valuesCount,this.scale.calculateCenterOffset(t));this.datasets[i].points.push(new this.PointClass({value:t,label:e,x:n.x,y:n.y,strokeColor:this.datasets[i].pointStrokeColor,fillColor:this.datasets[i].pointColor}))},this),this.scale.labels.push(e),this.reflow(),this.update()},removeData:function(){this.scale.valuesCount--,this.scale.labels.shift(),i.each(this.datasets,function(t){t.points.shift()},this),this.reflow(),this.update()},update:function(){this.eachPoints(function(t){t.save()}),this.reflow(),this.render()},reflow:function(){i.extend(this.scale,{width:this.chart.width,height:this.chart.height,size:i.min([this.chart.width,this.chart.height]),xCenter:this.chart.width/2,yCenter:this.chart.height/2}),this.updateScaleRange(this.datasets),this.scale.setScaleSize(),this.scale.buildYLabels()},draw:function(t){var e=t||1,n=this.chart.ctx;this.clear(),this.scale.draw(),i.each(this.datasets,function(t){i.each(t.points,function(t,i){t.hasValue()&&t.transition(this.scale.getPointPosition(i,this.scale.calculateCenterOffset(t.value)),e)},this),n.lineWidth=this.options.datasetStrokeWidth,n.strokeStyle=t.strokeColor,n.beginPath(),i.each(t.points,function(t,e){0===e?n.moveTo(t.x,t.y):n.lineTo(t.x,t.y)},this),n.closePath(),n.stroke(),n.fillStyle=t.fillColor,n.fill(),i.each(t.points,function(t){t.hasValue()&&t.draw()})},this)}})}.call(this),define("listDonutChart",["chartJS"],function(){var t={},e=$(".donut-chart");t={init:function(){t.verifyChart()},verifyChart:function(){e.each(function(){var e=($(this),$(this).find("canvas:first"));t.loadDonutChart(e)})},loadDonutChart:function(t){var e,i=t.get(0).getContext("2d");if("undefined"!=typeof donutChartData){var n=[{value:donutChartData[0].value,color:"rgb(253,193,120)",highlight:"rgb(253,193,120)",label:donutChartData[0].label},{value:donutChartData[1].value,color:"rgb(240,99,71)",highlight:"rgb(240,99,71)",label:donutChartData[1].label},{value:donutChartData[2].value,color:"rgb(144,11,58)",highlight:"rgb(144,11,58)",label:donutChartData[2].label},{value:donutChartData[3].value,color:"rgb(68,88,115)",highlight:"rgb(68,88,115)",label:donutChartData[3].label},{value:donutChartData[4].value,color:"rgb(68,68,68)",highlight:"rgb(68,68,68)",label:donutChartData[4].label}];e=new Chart(i).Doughnut(n,{responsive:!0,segmentShowStroke:!1})}}},e.length&&t.init()}),define("postCharts",["chartJS"],function(t){var e={},i=$(".line-chart-container");e={init:function(){e.verifyChart()},verifyChart:function(){i.each(function(){var t=($(this),$(this).find("canvas:first"));"single-line"===t.data("chart")?e.loadSingleLine(t):"multi-line"===t.data("chart")&&e.loadMultiLine(t)})},loadSingleLine:function(e){if("undefined"!=typeof singleLineChartData){var i={labels:singleLineChartData.labels,datasets:[{label:"Posts",fillColor:"rgba(19,132,138,0.5)",strokeColor:"rgb(19,132,138)",pointColor:"rgb(255,255,255)",pointStrokeColor:"rgb(19,132,138)",pointHighlightFill:"rgb(19,132,138)",pointHighlightStroke:"rgba(151,187,205,1)",data:singleLineChartData.data}]},n=e.get(0).getContext("2d");new t(n).Line(i,{showScale:!0,pointDot:!0,responsive:!0,scaleShowLabels:!1,scaleShowGridLines:!1,pointDotRadius:5,pointDotStrokeWidth:3,pointHitDetectionRadius:5})}},loadMultiLine:function(e){var i,n,s=e.get(0).getContext("2d");i={labels:multiLineChartData.labels,datasets:[{label:"OD4D",fillColor:"rgba(221,119,38,0.5)",strokeColor:"rgb(221,119,38)",pointColor:"rgb(255,255,255)",pointStrokeColor:"rgb(221,119,38)",pointHighlightFill:"rgb(221,119,38)",pointHighlightStroke:"rgba(220,220,220,1)",data:multiLineChartData.dataNetwork},{label:"Posts",fillColor:"rgba(19,132,138,0.5)",strokeColor:"rgb(19,132,138)",pointColor:"rgb(255,255,255)",pointStrokeColor:"rgb(19,132,138)",pointHighlightFill:"rgb(19,132,138)",pointHighlightStroke:"rgba(151,187,205,1)",data:multiLineChartData.dataPosts}]},n=new t(s).Line(i,{showScale:!0,pointDot:!0,responsive:!0,scaleShowLabels:!1,scaleShowGridLines:!1,pointDotRadius:5,pointDotStrokeWidth:3,pointHitDetectionRadius:5,customTooltips:function(t){var e=$(".network-line-chart-tooltip:first"),n="";if(!t)return void e.css({opacity:0});e.removeClass("above below"),e.addClass(t.yAlign),n+='<strong class="network-line-chart-tooltip__title"> '+t.title+" </strong>";for(var s=t.labels.length-1;s>=0;s--)n+=['<div class="network-line-chart-tooltip__items">','   <span class="network-line-chart-tooltip__key" style="background-color:'+i.datasets[s].strokeColor+'"></span>','   <span class="network-line-chart-tooltip__value">'+t.labels[s]+' <span class="network-line-chart-tooltip__value-name">'+i.datasets[s].label+"</span> </span>","</div>"].join("");e.html(n),e.css({opacity:1,left:t.chart.canvas.offsetLeft+t.x+"px",top:t.chart.canvas.offsetTop+t.y+"px",fontFamily:t.fontFamily,fontSize:t.fontSize,fontStyle:t.fontStyle})}})}},i.length&&e.init()}),function(){"use strict";var t={},e={},i=$("body").data("language"),n="http://connect.facebook.net/"+i+"/all.js#xfbml=1&version=v2.0";return window.screenSize=document.documentElement.clientWidth||window.innerWidth,window.isSmallScreen=window.screenSize<=1024?!0:!1,window.isMobileScreen=window.screenSize<768?!0:!1,e.init=function(){window.configRequirePaths=function(){require.config({paths:{acessibleMenu:"plugins/jquery-accessibleMegaMenu",trap:"plugins/trap",twitterFetcher:"plugins/twitterFetcher",salvattore:"plugins/salvattore",salvattore:"plugins/salvattore",pinterest:"//assets.pinterest.com/js/pinit",chartJS:"plugins/chart.min",postCharts:"modules/post-charts",skipLinks:"modules/skip-links",navigation:"modules/navigation",cards:"modules/cards",facebookLikeBox:"modules/facebook-like-box",linkedDataToggler:"modules/linked-data-toggler",aboutPlatform:"modules/about-platform",twitterList:"modules/twitter-list",pinterestBoard:"modules/pinterest-board",listCardExhibition:"modules/list-card-exhibition",listDonutChart:"modules/list-donut-chart"}})},t.init()},t.init=function(){window.configRequirePaths(),t.skipLinks(),t.navigation(),t.aboutPlatform(),t.cards(),t.linkedDataToggler(),t.listCardExhibition(),t.listDonutChart(),t.postCharts(),isMobileScreen||(t.facebookLikeBox(),t.twitterList(),t.pinterestBoard())},t.skipLinks=function(){var t=document.getElementById("js-skip-links");t&&require(["skipLinks"])},t.navigation=function(){var t=document.getElementById("js-navigation");t&&require(["navigation"])},t.aboutPlatform=function(){var t=document.getElementById("js-about-platform");t&&require(["aboutPlatform"])},t.cards=function(){var t=$(".article-cards__card:first");t.length&&require(["cards","salvattore"])},t.linkedDataToggler=function(){var t=document.getElementById("js-linked-data-toggler__toggler");t&&require(["linkedDataToggler"])},t.facebookLikeBox=function(){var t=document.getElementById("js-facebook-like-box");t&&require([n,"facebookLikeBox"])},t.twitterList=function(){var t=document.getElementById("js-twitter-list");t&&require(["twitterList"])},t.pinterestBoard=function(){var t=document.getElementById("js-pinterest-board");t&&require(["pinterestBoard"])},t.listCardExhibition=function(){var t=document.getElementById("js-list-card-exhibition");t&&require(["listCardExhibition"])},t.listDonutChart=function(){var t=$(".donut-chart:first");t.length&&require(["listDonutChart"])},t.postCharts=function(){var t=$(".line-chart-container:first");t.length&&require(["postCharts"])},e.init()}(),define("main",function(){});