dynamictemplate
Version:
Δt - async & dynamic templating engine
1 lines • 25.4 kB
JavaScript
!function(){var t=function(e,n){var r=t.resolve(e,n||"/"),i=t.modules[r];if(!i)throw new Error("Failed to resolve module "+e+", tried "+r);var s=i._cached?i._cached:i();return s};t.paths=[],t.modules={},t.extensions=[".js",".coffee"],t._core={assert:!0,events:!0,fs:!0,path:!0,vm:!0},t.resolve=function(){return function(e,n){function r(e){if(t.modules[e])return e;for(var n=0;n<t.extensions.length;n++){var r=t.extensions[n];if(t.modules[e+r])return e+r}}function i(e){e=e.replace(/\/+$/,"");var n=e+"/package.json";if(t.modules[n]){var i=t.modules[n](),s=i.browserify;if("object"==typeof s&&s.main){var o=r(l.resolve(e,s.main));if(o)return o}else if("string"==typeof s){var o=r(l.resolve(e,s));if(o)return o}else if(i.main){var o=r(l.resolve(e,i.main));if(o)return o}}return r(e+"/index")}function s(t,e){for(var n=o(e),s=0;s<n.length;s++){var l=n[s],a=r(l+"/"+t);if(a)return a;var u=i(l+"/"+t);if(u)return u}var a=r(t);return a?a:void 0}function o(t){var e;e="/"===t?[""]:l.normalize(t).split("/");for(var n=[],r=e.length-1;r>=0;r--)if("node_modules"!==e[r]){var i=e.slice(0,r+1).join("/")+"/node_modules";n.push(i)}return n}if(n||(n="/"),t._core[e])return e;var l=t.modules.path(),a=n||".";if(e.match(/^(?:\.\.?\/|\/)/)){var u=r(l.resolve(a,e))||i(l.resolve(a,e));if(u)return u}var h=s(e,a);if(h)return h;throw new Error("Cannot find module '"+e+"'")}}(),t.alias=function(n,r){var i=t.modules.path(),s=null;try{s=t.resolve(n+"/package.json","/")}catch(o){s=t.resolve(n,"/")}for(var l=i.dirname(s),a=e(t.modules),u=0;u<a.length;u++){var h=a[u];if(h.slice(0,l.length+1)===l+"/"){var c=h.slice(l.length);t.modules[r+c]=t.modules[l+c]}else h===l&&(t.modules[r]=t.modules[l])}},t.define=function(e,n){var r=t._core[e]?"":t.modules.path().dirname(e),i=function(e){return t(e,r)};i.resolve=function(e){return t.resolve(e,r)},i.modules=t.modules;var s={exports:{}};t.modules[e]=function(){return n.call(s.exports,i,s,s.exports,r,e),t.modules[e]._cached=s.exports,s.exports}};var e=Object.keys||function(t){var e=[];for(var n in t)e.push(n);return e};"undefined"==typeof process&&(process={}),process.nextTick||(process.nextTick=function(t){setTimeout(t,0)}),process.title||(process.title="browser"),process.binding||(process.binding=function(e){if("evals"===e)return t("vm");throw new Error("No such module")}),process.cwd||(process.cwd=function(){return"."}),t.define("path",function(t,e,n){function r(t,e){for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}function i(t,e){for(var n=0,r=t.length;r>=0;r--){var i=t[r];"."==i?t.splice(r,1):".."===i?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}var s=/^(.+\/(?!$)|\/)?((?:.+?)?(\.[^.]*)?)$/;n.resolve=function(){for(var t="",e=!1,n=arguments.length;n>=-1&&!e;n--){var s=n>=0?arguments[n]:process.cwd();"string"==typeof s&&s&&(t=s+"/"+t,e="/"===s.charAt(0))}return t=i(r(t.split("/"),function(t){return!!t}),!e).join("/"),(e?"/":"")+t||"."},n.normalize=function(t){var e="/"===t.charAt(0),n="/"===t.slice(-1);return t=i(r(t.split("/"),function(t){return!!t}),!e).join("/"),t||e||(t="."),t&&n&&(t+="/"),(e?"/":"")+t},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){return t&&"string"==typeof t}).join("/"))},n.dirname=function(t){var e=s.exec(t)[1]||"",n=!1;return e?1===e.length||n&&e.length<=3&&":"===e.charAt(1)?e:e.substring(0,e.length-1):"."},n.basename=function(t,e){var n=s.exec(t)[2]||"";return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},n.extname=function(t){return s.exec(t)[3]||""}}),t.define("/dynamictemplate.js",function(t,e){!function(){var n,r,i,s;s=t("asyncxml"),r=s.Tag,n=s.Builder,i=t("./template"),e.exports={Tag:r,Builder:n,Template:i},"browser"===process.title&&function(){return null!=this.dynamictemplate?(this.dynamictemplate.Template=i,this.dynamictemplate.Builder=n,this.dynamictemplate.Tag=r):this.dynamictemplate=e.exports}.call(window)}.call(this)}),t.define("/node_modules/asyncxml/package.json",function(t,e){e.exports={name:"asyncxml",description:"async xml builder and generator",version:"0.6.0",homepage:"https://github.com/dodo/node-asyncxml",author:"dodo (https://github.com/dodo)",repository:{type:"git",url:"git://github.com/dodo/node-asyncxml.git"},main:"asyncxml.js",engines:{node:">= 0.4.x"},keywords:["async","xml","generation","stream","browser"],scripts:{test:"cake build && nodeunit test",prepublish:"cake build"},devDependencies:{"coffee-script":">= 1.1.2",muffin:">= 0.2.6",browserify:"1.6.1",scopify:">= 0.1.0","dt-stream":">= 0.3.0",nodeunit:">= 0.7.4"},licenses:[{type:"MIT",url:"http://github.com/dodo/node-asyncxml/raw/master/LICENSE"}]}}),t.define("/node_modules/asyncxml/asyncxml.js",function(t,e){e.exports=t("./lib/asyncxml")}),t.define("/node_modules/asyncxml/lib/asyncxml.js",function(t,e){!function(){var n,r,i;i=t("./xml"),r=i.Tag,n=i.Builder,this.asyncxml=e.exports={Tag:r,Builder:n}}.call(this)}),t.define("/node_modules/asyncxml/lib/xml.js",function(t,e){!function(){var n,r,i,s,o,l,a,u,h,c,p,d,m,f=[].slice,v=function(t,e){return function(){return t.apply(e,arguments)}},y={}.hasOwnProperty,g=function(t,e){function n(){this.constructor=t}for(var r in e)y.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t};i=t("events").EventEmitter,m=t("./util"),u=m.new_attrs,p=m.safe,r=["add","attr","data","text","raw","show","hide","remove","replace","close"],c=function(t,e,n,r){var i;return"object"!=typeof e?(i=[{},e,n],e=i[0],n=i[1],r=i[2]):null==e&&(e={}),null==r&&(r={}),[t,e,n,r]},l=function(t,e){var n,i,s,o,l,a;return i={},s=function(n){return null==i[n]?"function"==typeof e.on?e.on(n,i[n]=function(){return t.emit.apply(t,[n].concat(f.call(arguments)))}):void 0:void 0},a=function(){var t,e,n,i;for(i=[],e=0,n=r.length;n>e;e++)t=r[e],i.push(s(t));return i},n=function(){var t,n,s,o,l;for(l=[],s=0,o=r.length;o>s;s++)t=r[s],null!=(n=i[t])?("function"==typeof e.removeListener&&e.removeListener(t,n),l.push(i[t]=void 0)):l.push(void 0);return l},o=function(r,i){return this===e?(t.removeListener("removed",o),t.removeListener("replaced",l),e.removeListener("replaced",l),n()):r?t.once("removed",o):(e.removeListener("removed",o),t.removeListener("replaced",l),e.removeListener("replaced",l),n(),i?void 0:e.remove())},l=function(n){return this===e?(o.call(t,!1,!0),e=n,a()):(t.removeListener("removed",o),t=n),n.once("replaced",l),n.once("removed",o)},a(),e.once("removed",o),t.once("removed",o),e.once("replaced",l),t.once("replaced",l)},o=function(t,e){var n,r=this;return null==t?null!=e?e.call(this):void 0:(n=function(t,n){var i,s;return null==(i=n.builder)&&(n.builder=r.builder),null==(s=n.parent)&&(n.parent=r),n.builder.opts.pretty=r.builder.opts.pretty,n.builder.level=r.level,l(r,n),r.emit("add",r,n),r.emit("new",n),r.isempty=!1,n.closed&&"approving"!==n.closed&&"function"==typeof n.emit&&n.emit("close",n),"function"==typeof n.emit&&n.emit("added",r),null!=e?e.call(r,n):void 0},t.parent=this,null!=this.builder?this.builder.approve("new",this,t,n):n(this,t))},h=function(){var t,e,n,r,i,l,a,u,h,p,d,m,f;return u=c.apply(null,arguments),i=u[0],e=u[1],r=u[2],a=u[3],null==(h=a.level)&&(a.level=this.level+1),null==(p=a.pretty)&&(a.pretty=null!=(d=this.builder)?d.opts.pretty:void 0),a.builder=this.builder,t=null!=(m=null!=(f=this.builder)?f.Tag:void 0)?m:s,l=new t(i,e,null,a),null!=r&&(n=function(t){return t.children(r)}),o.call(this,l,n),l},d=function(){var t,e,n,r,i,s;return s=c.apply(null,arguments),n=s[0],t=s[1],e=s[2],r=s[3],i=function(){return null!=e&&this.children(e),this.end()},h.call(this,n,t,i,r)},s=function(t){function e(){this.ready=v(this.ready,this),this.remove=v(this.remove,this),this.replace=v(this.replace,this),this.add=v(this.add,this),this.toString=v(this.toString,this),this.end=v(this.end,this),this.hide=v(this.hide,this),this.show=v(this.show,this),this.root=v(this.root,this),this.up=v(this.up,this),this.write=v(this.write,this),this.raw=v(this.raw,this),this.text=v(this.text,this),this.children=v(this.children,this),this.removeAttr=v(this.removeAttr,this),this.attr=v(this.attr,this);var t,e,n,r,i;n=c.apply(null,arguments),this.name=n[0],this.attrs=n[1],t=n[2],e=n[3],this.pretty=null!=(r=e.pretty)?r:!1,this.level=null!=(i=e.level)?i:0,this.builder=e.builder,this.setMaxListeners(0),this.parent=this.builder,this.closed=!1,this.writable=!0,this.hidden=!1,this.isready=!1,this.isempty=!0,this.isselfclosing=!1,this.content="",this.$tag=d,this.tag=h,this.children(t)}return g(e,t),e.prototype.attr=function(t,e){var n,r,i,s;if("string"==typeof t){if(void 0===e)return n=null!=(s=this.builder)?s.query("attr",this,t):void 0,void 0!==n&&(this.attrs[t]=n),n;this.attrs[t]=e,this.emit("attr",this,t,e)}else for(r in t)y.call(t,r)&&(i=t[r],void 0!==i?this.attrs[r]=i:delete this.attr[t],this.emit("attr",this,r,i));return this},e.prototype.removeAttr=function(){var t,e,n,r;for(e=1<=arguments.length?f.call(arguments,0):[],n=0,r=e.length;r>n;n++)t=e[n],delete this.attrs[t],this.emit("attr",this,t,void 0);return this},e.prototype.children=function(t){return null==t?this:(this.parent?"function"==typeof t?t.call(this):this.text(t):this.once("added",function(){return this.children(t)}),this)},e.prototype.text=function(t,e){var n;return null==e&&(e={}),null==t?this.content=null!=(n=this.builder)?n.query("text",this):void 0:(e.escape&&(t=p(t)),e.append?this.content+=t:this.content=t,this.emit("text",this,t),this.isempty=!1,this)},e.prototype.raw=function(t,e){return null==e&&(e={}),this.emit("raw",this,t),this.isempty=!1,this},e.prototype.write=function(t,e){var n,r,i;return i=null!=e?e:{},r=i.escape,n=i.append,r&&(t=p(t)),t&&this.emit("data",this,""+t),(null!=n?n:!0)?this.content+=t:this.content=t,this.isempty=!1,!0},e.prototype.up=function(t){var e,n;return null==t&&(t={}),null==(n=t.end)&&(t.end=!0),e=this.parent,t.end&&this.end.apply(this,arguments),e},e.prototype.root=function(){var t,e;return null!=(t=null!=(e=this.parent)?e.root():void 0)?t:this},e.prototype.show=function(){return this.hidden=!1,this.emit("show",this),this},e.prototype.hide=function(){return this.hidden=!0,this.emit("hide",this),this},e.prototype.end=function(){var t,e=this;return this.closed?"approving"===this.closed||("removed"===this.closed?(this.emit("end"),this.writable=!1):(this.closed=!0,this.writable=!1)):(this.isempty&&(this.isempty=!1,this.isselfclosing=!0),this.closed="approving",t=function(){var t;return e.closed=!0,e.emit("close",e),e.writable=!1,t=function(){return e.isready=!0,e.emit("ready")},null!=e.builder?e.builder.approve("ready",e,t):t(),e.emit("end")},null!=this.builder?this.builder.approve("end",this,t):t(this,this)),this},e.prototype.toString=function(){return"<"+this.name+u(this.attrs)+(this.isempty?"/>":this.closed?">"+this.content+"</"+this.name+">":">"+this.content)},e.prototype.add=function(t,e){var n,r;return n=null!=(r=this.builder)?r.query("tag",this,t):void 0,null==n&&null==this.builder&&(n=t),o.call(this,n,e),this},e.prototype.replace=function(t){var e,n,r,i;return e=null!=(n=this.builder)?n.query("tag",this,t):void 0,null==e&&null==this.builder&&(e=t),this===e?this:(null==(r=e.parent)&&(e.parent=this.parent),null==(i=e.builder)&&(e.builder=this.builder),this.emit("replace",this,e),this.builder===e.builder&&(this.builder=null),this.parent=null,this.emit("replaced",e),e)},e.prototype.remove=function(t){return null==t&&(t={}),t.soft||(this.closed="removed"),this.emit("remove",this,t),this!==this.builder&&(this.builder=null),this.parent=null,this.emit("removed",t.soft),t.soft||this.removeAllListeners(),this},e.prototype.ready=function(t){return this.isready?(null!=t&&t.call(this),this):(this.once("ready",t),this)},e}(i),a=function(t,e,n){return"attr"===t?e.attrs[n]:"text"===t?e.content:"tag"===t?n:void 0},n=function(t){function e(t){var e,n,r;this.opts=null!=t?t:{},this.removeAllListeners=v(this.removeAllListeners,this),this.ready=v(this.ready,this),this.end=v(this.end,this),this.add=v(this.add,this),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.remove=this.remove.bind(this),this.replace=this.replace.bind(this),this.builder=this,this.checkers={},this.closed=!1,this.isempty=!0,this.writable=!0,null==(n=(e=this.opts).pretty)&&(e.pretty=!1),this.level=null!=(r=this.opts.level)?r:-1,this.setMaxListeners(0),this.Tag=s,this.tag=h,this.$tag=d}return g(e,t),e.prototype.root=s.prototype.root,e.prototype.show=s.prototype.show,e.prototype.hide=s.prototype.hide,e.prototype.remove=s.prototype.remove,e.prototype.replace=s.prototype.replace,e.prototype.query=a,e.prototype.toString=function(){return"[object AsyncXMLBuilder]"},e.prototype.add=function(t,e){var n;return n=this.query("tag",this,t),null==n&&(n=t),o.call(this,n,e),this},e.prototype.end=function(){return this.closed=!0,this.writable=!1,this.emit("close",this),this.emit("end"),this},e.prototype.ready=function(t){return this.closed===!0?null!=t?t.call(this):void 0:this.once("end",t)},e.prototype.removeAllListeners=function(t){return delete this.checkers,this.query=a,i.prototype.removeAllListeners.call(this,t)},e.prototype.register=function(t,e){var n,r;if("new"!==t&&"end"!==t&&"ready"!==t)throw new Error("only type 'ready', 'new' or 'end' allowed.");return null==(r=(n=this.checkers)[t])&&(n[t]=[]),this.checkers[t].push(e)},e.prototype.approve=function(t,e,n,r){var i,s,o,l,a;switch(i=null!=(o=null!=(l=this.checkers[t])?"function"==typeof l.slice?l.slice():void 0:void 0)?o:[],t){case"new":s=function(t){var n,o;return n=null!=(o=i.shift())?o:r,n(e,t,s)};break;case"ready":case"end":a=[e,n],n=a[0],r=a[1],s=function(t){var e,n;return e=null!=(n=i.shift())?n:r,e(t,s)};break;default:throw new Error("type '"+t+"' not supported.")}return s(n)},e}(i),e.exports={Tag:s,Builder:n}}.call(this)}),t.define("events",function(t,e,n){process.EventEmitter||(process.EventEmitter=function(){});var r=n.EventEmitter=process.EventEmitter,i="function"==typeof Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.toString.call(t)},s=10;r.prototype.setMaxListeners=function(t){this._events||(this._events={}),this._events.maxListeners=t},r.prototype.emit=function(t){if("error"===t&&(!this._events||!this._events.error||i(this._events.error)&&!this._events.error.length))throw arguments[1]instanceof Error?arguments[1]:new Error("Uncaught, unspecified 'error' event.");if(!this._events)return!1;var e=this._events[t];if(!e)return!1;if("function"==typeof e){switch(arguments.length){case 1:e.call(this);break;case 2:e.call(this,arguments[1]);break;case 3:e.call(this,arguments[1],arguments[2]);break;default:var n=Array.prototype.slice.call(arguments,1);e.apply(this,n)}return!0}if(i(e)){for(var n=Array.prototype.slice.call(arguments,1),r=e.slice(),s=0,o=r.length;o>s;s++)r[s].apply(this,n);return!0}return!1},r.prototype.addListener=function(t,e){if("function"!=typeof e)throw new Error("addListener only takes instances of Function");if(this._events||(this._events={}),this.emit("newListener",t,e),this._events[t])if(i(this._events[t])){if(!this._events[t].warned){var n;n=void 0!==this._events.maxListeners?this._events.maxListeners:s,n&&n>0&&this._events[t].length>n&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),console.trace())}this._events[t].push(e)}else this._events[t]=[this._events[t],e];else this._events[t]=e;return this},r.prototype.on=r.prototype.addListener,r.prototype.once=function(t,e){var n=this;return n.on(t,function r(){n.removeListener(t,r),e.apply(this,arguments)}),this},r.prototype.removeListener=function(t,e){if("function"!=typeof e)throw new Error("removeListener only takes instances of Function");if(!this._events||!this._events[t])return this;var n=this._events[t];if(i(n)){var r=n.indexOf(e);if(0>r)return this;n.splice(r,1),0==n.length&&delete this._events[t]}else this._events[t]===e&&delete this._events[t];return this},r.prototype.removeAllListeners=function(t){return t&&this._events&&this._events[t]&&(this._events[t]=null),this},r.prototype.listeners=function(t){return this._events||(this._events={}),this._events[t]||(this._events[t]=[]),i(this._events[t])||(this._events[t]=[this._events[t]]),this._events[t]}}),t.define("/node_modules/asyncxml/lib/util.js",function(t,e){!function(){var t,n,r,i,s,o;r=Array.isArray,n=function(t){var e,n;return e=t.level,n=t.pretty,n&&0!==e?(n===!0&&(n=" "),n):""},t=function(t,e){var n,r;return n=t.level,r=t.pretty,r?"\n"===(null!=e?e[(null!=e?e.length:void 0)-1]:void 0)?e:""+e+"\n":e},s=function(e,r){return(null!=e?e.pretty:void 0)?""+n(e)+t(e,r):r},i=function(t){var e,n,r;return null==t&&(t={}),n=function(){var n;n=[];for(e in t)r=t[e],null!=r?("number"!=typeof r&&(r='"'+r+'"'),n.push(""+e+"="+r)):n.push(""+e);return n}(),n.length&&n.unshift(""),n.join(" ")},o=function(t){return String(t).replace(/&(?!\w+;)/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")},e.exports={prettify:s,indent:n,new_attrs:i,safe:o}}.call(this)}),t.define("/template.js",function(t,e){!function(){var n,r,i,s,o,l,a,u,h,c,p,d=function(t,e){return function(){return t.apply(e,arguments)}},m={}.hasOwnProperty,f=function(t,e){function n(){this.constructor=t}for(var r in e)m.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t};r=t("events").EventEmitter,c=t("./schema"),u=c.schema,h=c.self_closing,l=t("./doctype").doctype,s=t("./alias").aliases,p=t("./cache"),a=p.lookup,o=p.clear,n=["new","add","show","hide","attr","text","raw","remove","replace","data","close","end"],i=function(t){function e(t,e){var r,i,o,l,c,p,m=this;null==t&&(t={}),this.hide=d(this.hide,this),this.show=d(this.show,this),this.ready=d(this.ready,this),this.end=d(this.end,this),this.remove=d(this.remove,this),this.register=d(this.register,this),"function"==typeof t&&(o=[t,{}],e=o[0],t=o[1]),t.partial&&(t.run=!1),null==(l=t.encoding)&&(t.encoding="utf-8"),null==(c=t.doctype)&&(t.doctype=!1),null==(p=t.end)&&(t.end=!0),t._schema=t.schema,i=s[t._schema]||t._schema||"xml",t.self_closing="function"==typeof h[i]?h[i](t):void 0,t.schema="function"==typeof u[i]?u[i](t).split(" "):void 0,this.xml=a(t),this.xml.template=this,r=this.xml.query,this.xml.query=function(t,e,n){var i;return"tag"===t?null!=(i=n.xml)?i:n:r.call(this,t,e,n)},t.self_closing!==!1&&this.xml.register("end",function(e,n){return e.isselfclosing?((t.self_closing===!0||t.self_closing.match(e.name))&&(e.isempty=!0),n(e)):n(e)}),n.forEach(function(t){return m.xml.on(t,m.emit.bind(m,t))}),this.run=this.run.bind(this,e,t),t.run!==!1&&process.nextTick(this.run)}return f(e,t),e.prototype.run=function(t,e,n){var r,i,o;if(o=(null!=n?n:{}).restart,!this.started||o)if(this.started=!0,e.doctype===!0&&(e.doctype=e._schema||"html"),r=s[e.doctype]||e.doctype,e.doctype&&(i="function"==typeof l[r]?l[r](e):void 0)&&(e.pretty&&(i+="\n"),this.xml.emit("data",this.xml,i)),"function"==typeof t){if(t.call(this.xml),e.end)return this.end()}else if(e.end)return this.end(t)},e.prototype.toString=function(){return"[object Template]"},e.prototype.register=function(){var t;return(t=this.xml).register.apply(t,arguments)},e.prototype.remove=function(){var t;return(t=this.xml).remove.apply(t,arguments),this.xml.template=null,this.xml=null},e.prototype.end=function(){var t;return(t=this.xml).end.apply(t,arguments)},e.prototype.ready=function(){var t;return(t=this.xml).ready.apply(t,arguments)},e.prototype.show=function(){var t;return(t=this.xml).show.apply(t,arguments)},e.prototype.hide=function(){var t;return(t=this.xml).hide.apply(t,arguments)},e}(r),i.schema=u,i.doctype=l,i.self_closing=h,i.aliases=s,i.clearCache=o,e.exports=i}.call(this)}),t.define("/schema.js",function(t,e){!function(){var t,n;t={none:function(){return""},xml:function(){return""+t.none()},html:function(){return""+t.xml()+" "+t["html-obsolete"]()+" iframe label legend "+(""+n.html()+" html body div ul li a b body button colgroup ")+"dfn div dl dt em dd del form h1 h2 h3 h4 h5 h6 head hgroup html ins "+"li map i mark menu meter nav noscript object ol optgroup option p "+"pre script select small span strong style sub sup table tbody tfoot "+"td textarea th thead title tr u ul"},html5:function(){return""+t.html()+" "+n.html5()+" section article video q s "+"audio abbr address aside bdi bdo blockquote canvas caption cite code "+"datalist details fieldset figcaption figure footer header kbd output "+"progress rp rt ruby samp summary time"},strict:function(){return""+t.html()},xhtml:function(){return""+t.html()},"xhtml1.1":function(){return""+t.xhtml()},frameset:function(){return""+t.xhtml()},transitional:function(){return""+t.xhtml()},mobile:function(){return""+t.xhtml()},"html-ce":function(){return""+t.xhtml()},"html-obsolete":function(){return"applet acronym bgsound dir frameset noframes isindex listing nextid noembed plaintext rb strike xmp big blink center font marquee nobr multicol spacer tt"},"svg1.1":function(){return"altGlyph altGlyphDef altGlyphItem animate animateColor animateMotiona animateTransform circle clipPath color-profile cursor defs descellipse feBlend feColorMatrix feComponentTransfer feCompositefeConvolveMatrix feDiffuseLighting feDisplacementMap feDistantLightfeFlood feFuncA feFuncB feFuncG feFuncR feGaussianBlur feImagefeMerge feMergeNode feMorphology feOffset fePointLight feSpotLightfeSpecularLighting feTile feTurbulence linearGradient polylinefilter font font-face font-face-format font-face-name font-face-srcfont-face-uri foreignObject g glyph glyphRef hkern image linemarker mask metadata missing-glyph mpath path pattern polygonradialGradient rect script set stop style svg switch symbol texttextPath title tref tspan use view vkern"}},n={none:function(){return!0},xml:function(){return!1},"svg1.1":function(){return!0},html:function(){return"area br col embed hr img input link meta param"},html5:function(){return""+n.html()+" base command keygen source track wbr main"},mobile:function(){return""+n.xhtml()},"html-ce":function(){return""+n.xhtml()},strict:function(){return""+n.xhtml()},"xhtml1.1":function(){return""+n.xhtml()},xhtml:function(){return""+n.html()},frameset:function(){return""+n.xhtml()},transitional:function(){return""+n.xhtml()}},e.exports={self_closing:n,schema:t}}.call(this)}),t.define("/doctype.js",function(t,e){!function(){var t;t={xml:function(t){var e;return e=t.encoding,'<?xml version="1.0" encoding="'+e+'" ?>'},html:function(){return"<!DOCTYPE html>"},html5:function(){return""+t.html()},mobile:function(){return'<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd">'},"html-ce":function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "ce-html-1.0-transitional.dtd">'},strict:function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'},"xhtml1.1":function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">'},xhtml:function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.1//EN" "http://www.w3.org/TR/xhtml-basic/xhtml-basic11.dtd">'},frameset:function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">'},transitional:function(){return'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'}},e.exports={doctype:t}}.call(this)}),t.define("/alias.js",function(t,e){!function(){var t;t={"default":"xml","null":"none",nil:"none",0:"none",5:"html5",5:"html5",0:"none",ce:"html-ce",1.1:"xhtml1.1",html11:"xhtml1.1",basic:"xhtml",xhtml1:"xhtml","xhtml-basic":"xhtml","xhtml-strict":"strict","xhtml-mobile":"mobile","xhtml-frameset":"frameset","xhtml-trasitional":"transitional",svg:"svg1.1"},e.exports={aliases:t}}.call(this)}),t.define("/cache.js",function(t,e){!function(){var n,r,i,s,o,l,a,u,h={}.hasOwnProperty,c=function(t,e){function n(){this.constructor=t}for(var r in e)h.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t};n=t("asyncxml").Builder,r={},u=function(t,e){t[e]=function(){var t;return this.tag.apply(this,(t=[e]).concat.apply(t,arguments))},t["$"+e]=function(){var t;return this.$tag.apply(this,(t=[e]).concat.apply(t,arguments))}},o=function(t,e){var n,r,i;for(r=0,i=e.length;i>r;r++)n=e[r],n&&u(t,n)},l=function(t,e){var n,i;return n=r[t].Builder,i=new n(e),i.Tag=i.opts.Tag=r[t].Tag,i},s=function(t,e){var i,s,l,a,u,h,p,d;return i=null!=(h=e.Builder)?h:n,s=function(t){function e(){return p=e.__super__.constructor.apply(this,arguments)}return c(e,t),e}(i),o(s.prototype,e.schema),u=new s(e),a=u.Tag,l=function(t){function e(){return d=e.__super__.constructor.apply(this,arguments)}return c(e,t),e.prototype.partial=function(t){return null==t.run?this:t.started?(console.warn("partial already started!","you can delay it by adding option {partial:true} to your template"),this):(this.add(t),t.run(),this)},e}(a),o(l.prototype,e.schema),u.Tag=u.opts.Tag=l,r[t]={Builder:s,Tag:l},u},a=function(t){var e,n;return e=null!=(n=t._schema)?n:t.schema,null!=r[e]?l(e,t):s(e,t)},i=function(){return r={}},e.exports={create:s,lookup:a,clear:i,get:l}}.call(this)}),t("./dynamictemplate")}.call(this);