@aofl/drawer
Advanced tools
Comparing version 3.5.0-beta.8 to 3.5.0-beta.9
@@ -1,2 +0,2 @@ | ||
module.exports=function(t){var n={};function e(i){if(n[i])return n[i].exports;var o=n[i]={i:i,l:!1,exports:{}};return t[i].call(o.exports,o,o.exports,e),o.l=!0,o.exports}return e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:i})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(e.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var o in t)e.d(i,o,function(n){return t[n]}.bind(null,o));return i},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="/",e(e.s="QfWi")}({"+IV6":function(t,n){function e(n){return t.exports=e=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},e(n)}t.exports=e},AQPL:function(t,n,e){var i=e("+IV6");t.exports=function(t,n){for(;!Object.prototype.hasOwnProperty.call(t,n)&&null!==(t=i(t)););return t}},Ai0b:function(t,n,e){"use strict";t.exports=function(t){var n=[];return n.toString=function(){return this.map((function(n){var e=function(t,n){var e=t[1]||"",i=t[3];if(!i)return e;if(n&&"function"==typeof btoa){var o=(s=i,a=btoa(unescape(encodeURIComponent(JSON.stringify(s)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),r=i.sources.map((function(t){return"/*# sourceURL=".concat(i.sourceRoot||"").concat(t," */")}));return[e].concat(r).concat([o]).join("\n")}var s,a,c;return[e].join("\n")}(n,t);return n[2]?"@media ".concat(n[2]," {").concat(e,"}"):e})).join("")},n.i=function(t,e,i){"string"==typeof t&&(t=[[null,t,""]]);var o={};if(i)for(var r=0;r<this.length;r++){var s=this[r][0];null!=s&&(o[s]=!0)}for(var a=0;a<t.length;a++){var c=[].concat(t[a]);i&&o[c[0]]||(e&&(c[2]?c[2]="".concat(e," and ").concat(c[2]):c[2]=e),n.push(c))}},n}},K4DB:function(t,n,e){var i=e("e+GP"),o=e("T1e2");t.exports=function(t,n){return!n||"object"!==i(n)&&"function"!=typeof n?o(t):n}},NToG:function(t,n){function e(t,n){for(var e=0;e<n.length;e++){var i=n[e];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}t.exports=function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}},QfWi:function(t,n,e){"use strict";e.r(n);var i=e("hc4W"),o=e.n(i),r=e("SDJZ"),s=e.n(r),a=e("NToG"),c=e.n(a),u=e("K4DB"),l=e.n(u),f=e("+IV6"),p=e.n(f),h=e("kxHp"),d=e.n(h),g=e("eef+"),y=e.n(g),v=e("ymFR"),b=e("WhZO"),m=e.n(b);function O(){var t=o()(["<slot></slot>"]);return O=function(){return t},t}var x=function(t){function n(){var t;return s()(this,n),(t=l()(this,p()(n).call(this))).open=null,t.transitionEndCount=0,t["transition-count"]=1,t}return y()(n,t),c()(n,[{key:"connectedCallback",value:function(){for(var t,e=arguments.length,i=new Array(e),o=0;o<e;o++)i[o]=arguments[o];(t=d()(p()(n.prototype),"connectedCallback",this)).call.apply(t,[this].concat(i)),this.cancelOpen=null,this.trigger=this.trigger||"animate",this.animated=void 0!==this.opening&&void 0!==this.closing,this.animated&&(this.open?(this.classList.remove(this.opening),this.classList.add(this.closing)):(this.classList.remove(this.closing),this.classList.add(this.opening)),this.addEventListener("animationend",this.animationEndHandler),this.addEventListener("transitionend",this.animationEndHandler))}},{key:"render",value:function(){return d()(p()(n.prototype),"render",this).call(this,(function(t,n){return n(O())}),[m.a])}},{key:"attributeChangedCallback",value:function(t,e,i){d()(p()(n.prototype),"attributeChangedCallback",this).call(this,t,e,i),"open"===t&&(this.animated?this.openChanged(this.open):this.dispatchEvent(new CustomEvent("drawer-toggle",{composed:!0,bubbles:!0})))}},{key:"openChanged",value:function(t){var n=this;!0===t?this.cancelOpen=this.startOpeningAnimation((function(){n.transitionEndCount=0,n.classList.remove(n.closing),n.classList.add(n.opening),n.classList.add(n.trigger)})):(this.classList.contains(this.closing)||this.classList.contains(this.trigger))&&("function"==typeof this.cancelOpen&&(this.cancelOpen(),this.cancelOpen=null),this.classList.remove(this.opening),this.classList.add(this.closing),this.classList.add(this.trigger),this.classList.add("closing"))}},{key:"startOpeningAnimation",value:function(t){var n=this,e=!1,i=100;return function o(){"block"===window.getComputedStyle(n).getPropertyValue("display")?t():!e&&i-- >0&&window.requestAnimationFrame(o)}(),function(){e=!0}}},{key:"animationEndHandler",value:function(t){var n=this;t.target===this&&(this.transitionEndCount+=1,this.transitionEndCount===this["transition-count"]&&(this.transitionEndCount=0,this.classList.remove(this.trigger),this.classList.contains(this.opening)?(this.classList.remove(this.opening),this.classList.add(this.closing),this.cancelOpen=null):(this.classList.add(this.opening),this.classList.remove(this.closing),this.classList.remove("closing")),setTimeout((function(){n.dispatchEvent(new CustomEvent("drawer-toggle",{composed:!0,bubbles:!0}))}))))}},{key:"disconnectedCallback",value:function(){for(var t,e=arguments.length,i=new Array(e),o=0;o<e;o++)i[o]=arguments[o];(t=d()(p()(n.prototype),"disconnectedCallback",this)).call.apply(t,[this].concat(i)),this.animated&&(this.removeEventListener("animationend",this.animationEndHandler),this.removeEventListener("transitionend",this.animationEndHandler))}}],[{key:"is",get:function(){return"aofl-drawer"}},{key:"properties",get:function(){return{open:{type:Boolean},trigger:{type:String},opening:{type:String},closing:{type:String},"transition-count":{type:Number}}}}]),n}(v.AoflElement);void 0===window.customElements.get(x.is)&&window.customElements.define(x.is,x);var w=x;e.d(n,"Drawer",(function(){return w}))},SDJZ:function(t,n){t.exports=function(t,n){if(!(t instanceof n))throw new TypeError("Cannot call a class as a function")}},T1e2:function(t,n){t.exports=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}},WI9V:function(t,n){function e(n,i){return t.exports=e=Object.setPrototypeOf||function(t,n){return t.__proto__=n,t},e(n,i)}t.exports=e},WhZO:function(t,n,e){(n=e("Ai0b")(!1)).push([t.i,":host{display:none}:host(.closing),:host([open]){display:block}",""]),t.exports=n},"e+GP":function(t,n){function e(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?t.exports=e=function(t){return typeof t}:t.exports=e=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},e(n)}t.exports=e},"eef+":function(t,n,e){var i=e("WI9V");t.exports=function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(n&&n.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),n&&i(t,n)}},hc4W:function(t,n){t.exports=function(t,n){return n||(n=t.slice(0)),Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(n)}}))}},kxHp:function(t,n,e){var i=e("AQPL");function o(n,e,r){return"undefined"!=typeof Reflect&&Reflect.get?t.exports=o=Reflect.get:t.exports=o=function(t,n,e){var o=i(t,n);if(o){var r=Object.getOwnPropertyDescriptor(o,n);return r.get?r.get.call(e):r.value}},o(n,e,r||n)}t.exports=o},ymFR:function(t,n){t.exports=require("@aofl/element")}}); | ||
module.exports=function(t){var n={};function e(i){if(n[i])return n[i].exports;var s=n[i]={i:i,l:!1,exports:{}};return t[i].call(s.exports,s,s.exports,e),s.l=!0,s.exports}return e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:i})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(e.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var s in t)e.d(i,s,function(n){return t[n]}.bind(null,s));return i},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="/",e(e.s="QfWi")}({"86LY":function(t,n){t.exports=require("@babel/runtime/helpers/possibleConstructorReturn")},Ai0b:function(t,n,e){"use strict";t.exports=function(t){var n=[];return n.toString=function(){return this.map((function(n){var e=function(t,n){var e=t[1]||"",i=t[3];if(!i)return e;if(n&&"function"==typeof btoa){var s=(o=i,a=btoa(unescape(encodeURIComponent(JSON.stringify(o)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),r=i.sources.map((function(t){return"/*# sourceURL=".concat(i.sourceRoot||"").concat(t," */")}));return[e].concat(r).concat([s]).join("\n")}var o,a,c;return[e].join("\n")}(n,t);return n[2]?"@media ".concat(n[2]," {").concat(e,"}"):e})).join("")},n.i=function(t,e,i){"string"==typeof t&&(t=[[null,t,""]]);var s={};if(i)for(var r=0;r<this.length;r++){var o=this[r][0];null!=o&&(s[o]=!0)}for(var a=0;a<t.length;a++){var c=[].concat(t[a]);i&&s[c[0]]||(e&&(c[2]?c[2]="".concat(e," and ").concat(c[2]):c[2]=e),n.push(c))}},n}},BBO7:function(t,n){t.exports=require("@babel/runtime/helpers/get")},MmcY:function(t,n){t.exports=require("@babel/runtime/helpers/classCallCheck")},QfWi:function(t,n,e){"use strict";e.r(n);var i=e("Y6CL"),s=e.n(i),r=e("MmcY"),o=e.n(r),a=e("iTvO"),c=e.n(a),l=e("86LY"),u=e.n(l),h=e("a4YD"),p=e.n(h),d=e("BBO7"),f=e.n(d),g=e("cB7G"),m=e.n(g),v=e("ymFR"),b=e("WhZO"),y=e.n(b);function L(){var t=s()(["<slot></slot>"]);return L=function(){return t},t}var C=function(t){function n(){var t;return o()(this,n),(t=u()(this,p()(n).call(this))).open=null,t.transitionEndCount=0,t["transition-count"]=1,t}return m()(n,t),c()(n,[{key:"connectedCallback",value:function(){for(var t,e=arguments.length,i=new Array(e),s=0;s<e;s++)i[s]=arguments[s];(t=f()(p()(n.prototype),"connectedCallback",this)).call.apply(t,[this].concat(i)),this.cancelOpen=null,this.trigger=this.trigger||"animate",this.animated=void 0!==this.opening&&void 0!==this.closing,this.animated&&(this.open?(this.classList.remove(this.opening),this.classList.add(this.closing)):(this.classList.remove(this.closing),this.classList.add(this.opening)),this.addEventListener("animationend",this.animationEndHandler),this.addEventListener("transitionend",this.animationEndHandler))}},{key:"render",value:function(){return f()(p()(n.prototype),"render",this).call(this,(function(t,n){return n(L())}),[y.a])}},{key:"attributeChangedCallback",value:function(t,e,i){f()(p()(n.prototype),"attributeChangedCallback",this).call(this,t,e,i),"open"===t&&(this.animated?this.openChanged(this.open):this.dispatchEvent(new CustomEvent("drawer-toggle",{composed:!0,bubbles:!0})))}},{key:"openChanged",value:function(t){var n=this;!0===t?this.cancelOpen=this.startOpeningAnimation((function(){n.transitionEndCount=0,n.classList.remove(n.closing),n.classList.add(n.opening),n.classList.add(n.trigger)})):(this.classList.contains(this.closing)||this.classList.contains(this.trigger))&&("function"==typeof this.cancelOpen&&(this.cancelOpen(),this.cancelOpen=null),this.classList.remove(this.opening),this.classList.add(this.closing),this.classList.add(this.trigger),this.classList.add("closing"))}},{key:"startOpeningAnimation",value:function(t){var n=this,e=!1,i=100;return function s(){"block"===window.getComputedStyle(n).getPropertyValue("display")?t():!e&&i-- >0&&window.requestAnimationFrame(s)}(),function(){e=!0}}},{key:"animationEndHandler",value:function(t){var n=this;t.target===this&&(this.transitionEndCount+=1,this.transitionEndCount===this["transition-count"]&&(this.transitionEndCount=0,this.classList.remove(this.trigger),this.classList.contains(this.opening)?(this.classList.remove(this.opening),this.classList.add(this.closing),this.cancelOpen=null):(this.classList.add(this.opening),this.classList.remove(this.closing),this.classList.remove("closing")),setTimeout((function(){n.dispatchEvent(new CustomEvent("drawer-toggle",{composed:!0,bubbles:!0}))}))))}},{key:"disconnectedCallback",value:function(){for(var t,e=arguments.length,i=new Array(e),s=0;s<e;s++)i[s]=arguments[s];(t=f()(p()(n.prototype),"disconnectedCallback",this)).call.apply(t,[this].concat(i)),this.animated&&(this.removeEventListener("animationend",this.animationEndHandler),this.removeEventListener("transitionend",this.animationEndHandler))}}],[{key:"is",get:function(){return"aofl-drawer"}},{key:"properties",get:function(){return{open:{type:Boolean},trigger:{type:String},opening:{type:String},closing:{type:String},"transition-count":{type:Number}}}}]),n}(v.AoflElement);void 0===window.customElements.get(C.is)&&window.customElements.define(C.is,C);var O=C;e.d(n,"Drawer",(function(){return O}))},WhZO:function(t,n,e){(n=e("Ai0b")(!1)).push([t.i,":host{display:none}:host(.closing),:host([open]){display:block}",""]),t.exports=n},Y6CL:function(t,n){t.exports=require("@babel/runtime/helpers/taggedTemplateLiteral")},a4YD:function(t,n){t.exports=require("@babel/runtime/helpers/getPrototypeOf")},cB7G:function(t,n){t.exports=require("@babel/runtime/helpers/inherits")},iTvO:function(t,n){t.exports=require("@babel/runtime/helpers/createClass")},ymFR:function(t,n){t.exports=require("@aofl/element")}}); | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@aofl/drawer", | ||
"version": "3.5.0-beta.8", | ||
"version": "3.5.0-beta.9", | ||
"description": "The <aofl-drawer> element toggles content between an open and closed state. Opening and closing animations are provided as classes to allow for any possible method of toggling content.", | ||
@@ -37,4 +37,4 @@ "main": "index.js", | ||
"devDependencies": { | ||
"@aofl/cli": "^3.5.0-beta.8", | ||
"@aofl/element": "^3.5.0-beta.8", | ||
"@aofl/cli": "^3.5.0-beta.9", | ||
"@aofl/element": "^3.5.0-beta.9", | ||
"cross-env": "^6.0.3", | ||
@@ -41,0 +41,0 @@ "jsdoc": "^3.6.3", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23483
276