Socket
Socket
Sign inDemoInstall

nunjucks

Package Overview
Dependencies
Maintainers
5
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nunjucks - npm Package Compare versions

Comparing version 3.1.2 to 3.1.3

3

browser/nunjucks-slim.min.js

@@ -1,2 +0,3 @@

!function(n,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.nunjucks=t():n.nunjucks=t()}("undefined"!=typeof self?self:this,function(){return function(n){var t={};function r(i){if(t[i])return t[i].exports;var e=t[i]={i:i,l:!1,exports:{}};return n[i].call(e.exports,e,e.exports,r),e.l=!0,e.exports}return r.m=n,r.c=t,r.d=function(n,t,i){r.o(n,t)||Object.defineProperty(n,t,{configurable:!1,enumerable:!0,get:i})},r.n=function(n){var t=n&&n.__esModule?function(){return n.default}:function(){return n};return r.d(t,"a",t),t},r.o=function(n,t){return Object.prototype.hasOwnProperty.call(n,t)},r.p="",r(r.s=6)}([function(n,t){},function(n,t,r){"use strict";var i=Array.prototype,e=Object.prototype,u={"&":"&amp;",'"':"&quot;","'":"&#39;","<":"&lt;",">":"&gt;"},o=/[&"'<>]/g;function f(n,t){return e.hasOwnProperty.call(n,t)}function c(n){return u[n]}function s(n,t,r){var i,e,u,o=this;if(n instanceof Error&&(n=(e=n).name+": "+e.message),Object.setPrototypeOf?Object.setPrototypeOf(i=Error(n),s.prototype):Object.defineProperty(i=this,"message",{enumerable:!1,writable:!0,value:n}),Object.defineProperty(i,"name",{value:"Template render error"}),Error.captureStackTrace&&Error.captureStackTrace(i,this.constructor),e){var f=Object.getOwnPropertyDescriptor(e,"stack");(u=f&&(f.get||function(){return f.value}))||(u=function(){return e.stack})}else{var c=Error(n).stack;u=function(){return c}}return Object.defineProperty(i,"stack",{get:function(){return u.call(o)}}),Object.defineProperty(i,"cause",{value:e}),i.lineno=t,i.colno=r,i.firstUpdate=!0,i.Update=function(n){var t="("+(n||"unknown path")+")";return o.firstUpdate&&(o.lineno&&o.colno?t+=" [Line "+o.lineno+", Column "+o.colno+"]":o.lineno&&(t+=" [Line "+o.lineno+"]")),t+="\n ",o.firstUpdate&&(t+=" "),o.message=t+(o.message||""),o.firstUpdate=!1,o},i}function a(n){return"[object Function]"===e.toString.call(n)}function h(n){return"[object Array]"===e.toString.call(n)}function l(n){return"[object String]"===e.toString.call(n)}function v(n){return"[object Object]"===e.toString.call(n)}function d(n){return Array.prototype.slice.call(n)}function p(n,t,r){return Array.prototype.indexOf.call(n||[],t,r)}function y(n){var t=[];for(var r in n)f(n,r)&&t.push(r);return t}(t=n.exports={}).hasOwnProp=f,t.t=function(n,r,i){if(i.Update||(i=new t.TemplateError(i)),i.Update(n),!r){var e=i;(i=Error(e.message)).name=e.name}return i},Object.setPrototypeOf?Object.setPrototypeOf(s.prototype,Error.prototype):s.prototype=Object.create(Error.prototype,{constructor:{value:s}}),t.TemplateError=s,t.escape=function(n){return n.replace(o,c)},t.isFunction=a,t.isArray=h,t.isString=l,t.isObject=v,t.groupBy=function(n,t){for(var r={},i=a(t)?t:function(n){return n[t]},e=0;e<n.length;e++){var u=n[e],o=i(u,e);(r[o]||(r[o]=[])).push(u)}return r},t.toArray=d,t.without=function(n){var t=[];if(!n)return t;for(var r=n.length,i=d(arguments).slice(1),e=-1;++e<r;)-1===p(i,n[e])&&t.push(n[e]);return t},t.repeat=function(n,t){for(var r="",i=0;i<t;i++)r+=n;return r},t.each=function(n,t,r){if(null!=n)if(i.forEach&&n.forEach===i.forEach)n.forEach(t,r);else if(n.length===+n.length)for(var e=0,u=n.length;e<u;e++)t.call(r,n[e],e,n)},t.map=function(n,t){var r=[];if(null==n)return r;if(i.map&&n.map===i.map)return n.map(t);for(var e=0;e<n.length;e++)r[r.length]=t(n[e],e);return n.length===+n.length&&(r.length=n.length),r},t.asyncIter=function(n,t,r){var i=-1;!function e(){++i<n.length?t(n[i],i,e,r):r()}()},t.asyncFor=function(n,t,r){var i=y(n||{}),e=i.length,u=-1;!function o(){var f=i[++u];u<e?t(f,n[f],u,e,o):r()}()},t.indexOf=p,t.keys=y,t.r=function(n){return y(n).map(function(t){return[t,n[t]]})},t.u=function(n){return y(n).map(function(t){return n[t]})},t.f=t.extend=function(n,t){return n=n||{},y(t).forEach(function(r){n[r]=t[r]}),n},t.inOperator=function(n,t){if(h(t)||l(t))return-1!==t.indexOf(n);if(v(t))return n in t;throw Error('Cannot use "in" operator to search for "'+n+'" in unexpected types.')}},function(n,t,r){"use strict";var i=r(1),e=Array.from,u="function"==typeof Symbol&&Symbol.iterator&&"function"==typeof e,o=function(){function n(n,t){this.variables={},this.parent=n,this.topLevel=!1,this.isolateWrites=t}var t=n.prototype;return t.set=function(n,t,r){var i=n.split("."),e=this.variables,u=this;if(r&&(u=this.resolve(i[0],!0)))u.set(n,t);else{for(var o=0;o<i.length-1;o++){var f=i[o];e[f]||(e[f]={}),e=e[f]}e[i[i.length-1]]=t}},t.get=function(n){var t=this.variables[n];return void 0!==t?t:null},t.lookup=function(n){var t=this.parent,r=this.variables[n];return void 0!==r?r:t&&t.lookup(n)},t.resolve=function(n,t){var r=t&&this.isolateWrites?void 0:this.parent;return void 0!==this.variables[n]?this:r&&r.resolve(n)},t.push=function(t){return new n(this,t)},t.pop=function(){return this.parent},n}();function f(n){return n&&Object.prototype.hasOwnProperty.call(n,"__keywords")}function c(n){var t=n.length;return 0===t?0:f(n[t-1])?t-1:t}function s(n){if("string"!=typeof n)return n;this.val=n,this.length=n.length}s.prototype=Object.create(String.prototype,{length:{writable:!0,configurable:!0,value:0}}),s.prototype.valueOf=function(){return this.val},s.prototype.toString=function(){return this.val},n.exports={Frame:o,makeMacro:function(n,t,r){var i=this;return function(){for(var e=arguments.length,u=Array(e),o=0;o<e;o++)u[o]=arguments[o];var s,a=c(u),h=function(n){var t=n.length;if(t){var r=n[t-1];if(f(r))return r}return{}}(u);if(a>n.length)s=u.slice(0,n.length),u.slice(s.length,a).forEach(function(n,r){r<t.length&&(h[t[r]]=n)}),s.push(h);else if(a<n.length){s=u.slice(0,a);for(var l=a;l<n.length;l++){var v=n[l];s.push(h[v]),delete h[v]}s.push(h)}else s=u;return r.apply(i,s)}},makeKeywordArgs:function(n){return n.__keywords=!0,n},numArgs:c,suppressValue:function(n,t){return n=void 0!==n&&null!==n?n:"",!t||n instanceof s||(n=i.escape(n.toString())),n},ensureDefined:function(n,t,r){if(null===n||void 0===n)throw new i.TemplateError("attempted to output null or undefined value",t+1,r+1);return n},memberLookup:function(n,t){if(void 0!==n&&null!==n)return"function"==typeof n[t]?function(){for(var r=arguments.length,i=Array(r),e=0;e<r;e++)i[e]=arguments[e];return n[t].apply(n,i)}:n[t]},contextOrFrameLookup:function(n,t,r){var i=t.lookup(r);return void 0!==i?i:n.lookup(r)},callWrap:function(n,t,r,i){if(!n)throw Error("Unable to call `"+t+"`, which is undefined or falsey");if("function"!=typeof n)throw Error("Unable to call `"+t+"`, which is not a function");return n.apply(r,i)},handleError:function(n,t,r){return n.lineno?n:new i.TemplateError(n,t,r)},isArray:i.isArray,keys:i.keys,SafeString:s,copySafeness:function(n,t){return n instanceof s?new s(t):t.toString()},markSafe:function(n){var t=typeof n;return"string"===t?new s(n):"function"!==t?n:function(t){var r=n.apply(this,arguments);return"string"==typeof r?new s(r):r}},asyncEach:function(n,t,r,e){if(i.isArray(n)){var u=n.length;i.asyncIter(n,function(n,i,e){switch(t){case 1:r(n,i,u,e);break;case 2:r(n[0],n[1],i,u,e);break;case 3:r(n[0],n[1],n[2],i,u,e);break;default:n.push(i,u,e),r.apply(this,n)}},e)}else i.asyncFor(n,function(n,t,i,e,u){r(n,t,i,e,u)},e)},asyncAll:function(n,t,r,e){var u,o,f=0;function c(n,t){f++,o[n]=t,f===u&&e(null,o.join(""))}if(i.isArray(n))if(u=n.length,o=Array(u),0===u)e(null,"");else for(var s=0;s<n.length;s++){var a=n[s];switch(t){case 1:r(a,s,u,c);break;case 2:r(a[0],a[1],s,u,c);break;case 3:r(a[0],a[1],a[2],s,u,c);break;default:a.push(s,u,c),r.apply(this,a)}}else{var h=i.keys(n||{});if(u=h.length,o=Array(u),0===u)e(null,"");else for(var l=0;l<h.length;l++){var v=h[l];r(v,n[v],l,u,c)}}},inOperator:i.inOperator,fromIterator:function(n){return"object"!=typeof n||null===n||i.isArray(n)?n:u&&Symbol.iterator in n?e(n):n}}},function(n,t,r){"use strict";var i=function(n){var t,r;function i(t){var r;return(r=n.call(this)||this).precompiled=t||{},r}return r=n,(t=i).prototype=Object.create(r.prototype),t.prototype.constructor=t,t.__proto__=r,i.prototype.getSource=function(n){return this.precompiled[n]?{src:{type:"code",obj:this.precompiled[n]},path:n}:null},i}(r(4));n.exports={PrecompiledLoader:i}},function(n,t,r){"use strict";var i=r(0),e=r(5);n.exports=function(n){var t,r;function e(){return n.apply(this,arguments)||this}r=n,(t=e).prototype=Object.create(r.prototype),t.prototype.constructor=t,t.__proto__=r;var u=e.prototype;return u.on=function(n,t){this.listeners=this.listeners||{},this.listeners[n]=this.listeners[n]||[],this.listeners[n].push(t)},u.emit=function(n){for(var t=arguments.length,r=Array(t>1?t-1:0),i=1;i<t;i++)r[i-1]=arguments[i];this.listeners&&this.listeners[n]&&this.listeners[n].forEach(function(n){n.apply(void 0,r)})},u.resolve=function(n,t){return i.resolve(i.dirname(n),t)},u.isRelative=function(n){return 0===n.indexOf("./")||0===n.indexOf("../")},e}(e)},function(n,t,r){"use strict";function i(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}function e(n,t,r){return t&&i(n.prototype,t),r&&i(n,r),n}var u=r(1);function o(n,t,r){r=r||{},u.keys(r).forEach(function(t){var i,e;r[t]=(i=n.prototype[t],e=r[t],"function"!=typeof i||"function"!=typeof e?e:function(){var n=this.parent;this.parent=i;var t=e.apply(this,arguments);return this.parent=n,t})});var i=function(n){var r,i;function u(){return n.apply(this,arguments)||this}return i=n,(r=u).prototype=Object.create(i.prototype),r.prototype.constructor=r,r.__proto__=i,e(u,[{key:"typename",get:function(){return t}}]),u}(n);return u.f(i.prototype,r),i}var f=function(){function n(){this.init.apply(this,arguments)}return n.prototype.init=function(){},n.extend=function(n,t){return"object"==typeof n&&(t=n,n="anonymous"),o(this,n,t)},e(n,[{key:"typename",get:function(){return this.constructor.name}}]),n}();n.exports=f},function(n,t,r){"use strict";var i,e=r(1),u=r(7),o=u.Environment,f=u.Template,c=r(4),s=r(3),a=r(0),h=r(0),l=r(0),v=r(0),d=r(2),p=r(0),y=r(16);function w(n,t){var r;return t=t||{},e.isObject(n)&&(t=n,n=null),s.FileSystemLoader?r=new s.FileSystemLoader(n,{watch:t.watch,noCache:t.noCache}):s.WebLoader&&(r=new s.WebLoader(n,{useCache:t.web&&t.web.useCache,async:t.web&&t.web.async})),i=new o(r,t),t&&t.express&&i.express(t.express),i}n.exports={Environment:o,Template:f,Loader:c,FileSystemLoader:s.FileSystemLoader,PrecompiledLoader:s.PrecompiledLoader,WebLoader:s.WebLoader,compiler:h,parser:l,lexer:v,runtime:d,lib:e,nodes:p,installJinjaCompat:y,configure:w,reset:function(){i=void 0},compile:function(n,t,r,e){return i||w(),new f(n,t,r,e)},render:function(n,t,r){return i||w(),i.render(n,t,r)},renderString:function(n,t,r){return i||w(),i.renderString(n,t,r)},precompile:a?a.precompile:void 0,precompileString:a?a.precompileString:void 0}},function(n,t,r){"use strict";function i(n,t){n.prototype=Object.create(t.prototype),n.prototype.constructor=n,n.__proto__=t}var e=r(8),u=r(11),o=r(1),f=r(0),c=r(12),s=r(3),a=s.FileSystemLoader,h=s.WebLoader,l=s.PrecompiledLoader,v=r(13),d=r(14),p=r(5),y=r(2),w=y.handleError,b=y.Frame,m=r(15);function g(n,t,r){e(function(){n(t,r)})}var j={type:"code",obj:{root:function(n,t,r,i,e){try{e(null,"")}catch(n){e(w(n,null,null))}}}},E=function(n){function t(){return n.apply(this,arguments)||this}i(t,n);var r=t.prototype;return r.init=function(n,t){var r=this;t=this.opts=t||{},this.opts.dev=!!t.dev,this.opts.autoescape=null==t.autoescape||t.autoescape,this.opts.throwOnUndefined=!!t.throwOnUndefined,this.opts.trimBlocks=!!t.trimBlocks,this.opts.lstripBlocks=!!t.lstripBlocks,this.loaders=[],n?this.loaders=o.isArray(n)?n:[n]:a?this.loaders=[new a("views")]:h&&(this.loaders=[new h("/views")]),"undefined"!=typeof window&&window.nunjucksPrecompiled&&this.loaders.unshift(new l(window.nunjucksPrecompiled)),this.initCache(),this.globals=d(),this.filters={},this.tests={},this.asyncFilters=[],this.extensions={},this.extensionsList=[],o.r(c).forEach(function(n){var t=n[0],i=n[1];return r.addFilter(t,i)}),o.r(v).forEach(function(n){var t=n[0],i=n[1];return r.addTest(t,i)})},r.initCache=function(){this.loaders.forEach(function(n){n.cache={},"function"==typeof n.on&&n.on("update",function(t){n.cache[t]=null})})},r.addExtension=function(n,t){return t.__name=n,this.extensions[n]=t,this.extensionsList.push(t),this},r.removeExtension=function(n){var t=this.getExtension(n);t&&(this.extensionsList=o.without(this.extensionsList,t),delete this.extensions[n])},r.getExtension=function(n){return this.extensions[n]},r.hasExtension=function(n){return!!this.extensions[n]},r.addGlobal=function(n,t){return this.globals[n]=t,this},r.getGlobal=function(n){if(void 0===this.globals[n])throw Error("global not found: "+n);return this.globals[n]},r.addFilter=function(n,t,r){var i=t;return r&&this.asyncFilters.push(n),this.filters[n]=i,this},r.getFilter=function(n){if(!this.filters[n])throw Error("filter not found: "+n);return this.filters[n]},r.addTest=function(n,t){return this.tests[n]=t,this},r.getTest=function(n){if(!this.tests[n])throw Error("test not found: "+n);return this.tests[n]},r.resolveTemplate=function(n,t,r){return!(!n.isRelative||!t)&&n.isRelative(r)&&n.resolve?n.resolve(t,r):r},r.getTemplate=function(n,t,r,i,e){var u,f=this,c=this,s=null;if(n&&n.raw&&(n=n.raw),o.isFunction(r)&&(e=r,r=null,t=t||!1),o.isFunction(t)&&(e=t,t=!1),n instanceof O)s=n;else{if("string"!=typeof n)throw Error("template names must be a string: "+n);for(var a=0;a<this.loaders.length;a++){var h=this.loaders[a];if(s=h.cache[this.resolveTemplate(h,r,n)])break}}if(s)return t&&s.compile(),e?void e(null,s):s;return o.asyncIter(this.loaders,function(t,i,e,u){function o(n,r){n?u(n):r?(r.loader=t,u(null,r)):e()}n=c.resolveTemplate(t,r,n),t.async?t.getSource(n,o):o(null,t.getSource(n))},function(r,o){if(o||r||i||(r=Error("template not found: "+n)),r){if(e)return void e(r);throw r}var c;o?(c=new O(o.src,f,o.path,t),o.noCache||(o.loader.cache[n]=c)):c=new O(j,f,"",t),e?e(null,c):u=c}),u},r.express=function(n){return m(this,n)},r.render=function(n,t,r){o.isFunction(t)&&(r=t,t=null);var i=null;return this.getTemplate(n,function(n,e){if(n&&r)g(r,n);else{if(n)throw n;i=e.render(t,r)}}),i},r.renderString=function(n,t,r,i){return o.isFunction(r)&&(i=r,r={}),new O(n,this,(r=r||{}).path).render(t,i)},r.waterfall=function(n,t,r){return u(n,t,r)},t}(p),k=function(n){function t(){return n.apply(this,arguments)||this}i(t,n);var r=t.prototype;return r.init=function(n,t,r){var i=this;this.env=r||new E,this.ctx=o.extend({},n),this.blocks={},this.exported=[],o.keys(t).forEach(function(n){i.addBlock(n,t[n])})},r.lookup=function(n){return n in this.env.globals&&!(n in this.ctx)?this.env.globals[n]:this.ctx[n]},r.setVariable=function(n,t){this.ctx[n]=t},r.getVariables=function(){return this.ctx},r.addBlock=function(n,t){return this.blocks[n]=this.blocks[n]||[],this.blocks[n].push(t),this},r.getBlock=function(n){if(!this.blocks[n])throw Error('unknown block "'+n+'"');return this.blocks[n][0]},r.getSuper=function(n,t,r,i,e,u){var f=o.indexOf(this.blocks[t]||[],r),c=this.blocks[t][f+1];if(-1===f||!c)throw Error('no super block available for "'+t+'"');c(n,this,i,e,u)},r.addExport=function(n){this.exported.push(n)},r.getExported=function(){var n=this,t={};return this.exported.forEach(function(r){t[r]=n.ctx[r]}),t},t}(p),O=function(n){function t(){return n.apply(this,arguments)||this}i(t,n);var r=t.prototype;return r.init=function(n,t,r,i){if(this.env=t||new E,o.isObject(n))switch(n.type){case"code":this.tmplProps=n.obj;break;case"string":this.tmplStr=n.obj;break;default:throw Error("Unexpected template object type "+n.type+"; expected 'code', or 'string'")}else{if(!o.isString(n))throw Error("src must be a string or an object describing the source");this.tmplStr=n}if(this.path=r,i)try{this.a()}catch(n){throw o.t(this.path,this.env.opts.dev,n)}else this.compiled=!1},r.render=function(n,t,r){var i=this;"function"==typeof n?(r=n,n={}):"function"==typeof t&&(r=t,t=null);var e=!t;try{this.compile()}catch(n){var u=o.t(this.path,this.env.opts.dev,n);if(r)return g(r,u);throw u}var f=new k(n||{},this.blocks,this.env),c=t?t.push(!0):new b;c.topLevel=!0;var s=null,a=!1;return this.rootRenderFunc(this.env,f,c,y,function(n,t){if(!a)if(n&&(n=o.t(i.path,i.env.opts.dev,n),a=!0),r)e?g(r,n,t):r(n,t);else{if(n)throw n;s=t}}),s},r.getExported=function(n,t,r){"function"==typeof n&&(r=n,n={}),"function"==typeof t&&(r=t,t=null);try{this.compile()}catch(n){if(r)return r(n);throw n}var i=t?t.push():new b;i.topLevel=!0;var e=new k(n||{},this.blocks,this.env);this.rootRenderFunc(this.env,e,i,y,function(n){n?r(n,null):r(null,e.getExported())})},r.compile=function(){this.compiled||this.a()},r.a=function(){var n;if(this.tmplProps)n=this.tmplProps;else{var t=f.compile(this.tmplStr,this.env.asyncFilters,this.env.extensionsList,this.path,this.env.opts);n=Function(t)()}this.blocks=this.h(n),this.rootRenderFunc=n.root,this.compiled=!0},r.h=function(n){var t={};return o.keys(n).forEach(function(r){"b_"===r.slice(0,2)&&(t[r.slice(2)]=n[r])}),t},t}(p);n.exports={Environment:E,Template:O}},function(n,t,r){"use strict";var i=r(9),e=[],u=[],o=i.makeRequestCallFromTimer(function(){if(u.length)throw u.shift()});function f(n){var t;(t=e.length?e.pop():new c).task=n,i(t)}function c(){this.task=null}n.exports=f,c.prototype.call=function(){try{this.task.call()}catch(n){f.onerror?f.onerror(n):(u.push(n),o())}finally{this.task=null,e[e.length]=this}}},function(n,t,r){"use strict";!function(t){function r(n){e.length||(i(),!0),e[e.length]=n}n.exports=r;var i,e=[],u=0,o=1024;function f(){for(;u<e.length;){var n=u;if(u+=1,e[n].call(),u>o){for(var t=0,r=e.length-u;t<r;t++)e[t]=e[t+u];e.length-=u,u=0}}e.length=0,u=0,!1}var c,s,a,h=void 0!==t?t:self,l=h.MutationObserver||h.WebKitMutationObserver;function v(n){return function(){var t=setTimeout(i,0),r=setInterval(i,50);function i(){clearTimeout(t),clearInterval(r),n()}}}"function"==typeof l?(c=1,s=new l(f),a=document.createTextNode(""),s.observe(a,{characterData:!0}),i=function(){c=-c,a.data=c}):i=v(f),r.requestFlush=i,r.makeRequestCallFromTimer=v}(r(10))},function(n,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(n){"object"==typeof window&&(r=window)}n.exports=r},function(n,t,r){var i;!function(r){"use strict";var e=function(){var n=Array.prototype.slice.call(arguments);"function"==typeof n[0]&&n[0].apply(null,n.splice(1))},u=function(n){"function"==typeof setImmediate?setImmediate(n):"undefined"!=typeof process&&process.nextTick?process.nextTick(n):setTimeout(n,0)},o=Array.isArray||function(n){return"[object Array]"===Object.prototype.toString.call(n)},f=function(n,t,r){var i=r?u:e;if(t=t||function(){},!o(n))return t(Error("First argument to waterfall must be an array of functions"));if(!n.length)return t();var f=function(n){return function(r){if(r)t.apply(null,arguments),t=function(){};else{var e=Array.prototype.slice.call(arguments,1),u=n.next();u?e.push(f(u)):e.push(t),i(function(){n.apply(null,e)})}}};f(function(n){var t=function(r){var i=function(){return n.length&&n[r].apply(null,arguments),i.next()};return i.next=function(){return r<n.length-1?t(r+1):null},i};return t(0)}(n))()};void 0===(i=function(){return f}.apply(t,[]))||(n.exports=i)}()},function(n,t,r){"use strict";var i=r(1),e=r(2);function u(n,t){return null===n||void 0===n||!1===n?t:n}function o(n){return n!=n}function f(n){var t=(n=u(n,"")).toLowerCase();return e.copySafeness(n,t.charAt(0).toUpperCase()+t.slice(1))}function c(n){if(i.isString(n))return n.split("");if(i.isObject(n))return i.r(n||{}).map(function(n){return{key:n[0],value:n[1]}});if(i.isArray(n))return n;throw new i.TemplateError("list filter: type not iterable")}function s(n){return e.copySafeness(n,n.replace(/^\s*|\s*$/g,""))}(t=n.exports={}).abs=Math.abs,t.batch=function(n,t,r){var i,e=[],u=[];for(i=0;i<n.length;i++)i%t==0&&u.length&&(e.push(u),u=[]),u.push(n[i]);if(u.length){if(r)for(i=u.length;i<t;i++)u.push(r);e.push(u)}return e},t.capitalize=f,t.center=function(n,t){if(n=u(n,""),t=t||80,n.length>=t)return n;var r=t-n.length,o=i.repeat(" ",r/2-r%2),f=i.repeat(" ",r/2);return e.copySafeness(n,o+n+f)},t.default=function(n,t,r){return r?n||t:void 0!==n?n:t},t.dictsort=function(n,t,r){if(!i.isObject(n))throw new i.TemplateError("dictsort filter: val must be an object");var e,u=[];for(var o in n)u.push([o,n[o]]);if(void 0===r||"key"===r)e=0;else{if("value"!==r)throw new i.TemplateError("dictsort filter: You can only sort by either key or value");e=1}return u.sort(function(n,r){var u=n[e],o=r[e];return t||(i.isString(u)&&(u=u.toUpperCase()),i.isString(o)&&(o=o.toUpperCase())),u>o?1:u===o?0:-1}),u},t.dump=function(n,t){return JSON.stringify(n,null,t)},t.escape=function(n){return n instanceof e.SafeString?n:(n=null===n||void 0===n?"":n,e.markSafe(i.escape(n.toString())))},t.safe=function(n){return n instanceof e.SafeString?n:(n=null===n||void 0===n?"":n,e.markSafe(n.toString()))},t.first=function(n){return n[0]},t.groupby=function(n,t){return i.groupBy(n,t)},t.indent=function(n,t,r){if(""===(n=u(n,"")))return"";t=t||4;var o=n.split("\n"),f=i.repeat(" ",t),c=o.map(function(n,t){return 0!==t||r?""+f+n+"\n":n+"\n"}).join("");return e.copySafeness(n,c)},t.join=function(n,t,r){return t=t||"",r&&(n=i.map(n,function(n){return n[r]})),n.join(t)},t.last=function(n){return n[n.length-1]},t.length=function(n){var t=u(n,"");return void 0!==t?"function"==typeof Map&&t instanceof Map||"function"==typeof Set&&t instanceof Set?t.size:!i.isObject(t)||t instanceof e.SafeString?t.length:i.keys(t).length:0},t.list=c,t.lower=function(n){return(n=u(n,"")).toLowerCase()},t.nl2br=function(n){return null===n||void 0===n?"":e.copySafeness(n,n.replace(/\r\n|\n/g,"<br />\n"))},t.random=function(n){return n[Math.floor(Math.random()*n.length)]},t.rejectattr=function(n,t){return n.filter(function(n){return!n[t]})},t.selectattr=function(n,t){return n.filter(function(n){return!!n[t]})},t.replace=function(n,t,r,i){var u=n;if(t instanceof RegExp)return n.replace(t,r);void 0===i&&(i=-1);var o="";if("number"==typeof t)t=""+t;else if("string"!=typeof t)return n;if("number"==typeof n&&(n=""+n),"string"!=typeof n&&!(n instanceof e.SafeString))return n;if(""===t)return o=r+n.split("").join(r)+r,e.copySafeness(n,o);var f=n.indexOf(t);if(0===i||-1===f)return n;for(var c=0,s=0;f>-1&&(-1===i||s<i);)o+=n.substring(c,f)+r,c=f+t.length,s++,f=n.indexOf(t,c);return c<n.length&&(o+=n.substring(c)),e.copySafeness(u,o)},t.reverse=function(n){var t;return(t=i.isString(n)?c(n):i.map(n,function(n){return n})).reverse(),i.isString(n)?e.copySafeness(n,t.join("")):t},t.round=function(n,t,r){var i=Math.pow(10,t=t||0);return("ceil"===r?Math.ceil:"floor"===r?Math.floor:Math.round)(n*i)/i},t.slice=function(n,t,r){for(var i=Math.floor(n.length/t),e=n.length%t,u=[],o=0,f=0;f<t;f++){var c=o+f*i;f<e&&o++;var s=o+(f+1)*i,a=n.slice(c,s);r&&f>=e&&a.push(r),u.push(a)}return u},t.sum=function(n,t,r){return void 0===r&&(r=0),t&&(n=i.map(n,function(n){return n[t]})),r+n.reduce(function(n,t){return n+t},0)},t.sort=e.makeMacro(["value","reverse","case_sensitive","attribute"],[],function(n,t,r,e){var u=i.map(n,function(n){return n});return u.sort(function(n,u){var o=e?n[e]:n,f=e?u[e]:u;return!r&&i.isString(o)&&i.isString(f)&&(o=o.toLowerCase(),f=f.toLowerCase()),o<f?t?1:-1:o>f?t?-1:1:0}),u}),t.string=function(n){return e.copySafeness(n,n)},t.striptags=function(n,t){var r=s((n=u(n,"")).replace(/<\/?([a-z][a-z0-9]*)\b[^>]*>|<!--[\s\S]*?-->/gi,"")),i="";return i=t?r.replace(/^ +| +$/gm,"").replace(/ +/g," ").replace(/(\r\n)/g,"\n").replace(/\n\n\n+/g,"\n\n"):r.replace(/\s+/gi," "),e.copySafeness(n,i)},t.title=function(n){var t=(n=u(n,"")).split(" ").map(function(n){return f(n)});return e.copySafeness(n,t.join(" "))},t.trim=s,t.truncate=function(n,t,r,i){var o=n;if(n=u(n,""),t=t||255,n.length<=t)return n;if(r)n=n.substring(0,t);else{var f=n.lastIndexOf(" ",t);-1===f&&(f=t),n=n.substring(0,f)}return n+=void 0!==i&&null!==i?i:"...",e.copySafeness(o,n)},t.upper=function(n){return(n=u(n,"")).toUpperCase()},t.urlencode=function(n){var t=encodeURIComponent;return i.isString(n)?t(n):(i.isArray(n)?n:i.r(n)).map(function(n){var r=n[0],i=n[1];return t(r)+"="+t(i)}).join("&")};var a=/^(?:\(|<|&lt;)?(.*?)(?:\.|,|\)|\n|&gt;)?$/,h=/^[\w.!#$%&'*+\-\/=?\^`{|}~]+@[a-z\d\-]+(\.[a-z\d\-]+)+$/i,l=/^https?:\/\/.*$/,v=/^www\./,d=/\.(?:org|net|com)(?:\:|\/|$)/;t.urlize=function(n,t,r){o(t)&&(t=1/0);var i=!0===r?' rel="nofollow"':"";return n.split(/(\s+)/).filter(function(n){return n&&n.length}).map(function(n){var r=n.match(a),e=r?r[1]:n,u=e.substr(0,t);return l.test(e)?'<a href="'+e+'"'+i+">"+u+"</a>":v.test(e)?'<a href="http://'+e+'"'+i+">"+u+"</a>":h.test(e)?'<a href="mailto:'+e+'">'+e+"</a>":d.test(e)?'<a href="http://'+e+'"'+i+">"+u+"</a>":n}).join("")},t.wordcount=function(n){var t=(n=u(n,""))?n.match(/\w+/g):null;return t?t.length:null},t.float=function(n,t){var r=parseFloat(n);return o(r)?t:r},t.int=function(n,t){var r=parseInt(n,10);return o(r)?t:r},t.d=t.default,t.e=t.escape},function(n,t,r){"use strict";var i=r(2).SafeString;t.callable=function(n){return"function"==typeof n},t.defined=function(n){return void 0!==n},t.divisibleby=function(n,t){return n%t==0},t.escaped=function(n){return n instanceof i},t.equalto=function(n,t){return n===t},t.eq=t.equalto,t.sameas=t.equalto,t.even=function(n){return n%2==0},t.falsy=function(n){return!n},t.ge=function(n,t){return n>=t},t.greaterthan=function(n,t){return n>t},t.gt=t.greaterthan,t.le=function(n,t){return n<=t},t.lessthan=function(n,t){return n<t},t.lt=t.lessthan,t.lower=function(n){return n.toLowerCase()===n},t.ne=function(n,t){return n!==t},t.null=function(n){return null===n},t.number=function(n){return"number"==typeof n},t.odd=function(n){return n%2==1},t.string=function(n){return"string"==typeof n},t.truthy=function(n){return!!n},t.undefined=function(n){return void 0===n},t.upper=function(n){return n.toUpperCase()===n},t.iterable=function(n){return"undefined"!=typeof Symbol?!!n[Symbol.iterator]:Array.isArray(n)||"string"==typeof n},t.mapping=function(n){var t=null!==n&&void 0!==n&&"object"==typeof n&&!Array.isArray(n);return Set?t&&!(n instanceof Set):t}},function(n,t,r){"use strict";n.exports=function(){return{range:function(n,t,r){void 0===t?(t=n,n=0,r=1):r||(r=1);var i=[];if(r>0)for(var e=n;e<t;e+=r)i.push(e);else for(var u=n;u>t;u+=r)i.push(u);return i},cycler:function(){return n=Array.prototype.slice.call(arguments),t=-1,{current:null,reset:function(){t=-1,this.current=null},next:function(){return++t>=n.length&&(t=0),this.current=n[t],this.current}};var n,t},joiner:function(n){return function(n){n=n||",";var t=!0;return function(){var r=t?"":n;return t=!1,r}}(n)}}}},function(n,t,r){var i=r(0);n.exports=function(n,t){function r(n,t){if(this.name=n,this.path=n,this.defaultEngine=t.defaultEngine,this.ext=i.extname(n),!this.ext&&!this.defaultEngine)throw Error("No default engine was specified and no extension was provided.");this.ext||(this.name+=this.ext=("."!==this.defaultEngine[0]?".":"")+this.defaultEngine)}return r.prototype.render=function(t,r){n.render(this.name,t,r)},t.set("view",r),t.set("nunjucksEnv",n),n}},function(n,t,r){n.exports=function(){"use strict";var n,t,r=this.runtime,i=this.lib,e=this.compiler.Compiler,u=this.parser.Parser,o=(this.nodes,this.lexer,r.contextOrFrameLookup),f=r.memberLookup;function c(n,t){return Object.prototype.hasOwnProperty.call(n,t)}e&&(n=e.prototype.assertType),u&&(t=u.prototype.parseAggregate),r.contextOrFrameLookup=function(n,t,r){var i=o.apply(this,arguments);if(void 0!==i)return i;switch(r){case"True":return!0;case"False":return!1;case"None":return null;default:return}};var s={pop:function(n){if(void 0===n)return this.pop();if(n>=this.length||n<0)throw Error("KeyError");return this.splice(n,1)},append:function(n){return this.push(n)},remove:function(n){for(var t=0;t<this.length;t++)if(this[t]===n)return this.splice(t,1);throw Error("ValueError")},count:function(n){for(var t=0,r=0;r<this.length;r++)this[r]===n&&t++;return t},index:function(n){var t;if(-1===(t=this.indexOf(n)))throw Error("ValueError");return t},find:function(n){return this.indexOf(n)},insert:function(n,t){return this.splice(n,0,t)}},a={items:function(){return i.r(this)},values:function(){return i.u(this)},keys:function(){return i.keys(this)},get:function(n,t){var r=this[n];return void 0===r&&(r=t),r},has_key:function(n){return c(this,n)},pop:function(n,t){var r=this[n];if(void 0===r&&void 0!==t)r=t;else{if(void 0===r)throw Error("KeyError");delete this[n]}return r},popitem:function(){var n=i.keys(this);if(!n.length)throw Error("KeyError");var t=n[0],r=this[t];return delete this[t],[t,r]},setdefault:function(n,t){return void 0===t&&(t=null),n in this||(this[n]=t),this[n]},update:function(n){return i.f(this,n),null}};return a.iteritems=a.items,a.itervalues=a.values,a.iterkeys=a.keys,r.memberLookup=function(n,t,e){return 4===arguments.length?function(n,t,i,e){n=n||[],null===t&&(t=e<0?n.length-1:0),null===i?i=e<0?-1:n.length:i<0&&(i+=n.length),t<0&&(t+=n.length);for(var u=[],o=t;!(o<0||o>n.length||e>0&&o>=i||e<0&&o<=i);o+=e)u.push(r.memberLookup(n,o));return u}.apply(this,arguments):(n=n||{},i.isArray(n)&&c(s,t)?s[t].bind(n):i.isObject(n)&&c(a,t)?a[t].bind(n):f.apply(this,arguments))},function(){r.contextOrFrameLookup=o,r.memberLookup=f,e&&(e.prototype.assertType=n),u&&(u.prototype.parseAggregate=t)}}}])});
/*! Browser bundle of nunjucks 3.1.3 (slim, only works with precompiled templates) */
!function(n,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.nunjucks=t():n.nunjucks=t()}("undefined"!=typeof self?self:this,function(){return function(n){var t={};function r(i){if(t[i])return t[i].exports;var u=t[i]={i:i,l:!1,exports:{}};return n[i].call(u.exports,u,u.exports,r),u.l=!0,u.exports}return r.m=n,r.c=t,r.d=function(n,t,i){r.o(n,t)||Object.defineProperty(n,t,{configurable:!1,enumerable:!0,get:i})},r.n=function(n){var t=n&&n.__esModule?function(){return n.default}:function(){return n};return r.d(t,"a",t),t},r.o=function(n,t){return Object.prototype.hasOwnProperty.call(n,t)},r.p="",r(r.s=6)}([function(n,t){},function(n,t,r){"use strict";var i=Array.prototype,u=Object.prototype,e={"&":"&amp;",'"':"&quot;","'":"&#39;","<":"&lt;",">":"&gt;"},o=/[&"'<>]/g,f=n.exports={};function c(n,t){return u.hasOwnProperty.call(n,t)}function s(n){return e[n]}function a(n,t,r){var i,u,e;if(n instanceof Error&&(n=(u=n).name+": "+u.message),Object.setPrototypeOf?Object.setPrototypeOf(i=Error(n),a.prototype):Object.defineProperty(i=this,"message",{enumerable:!1,writable:!0,value:n}),Object.defineProperty(i,"name",{value:"Template render error"}),Error.captureStackTrace&&Error.captureStackTrace(i,this.constructor),u){var o=Object.getOwnPropertyDescriptor(u,"stack");(e=o&&(o.get||function(){return o.value}))||(e=function(){return u.stack})}else{var f=Error(n).stack;e=function(){return f}}return Object.defineProperty(i,"stack",{get:function(){return e.call(i)}}),Object.defineProperty(i,"cause",{value:u}),i.lineno=t,i.colno=r,i.firstUpdate=!0,i.Update=function(n){var t="("+(n||"unknown path")+")";return this.firstUpdate&&(this.lineno&&this.colno?t+=" [Line "+this.lineno+", Column "+this.colno+"]":this.lineno&&(t+=" [Line "+this.lineno+"]")),t+="\n ",this.firstUpdate&&(t+=" "),this.message=t+(this.message||""),this.firstUpdate=!1,this},i}function h(n){return"[object Function]"===u.toString.call(n)}function l(n){return"[object Array]"===u.toString.call(n)}function v(n){return"[object String]"===u.toString.call(n)}function d(n){return"[object Object]"===u.toString.call(n)}function p(n){return Array.prototype.slice.call(n)}function y(n,t,r){return Array.prototype.indexOf.call(n||[],t,r)}function w(n){var t=[];for(var r in n)c(n,r)&&t.push(r);return t}f.hasOwnProp=c,f.t=function(n,t,r){if(r.Update||(r=new f.TemplateError(r)),r.Update(n),!t){var i=r;(r=Error(i.message)).name=i.name}return r},Object.setPrototypeOf?Object.setPrototypeOf(a.prototype,Error.prototype):a.prototype=Object.create(Error.prototype,{constructor:{value:a}}),f.TemplateError=a,f.escape=function(n){return n.replace(o,s)},f.isFunction=h,f.isArray=l,f.isString=v,f.isObject=d,f.groupBy=function(n,t){for(var r={},i=h(t)?t:function(n){return n[t]},u=0;u<n.length;u++){var e=n[u],o=i(e,u);(r[o]||(r[o]=[])).push(e)}return r},f.toArray=p,f.without=function(n){var t=[];if(!n)return t;for(var r=n.length,i=p(arguments).slice(1),u=-1;++u<r;)-1===y(i,n[u])&&t.push(n[u]);return t},f.repeat=function(n,t){for(var r="",i=0;i<t;i++)r+=n;return r},f.each=function(n,t,r){if(null!=n)if(i.forEach&&n.forEach===i.forEach)n.forEach(t,r);else if(n.length===+n.length)for(var u=0,e=n.length;u<e;u++)t.call(r,n[u],u,n)},f.map=function(n,t){var r=[];if(null==n)return r;if(i.map&&n.map===i.map)return n.map(t);for(var u=0;u<n.length;u++)r[r.length]=t(n[u],u);return n.length===+n.length&&(r.length=n.length),r},f.asyncIter=function(n,t,r){var i=-1;!function u(){++i<n.length?t(n[i],i,u,r):r()}()},f.asyncFor=function(n,t,r){var i=w(n||{}),u=i.length,e=-1;!function o(){var f=i[++e];e<u?t(f,n[f],e,u,o):r()}()},f.indexOf=y,f.keys=w,f.r=function(n){return w(n).map(function(t){return[t,n[t]]})},f.u=function(n){return w(n).map(function(t){return n[t]})},f.f=f.extend=function(n,t){return n=n||{},w(t).forEach(function(r){n[r]=t[r]}),n},f.inOperator=function(n,t){if(l(t)||v(t))return-1!==t.indexOf(n);if(d(t))return n in t;throw Error('Cannot use "in" operator to search for "'+n+'" in unexpected types.')}},function(n,t,r){"use strict";var i=r(1),u=Array.from,e="function"==typeof Symbol&&Symbol.iterator&&"function"==typeof u,o=function(){function n(n,t){this.variables={},this.parent=n,this.topLevel=!1,this.isolateWrites=t}var t=n.prototype;return t.set=function(n,t,r){var i=n.split("."),u=this.variables,e=this;if(r&&(e=this.resolve(i[0],!0)))e.set(n,t);else{for(var o=0;o<i.length-1;o++){var f=i[o];u[f]||(u[f]={}),u=u[f]}u[i[i.length-1]]=t}},t.get=function(n){var t=this.variables[n];return void 0!==t?t:null},t.lookup=function(n){var t=this.parent,r=this.variables[n];return void 0!==r?r:t&&t.lookup(n)},t.resolve=function(n,t){var r=t&&this.isolateWrites?void 0:this.parent;return void 0!==this.variables[n]?this:r&&r.resolve(n)},t.push=function(t){return new n(this,t)},t.pop=function(){return this.parent},n}();function f(n){return n&&Object.prototype.hasOwnProperty.call(n,"__keywords")}function c(n){var t=n.length;return 0===t?0:f(n[t-1])?t-1:t}function s(n){if("string"!=typeof n)return n;this.val=n,this.length=n.length}s.prototype=Object.create(String.prototype,{length:{writable:!0,configurable:!0,value:0}}),s.prototype.valueOf=function(){return this.val},s.prototype.toString=function(){return this.val},n.exports={Frame:o,makeMacro:function(n,t,r){var i=this;return function(){for(var u=arguments.length,e=Array(u),o=0;o<u;o++)e[o]=arguments[o];var s,a=c(e),h=function(n){var t=n.length;if(t){var r=n[t-1];if(f(r))return r}return{}}(e);if(a>n.length)s=e.slice(0,n.length),e.slice(s.length,a).forEach(function(n,r){r<t.length&&(h[t[r]]=n)}),s.push(h);else if(a<n.length){s=e.slice(0,a);for(var l=a;l<n.length;l++){var v=n[l];s.push(h[v]),delete h[v]}s.push(h)}else s=e;return r.apply(i,s)}},makeKeywordArgs:function(n){return n.__keywords=!0,n},numArgs:c,suppressValue:function(n,t){return n=void 0!==n&&null!==n?n:"",!t||n instanceof s||(n=i.escape(n.toString())),n},ensureDefined:function(n,t,r){if(null===n||void 0===n)throw new i.TemplateError("attempted to output null or undefined value",t+1,r+1);return n},memberLookup:function(n,t){if(void 0!==n&&null!==n)return"function"==typeof n[t]?function(){for(var r=arguments.length,i=Array(r),u=0;u<r;u++)i[u]=arguments[u];return n[t].apply(n,i)}:n[t]},contextOrFrameLookup:function(n,t,r){var i=t.lookup(r);return void 0!==i?i:n.lookup(r)},callWrap:function(n,t,r,i){if(!n)throw Error("Unable to call `"+t+"`, which is undefined or falsey");if("function"!=typeof n)throw Error("Unable to call `"+t+"`, which is not a function");return n.apply(r,i)},handleError:function(n,t,r){return n.lineno?n:new i.TemplateError(n,t,r)},isArray:i.isArray,keys:i.keys,SafeString:s,copySafeness:function(n,t){return n instanceof s?new s(t):t.toString()},markSafe:function(n){var t=typeof n;return"string"===t?new s(n):"function"!==t?n:function(t){var r=n.apply(this,arguments);return"string"==typeof r?new s(r):r}},asyncEach:function(n,t,r,u){if(i.isArray(n)){var e=n.length;i.asyncIter(n,function(n,i,u){switch(t){case 1:r(n,i,e,u);break;case 2:r(n[0],n[1],i,e,u);break;case 3:r(n[0],n[1],n[2],i,e,u);break;default:n.push(i,e,u),r.apply(this,n)}},u)}else i.asyncFor(n,function(n,t,i,u,e){r(n,t,i,u,e)},u)},asyncAll:function(n,t,r,u){var e,o,f=0;function c(n,t){f++,o[n]=t,f===e&&u(null,o.join(""))}if(i.isArray(n))if(e=n.length,o=Array(e),0===e)u(null,"");else for(var s=0;s<n.length;s++){var a=n[s];switch(t){case 1:r(a,s,e,c);break;case 2:r(a[0],a[1],s,e,c);break;case 3:r(a[0],a[1],a[2],s,e,c);break;default:a.push(s,e,c),r.apply(this,a)}}else{var h=i.keys(n||{});if(e=h.length,o=Array(e),0===e)u(null,"");else for(var l=0;l<h.length;l++){var v=h[l];r(v,n[v],l,e,c)}}},inOperator:i.inOperator,fromIterator:function(n){return"object"!=typeof n||null===n||i.isArray(n)?n:e&&Symbol.iterator in n?u(n):n}}},function(n,t,r){"use strict";var i=function(n){function t(t){var r;return(r=n.call(this)||this).precompiled=t||{},r}var r,i;return t.prototype.getSource=function(n){return this.precompiled[n]?{src:{type:"code",obj:this.precompiled[n]},path:n}:null},i=n,(r=t).prototype.__proto__=i&&i.prototype,r.__proto__=i,t}(r(4));n.exports={PrecompiledLoader:i}},function(n,t,r){"use strict";var i=r(0),u=r(5);n.exports=function(n){function t(){return n.apply(this,arguments)||this}var r,u,e=t.prototype;return e.on=function(n,t){this.listeners=this.listeners||{},this.listeners[n]=this.listeners[n]||[],this.listeners[n].push(t)},e.emit=function(n){for(var t=arguments.length,r=Array(t>1?t-1:0),i=1;i<t;i++)r[i-1]=arguments[i];this.listeners&&this.listeners[n]&&this.listeners[n].forEach(function(n){n.apply(void 0,r)})},e.resolve=function(n,t){return i.resolve(i.dirname(n),t)},e.isRelative=function(n){return 0===n.indexOf("./")||0===n.indexOf("../")},u=n,(r=t).prototype.__proto__=u&&u.prototype,r.__proto__=u,t}(u)},function(n,t,r){"use strict";function i(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}function u(n,t,r){return t&&i(n.prototype,t),r&&i(n,r),n}var e=r(1);var o=function(){function n(){this.init.apply(this,arguments)}return n.prototype.init=function(){},n.extend=function(n,t){return"object"==typeof n&&(t=n,n="anonymous"),function(n,t,r){r=r||{},e.keys(r).forEach(function(t){var i,u;r[t]=(i=n.prototype[t],u=r[t],"function"!=typeof i||"function"!=typeof u?u:function(){var n=this.parent;this.parent=i;var t=u.apply(this,arguments);return this.parent=n,t})});var i=function(n){function r(){return n.apply(this,arguments)||this}var i,e;return u(r,[{key:"typename",get:function(){return t}}]),e=n,(i=r).prototype.__proto__=e&&e.prototype,i.__proto__=e,r}(n);return e.f(i.prototype,r),i}(this,n,t)},u(n,[{key:"typename",get:function(){return this.constructor.name}}]),n}();n.exports=o},function(n,t,r){"use strict";var i,u=r(1),e=r(7),o=e.Environment,f=e.Template,c=r(4),s=r(3),a=r(0),h=r(0),l=r(0),v=r(0),d=r(2),p=r(0),y=r(16);function w(n,t){var r;return t=t||{},u.isObject(n)&&(t=n,n=null),s.FileSystemLoader?r=new s.FileSystemLoader(n,{watch:t.watch,noCache:t.noCache}):s.WebLoader&&(r=new s.WebLoader(n,{useCache:t.web&&t.web.useCache,async:t.web&&t.web.async})),i=new o(r,t),t&&t.express&&i.express(t.express),i}n.exports={Environment:o,Template:f,Loader:c,FileSystemLoader:s.FileSystemLoader,PrecompiledLoader:s.PrecompiledLoader,WebLoader:s.WebLoader,compiler:h,parser:l,lexer:v,runtime:d,lib:u,nodes:p,installJinjaCompat:y,configure:w,reset:function(){i=void 0},compile:function(n,t,r,u){return i||w(),new f(n,t,r,u)},render:function(n,t,r){return i||w(),i.render(n,t,r)},renderString:function(n,t,r){return i||w(),i.renderString(n,t,r)},precompile:a?a.precompile:void 0,precompileString:a?a.precompileString:void 0}},function(n,t,r){"use strict";function i(n,t){n.prototype.__proto__=t&&t.prototype,n.__proto__=t}var u=r(8),e=r(11),o=r(1),f=r(0),c=r(12),s=r(3),a=s.FileSystemLoader,h=s.WebLoader,l=s.PrecompiledLoader,v=r(13),d=r(14),p=r(5),y=r(2),w=y.handleError,b=y.Frame,m=r(15);function g(n,t,r){u(function(){n(t,r)})}var j={type:"code",obj:{root:function(n,t,r,i,u){try{u(null,"")}catch(n){u(w(n,null,null))}}}},E=function(n){function t(){return n.apply(this,arguments)||this}var r=t.prototype;return r.init=function(n,t){var r=this;t=this.opts=t||{},this.opts.dev=!!t.dev,this.opts.autoescape=null==t.autoescape||t.autoescape,this.opts.throwOnUndefined=!!t.throwOnUndefined,this.opts.trimBlocks=!!t.trimBlocks,this.opts.lstripBlocks=!!t.lstripBlocks,this.loaders=[],n?this.loaders=o.isArray(n)?n:[n]:a?this.loaders=[new a("views")]:h&&(this.loaders=[new h("/views")]),"undefined"!=typeof window&&window.nunjucksPrecompiled&&this.loaders.unshift(new l(window.nunjucksPrecompiled)),this.initCache(),this.globals=d(),this.filters={},this.tests={},this.asyncFilters=[],this.extensions={},this.extensionsList=[],o.r(c).forEach(function(n){var t=n[0],i=n[1];return r.addFilter(t,i)}),o.r(v).forEach(function(n){var t=n[0],i=n[1];return r.addTest(t,i)})},r.initCache=function(){this.loaders.forEach(function(n){n.cache={},"function"==typeof n.on&&n.on("update",function(t){n.cache[t]=null})})},r.addExtension=function(n,t){return t.__name=n,this.extensions[n]=t,this.extensionsList.push(t),this},r.removeExtension=function(n){var t=this.getExtension(n);t&&(this.extensionsList=o.without(this.extensionsList,t),delete this.extensions[n])},r.getExtension=function(n){return this.extensions[n]},r.hasExtension=function(n){return!!this.extensions[n]},r.addGlobal=function(n,t){return this.globals[n]=t,this},r.getGlobal=function(n){if(void 0===this.globals[n])throw Error("global not found: "+n);return this.globals[n]},r.addFilter=function(n,t,r){var i=t;return r&&this.asyncFilters.push(n),this.filters[n]=i,this},r.getFilter=function(n){if(!this.filters[n])throw Error("filter not found: "+n);return this.filters[n]},r.addTest=function(n,t){return this.tests[n]=t,this},r.getTest=function(n){if(!this.tests[n])throw Error("test not found: "+n);return this.tests[n]},r.resolveTemplate=function(n,t,r){return!(!n.isRelative||!t)&&n.isRelative(r)&&n.resolve?n.resolve(t,r):r},r.getTemplate=function(n,t,r,i,u){var e,f=this,c=this,s=null;if(n&&n.raw&&(n=n.raw),o.isFunction(r)&&(u=r,r=null,t=t||!1),o.isFunction(t)&&(u=t,t=!1),n instanceof O)s=n;else{if("string"!=typeof n)throw Error("template names must be a string: "+n);for(var a=0;a<this.loaders.length;a++){var h=this.loaders[a];if(s=h.cache[this.resolveTemplate(h,r,n)])break}}if(s)return t&&s.compile(),u?void u(null,s):s;return o.asyncIter(this.loaders,function(t,i,u,e){function o(n,r){n?e(n):r?(r.loader=t,e(null,r)):u()}n=c.resolveTemplate(t,r,n),t.async?t.getSource(n,o):o(null,t.getSource(n))},function(r,o){if(o||r||i||(r=Error("template not found: "+n)),r){if(u)return void u(r);throw r}var c;o?(c=new O(o.src,f,o.path,t),o.noCache||(o.loader.cache[n]=c)):c=new O(j,f,"",t),u?u(null,c):e=c}),e},r.express=function(n){return m(this,n)},r.render=function(n,t,r){o.isFunction(t)&&(r=t,t=null);var i=null;return this.getTemplate(n,function(n,u){if(n&&r)g(r,n);else{if(n)throw n;i=u.render(t,r)}}),i},r.renderString=function(n,t,r,i){return o.isFunction(r)&&(i=r,r={}),new O(n,this,(r=r||{}).path).render(t,i)},r.waterfall=function(n,t,r){return e(n,t,r)},i(t,n),t}(p),k=function(n){function t(){return n.apply(this,arguments)||this}var r=t.prototype;return r.init=function(n,t,r){var i=this;this.env=r||new E,this.ctx=o.extend({},n),this.blocks={},this.exported=[],o.keys(t).forEach(function(n){i.addBlock(n,t[n])})},r.lookup=function(n){return n in this.env.globals&&!(n in this.ctx)?this.env.globals[n]:this.ctx[n]},r.setVariable=function(n,t){this.ctx[n]=t},r.getVariables=function(){return this.ctx},r.addBlock=function(n,t){return this.blocks[n]=this.blocks[n]||[],this.blocks[n].push(t),this},r.getBlock=function(n){if(!this.blocks[n])throw Error('unknown block "'+n+'"');return this.blocks[n][0]},r.getSuper=function(n,t,r,i,u,e){var f=o.indexOf(this.blocks[t]||[],r),c=this.blocks[t][f+1];if(-1===f||!c)throw Error('no super block available for "'+t+'"');c(n,this,i,u,e)},r.addExport=function(n){this.exported.push(n)},r.getExported=function(){var n=this,t={};return this.exported.forEach(function(r){t[r]=n.ctx[r]}),t},i(t,n),t}(p),O=function(n){function t(){return n.apply(this,arguments)||this}var r=t.prototype;return r.init=function(n,t,r,i){if(this.env=t||new E,o.isObject(n))switch(n.type){case"code":this.tmplProps=n.obj;break;case"string":this.tmplStr=n.obj;break;default:throw Error("Unexpected template object type "+n.type+"; expected 'code', or 'string'")}else{if(!o.isString(n))throw Error("src must be a string or an object describing the source");this.tmplStr=n}if(this.path=r,i)try{this.a()}catch(n){throw o.t(this.path,this.env.opts.dev,n)}else this.compiled=!1},r.render=function(n,t,r){var i=this;"function"==typeof n?(r=n,n={}):"function"==typeof t&&(r=t,t=null);var u=!t;try{this.compile()}catch(n){var e=o.t(this.path,this.env.opts.dev,n);if(r)return g(r,e);throw e}var f=new k(n||{},this.blocks,this.env),c=t?t.push(!0):new b;c.topLevel=!0;var s=null,a=!1;return this.rootRenderFunc(this.env,f,c,y,function(n,t){if(!a)if(n&&(n=o.t(i.path,i.env.opts.dev,n),a=!0),r)u?g(r,n,t):r(n,t);else{if(n)throw n;s=t}}),s},r.getExported=function(n,t,r){"function"==typeof n&&(r=n,n={}),"function"==typeof t&&(r=t,t=null);try{this.compile()}catch(n){if(r)return r(n);throw n}var i=t?t.push():new b;i.topLevel=!0;var u=new k(n||{},this.blocks,this.env);this.rootRenderFunc(this.env,u,i,y,function(n){n?r(n,null):r(null,u.getExported())})},r.compile=function(){this.compiled||this.a()},r.a=function(){var n;if(this.tmplProps)n=this.tmplProps;else{var t=f.compile(this.tmplStr,this.env.asyncFilters,this.env.extensionsList,this.path,this.env.opts);n=Function(t)()}this.blocks=this.h(n),this.rootRenderFunc=n.root,this.compiled=!0},r.h=function(n){var t={};return o.keys(n).forEach(function(r){"b_"===r.slice(0,2)&&(t[r.slice(2)]=n[r])}),t},i(t,n),t}(p);n.exports={Environment:E,Template:O}},function(n,t,r){"use strict";var i=r(9),u=[],e=[],o=i.makeRequestCallFromTimer(function(){if(e.length)throw e.shift()});function f(n){var t;(t=u.length?u.pop():new c).task=n,i(t)}function c(){this.task=null}n.exports=f,c.prototype.call=function(){try{this.task.call()}catch(n){f.onerror?f.onerror(n):(e.push(n),o())}finally{this.task=null,u[u.length]=this}}},function(n,t,r){"use strict";!function(t){function r(n){u.length||(i(),!0),u[u.length]=n}n.exports=r;var i,u=[],e=0,o=1024;function f(){for(;e<u.length;){var n=e;if(e+=1,u[n].call(),e>o){for(var t=0,r=u.length-e;t<r;t++)u[t]=u[t+e];u.length-=e,e=0}}u.length=0,e=0,!1}var c,s,a,h=void 0!==t?t:self,l=h.MutationObserver||h.WebKitMutationObserver;function v(n){return function(){var t=setTimeout(i,0),r=setInterval(i,50);function i(){clearTimeout(t),clearInterval(r),n()}}}"function"==typeof l?(c=1,s=new l(f),a=document.createTextNode(""),s.observe(a,{characterData:!0}),i=function(){c=-c,a.data=c}):i=v(f),r.requestFlush=i,r.makeRequestCallFromTimer=v}(r(10))},function(n,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(n){"object"==typeof window&&(r=window)}n.exports=r},function(n,t,r){var i;!function(r){"use strict";var u=function(){var n=Array.prototype.slice.call(arguments);"function"==typeof n[0]&&n[0].apply(null,n.splice(1))},e=function(n){"function"==typeof setImmediate?setImmediate(n):"undefined"!=typeof process&&process.nextTick?process.nextTick(n):setTimeout(n,0)},o=Array.isArray||function(n){return"[object Array]"===Object.prototype.toString.call(n)},f=function(n,t,r){var i=r?e:u;if(t=t||function(){},!o(n))return t(Error("First argument to waterfall must be an array of functions"));if(!n.length)return t();var f=function(n){return function(r){if(r)t.apply(null,arguments),t=function(){};else{var u=Array.prototype.slice.call(arguments,1),e=n.next();e?u.push(f(e)):u.push(t),i(function(){n.apply(null,u)})}}};f(function(n){var t=function(r){var i=function(){return n.length&&n[r].apply(null,arguments),i.next()};return i.next=function(){return r<n.length-1?t(r+1):null},i};return t(0)}(n))()};void 0===(i=function(){return f}.apply(t,[]))||(n.exports=i)}()},function(n,t,r){"use strict";var i=r(1),u=r(2),e=n.exports={};function o(n,t){return null===n||void 0===n||!1===n?t:n}function f(n){return n!=n}function c(n){var t=(n=o(n,"")).toLowerCase();return u.copySafeness(n,t.charAt(0).toUpperCase()+t.slice(1))}function s(n){if(i.isString(n))return n.split("");if(i.isObject(n))return i.r(n||{}).map(function(n){return{key:n[0],value:n[1]}});if(i.isArray(n))return n;throw new i.TemplateError("list filter: type not iterable")}function a(n){return u.copySafeness(n,n.replace(/^\s*|\s*$/g,""))}e.abs=Math.abs,e.batch=function(n,t,r){var i,u=[],e=[];for(i=0;i<n.length;i++)i%t==0&&e.length&&(u.push(e),e=[]),e.push(n[i]);if(e.length){if(r)for(i=e.length;i<t;i++)e.push(r);u.push(e)}return u},e.capitalize=c,e.center=function(n,t){if(n=o(n,""),t=t||80,n.length>=t)return n;var r=t-n.length,e=i.repeat(" ",r/2-r%2),f=i.repeat(" ",r/2);return u.copySafeness(n,e+n+f)},e.default=function(n,t,r){return r?n||t:void 0!==n?n:t},e.dictsort=function(n,t,r){if(!i.isObject(n))throw new i.TemplateError("dictsort filter: val must be an object");var u,e=[];for(var o in n)e.push([o,n[o]]);if(void 0===r||"key"===r)u=0;else{if("value"!==r)throw new i.TemplateError("dictsort filter: You can only sort by either key or value");u=1}return e.sort(function(n,r){var e=n[u],o=r[u];return t||(i.isString(e)&&(e=e.toUpperCase()),i.isString(o)&&(o=o.toUpperCase())),e>o?1:e===o?0:-1}),e},e.dump=function(n,t){return JSON.stringify(n,null,t)},e.escape=function(n){return n instanceof u.SafeString?n:(n=null===n||void 0===n?"":n,u.markSafe(i.escape(n.toString())))},e.safe=function(n){return n instanceof u.SafeString?n:(n=null===n||void 0===n?"":n,u.markSafe(n.toString()))},e.first=function(n){return n[0]},e.forceescape=function(n){return n=null===n||void 0===n?"":n,u.markSafe(i.escape(n.toString()))},e.groupby=function(n,t){return i.groupBy(n,t)},e.indent=function(n,t,r){if(""===(n=o(n,"")))return"";t=t||4;var e=n.split("\n"),f=i.repeat(" ",t),c=e.map(function(n,t){return 0!==t||r?""+f+n+"\n":n+"\n"}).join("");return u.copySafeness(n,c)},e.join=function(n,t,r){return t=t||"",r&&(n=i.map(n,function(n){return n[r]})),n.join(t)},e.last=function(n){return n[n.length-1]},e.length=function(n){var t=o(n,"");return void 0!==t?"function"==typeof Map&&t instanceof Map||"function"==typeof Set&&t instanceof Set?t.size:!i.isObject(t)||t instanceof u.SafeString?t.length:i.keys(t).length:0},e.list=s,e.lower=function(n){return(n=o(n,"")).toLowerCase()},e.nl2br=function(n){return null===n||void 0===n?"":u.copySafeness(n,n.replace(/\r\n|\n/g,"<br />\n"))},e.random=function(n){return n[Math.floor(Math.random()*n.length)]},e.rejectattr=function(n,t){return n.filter(function(n){return!n[t]})},e.selectattr=function(n,t){return n.filter(function(n){return!!n[t]})},e.replace=function(n,t,r,i){var e=n;if(t instanceof RegExp)return n.replace(t,r);void 0===i&&(i=-1);var o="";if("number"==typeof t)t=""+t;else if("string"!=typeof t)return n;if("number"==typeof n&&(n=""+n),"string"!=typeof n&&!(n instanceof u.SafeString))return n;if(""===t)return o=r+n.split("").join(r)+r,u.copySafeness(n,o);var f=n.indexOf(t);if(0===i||-1===f)return n;for(var c=0,s=0;f>-1&&(-1===i||s<i);)o+=n.substring(c,f)+r,c=f+t.length,s++,f=n.indexOf(t,c);return c<n.length&&(o+=n.substring(c)),u.copySafeness(e,o)},e.reverse=function(n){var t;return(t=i.isString(n)?s(n):i.map(n,function(n){return n})).reverse(),i.isString(n)?u.copySafeness(n,t.join("")):t},e.round=function(n,t,r){var i=Math.pow(10,t=t||0);return("ceil"===r?Math.ceil:"floor"===r?Math.floor:Math.round)(n*i)/i},e.slice=function(n,t,r){for(var i=Math.floor(n.length/t),u=n.length%t,e=[],o=0,f=0;f<t;f++){var c=o+f*i;f<u&&o++;var s=o+(f+1)*i,a=n.slice(c,s);r&&f>=u&&a.push(r),e.push(a)}return e},e.sum=function(n,t,r){return void 0===r&&(r=0),t&&(n=i.map(n,function(n){return n[t]})),r+n.reduce(function(n,t){return n+t},0)},e.sort=u.makeMacro(["value","reverse","case_sensitive","attribute"],[],function(n,t,r,u){var e=i.map(n,function(n){return n});return e.sort(function(n,e){var o=u?n[u]:n,f=u?e[u]:e;return!r&&i.isString(o)&&i.isString(f)&&(o=o.toLowerCase(),f=f.toLowerCase()),o<f?t?1:-1:o>f?t?-1:1:0}),e}),e.string=function(n){return u.copySafeness(n,n)},e.striptags=function(n,t){var r=a((n=o(n,"")).replace(/<\/?([a-z][a-z0-9]*)\b[^>]*>|<!--[\s\S]*?-->/gi,"")),i="";return i=t?r.replace(/^ +| +$/gm,"").replace(/ +/g," ").replace(/(\r\n)/g,"\n").replace(/\n\n\n+/g,"\n\n"):r.replace(/\s+/gi," "),u.copySafeness(n,i)},e.title=function(n){var t=(n=o(n,"")).split(" ").map(function(n){return c(n)});return u.copySafeness(n,t.join(" "))},e.trim=a,e.truncate=function(n,t,r,i){var e=n;if(n=o(n,""),t=t||255,n.length<=t)return n;if(r)n=n.substring(0,t);else{var f=n.lastIndexOf(" ",t);-1===f&&(f=t),n=n.substring(0,f)}return n+=void 0!==i&&null!==i?i:"...",u.copySafeness(e,n)},e.upper=function(n){return(n=o(n,"")).toUpperCase()},e.urlencode=function(n){var t=encodeURIComponent;return i.isString(n)?t(n):(i.isArray(n)?n:i.r(n)).map(function(n){var r=n[0],i=n[1];return t(r)+"="+t(i)}).join("&")};var h=/^(?:\(|<|&lt;)?(.*?)(?:\.|,|\)|\n|&gt;)?$/,l=/^[\w.!#$%&'*+\-\/=?\^`{|}~]+@[a-z\d\-]+(\.[a-z\d\-]+)+$/i,v=/^https?:\/\/.*$/,d=/^www\./,p=/\.(?:org|net|com)(?:\:|\/|$)/;e.urlize=function(n,t,r){f(t)&&(t=1/0);var i=!0===r?' rel="nofollow"':"";return n.split(/(\s+)/).filter(function(n){return n&&n.length}).map(function(n){var r=n.match(h),u=r?r[1]:n,e=u.substr(0,t);return v.test(u)?'<a href="'+u+'"'+i+">"+e+"</a>":d.test(u)?'<a href="http://'+u+'"'+i+">"+e+"</a>":l.test(u)?'<a href="mailto:'+u+'">'+u+"</a>":p.test(u)?'<a href="http://'+u+'"'+i+">"+e+"</a>":n}).join("")},e.wordcount=function(n){var t=(n=o(n,""))?n.match(/\w+/g):null;return t?t.length:null},e.float=function(n,t){var r=parseFloat(n);return f(r)?t:r},e.int=function(n,t){var r=parseInt(n,10);return f(r)?t:r},e.d=e.default,e.e=e.escape},function(n,t,r){"use strict";var i=r(2).SafeString;t.callable=function(n){return"function"==typeof n},t.defined=function(n){return void 0!==n},t.divisibleby=function(n,t){return n%t==0},t.escaped=function(n){return n instanceof i},t.equalto=function(n,t){return n===t},t.eq=t.equalto,t.sameas=t.equalto,t.even=function(n){return n%2==0},t.falsy=function(n){return!n},t.ge=function(n,t){return n>=t},t.greaterthan=function(n,t){return n>t},t.gt=t.greaterthan,t.le=function(n,t){return n<=t},t.lessthan=function(n,t){return n<t},t.lt=t.lessthan,t.lower=function(n){return n.toLowerCase()===n},t.ne=function(n,t){return n!==t},t.null=function(n){return null===n},t.number=function(n){return"number"==typeof n},t.odd=function(n){return n%2==1},t.string=function(n){return"string"==typeof n},t.truthy=function(n){return!!n},t.undefined=function(n){return void 0===n},t.upper=function(n){return n.toUpperCase()===n},t.iterable=function(n){return"undefined"!=typeof Symbol?!!n[Symbol.iterator]:Array.isArray(n)||"string"==typeof n},t.mapping=function(n){var t=null!==n&&void 0!==n&&"object"==typeof n&&!Array.isArray(n);return Set?t&&!(n instanceof Set):t}},function(n,t,r){"use strict";n.exports=function(){return{range:function(n,t,r){void 0===t?(t=n,n=0,r=1):r||(r=1);var i=[];if(r>0)for(var u=n;u<t;u+=r)i.push(u);else for(var e=n;e>t;e+=r)i.push(e);return i},cycler:function(){return n=Array.prototype.slice.call(arguments),t=-1,{current:null,reset:function(){t=-1,this.current=null},next:function(){return++t>=n.length&&(t=0),this.current=n[t],this.current}};var n,t},joiner:function(n){return function(n){n=n||",";var t=!0;return function(){var r=t?"":n;return t=!1,r}}(n)}}}},function(n,t,r){"use strict";var i=r(0);n.exports=function(n,t){function r(n,t){if(this.name=n,this.path=n,this.defaultEngine=t.defaultEngine,this.ext=i.extname(n),!this.ext&&!this.defaultEngine)throw Error("No default engine was specified and no extension was provided.");this.ext||(this.name+=this.ext=("."!==this.defaultEngine[0]?".":"")+this.defaultEngine)}return r.prototype.render=function(t,r){n.render(this.name,t,r)},t.set("view",r),t.set("nunjucksEnv",n),n}},function(n,t,r){"use strict";n.exports=function(){var n,t,r=this.runtime,i=this.lib,u=this.compiler.Compiler,e=this.parser.Parser,o=(this.nodes,this.lexer,r.contextOrFrameLookup),f=r.memberLookup;function c(n,t){return Object.prototype.hasOwnProperty.call(n,t)}u&&(n=u.prototype.assertType),e&&(t=e.prototype.parseAggregate),r.contextOrFrameLookup=function(n,t,r){var i=o.apply(this,arguments);if(void 0!==i)return i;switch(r){case"True":return!0;case"False":return!1;case"None":return null;default:return}};var s={pop:function(n){if(void 0===n)return this.pop();if(n>=this.length||n<0)throw Error("KeyError");return this.splice(n,1)},append:function(n){return this.push(n)},remove:function(n){for(var t=0;t<this.length;t++)if(this[t]===n)return this.splice(t,1);throw Error("ValueError")},count:function(n){for(var t=0,r=0;r<this.length;r++)this[r]===n&&t++;return t},index:function(n){var t;if(-1===(t=this.indexOf(n)))throw Error("ValueError");return t},find:function(n){return this.indexOf(n)},insert:function(n,t){return this.splice(n,0,t)}},a={items:function(){return i.r(this)},values:function(){return i.u(this)},keys:function(){return i.keys(this)},get:function(n,t){var r=this[n];return void 0===r&&(r=t),r},has_key:function(n){return c(this,n)},pop:function(n,t){var r=this[n];if(void 0===r&&void 0!==t)r=t;else{if(void 0===r)throw Error("KeyError");delete this[n]}return r},popitem:function(){var n=i.keys(this);if(!n.length)throw Error("KeyError");var t=n[0],r=this[t];return delete this[t],[t,r]},setdefault:function(n,t){return void 0===t&&(t=null),n in this||(this[n]=t),this[n]},update:function(n){return i.f(this,n),null}};return a.iteritems=a.items,a.itervalues=a.values,a.iterkeys=a.keys,r.memberLookup=function(n,t,u){return 4===arguments.length?function(n,t,i,u){n=n||[],null===t&&(t=u<0?n.length-1:0),null===i?i=u<0?-1:n.length:i<0&&(i+=n.length),t<0&&(t+=n.length);for(var e=[],o=t;!(o<0||o>n.length||u>0&&o>=i||u<0&&o<=i);o+=u)e.push(r.memberLookup(n,o));return e}.apply(this,arguments):(n=n||{},i.isArray(n)&&c(s,t)?s[t].bind(n):i.isObject(n)&&c(a,t)?a[t].bind(n):f.apply(this,arguments))},function(){r.contextOrFrameLookup=o,r.memberLookup=f,u&&(u.prototype.assertType=n),e&&(e.prototype.parseAggregate=t)}}}])});
//# sourceMappingURL=nunjucks-slim.min.js.map
Changelog
=========
3.1.3 (May 19 2018)
-------------------
* Add `forceescape` filter. Fixes [#782](https://github.com/mozilla/nunjucks/issues/782)
* Fix regression that prevented template errors from reporting line and column number.
Fixes [#1087](https://github.com/mozilla/nunjucks/issues/1087) and
[#1095](https://github.com/mozilla/nunjucks/issues/1095).
* Fix "Invalid type: Is" error for `{% if value is defined %}`. Fixes
[#1110](https://github.com/mozilla/nunjucks/issues/1110)
* Formally drop support for node v4 (the upgrade to babel 7 in 3.1.0 made the
build process incompatible with node < 6.9.0).
3.1.2 (Feb 23 2018)

@@ -6,0 +20,0 @@ -------------------

@@ -12,3 +12,4 @@ # Contributing

* Aim for templating feature parity with Twig, but only when not conflicting with Jinja2 parity.
* Works in Node LTS 4, 6, and >= 8.
* Works in all node releases that are
[actively maintained by the Node Foundation](https://github.com/nodejs/Release#release-schedule)
* Works in all modern browsers (with [ES5 support](http://kangax.github.io/compat-table/es5/)).

@@ -15,0 +16,0 @@ * Works in IE8 with [es5-shim](https://github.com/es-shims/es5-shim).

{
"name": "nunjucks",
"description": "A powerful templating engine with inheritance, asynchronous control, and more (jinja2 inspired)",
"version": "3.1.2",
"version": "3.1.3",
"author": "James Long <longster@gmail.com>",

@@ -60,3 +60,3 @@ "dependencies": {

"optionalDependencies": {
"chokidar": "^1.6.0"
"chokidar": "^2.0.0"
},

@@ -67,3 +67,3 @@ "_moduleAliases": {

"engines": {
"node": "*"
"node": ">= 6.9.0 <= 11.0.0-0"
},

@@ -70,0 +70,0 @@ "scripts": {

'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -35,4 +35,2 @@ var parser = require('./parser');

function (_Obj) {
_inheritsLoose(Compiler, _Obj);
function Compiler() {

@@ -201,3 +199,3 @@ return _Obj.apply(this, arguments) || this;

// not.
this.assertType(node, nodes.Literal, nodes.Symbol, nodes.Group, nodes.Array, nodes.Dict, nodes.FunCall, nodes.Caller, nodes.Filter, nodes.LookupVal, nodes.Compare, nodes.InlineIf, nodes.In, nodes.And, nodes.Or, nodes.Not, nodes.Add, nodes.Concat, nodes.Sub, nodes.Mul, nodes.Div, nodes.FloorDiv, nodes.Mod, nodes.Pow, nodes.Neg, nodes.Pos, nodes.Compare, nodes.NodeList);
this.assertType(node, nodes.Literal, nodes.Symbol, nodes.Group, nodes.Array, nodes.Dict, nodes.FunCall, nodes.Caller, nodes.Filter, nodes.LookupVal, nodes.Compare, nodes.InlineIf, nodes.In, nodes.Is, nodes.And, nodes.Or, nodes.Not, nodes.Add, nodes.Concat, nodes.Sub, nodes.Mul, nodes.Div, nodes.FloorDiv, nodes.Mod, nodes.Pow, nodes.Neg, nodes.Pos, nodes.Compare, nodes.NodeList);
this.compile(node, frame);

@@ -1426,2 +1424,4 @@ };

_inheritsLoose(Compiler, _Obj);
return Compiler;

@@ -1428,0 +1428,0 @@ }(Obj);

'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -61,4 +61,2 @@ var asap = require('asap');

function (_Obj) {
_inheritsLoose(Environment, _Obj);
function Environment() {

@@ -372,2 +370,4 @@ return _Obj.apply(this, arguments) || this;

_inheritsLoose(Environment, _Obj);
return Environment;

@@ -379,4 +379,2 @@ }(Obj);

function (_Obj2) {
_inheritsLoose(Context, _Obj2);
function Context() {

@@ -460,2 +458,4 @@ return _Obj2.apply(this, arguments) || this;

_inheritsLoose(Context, _Obj2);
return Context;

@@ -467,4 +467,2 @@ }(Obj);

function (_Obj3) {
_inheritsLoose(Template, _Obj3);
function Template() {

@@ -642,2 +640,4 @@ return _Obj3.apply(this, arguments) || this;

_inheritsLoose(Template, _Obj3);
return Template;

@@ -644,0 +644,0 @@ }(Obj);

@@ -0,1 +1,3 @@

"use strict";
var path = require('path');

@@ -2,0 +4,0 @@

@@ -7,3 +7,3 @@ 'use strict';

var exports = module.exports = {};
var _exports = module.exports = {};

@@ -18,3 +18,3 @@ function normalize(value, defaultValue) {

exports.abs = Math.abs;
_exports.abs = Math.abs;

@@ -52,3 +52,3 @@ function isNaN(num) {

exports.batch = batch;
_exports.batch = batch;

@@ -61,3 +61,3 @@ function capitalize(str) {

exports.capitalize = capitalize;
_exports.capitalize = capitalize;

@@ -78,3 +78,3 @@ function center(str, width) {

exports.center = center;
_exports.center = center;

@@ -90,3 +90,3 @@ function default_(val, def, bool) {

exports['default'] = default_; // eslint-disable-line dot-notation
_exports['default'] = default_; // eslint-disable-line dot-notation

@@ -134,3 +134,3 @@ function dictsort(val, caseSensitive, by) {

exports.dictsort = dictsort;
_exports.dictsort = dictsort;

@@ -141,3 +141,3 @@ function dump(obj, spaces) {

exports.dump = dump;
_exports.dump = dump;

@@ -153,3 +153,3 @@ function escape(str) {

exports.escape = escape;
_exports.escape = escape;

@@ -165,3 +165,3 @@ function safe(str) {

exports.safe = safe;
_exports.safe = safe;

@@ -172,4 +172,11 @@ function first(arr) {

exports.first = first;
_exports.first = first;
function forceescape(str) {
str = str === null || str === undefined ? '' : str;
return r.markSafe(lib.escape(str.toString()));
}
_exports.forceescape = forceescape;
function groupby(arr, attr) {

@@ -179,3 +186,3 @@ return lib.groupBy(arr, attr);

exports.groupby = groupby;
_exports.groupby = groupby;

@@ -199,3 +206,3 @@ function indent(str, width, indentfirst) {

exports.indent = indent;
_exports.indent = indent;

@@ -214,3 +221,3 @@ function join(arr, del, attr) {

exports.join = join;
_exports.join = join;

@@ -221,3 +228,3 @@ function last(arr) {

exports.last = last;
_exports.last = last;

@@ -244,3 +251,3 @@ function lengthFilter(val) {

exports.length = lengthFilter;
_exports.length = lengthFilter;

@@ -266,3 +273,3 @@ function list(val) {

exports.list = list;
_exports.list = list;

@@ -274,3 +281,3 @@ function lower(str) {

exports.lower = lower;
_exports.lower = lower;

@@ -285,3 +292,3 @@ function nl2br(str) {

exports.nl2br = nl2br;
_exports.nl2br = nl2br;

@@ -292,3 +299,3 @@ function random(arr) {

exports.random = random;
_exports.random = random;

@@ -301,3 +308,3 @@ function rejectattr(arr, attr) {

exports.rejectattr = rejectattr;
_exports.rejectattr = rejectattr;

@@ -310,3 +317,3 @@ function selectattr(arr, attr) {

exports.selectattr = selectattr;
_exports.selectattr = selectattr;

@@ -383,3 +390,3 @@ function replace(str, old, new_, maxCount) {

exports.replace = replace;
_exports.replace = replace;

@@ -407,3 +414,3 @@ function reverse(val) {

exports.reverse = reverse;
_exports.reverse = reverse;

@@ -426,3 +433,3 @@ function round(val, precision, method) {

exports.round = round;
_exports.round = round;

@@ -455,3 +462,3 @@ function slice(arr, slices, fillWith) {

exports.slice = slice;
_exports.slice = slice;

@@ -474,4 +481,4 @@ function sum(arr, attr, start) {

exports.sum = sum;
exports.sort = r.makeMacro(['value', 'reverse', 'case_sensitive', 'attribute'], [], function (arr, reversed, caseSens, attr) {
_exports.sum = sum;
_exports.sort = r.makeMacro(['value', 'reverse', 'case_sensitive', 'attribute'], [], function (arr, reversed, caseSens, attr) {
// Copy it

@@ -505,3 +512,3 @@ var array = lib.map(arr, function (v) {

exports.string = string;
_exports.string = string;

@@ -526,3 +533,3 @@ function striptags(input, preserveLinebreaks) {

exports.striptags = striptags;
_exports.striptags = striptags;

@@ -537,3 +544,3 @@ function title(str) {

exports.title = title;
_exports.title = title;

@@ -544,3 +551,3 @@ function trim(str) {

exports.trim = trim;
_exports.trim = trim;

@@ -572,3 +579,3 @@ function truncate(input, length, killwords, end) {

exports.truncate = truncate;
_exports.truncate = truncate;

@@ -580,3 +587,3 @@ function upper(str) {

exports.upper = upper;
_exports.upper = upper;

@@ -598,3 +605,3 @@ function urlencode(obj) {

exports.urlencode = urlencode; // For the jinja regexp, see
_exports.urlencode = urlencode; // For the jinja regexp, see
// https://github.com/mitsuhiko/jinja2/blob/f15b814dcba6aa12bc74d1f7d0c881d55f7126be/jinja2/utils.py#L20-L23

@@ -648,3 +655,3 @@

exports.urlize = urlize;
_exports.urlize = urlize;

@@ -657,3 +664,3 @@ function wordcount(str) {

exports.wordcount = wordcount;
_exports.wordcount = wordcount;

@@ -665,3 +672,3 @@ function float(val, def) {

exports.float = float;
_exports.float = float;

@@ -673,5 +680,5 @@ function int(val, def) {

exports.int = int; // Aliases
_exports.int = int; // Aliases
exports.d = exports.default;
exports.e = exports.escape;
_exports.d = _exports.default;
_exports.e = _exports.escape;

@@ -0,1 +1,3 @@

"use strict";
function installCompat() {

@@ -2,0 +4,0 @@ 'use strict';

@@ -13,4 +13,5 @@ 'use strict';

var escapeRegex = /[&"'<>]/g;
var exports = module.exports = {};
var _exports = module.exports = {};
function hasOwnProp(obj, k) {

@@ -20,3 +21,3 @@ return ObjProto.hasOwnProperty.call(obj, k);

exports.hasOwnProp = hasOwnProp;
_exports.hasOwnProp = hasOwnProp;

@@ -30,3 +31,3 @@ function lookupEscape(ch) {

// not one of ours, cast it
err = new exports.TemplateError(err);
err = new _exports.TemplateError(err);
}

@@ -45,7 +46,5 @@

exports._prettifyError = _prettifyError;
_exports._prettifyError = _prettifyError;
function TemplateError(message, lineno, colno) {
var _this = this;
var err;

@@ -103,3 +102,3 @@ var cause;

get: function get() {
return getStack.call(_this);
return getStack.call(err);
}

@@ -114,11 +113,11 @@ });

err.Update = function (path) {
err.Update = function Update(path) {
var msg = '(' + (path || 'unknown path') + ')'; // only show lineno + colno next to path of template
// where error occurred
if (_this.firstUpdate) {
if (_this.lineno && _this.colno) {
msg += " [Line " + _this.lineno + ", Column " + _this.colno + "]";
} else if (_this.lineno) {
msg += " [Line " + _this.lineno + "]";
if (this.firstUpdate) {
if (this.lineno && this.colno) {
msg += " [Line " + this.lineno + ", Column " + this.colno + "]";
} else if (this.lineno) {
msg += " [Line " + this.lineno + "]";
}

@@ -129,9 +128,9 @@ }

if (_this.firstUpdate) {
if (this.firstUpdate) {
msg += ' ';
}
_this.message = msg + (_this.message || '');
_this.firstUpdate = false;
return _this;
this.message = msg + (this.message || '');
this.firstUpdate = false;
return this;
};

@@ -152,3 +151,3 @@

exports.TemplateError = TemplateError;
_exports.TemplateError = TemplateError;

@@ -159,3 +158,3 @@ function escape(val) {

exports.escape = escape;
_exports.escape = escape;

@@ -166,3 +165,3 @@ function isFunction(obj) {

exports.isFunction = isFunction;
_exports.isFunction = isFunction;

@@ -173,3 +172,3 @@ function isArray(obj) {

exports.isArray = isArray;
_exports.isArray = isArray;

@@ -180,3 +179,3 @@ function isString(obj) {

exports.isString = isString;
_exports.isString = isString;

@@ -187,3 +186,3 @@ function isObject(obj) {

exports.isObject = isObject;
_exports.isObject = isObject;

@@ -205,3 +204,3 @@ function groupBy(obj, val) {

exports.groupBy = groupBy;
_exports.groupBy = groupBy;

@@ -212,3 +211,3 @@ function toArray(obj) {

exports.toArray = toArray;
_exports.toArray = toArray;

@@ -235,3 +234,3 @@ function without(array) {

exports.without = without;
_exports.without = without;

@@ -248,3 +247,3 @@ function repeat(char_, n) {

exports.repeat = repeat;
_exports.repeat = repeat;

@@ -265,3 +264,3 @@ function each(obj, func, context) {

exports.each = each;
_exports.each = each;

@@ -290,3 +289,3 @@ function map(obj, func) {

exports.map = map;
_exports.map = map;

@@ -309,3 +308,3 @@ function asyncIter(arr, iter, cb) {

exports.asyncIter = asyncIter;
_exports.asyncIter = asyncIter;

@@ -331,3 +330,3 @@ function asyncFor(obj, iter, cb) {

exports.asyncFor = asyncFor;
_exports.asyncFor = asyncFor;

@@ -338,3 +337,3 @@ function indexOf(arr, searchElement, fromIndex) {

exports.indexOf = indexOf;
_exports.indexOf = indexOf;

@@ -354,3 +353,3 @@ function keys_(obj) {

exports.keys = keys_;
_exports.keys = keys_;

@@ -363,3 +362,3 @@ function _entries(obj) {

exports._entries = _entries;
_exports._entries = _entries;

@@ -372,3 +371,3 @@ function _values(obj) {

exports._values = _values;
_exports._values = _values;

@@ -383,3 +382,3 @@ function extend(obj1, obj2) {

exports._assign = exports.extend = extend;
_exports._assign = _exports.extend = extend;

@@ -396,2 +395,2 @@ function inOperator(key, val) {

exports.inOperator = inOperator;
_exports.inOperator = inOperator;
'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -12,4 +12,2 @@ var path = require('path');

function (_Obj) {
_inheritsLoose(Loader, _Obj);
function Loader() {

@@ -47,3 +45,5 @@ return _Obj.apply(this, arguments) || this;

_inheritsLoose(Loader, _Obj);
return Loader;
}(Obj);

@@ -0,3 +1,5 @@

"use strict";
// This file will automatically be rewired to web-loader.js when
// building for the browser
module.exports = require('./node-loaders');
/* eslint-disable no-console */
'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -25,4 +25,2 @@ var fs = require('fs');

function (_Loader) {
_inheritsLoose(FileSystemLoader, _Loader);
function FileSystemLoader(searchPaths, opts) {

@@ -103,2 +101,4 @@ var _this;

_inheritsLoose(FileSystemLoader, _Loader);
return FileSystemLoader;

@@ -105,0 +105,0 @@ }(Loader);

@@ -7,3 +7,3 @@ 'use strict';

function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -25,4 +25,2 @@ var Obj = require('./object');

function (_Obj) {
_inheritsLoose(Node, _Obj);
function Node() {

@@ -83,2 +81,4 @@ return _Obj.apply(this, arguments) || this;

_inheritsLoose(Node, _Obj);
return Node;

@@ -91,4 +91,2 @@ }(Obj); // Abstract nodes

function (_Node) {
_inheritsLoose(Value, _Node);
function Value() {

@@ -110,2 +108,4 @@ return _Node.apply(this, arguments) || this;

_inheritsLoose(Value, _Node);
return Value;

@@ -118,4 +118,2 @@ }(Node); // Concrete nodes

function (_Node2) {
_inheritsLoose(NodeList, _Node2);
function NodeList() {

@@ -147,2 +145,4 @@ return _Node2.apply(this, arguments) || this;

_inheritsLoose(NodeList, _Node2);
return NodeList;

@@ -186,4 +186,2 @@ }(Node);

function (_Node3) {
_inheritsLoose(FromImport, _Node3);
function FromImport() {

@@ -211,2 +209,4 @@ return _Node3.apply(this, arguments) || this;

_inheritsLoose(FromImport, _Node3);
return FromImport;

@@ -213,0 +213,0 @@ }(Node);

'use strict'; // A simple class system, more documentation to come
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }

@@ -7,4 +9,2 @@

function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
var lib = require('./lib');

@@ -37,4 +37,2 @@

function (_cls) {
_inheritsLoose(subclass, _cls);
function subclass() {

@@ -51,2 +49,4 @@ return _cls.apply(this, arguments) || this;

_inheritsLoose(subclass, _cls);
return subclass;

@@ -53,0 +53,0 @@ }(cls);

'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -16,4 +16,2 @@ var lexer = require('./lexer');

function (_Obj) {
_inheritsLoose(Parser, _Obj);
function Parser() {

@@ -1243,2 +1241,4 @@ return _Obj.apply(this, arguments) || this;

_inheritsLoose(Parser, _Obj);
return Parser;

@@ -1245,0 +1245,0 @@ }(Obj); // var util = require('util');

'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -10,4 +10,2 @@ var Loader = require('./loader');

function (_Loader) {
_inheritsLoose(PrecompiledLoader, _Loader);
function PrecompiledLoader(compiledTemplates) {

@@ -37,2 +35,4 @@ var _this;

_inheritsLoose(PrecompiledLoader, _Loader);
return PrecompiledLoader;

@@ -39,0 +39,0 @@ }(Loader);

'use strict';
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
function _inheritsLoose(subClass, superClass) { subClass.prototype.__proto__ = superClass && superClass.prototype; subClass.__proto__ = superClass; }

@@ -13,4 +13,2 @@ var Loader = require('./loader');

function (_Loader) {
_inheritsLoose(WebLoader, _Loader);
function WebLoader(baseURL, opts) {

@@ -101,2 +99,4 @@ var _this;

_inheritsLoose(WebLoader, _Loader);
return WebLoader;

@@ -103,0 +103,0 @@ }(Loader);

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc