| !function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports,require("@angular/cdk/testing")):"function"==typeof define&&define.amd?define("@angular/material/sidenav/testing",["exports","@angular/cdk/testing"],n):n(((t=t||self).ng=t.ng||{},t.ng.material=t.ng.material||{},t.ng.material.sidenav=t.ng.material.sidenav||{},t.ng.material.sidenav.testing={}),t.ng.cdk.testing)}(this,(function(t,n){"use strict"; |
| ***************************************************************************** */var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e])})(t,n)};function r(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}function o(t,n,e,r){return new(e||(e=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){t.done?o(t.value):function n(t){return t instanceof e?t:new e((function(n){n(t)}))}(t.value).then(s,a)}u((r=r.apply(t,n||[])).next())}))}function i(t,n){var e,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function u(i){if(e)throw new TypeError("Generator is already executing.");for(;s;)try{if(e=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=n.call(t,s)}catch(t){i=[6,t],r=0}finally{e=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var s=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return r(n,t),n.prototype.isOpen=function(){return o(this,void 0,void 0,(function(){return i(this,(function(t){switch(t.label){case 0:return[4,this.host()];case 1:return[2,t.sent().hasClass("mat-drawer-opened")]}}))}))},n.prototype.getPosition=function(){return o(this,void 0,void 0,(function(){return i(this,(function(t){switch(t.label){case 0:return[4,this.host()];case 1:return[4,t.sent().hasClass("mat-drawer-end")];case 2:return[2,t.sent()?"end":"start"]}}))}))},n.prototype.getMode=function(){return o(this,void 0,void 0,(function(){var t;return i(this,(function(n){switch(n.label){case 0:return[4,this.host()];case 1:return[4,(t=n.sent()).hasClass("mat-drawer-push")];case 2:return n.sent()?[2,"push"]:[4,t.hasClass("mat-drawer-side")];case 3:return n.sent()?[2,"side"]:[2,"over"]}}))}))},n}(n.ContentContainerComponentHarness),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){var r=this;return void 0===t&&(t={}),new n.HarnessPredicate(e,t).addOption("position",t.position,(function(t,n){return o(r,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return[4,t.getPosition()];case 1:return[2,e.sent()===n]}}))}))}))},e}(s);a.hostSelector=".mat-drawer";var u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){return void 0===t&&(t={}),new n.HarnessPredicate(e,t)},e}(n.ContentContainerComponentHarness);u.hostSelector=".mat-drawer-content";var c=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){return void 0===t&&(t={}),new n.HarnessPredicate(e,t)},e.prototype.getDrawers=function(t){return void 0===t&&(t={}),o(this,void 0,void 0,(function(){return i(this,(function(n){return[2,this.locatorForAll(a.with(t))()]}))}))},e.prototype.getContent=function(){return o(this,void 0,void 0,(function(){return i(this,(function(t){return[2,this.locatorFor(u)()]}))}))},e}(n.ContentContainerComponentHarness);c.hostSelector=".mat-drawer-container";var l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){return void 0===t&&(t={}),new n.HarnessPredicate(e,t)},e}(n.ContentContainerComponentHarness);l.hostSelector=".mat-sidenav-content";var f=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){var r=this;return void 0===t&&(t={}),new n.HarnessPredicate(e,t).addOption("position",t.position,(function(t,n){return o(r,void 0,void 0,(function(){return i(this,(function(e){switch(e.label){case 0:return[4,t.getPosition()];case 1:return[2,e.sent()===n]}}))}))}))},e.prototype.isFixedInViewport=function(){return o(this,void 0,void 0,(function(){return i(this,(function(t){switch(t.label){case 0:return[4,this.host()];case 1:return[2,t.sent().hasClass("mat-sidenav-fixed")]}}))}))},e}(s);f.hostSelector=".mat-sidenav";var h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.with=function(t){return void 0===t&&(t={}),new n.HarnessPredicate(e,t)},e.prototype.getSidenavs=function(t){return void 0===t&&(t={}),o(this,void 0,void 0,(function(){return i(this,(function(n){return[2,this.locatorForAll(f.with(t))()]}))}))},e.prototype.getContent=function(){return o(this,void 0,void 0,(function(){return i(this,(function(t){return[2,this.locatorFor(l)()]}))}))},e}(n.ContentContainerComponentHarness);h.hostSelector=".mat-sidenav-container", |