-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path856.4a657d3487cb239f.js
1 lines (1 loc) · 5.48 KB
/
856.4a657d3487cb239f.js
1
"use strict";(self.webpackChunkmaterial_angular_io=self.webpackChunkmaterial_angular_io||[]).push([[856],{9529:(u,p,o)=>{o.d(p,{Ky:()=>c,bU:()=>x,z8:()=>a});var e=o(4438),l=o(5024),h=o(5286),m=o(4337);let d=0;const r=new e.nKC("CdkAccordion");let a=(()=>{class n{constructor(){this._stateChanges=new h.B7,this._openCloseAllActions=new h.B7,this.id="cdk-accordion-"+d++,this.multi=!1}openAll(){this.multi&&this._openCloseAllActions.next(!0)}closeAll(){this._openCloseAllActions.next(!1)}ngOnChanges(t){this._stateChanges.next(t)}ngOnDestroy(){this._stateChanges.complete(),this._openCloseAllActions.complete()}static#e=this.\u0275fac=function(s){return new(s||n)};static#n=this.\u0275dir=e.FsC({type:n,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:[2,"multi","multi",e.L39]},exportAs:["cdkAccordion"],standalone:!0,features:[e.Jv_([{provide:r,useExisting:n}]),e.GFd,e.OA$]})}return n})(),i=0,c=(()=>{class n{get expanded(){return this._expanded}set expanded(t){this._expanded!==t&&(this._expanded=t,this.expandedChange.emit(t),t?(this.opened.emit(),this._expansionDispatcher.notify(this.id,this.accordion?this.accordion.id:this.id)):this.closed.emit(),this._changeDetectorRef.markForCheck())}constructor(t,s,_){this.accordion=t,this._changeDetectorRef=s,this._expansionDispatcher=_,this._openCloseAllSubscription=m.y.EMPTY,this.closed=new e.bkB,this.opened=new e.bkB,this.destroyed=new e.bkB,this.expandedChange=new e.bkB,this.id="cdk-accordion-child-"+i++,this._expanded=!1,this.disabled=!1,this._removeUniqueSelectionListener=()=>{},this._removeUniqueSelectionListener=_.listen((C,f)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===f&&this.id!==C&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(t=>{this.disabled||(this.expanded=t)})}static#e=this.\u0275fac=function(s){return new(s||n)(e.rXU(r,12),e.rXU(e.gRc),e.rXU(l.zP))};static#n=this.\u0275dir=e.FsC({type:n,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",e.L39],disabled:[2,"disabled","disabled",e.L39]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],standalone:!0,features:[e.Jv_([{provide:r,useValue:void 0}]),e.GFd]})}return n})(),x=(()=>{class n{static#e=this.\u0275fac=function(s){return new(s||n)};static#n=this.\u0275mod=e.$C({type:n});static#t=this.\u0275inj=e.G2t({})}return n})()},856:(u,p,o)=>{o.r(p),o.d(p,{CdkAccordionOverviewExample:()=>m});var e=o(4438),l=o(9529);function h(d,r){if(1&d){const a=e.RV6();e.j41(0,"cdk-accordion-item",2,0)(2,"div",3),e.bIt("click",function(){e.eBV(a);const c=e.sdS(1);return e.Njj(c.toggle())}),e.EFF(3),e.j41(4,"span",4),e.EFF(5),e.k0s()(),e.j41(6,"div",5),e.EFF(7," Lorem ipsum dolor, sit amet consectetur adipisicing elit. Perferendis excepturi incidunt ipsum deleniti labore, tempore non nam doloribus blanditiis veritatis illo autem iure aliquid ullam rem tenetur deserunt velit culpa? "),e.k0s()()}if(2&d){const a=r.$implicit,i=r.$index,c=e.sdS(1);e.BMQ("id","accordion-header-"+i)("aria-expanded",c.expanded)("aria-controls","accordion-body-"+i),e.R7$(3),e.SpI(" ",a," "),e.R7$(2),e.SpI(" Click to ",c.expanded?"close":"open"," "),e.R7$(),e.xc7("display",c.expanded?"":"none"),e.BMQ("id","accordion-body-"+i)("aria-labelledby","accordion-header-"+i)}}let m=(()=>{class d{constructor(){this.items=["Item 1","Item 2","Item 3","Item 4","Item 5"],this.expandedIndex=0}static#e=this.\u0275fac=function(i){return new(i||d)};static#n=this.\u0275cmp=e.VBU({type:d,selectors:[["cdk-accordion-overview-example"]],standalone:!0,features:[e.aNF],decls:3,vars:0,consts:[["accordionItem","cdkAccordionItem"],[1,"example-accordion"],["role","button","tabindex","0",1,"example-accordion-item"],[1,"example-accordion-item-header",3,"click"],[1,"example-accordion-item-description"],["role","region",1,"example-accordion-item-body"]],template:function(i,c){1&i&&(e.j41(0,"cdk-accordion",1),e.Z7z(1,h,8,9,"cdk-accordion-item",2,e.fX1),e.k0s()),2&i&&(e.R7$(),e.Dyx(c.items))},dependencies:[l.bU,l.z8,l.Ky],styles:[".example-accordion[_ngcontent-%COMP%] {\n display: block;\n max-width: 500px;\n}\n\n.example-accordion-item[_ngcontent-%COMP%] {\n display: block;\n border: solid 1px #ccc;\n}\n\n.example-accordion-item[_ngcontent-%COMP%] + .example-accordion-item[_ngcontent-%COMP%] {\n border-top: none;\n}\n\n.example-accordion-item-header[_ngcontent-%COMP%] {\n display: flex;\n align-content: center;\n justify-content: space-between;\n}\n\n.example-accordion-item-description[_ngcontent-%COMP%] {\n font-size: 0.85em;\n color: #999;\n}\n\n.example-accordion-item-header[_ngcontent-%COMP%], \n.example-accordion-item-body[_ngcontent-%COMP%] {\n padding: 16px;\n}\n\n.example-accordion-item-header[_ngcontent-%COMP%]:hover {\n cursor: pointer;\n background-color: #eee;\n}\n\n.example-accordion-item[_ngcontent-%COMP%]:first-child {\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n}\n\n.example-accordion-item[_ngcontent-%COMP%]:last-child {\n border-bottom-left-radius: 4px;\n border-bottom-right-radius: 4px;\n}"]})}return d})()}}]);