diff --git a/117.6e2be7fed3733705.js b/117.6e2be7fed3733705.js new file mode 100644 index 0000000000..5e37324d98 --- /dev/null +++ b/117.6e2be7fed3733705.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[117],{52439:(p,i,e)=>{e.d(i,{C:()=>S});var r=e(27e3),n=e(54438),C=e(8681),t=e(60177),k=e(4875),E=e(80903);const j=["scrollElement"],_=d=>({tab:d});function B(d,y){if(1&d&&(n.j41(0,"li")(1,"a",6,0),n.EFF(3),n.k0s()()),2&d){const s=y.$implicit,c=n.XpG(3);n.R7$(),n.Y8G("queryParams",n.eq3(4,_,c._componentContent.name))("fragment",s.anchor),n.BMQ("data-anchor",s.anchor),n.R7$(2),n.JRh(s.title)}}function h(d,y){if(1&d&&(n.j41(0,"ul"),n.DNE(1,B,4,6,"li",5),n.k0s()),2&d){const s=n.XpG(2);n.R7$(),n.Y8G("ngForOf",s._componentContent.content)}}function R(d,y){if(1&d){const s=n.RV6();n.j41(0,"div",2),n.bIt("click",function(u){n.eBV(s);const g=n.XpG();return n.Njj(g.goToSection(u))}),n.j41(1,"a",3),n.EFF(2),n.k0s(),n.DNE(3,h,2,1,"ul",4),n.k0s()}if(2&d){const s=n.XpG();n.R7$(),n.Mz_("routerLink","/",s._componentContent.parentRouteTitle,""),n.R7$(),n.JRh(s._componentContent.parentRouteTitle),n.R7$(),n.Y8G("ngIf",(null==s._componentContent?null:s._componentContent.content)&&(null==s._componentContent.content?null:s._componentContent.content.length))}}let b=(()=>{class d{onScrollEvent(){this.initActiveMenuTab()}constructor(s,c,u){this.document=s,this._renderer=c,this.router=u}ngOnChanges(s){s?.componentContent&&(this._componentContent=this.mapComponentContent(s.componentContent.currentValue),s?.componentContent.firstChange||this.setScrollAttributes())}mapComponentContent(s){const c=this.router.parseUrl(this.router.url).root.children.primary.segments[0].path;return{name:s.tabName,parentRouteTitle:c,content:Array.isArray(s.content)?s.content.map(u=>({anchor:u.anchor,title:u.title})):[]}}goToSection(s){const c=s.target;c.dataset.anchor&&this.goToSectionWIthAnchor(c.dataset.anchor)}goToSectionWIthAnchor(s){if(!s)return;const c=this.document.getElementById(s),u=this.document.getElementById("header");c&&u&&setTimeout(()=>{window.scrollTo({top:c.offsetTop-u.offsetHeight-6,behavior:"smooth"})},100)}initActiveMenuTab(){this.scrollElementsList?.length&&this.scrollElementsList.map(s=>{const c=s.nativeElement.getAttribute("data-min-scroll-value"),u=s.nativeElement.getAttribute("data-max-scroll-value"),g=window.pageYOffset;g>=c&&g<=u?this._renderer.addClass(s.nativeElement.parentElement,"active"):this._renderer.removeClass(s.nativeElement.parentElement,"active")})}setScrollAttributes(){const s=this.document.querySelector("header")?.offsetHeight||0;this.scrollElementsList?.map(c=>{const u=c.nativeElement.getAttribute("data-anchor"),g=this.document.getElementById(u);if(g){const A=g.offsetTop-s-10,F=g.parentElement.getBoundingClientRect().height+6||0;this._renderer.setAttribute(c.nativeElement,"data-max-scroll-value",(A+F).toString()),this._renderer.setAttribute(c.nativeElement,"data-min-scroll-value",A.toString())}return c})}ngAfterViewInit(){this.goToSectionWIthAnchor(this.router.parseUrl(this.router.url).fragment)}ngAfterViewChecked(){this.setScrollAttributes()}static#t=this.\u0275fac=function(c){return new(c||d)(n.rXU(t.qQ),n.rXU(n.sFG),n.rXU(C.Ix))};static#e=this.\u0275cmp=n.VBU({type:d,selectors:[["add-nav"]],viewQuery:function(c,u){if(1&c&&n.GBs(j,5),2&c){let g;n.mGM(g=n.lsd())&&(u.scrollElementsList=g)}},hostBindings:function(c,u){1&c&&n.bIt("scroll",function(){return u.onScrollEvent()},!1,n.tSv)},inputs:{componentContent:"componentContent"},features:[n.OA$],decls:1,vars:1,consts:[["scrollElement",""],["class","add-nav-container",3,"click",4,"ngIf"],[1,"add-nav-container",3,"click"],[3,"routerLink"],[4,"ngIf"],[4,"ngFor","ngForOf"],["routerLink",".",3,"queryParams","fragment"]],template:function(c,u){1&c&&n.DNE(0,R,4,4,"div",1),2&c&&n.Y8G("ngIf",u._componentContent)},dependencies:[t.Sq,t.bT,C.Wk],encapsulation:2})}return d})();function v(d,y){1&d&&n.eu8(0)}function D(d,y){1&d&&n.eu8(0)}function x(d,y){1&d&&n.eu8(0)}function O(d,y){if(1&d){const s=n.RV6();n.qex(0),n.j41(1,"tabset",1)(2,"tab",2),n.bIt("selectTab",function(){n.eBV(s);const u=n.XpG();return n.Njj(u.onSelect("overview"))}),n.DNE(3,v,1,0,"ng-container",3),n.k0s(),n.j41(4,"tab",4),n.bIt("selectTab",function(){n.eBV(s);const u=n.XpG();return n.Njj(u.onSelect("api"))}),n.DNE(5,D,1,0,"ng-container",3),n.k0s(),n.j41(6,"tab",5),n.bIt("selectTab",function(){n.eBV(s);const u=n.XpG();return n.Njj(u.onSelect("examples"))}),n.DNE(7,x,1,0,"ng-container",3),n.k0s()(),n.nrm(8,"add-nav",6),n.bVm()}if(2&d){const s=n.XpG();n.R7$(2),n.Y8G("customClass","example-tabset")("active",s.overview),n.R7$(),n.Y8G("ngComponentOutlet",s.content[0].outlet)("ngComponentOutletInjector",s.sectionInjections(s.content[0])),n.R7$(),n.Y8G("customClass","example-tabset")("active",s.api),n.R7$(),n.Y8G("ngComponentOutlet",s.content[1].outlet)("ngComponentOutletInjector",s.sectionInjections(s.content[1])),n.R7$(),n.Y8G("customClass","example-tabset")("active",s.examples),n.R7$(),n.Y8G("ngComponentOutlet",s.content[2].outlet)("ngComponentOutletInjector",s.sectionInjections(s.content[2])),n.R7$(),n.Y8G("componentContent",s.overview?s.content[0]:s.api?s.content[1]:s.content[2])}}let S=(()=>{class d{constructor(s,c,u,g){this.injector=s,this.activatedRoute=c,this.router=u,this.changeDetection=g,this._injectors=new Map,this.overview=!1,this.api=!1,this.examples=!1,this.routeSubscription=this.router.events.subscribe(A=>{if(A instanceof C.wF){const F=this.router.parseUrl(A.url).queryParams;this.initActiveTab(F.tab?.toString())}})}initActiveTab(s){if(this.resetTabs(),!s||!this.checkActiveTab(s))return this.overview=!0,void this.onSelect("overview");this[s]=!0,this.changeDetection.detectChanges()}checkActiveTab(s){return"overview"===s||"api"===s||"examples"===s}onSelect(s){this.resetTabs();const c={queryParams:{tab:s},fragment:this.router.parseUrl(this.router.url).fragment||void 0};this.router.navigate([],c),this[s]=!0}sectionInjections(s){if(this._injectors.has(s))return this._injectors.get(s);const c=n.zZn.create([{provide:r.F,useValue:s}],this.injector);return this._injectors.set(s,c),c}resetTabs(){this.overview=!1,this.api=!1,this.examples=!1}ngOnDestroy(){this.routeSubscription.unsubscribe()}static#t=this.\u0275fac=function(c){return new(c||d)(n.rXU(n.zZn),n.rXU(C.nX),n.rXU(C.Ix),n.rXU(n.gRc))};static#e=this.\u0275cmp=n.VBU({type:d,selectors:[["docs-section"]],inputs:{content:"content"},decls:1,vars:1,consts:[[4,"ngIf"],[1,"example-tabset-box"],["heading","Overview",3,"selectTab","customClass","active"],[4,"ngComponentOutlet","ngComponentOutletInjector"],["heading","API",3,"selectTab","customClass","active"],["heading","Examples",3,"selectTab","customClass","active"],[1,"add-nav",3,"componentContent"]],template:function(c,u){1&c&&n.DNE(0,O,9,13,"ng-container",0),2&c&&n.Y8G("ngIf",u.content)},dependencies:[t.OI,t.bT,k.V,E.f,b],encapsulation:2})}return d})()},95117:(p,i,e)=>{e.r(i),e.d(i,{AlertsSectionComponent:()=>P,DemoAlertsModule:()=>w});var r=e(60177),n=e(8681),C=e(31635),t=e(54438),k=e(39555);let E=(()=>{class o{constructor(){this.type="warning",this.dismissible=!1,this.dismissOnTimeout=void 0}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275prov=t.jDH({token:o,factory:o.\u0275fac,providedIn:"root"})}return o})();const j=["*"];function _(o,f){if(1&o){const a=t.RV6();t.j41(0,"button",2),t.bIt("click",function(){t.eBV(a);const m=t.XpG(2);return t.Njj(m.close())}),t.j41(1,"span",3),t.EFF(2,"\xd7"),t.k0s(),t.j41(3,"span",4),t.EFF(4,"Close"),t.k0s()()}}function B(o,f){if(1&o&&(t.j41(0,"div",1),t.DNE(1,_,5,0,"ng-template",0),t.SdG(2),t.k0s()),2&o){const a=t.XpG();t.HbH("alert alert-"+a.type),t.Y8G("ngClass",a.classes),t.R7$(),t.Y8G("ngIf",a.dismissible)}}class h{constructor(f,a){this.changeDetection=a,this.type="warning",this.dismissible=!1,this.isOpen=!0,this.onClose=new t.bkB,this.onClosed=new t.bkB,this.classes="",this.dismissibleChange=new t.bkB,Object.assign(this,f),this.dismissibleChange.subscribe(()=>{this.classes=this.dismissible?"alert-dismissible":"",this.changeDetection.markForCheck()})}ngOnInit(){this.dismissOnTimeout&&setTimeout(()=>this.close(),parseInt(this.dismissOnTimeout,10))}close(){this.isOpen&&(this.onClose.emit(this),this.isOpen=!1,this.changeDetection.markForCheck(),this.onClosed.emit(this))}static#t=this.\u0275fac=function(a){return new(a||h)(t.rXU(E),t.rXU(t.gRc))};static#e=this.\u0275cmp=t.VBU({type:h,selectors:[["alert"],["bs-alert"]],inputs:{type:"type",dismissible:"dismissible",dismissOnTimeout:"dismissOnTimeout",isOpen:"isOpen"},outputs:{onClose:"onClose",onClosed:"onClosed"},standalone:!0,features:[t.aNF],ngContentSelectors:j,decls:1,vars:1,consts:[[3,"ngIf"],["role","alert",3,"ngClass"],["type","button","aria-label","Close",1,"close","btn-close",3,"click"],["aria-hidden","true",1,"visually-hidden"],[1,"sr-only","visually-hidden"]],template:function(a,l){1&a&&(t.NAR(),t.DNE(0,B,3,4,"ng-template",0)),2&a&&t.Y8G("ngIf",l.isOpen)},dependencies:[r.bT,r.YU],encapsulation:2,changeDetection:0})}(0,C.Cg)([(0,k.Yr)(),(0,C.Sn)("design:type",Object)],h.prototype,"dismissible",void 0);let R=(()=>{class o{static forRoot(){return o}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275mod=t.$C({type:o});static#n=this.\u0275inj=t.G2t({})}return o})();var b=e(37472);let v=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-basic"]],decls:16,vars:0,consts:[["type","success"],["type","info"],["type","warning"],["type","danger"]],template:function(l,m){1&l&&(t.j41(0,"alert",0)(1,"strong"),t.EFF(2,"Well done!"),t.k0s(),t.EFF(3," You successfully read this important alert message.\n"),t.k0s(),t.j41(4,"alert",1)(5,"strong"),t.EFF(6,"Heads up!"),t.k0s(),t.EFF(7," This alert needs your attention, but it's not super important.\n"),t.k0s(),t.j41(8,"alert",2)(9,"strong"),t.EFF(10,"Warning!"),t.k0s(),t.EFF(11," Better check yourself, you're not looking too good.\n"),t.k0s(),t.j41(12,"alert",3)(13,"strong"),t.EFF(14,"Oh snap!"),t.k0s(),t.EFF(15," Change a few things up and try submitting again.\n"),t.k0s())},dependencies:[h],encapsulation:2})}return o})(),D=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-link"]],decls:27,vars:0,consts:[["type","success"],["href","#",1,"alert-link"],["type","info"],["type","warning"],["type","danger"]],template:function(l,m){1&l&&(t.j41(0,"alert",0)(1,"strong"),t.EFF(2,"Well done!"),t.k0s(),t.EFF(3," You successfully read "),t.j41(4,"a",1),t.EFF(5,"this important alert message"),t.k0s(),t.EFF(6,".\n"),t.k0s(),t.j41(7,"alert",2)(8,"strong"),t.EFF(9,"Heads up!"),t.k0s(),t.EFF(10," This "),t.j41(11,"a",1),t.EFF(12,"alert needs your attention"),t.k0s(),t.EFF(13,", but it's not super important.\n"),t.k0s(),t.j41(14,"alert",3)(15,"strong"),t.EFF(16,"Warning!"),t.k0s(),t.EFF(17," Better check yourself, you're "),t.j41(18,"a",1),t.EFF(19,"not looking too good"),t.k0s(),t.EFF(20,".\n"),t.k0s(),t.j41(21,"alert",4)(22,"strong"),t.EFF(23,"Oh snap!"),t.k0s(),t.j41(24,"a",1),t.EFF(25,"Change a few things up"),t.k0s(),t.EFF(26," and try submitting again.\n"),t.k0s())},dependencies:[h],encapsulation:2})}return o})(),x=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-content"]],decls:7,vars:0,consts:[["type","success"],[1,"alert-heading"],[1,"mb-0"]],template:function(l,m){1&l&&(t.j41(0,"alert",0)(1,"h4",1),t.EFF(2,"Well done!"),t.k0s(),t.j41(3,"p"),t.EFF(4,"Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content."),t.k0s(),t.j41(5,"p",2),t.EFF(6,"Whenever you need to, be sure to use margin utilities to keep things nice and tidy."),t.k0s()())},dependencies:[h],encapsulation:2})}return o})();function O(o,f){if(1&o){const a=t.RV6();t.j41(0,"div")(1,"alert",2),t.bIt("onClosed",function(){const m=t.eBV(a).$implicit,T=t.XpG();return t.Njj(T.onClosed(m))}),t.EFF(2),t.k0s()()}if(2&o){const a=f.$implicit,l=t.XpG();t.R7$(),t.Y8G("type",a.type)("dismissible",l.dismissible),t.R7$(),t.JRh(a.msg)}}let U=(()=>{class o{constructor(){this.dismissible=!0,this.defaultAlerts=[{type:"success",msg:"You successfully read this important alert message."},{type:"info",msg:"This alert needs your attention, but it's not super important."},{type:"danger",msg:"Better check yourself, you're not looking too good."}],this.alerts=this.defaultAlerts}reset(){this.alerts=this.defaultAlerts}onClosed(a){this.alerts=this.alerts.filter(l=>l!==a)}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-dismiss"]],decls:5,vars:1,consts:[[4,"ngFor","ngForOf"],["type","button",1,"btn","btn-primary",3,"click"],[3,"onClosed","type","dismissible"]],template:function(l,m){1&l&&(t.DNE(0,O,3,3,"div",0),t.j41(1,"button",1),t.bIt("click",function(){return m.dismissible=!m.dismissible}),t.EFF(2,"Toggle dismissible"),t.k0s(),t.j41(3,"button",1),t.bIt("click",function(){return m.reset()}),t.EFF(4,"Reset"),t.k0s()),2&l&&t.Y8G("ngForOf",m.alerts)},dependencies:[h,r.Sq],encapsulation:2})}return o})();var S=e(345);function d(o,f){if(1&o&&(t.j41(0,"div")(1,"alert",1),t.nrm(2,"span",2),t.k0s()()),2&o){const a=f.$implicit;t.R7$(),t.Y8G("type",a.type),t.R7$(),t.Y8G("innerHtml",a.msg,t.npT)}}let y=(()=>{class o{constructor(a){this.alerts=[{type:"success",msg:"Well done! You successfully read this important alert message."},{type:"info",msg:"Heads up! This alert needs your attention, but it's not super important."},{type:"danger",msg:"Warning! Better check yourself, you're not looking too good."}].map(l=>({type:l.type,msg:a.bypassSecurityTrustHtml(l.msg)}))}static#t=this.\u0275fac=function(l){return new(l||o)(t.rXU(S.up))};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-dynamic-html"]],decls:1,vars:1,consts:[[4,"ngFor","ngForOf"],[3,"type"],[3,"innerHtml"]],template:function(l,m){1&l&&t.DNE(0,d,3,2,"div",0),2&l&&t.Y8G("ngForOf",m.alerts)},dependencies:[h,r.Sq],encapsulation:2})}return o})();function s(o,f){if(1&o){const a=t.RV6();t.j41(0,"div")(1,"button",3),t.bIt("click",function(){t.eBV(a);const m=t.XpG();return t.Njj(m.changeText())}),t.EFF(2,"Change text"),t.k0s()()}}function c(o,f){if(1&o){const a=t.RV6();t.j41(0,"button",3),t.bIt("click",function(){t.eBV(a);const m=t.XpG();return t.Njj(m.index=0)}),t.EFF(1,"Reset"),t.k0s()}}let u=(()=>{class o{constructor(){this.index=0,this.messages=["You successfully read this important alert message.","Now this text is different from what it was before. Go ahead and click the button one more time","Well done! Click reset button and you'll see the first message"]}changeText(){this.messages.length-1!==this.index&&this.index++}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-content-html"]],decls:5,vars:3,consts:[["elseBlock",""],["type","success"],[4,"ngIf","ngIfElse"],[1,"btn","btn-primary",3,"click"]],template:function(l,m){if(1&l&&(t.j41(0,"alert",1),t.EFF(1),t.k0s(),t.DNE(2,s,3,0,"div",2)(3,c,2,0,"ng-template",null,0,t.C5r)),2&l){const T=t.sdS(4);t.R7$(),t.JRh(m.messages[m.index]),t.R7$(),t.Y8G("ngIf",m.index!==m.messages.length-1)("ngIfElse",T)}},dependencies:[h,r.bT],encapsulation:2})}return o})();function g(o,f){if(1&o){const a=t.RV6();t.j41(0,"div")(1,"alert",2),t.bIt("onClosed",function(){const m=t.eBV(a).$implicit,T=t.XpG();return t.Njj(T.onClosed(m))}),t.EFF(2),t.k0s()()}if(2&o){const a=f.$implicit;t.R7$(),t.Y8G("type",a.type)("dismissOnTimeout",a.timeout),t.R7$(),t.JRh(a.msg)}}let A=(()=>{class o{constructor(){this.alerts=[{type:"success",msg:`Well done! You successfully read this important alert message. (added: ${(new Date).toLocaleTimeString()})`,timeout:5e3}]}add(){this.alerts.push({type:"info",msg:`This alert will be closed in 5 seconds (added: ${(new Date).toLocaleTimeString()})`,timeout:5e3})}onClosed(a){this.alerts=this.alerts.filter(l=>l!==a)}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-timeout"]],decls:8,vars:1,consts:[[4,"ngFor","ngForOf"],["type","button",1,"btn","btn-primary",3,"click"],[3,"onClosed","type","dismissOnTimeout"]],template:function(l,m){1&l&&(t.j41(0,"p"),t.EFF(1,"If you missed alert under me, just press "),t.j41(2,"code"),t.EFF(3,"Add more"),t.k0s(),t.EFF(4," button"),t.k0s(),t.DNE(5,g,3,3,"div",0),t.j41(6,"button",1),t.bIt("click",function(){return m.add()}),t.EFF(7,"Add more"),t.k0s()),2&l&&(t.R7$(5),t.Y8G("ngForOf",m.alerts))},dependencies:[h,r.Sq],encapsulation:2})}return o})(),F=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-styling-global"]],decls:4,vars:0,consts:[["type","md-color"]],template:function(l,m){1&l&&(t.j41(0,"alert",0)(1,"strong"),t.EFF(2,"Well done!"),t.k0s(),t.EFF(3," You successfully read this important alert message.\n"),t.k0s())},dependencies:[h],styles:["\n .alert-md-color {\n background-color: #7B1FA2;\n border-color: #4A148C;\n color: #fff;\n }\n"],encapsulation:2})}return o})(),I=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-styling-local"]],decls:4,vars:0,consts:[["type","md-local"]],template:function(l,m){1&l&&(t.j41(0,"alert",0)(1,"strong"),t.EFF(2,"Well done!"),t.k0s(),t.EFF(3," You successfully read this important alert message.\n"),t.k0s())},dependencies:[h],styles:["[_nghost-%COMP%] .alert-md-local[_ngcontent-%COMP%]{background-color:#009688;border-color:#00695c;color:#fff}"]})}return o})();function Y(){return Object.assign(new E,{type:"success"})}let G=(()=>{class o{static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["demo-alert-config"]],features:[t.Jv_([{provide:E,useFactory:Y}])],decls:8,vars:0,consts:[["type","info"]],template:function(l,m){1&l&&(t.j41(0,"alert")(1,"strong"),t.EFF(2,"Well done!"),t.k0s(),t.EFF(3," You successfully read this important alert message.\n"),t.k0s(),t.j41(4,"alert",0)(5,"strong"),t.EFF(6,"Heads up!"),t.k0s(),t.EFF(7," This alert needs your attention, but it's not super important.\n"),t.k0s())},dependencies:[h],encapsulation:2})}return o})();const X=[{name:"Overview",anchor:"overview",tabName:"overview",outlet:b.xK,content:[{title:"Basic",anchor:"basic",description:"
Alerts are available for any length of text, as well as an optional dismiss\n button. For proper styling, use one of the four required\n contextual classes (e.g., .alert-success
). For inline\n dismissal, use the dismissible
property.
Use the .alert-link
utility class to quickly provide matching\n colored links within any alert.
Alerts can also contain additional HTML elements like headings and\n paragraphs.
",component:e(60491),html:e(40051),outlet:x},{title:"Dismissing",anchor:"dismissing",description:"Alerts have dismiss
option. Enabling it will show close button\n to the right of the alert.
Sometimes you will need to show dynamically generated html in alerts, here\n is how you can make it. And don't forget to sanitize your html.
",component:e(23987),html:e(58283),outlet:y},{title:"Dynamic content",anchor:"dynamic-content",description:"Alerts fully support bindings.
",component:e(73731),html:e(44123),outlet:u},{title:"Dismiss on timeout",anchor:"dismiss-on-timeout",description:"You can simply set timeout in milliseconds to dismissOnTimeout
\n property to create self closable alerts.
You can add additional types of alerts globally.
",component:e(22537),html:e(18173),outlet:F},{title:"Component level styling",anchor:"local-styling",description:"You can add additional types of alerts directly to containing component
",component:e(35743),html:e(28807),outlet:I},{title:"Configuring defaults",anchor:"configuration",description:"It is possible to override default alert config partially or completely.
",component:e(82401),html:e(4101),outlet:G}]},{name:"Installation",anchor:"api-reference",tabName:"api",usage:e(2796),importInfo:'ng add ngx-bootstrap --component alerts',outlet:b.Mg,content:[{title:"AlertComponent",anchor:"alert-component",outlet:b.r2},{title:"AlertConfig",anchor:"alert-config",outlet:b.TJ}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:b.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:v},{title:"Link color",anchor:"link-color-ex",outlet:D},{title:"Additional content",anchor:"additional-content-ex",outlet:x},{title:"Dismissing",anchor:"dismissing-ex",outlet:U},{title:"Dynamic html",anchor:"dynamic-html-ex",outlet:y},{title:"Dynamic content",anchor:"dynamic-content-ex",outlet:u},{title:"Dismiss on timeout",anchor:"dismiss-on-timeout-ex",outlet:A},{title:"Global styling",anchor:"global-styling-ex",outlet:F},{title:"Component level styling",anchor:"local-styling-ex",outlet:I},{title:"Configuring defaults",anchor:"configuration-ex",outlet:G}]}];var L=e(86223),N=e(52439);let P=(()=>{class o{constructor(){this.name="Alerts",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/alert",this.componentContent=X}static#t=this.\u0275fac=function(l){return new(l||o)};static#e=this.\u0275cmp=t.VBU({type:o,selectors:[["alert-section"]],decls:6,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(l,m){1&l&&(t.j41(0,"demo-section",0)(1,"p"),t.EFF(2,"Provides contextual feedback messages for typical user actions with the handful of available and flexible alert messages."),t.k0s(),t.j41(3,"p"),t.EFF(4,"The easiest way to add an alerts component to your app (will be added to the root module)"),t.k0s(),t.nrm(5,"docs-section",1),t.k0s()),2&l&&(t.Y8G("name",m.name)("src",m.src)("componentContent",m.componentContent),t.R7$(5),t.Y8G("content",m.componentContent))},dependencies:[L.q,N.C],encapsulation:2,changeDetection:0})}return o})();const W=[{path:"",component:P}];let w=(()=>{class o{static#t=this.routes=W;static#e=this.\u0275fac=function(l){return new(l||o)};static#n=this.\u0275mod=t.$C({type:o});static#o=this.\u0275inj=t.G2t({imports:[R,r.MD,b.ky,n.iI.forChild(W)]})}return o})()},67007:(p,i,e)=>{e.r(i),e.d(i,{default:()=>r});const r='Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content.
\nWhenever you need to, be sure to use margin utilities to keep things nice and tidy.
\nIf you missed alert under me, just press Add more
button
Limit the maximum visible page numbers
",outlet:v},{title:"Centering the active page link",anchor:"pagination-rotate",component:o(54363),html:o(7275),description:"Set current page link to center
",outlet:B},{title:"Content switching",anchor:"content-switching",component:o(81588),html:o(27700),outlet:L},{title:"Pager",anchor:"pagination-pager",component:o(43528),html:o(55e3),outlet:x},{title:"Custom Template",anchor:"custom-template",description:"\n\n It is possible to customize what exactly is displayed in each pagination link. To overwrite default\n templates use these inputs:\n
customPageTemplate
customNextTemplate
customPreviousTemplate
customFirstTemplate
customLastTemplate
PaginationLinkContext
is available for all\n templates and for page numbers there is a PaginationNumberLinkContext
that\n contains the page number.\n \n ",component:o(31836),html:o(19180),outlet:R}]},{name:"Installation",anchor:"api-reference",tabName:"api",outlet:h.Mg,usage:o(4253),importInfo:'ng add ngx-bootstrap --component pagination',content:[{title:"PaginationComponent",anchor:"pagination-component",outlet:h.r2},{title:"PagerComponent",anchor:"pager-component",outlet:h.r2},{title:"PaginationConfig",anchor:"pagination-config",outlet:h.TJ},{title:"PaginationLinkContext",anchor:"pagination-link-context",outlet:h.TJ},{title:"PaginationNumberLinkContext",anchor:"pagination-number-link-context",outlet:h.TJ},{title:"PagesModel",anchor:"pagination-models",outlet:h.TJ}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:h.xK,description:"On small screens bootstrap4 pagination can be cropped
",content:[{title:"Basic",anchor:"basic-ex",outlet:_},{title:"Manual switching page",anchor:"manual-switching-ex",outlet:y},{title:"Page changed event",anchor:"page-changed-event-ex",outlet:k},{title:"Pages count changed event",anchor:"pages-count-changed-ex",outlet:D},{title:"Boundary links",anchor:"boundary-links-ex",outlet:I},{title:"Direction links",anchor:"direction-links-ex",outlet:F},{title:"Custom links content",anchor:"custom-links-content-ex",outlet:E},{title:"Disabled",anchor:"pagination-disabled-ex",outlet:S},{title:"Limits",anchor:"pagination-limit-ex",outlet:v},{title:"Centering the active page link",anchor:"pagination-rotate-ex",outlet:B},{title:"Content switching",anchor:"content-switching-ex",outlet:L},{title:"Pager",anchor:"pagination-pager-ex",outlet:x},{title:"Custom Template",anchor:"custom-template-ex",outlet:R}]}];var mt=o(86223),ct=o(52439);let M=(()=>{class n{constructor(){this.name="Pagination",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/pagination",this.componentContent=rt}static#t=this.\u0275fac=function(a){return new(a||n)};static#e=this.\u0275cmp=t.VBU({type:n,selectors:[["pagination-section"]],decls:12,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(a,i){1&a&&(t.j41(0,"demo-section",0)(1,"p")(2,"strong"),t.EFF(3,"Pagination"),t.k0s(),t.EFF(4," - provide pagination links for your site or app with the multi-page pagination component, or the simpler pager alternative."),t.k0s(),t.j41(5,"p")(6,"strong"),t.EFF(7,"Pager"),t.k0s(),t.EFF(8," - quick previous and next links for simple pagination implementations with light markup and styles. It's great for simple sites like blogs or magazines."),t.k0s(),t.j41(9,"p"),t.EFF(10,"The easiest way to add the pagination component to your app (will be added to the root module)"),t.k0s(),t.nrm(11,"docs-section",1),t.k0s()),2&a&&(t.Y8G("name",i.name)("src",i.src)("componentContent",i.componentContent),t.R7$(11),t.Y8G("content",i.componentContent))},dependencies:[mt.q,ct.C],encapsulation:2,changeDetection:0})}return n})();const pt=[{path:"",component:M}];let ut=(()=>{class n{static#t=this.\u0275fac=function(a){return new(a||n)};static#e=this.\u0275mod=t.$C({type:n});static#n=this.\u0275inj=t.G2t({imports:[Q,g.MD,d.YN,h.ky,A.iI.forChild(pt)]})}return n})()},31324:(c,s,o)=>{o.r(s),o.d(s,{default:()=>g});const g='{{content}}
\n\n Page changed to: {{page}}\n\n'},81384:(c,s,o)=>{o.r(s),o.d(s,{default:()=>g});const g="import { Component } from '@angular/core';\nimport { PageChangedEvent } from 'ngx-bootstrap/pagination';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-pagination-page-changed-event',\n templateUrl: './page-changed-event.html'\n})\nexport class DemoPaginationPageChangedComponent {\n currentPage = 4;\n page?: number;\n\n pageChanged(event: PageChangedEvent): void {\n this.page = event.page;\n }\n}\n"},55e3:(c,s,o)=>{o.r(s),o.d(s,{default:()=>g});const g='
The selected page no: {{currentPage}}/{{smallnumPages}}\n'},81496:(c,s,o)=>{o.r(s),o.d(s,{default:()=>g});const g="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-pagination-pages-count-changed',\n templateUrl: './pages-count-changed.html'\n})\nexport class DemoPaginationPagesCountChangedComponent {\n currentPage = 4;\n smallnumPages = 0;\n}\n"},7275:(c,s,o)=>{o.r(s),o.d(s,{default:()=>g});const g='
Four base positioning options are available: top
, right
,\n bottom
, and left
.\n Besides that, auto
option may be used to detect a position that fits the component on screen.
Placement property of a popover can contain "corner placement" specifier following the base positioning.\n Thus, in addition to the four base positioning options, namely top
, right
,\n bottom
, and left
, eight more positioning options are available: top left
, top right
,\n right top
, right bottom
, bottom right
, bottom left
, left bottom
, and left top
.',component:o(28587),html:o(96083),outlet:j},{title:"Disable adaptive position",anchor:"adaptive-position",description:"\n
You can disable adaptive position via adaptivePosition
input or config option
You can control the popover boundaries via boundariesElement
input or config option. boundariesElement
property of a popover can contain boundaries namely viewport, scrollParent, window
.
Use the focus
trigger to dismiss popovers on the next click that the\n user makes.
Pass a string as popover content.
",outlet:O},{title:"Custom content template",anchor:"custom-content-template",component:o(70843),html:o(89795),description:'Create <ng-template #myId>
with any html allowed by Angular,\n and provide template ref [popover]="myId"
as popover content.
By using [innerHtml]
inside ng-template
you can display any dynamic html
When you have any styles on a parent element that interfere with a popover,\n you\u2019ll want to specify a container="body"
so that the popover\u2019s HTML will be\n appended to body. This will help to avoid rendering problems in more complex components\n (like input groups, button groups, etc) or inside elements with overflow: hidden
This demo shows manipulating popover by show
,\n hide
and toggle
methods
You can show/hide popover by switching isOpen
property
Click on the button to see popover delayed for 0,5 second
",outlet:F}]},{name:"Installation",anchor:"api-reference",tabName:"api",usage:o(65804),importInfo:'ng add ngx-bootstrap --component popover',outlet:m.Mg,content:[{title:"PopoverDirective",anchor:"popover-directive",outlet:m.r2},{title:"PopoverConfig",anchor:"popover-config",outlet:m.TJ}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:m.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:h},{title:"Placement",anchor:"placement-ex",outlet:V},{title:"Corner placement",anchor:"corner-placement-ex",outlet:j},{title:"Disable adaptive position",anchor:"adaptive-position-ex",outlet:f},{title:"Adaptive position with overflow boundary",anchor:"adaptive-position-overflow-boundary-ex",outlet:W},{title:"Dismiss on next click",anchor:"popover-dismiss-ex",outlet:A},{title:"Dynamic content",anchor:"dynamic-content-ex",outlet:O},{title:"Custom content template",anchor:"custom-content-template-ex",outlet:D},{title:"Dynamic Html",anchor:"dynamic-html-ex",outlet:U},{title:"Append to body",anchor:"container-body-ex",outlet:T},{title:"Visibility events",anchor:"events-ex",outlet:B},{title:"Configuring defaults",anchor:"config-defaults-ex",outlet:C},{title:"Outside click",anchor:"outside-click-ex",outlet:x},{title:"Custom triggers",anchor:"triggers-custom-ex",outlet:H},{title:"Manual triggering",anchor:"triggers-manual-ex",outlet:L},{title:"Trigger by isOpen property",anchor:"trigger-by-isopen-property-ex",outlet:y},{title:"Component level styling",anchor:"styling-local-ex",outlet:R},{title:"Custom class",anchor:"popover-custom-class-ex",outlet:P},{title:"Popover context",anchor:"popover-context-ex",outlet:E},{title:"Popover with delay",anchor:"popover-delay-ex",outlet:F}]}];var $=o(86223),N=o(52439);let G=(()=>{class n{constructor(){this.name="Popover",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/popover",this.componentContent=I}static#t=this.\u0275fac=function(s){return new(s||n)};static#o=this.\u0275cmp=t.VBU({type:n,selectors:[["tooltip-section"]],decls:6,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(s,r){1&s&&(t.j41(0,"demo-section",0)(1,"p"),t.EFF(2,"Add small overlay content, like those found in iOS, to any element for housing secondary information."),t.k0s(),t.j41(3,"p"),t.EFF(4,"The easiest way to add the popover component to your app (will be added to the root module)"),t.k0s(),t.nrm(5,"docs-section",1),t.k0s()),2&s&&(t.Y8G("name",r.name)("src",r.src)("componentContent",r.componentContent),t.R7$(5),t.Y8G("content",r.componentContent))},dependencies:[$.q,N.C],encapsulation:2,changeDetection:0})}return n})();const k=[{path:"",component:G}];let J=(()=>{class n{static#t=this.\u0275fac=function(s){return new(s||n)};static#o=this.\u0275mod=t.$C({type:n});static#e=this.\u0275inj=t.G2t({imports:[p.MD,u.YN,m.ky,g.k0,S.iI.forChild(k)]})}return n})()},24755:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='\n \n
\n\n'},28587:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='import { Component } from \'@angular/core\';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: \'demo-popover-corner-placement\',\n templateUrl: \'./corner-placement.html\'\n})\nexport class DemoPopoverCornerPlacementComponent {\n placements = [\n \'top left\',\n \'top right\',\n \'right top\',\n \'right bottom\',\n \'bottom right\',\n \'bottom left\',\n \'left bottom\',\n \'left top\'\n ];\n placement: "top" | "bottom" | "left" | "right" | "auto" | "top left" | "top right" | "right top" | "right bottom" | "bottom right" | "bottom left" | "left bottom" | "left top" = \'top left\';\n}\n'},89795:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='Event: {{message}}\n'},33763:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-popover-events',\n templateUrl: './events.html'\n})\nexport class DemoPopoverEventsComponent {\n message?: string;\n\n onShown(): void {\n this.message = 'shown';\n }\n\n onHidden(): void {\n this.message = 'hidden';\n }\n}\n"},11527:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='\n\n'},20319:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-popover-outside-click',\n templateUrl: './outside-click.html'\n})\nexport class DemoPopoverOutsideClickComponent {}\n"},81003:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='\n\n\n\n\n\n\n\n\n'},92307:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-popover-placement',\n templateUrl: './placement.html'\n})\nexport class DemoPopoverPlacementComponent {}\n"},56571:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='
\n \n This text has attached popover\n \n
\n\n'},66627:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-popover-trigger-by-isopen',\n templateUrl: './trigger-by-isopen-property.html'\n})\nexport class DemoPopoverByIsOpenPropComponent {\n isOpen = false;\n}\n"},84731:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p='\n \n This text has attached popover\n \n
\n\n\n\n\n'},30839:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-popover-triggers-manual',\n templateUrl: './triggers-manual.html'\n})\nexport class DemoPopoverTriggersManualComponent {}\n"},65804:(a,e,o)=>{o.r(e),o.d(e,{default:()=>p});const p="### Standalone component usage\nimport { PopoverModule } from 'ngx-bootstrap/popover';\n\n@Component({\n standalone: true,\n imports: [PopoverModule,...]\n})\nexport class AppComponent(){}\n\n### Module usage\nimport { PopoverModule } from 'ngx-bootstrap/popover';\n\n@NgModule({\n imports: [PopoverModule,...]\n})\nexport class AppModule(){}\n"}}]); \ No newline at end of file diff --git a/412.c7fae957d9db9049.js b/412.c7fae957d9db9049.js new file mode 100644 index 0000000000..65646cb1a1 --- /dev/null +++ b/412.c7fae957d9db9049.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[412],{14412:(u,s,o)=>{o.r(s),o.d(s,{ButtonsSectionComponent:()=>E,DemoButtonsModule:()=>_});var r=o(60177),c=o(84341),T=o(8681),e=o(54438);const x={provide:c.kq,useExisting:(0,e.Rfq)(()=>g),multi:!0};let g=(()=>{class i{constructor(){this.btnCheckboxTrue=!0,this.btnCheckboxFalse=!1,this.state=!1,this.isDisabled=!1,this.onChange=Function.prototype,this.onTouched=Function.prototype}onClick(){this.isDisabled||(this.toggle(!this.state),this.onChange(this.value))}ngOnInit(){this.toggle(this.trueValue===this.value)}get trueValue(){return!(typeof this.btnCheckboxTrue<"u")||this.btnCheckboxTrue}get falseValue(){return typeof this.btnCheckboxFalse<"u"&&this.btnCheckboxFalse}toggle(t){this.state=t,this.value=this.state?this.trueValue:this.falseValue}writeValue(t){this.state=this.trueValue===t,this.value=t?this.trueValue:this.falseValue}setDisabledState(t){this.isDisabled=t}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275dir=e.FsC({type:i,selectors:[["","btnCheckbox",""]],hostVars:3,hostBindings:function(l,n){1&l&&e.bIt("click",function(){return n.onClick()}),2&l&&(e.BMQ("aria-pressed",n.state),e.AVh("active",n.state))},inputs:{btnCheckboxTrue:"btnCheckboxTrue",btnCheckboxFalse:"btnCheckboxFalse"},standalone:!0,features:[e.Jv_([x])]})}return i})();const A={provide:c.kq,useExisting:(0,e.Rfq)(()=>h),multi:!0};let h=(()=>{class i{get value(){return this.group?this.group.value:this._value}set value(t){this.group?this.group.value=t:(this._value=t,this._onChange(t))}get disabled(){return this._disabled}set disabled(t){this.setDisabledState(t)}get controlOrGroupDisabled(){return!!(this.disabled||this.group&&this.group.disabled)||void 0}get hasDisabledClass(){return this.controlOrGroupDisabled&&!this.isActive}get isActive(){return this.btnRadio===this.value}get tabindex(){if(!this.controlOrGroupDisabled)return this.isActive||null==this.group?0:-1}get hasFocus(){return this._hasFocus}constructor(t,l,n,d){this.el=t,this.cdr=l,this.renderer=n,this.group=d,this.onChange=Function.prototype,this.onTouched=Function.prototype,this.uncheckable=!1,this.role="radio",this._disabled=!1,this._hasFocus=!1}toggleIfAllowed(){this.canToggle()&&(this.value=this.uncheckable&&this.btnRadio===this.value?void 0:this.btnRadio)}onSpacePressed(t){this.toggleIfAllowed(),t.preventDefault()}focus(){this.el.nativeElement.focus()}onFocus(){this._hasFocus=!0}onBlur(){this._hasFocus=!1,this.onTouched()}canToggle(){return!this.controlOrGroupDisabled&&(this.uncheckable||this.btnRadio!==this.value)}ngOnChanges(t){"uncheckable"in t&&(this.uncheckable=!1!==this.uncheckable&&typeof this.uncheckable<"u")}_onChange(t){this.group?this.group.value=t:(this.onTouched(),this.onChange(t))}writeValue(t){this.value=t,this.cdr.markForCheck()}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}setDisabledState(t){this._disabled=t,t?this.renderer.setAttribute(this.el.nativeElement,"disabled","disabled"):this.renderer.removeAttribute(this.el.nativeElement,"disabled")}static#e=this.\u0275fac=function(l){return new(l||i)(e.rXU(e.aKT),e.rXU(e.gRc),e.rXU(e.sFG),e.rXU((0,e.Rfq)(()=>p),8))};static#t=this.\u0275dir=e.FsC({type:i,selectors:[["","btnRadio",""]],hostVars:8,hostBindings:function(l,n){1&l&&e.bIt("click",function(){return n.toggleIfAllowed()})("keydown.space",function(a){return n.onSpacePressed(a)})("focus",function(){return n.onFocus()})("blur",function(){return n.onBlur()}),2&l&&(e.BMQ("aria-disabled",n.controlOrGroupDisabled)("aria-checked",n.isActive)("role",n.role)("tabindex",n.tabindex),e.AVh("disabled",n.hasDisabledClass)("active",n.isActive))},inputs:{btnRadio:"btnRadio",uncheckable:"uncheckable",value:"value",disabled:"disabled"},standalone:!0,features:[e.Jv_([A]),e.OA$]})}return i})();const G={provide:c.kq,useExisting:(0,e.Rfq)(()=>p),multi:!0};let p=(()=>{class i{constructor(t){this.cdr=t,this.onChange=Function.prototype,this.onTouched=Function.prototype,this.role="radiogroup",this._disabled=!1}get value(){return this._value}set value(t){this._value=t,this.onChange(t)}get disabled(){return this._disabled}get tabindex(){return this._disabled?null:0}writeValue(t){this._value=t,this.cdr.markForCheck()}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}setDisabledState(t){this.radioButtons&&(this._disabled=t,this.radioButtons.forEach(l=>{l.setDisabledState(t)}),this.cdr.markForCheck())}onFocus(){if(this._disabled)return;const t=this.getActiveOrFocusedRadio();if(t)t.focus();else if(this.radioButtons){const l=this.radioButtons.find(n=>!n.disabled);l&&l.focus()}}onBlur(){this.onTouched&&this.onTouched()}selectNext(t){this.selectInDirection("next"),t.preventDefault()}selectPrevious(t){this.selectInDirection("previous"),t.preventDefault()}selectInDirection(t){if(this._disabled)return;function l(d,a){let f=(d+("next"===t?1:-1))%a.length;return f<0&&(f=a.length-1),f}const n=this.getActiveOrFocusedRadio();if(n&&this.radioButtons){const d=this.radioButtons.toArray(),a=d.indexOf(n);for(let m=l(a,d);m!==a;m=l(m,d))if(d[m].canToggle()){d[m].toggleIfAllowed(),d[m].focus();break}}}getActiveOrFocusedRadio(){if(this.radioButtons)return this.radioButtons.find(t=>t.isActive)||this.radioButtons.find(t=>t.hasFocus)}static#e=this.\u0275fac=function(l){return new(l||i)(e.rXU(e.gRc))};static#t=this.\u0275dir=e.FsC({type:i,selectors:[["","btnRadioGroup",""]],contentQueries:function(l,n,d){if(1&l&&e.wni(d,h,4),2&l){let a;e.mGM(a=e.lsd())&&(n.radioButtons=a)}},hostVars:2,hostBindings:function(l,n){1&l&&e.bIt("focus",function(){return n.onFocus()})("blur",function(){return n.onBlur()})("keydown.ArrowRight",function(a){return n.selectNext(a)})("keydown.ArrowDown",function(a){return n.selectNext(a)})("keydown.ArrowLeft",function(a){return n.selectPrevious(a)})("keydown.ArrowUp",function(a){return n.selectPrevious(a)}),2&l&&e.BMQ("role",n.role)("tabindex",n.tabindex)},standalone:!0,features:[e.Jv_([G])]})}return i})(),U=(()=>{class i{static forRoot(){return i}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275mod=e.$C({type:i});static#n=this.\u0275inj=e.G2t({})}return i})();var b=o(37472);let C=(()=>{class i{static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-basic"]],decls:2,vars:0,consts:[["type","button",1,"btn","btn-primary"]],template:function(l,n){1&l&&(e.j41(0,"button",0),e.EFF(1," Single Button\n"),e.k0s())},encapsulation:2})}return i})(),R=(()=>{class i{constructor(){this.checkModel={left:!1,middle:!0,right:!1}}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-checkbox"]],decls:10,vars:6,consts:[[1,"card","card-block","card-header"],[1,"btn-group"],["btnCheckbox","","tabindex","0","role","button",1,"btn","btn-primary",3,"ngModelChange","ngModel"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.nI1(2,"json"),e.k0s(),e.j41(3,"div",1)(4,"label",2),e.mxI("ngModelChange",function(a){return e.DH7(n.checkModel.left,a)||(n.checkModel.left=a),a}),e.EFF(5,"Left"),e.k0s(),e.j41(6,"label",2),e.mxI("ngModelChange",function(a){return e.DH7(n.checkModel.middle,a)||(n.checkModel.middle=a),a}),e.EFF(7,"Middle"),e.k0s(),e.j41(8,"label",2),e.mxI("ngModelChange",function(a){return e.DH7(n.checkModel.right,a)||(n.checkModel.right=a),a}),e.EFF(9,"Right"),e.k0s()()),2&l&&(e.R7$(),e.JRh(e.bMT(2,4,n.checkModel)),e.R7$(3),e.R50("ngModel",n.checkModel.left),e.R7$(2),e.R50("ngModel",n.checkModel.middle),e.R7$(2),e.R50("ngModel",n.checkModel.right))},dependencies:[c.BC,c.vS,g,r.TG],encapsulation:2})}return i})(),F=(()=>{class i{constructor(){this.radioModel="Middle"}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-radio"]],decls:9,vars:4,consts:[[1,"card","card-block","card-header"],[1,"btn-group"],["btnRadio","Left","tabindex","0","role","button",1,"btn","btn-primary",3,"ngModelChange","ngModel"],["btnRadio","Middle","tabindex","0","role","button",1,"btn","btn-primary",3,"ngModelChange","ngModel"],["btnRadio","Right","tabindex","0","role","button",1,"btn","btn-primary",3,"ngModelChange","ngModel"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.k0s(),e.j41(2,"div",1)(3,"label",2),e.mxI("ngModelChange",function(a){return e.DH7(n.radioModel,a)||(n.radioModel=a),a}),e.EFF(4,"Left"),e.k0s(),e.j41(5,"label",3),e.mxI("ngModelChange",function(a){return e.DH7(n.radioModel,a)||(n.radioModel=a),a}),e.EFF(6,"Middle"),e.k0s(),e.j41(7,"label",4),e.mxI("ngModelChange",function(a){return e.DH7(n.radioModel,a)||(n.radioModel=a),a}),e.EFF(8,"Right"),e.k0s()()),2&l&&(e.R7$(),e.JRh(n.radioModel||"null"),e.R7$(2),e.R50("ngModel",n.radioModel),e.R7$(2),e.R50("ngModel",n.radioModel),e.R7$(2),e.R50("ngModel",n.radioModel))},dependencies:[c.BC,c.vS,h],encapsulation:2})}return i})(),k=(()=>{class i{constructor(){this.uncheckableRadioModel="Middle"}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-radio-uncheckable"]],decls:9,vars:5,consts:[[1,"card","card-block","card-header"],["btnRadioGroup","",1,"btn-group",3,"ngModelChange","ngModel"],["btnRadio","Left","tabindex","0","role","button",1,"btn","btn-info",3,"uncheckable"],["btnRadio","Middle","tabindex","0","role","button",1,"btn","btn-info",3,"uncheckable"],["btnRadio","Right","tabindex","0","role","button",1,"btn","btn-info",3,"uncheckable"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.k0s(),e.j41(2,"div",1),e.mxI("ngModelChange",function(a){return e.DH7(n.uncheckableRadioModel,a)||(n.uncheckableRadioModel=a),a}),e.j41(3,"label",2),e.EFF(4,"Left"),e.k0s(),e.j41(5,"label",3),e.EFF(6,"Middle"),e.k0s(),e.j41(7,"label",4),e.EFF(8,"Right"),e.k0s()()),2&l&&(e.R7$(),e.JRh(n.uncheckableRadioModel||"null"),e.R7$(),e.R50("ngModel",n.uncheckableRadioModel),e.R7$(),e.Y8G("uncheckable",!0),e.R7$(2),e.Y8G("uncheckable",!0),e.R7$(2),e.Y8G("uncheckable",!0))},dependencies:[c.BC,c.vS,h,p],encapsulation:2})}return i})();function O(i,V){if(1&i&&(e.j41(0,"form",2)(1,"div",3)(2,"label",4),e.EFF(3,"Left"),e.k0s(),e.j41(4,"label",5),e.EFF(5,"Middle"),e.k0s(),e.j41(6,"label",6),e.EFF(7,"Right"),e.k0s()()()),2&i){const t=e.XpG();e.Y8G("formGroup",t.myForm),e.R7$(2),e.AVh("active",null==t.myForm?null:t.myForm.value.left),e.R7$(2),e.AVh("active",null==t.myForm?null:t.myForm.value.middle),e.R7$(2),e.AVh("active",null==t.myForm?null:t.myForm.value.right)}}let v=(()=>{class i{constructor(t){this.formBuilder=t}ngOnInit(){this.myForm=this.formBuilder.group({left:!1,middle:!0,right:!1})}static#e=this.\u0275fac=function(l){return new(l||i)(e.rXU(c.ze))};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-checkbox-reactiveforms"]],decls:4,vars:4,consts:[[1,"card","card-block","card-header"],[3,"formGroup",4,"ngIf"],[3,"formGroup"],[1,"btn-group"],["btnCheckbox","","formControlName","left","tabindex","0","role","button",1,"btn","btn-primary"],["btnCheckbox","","formControlName","middle","tabindex","0","role","button",1,"btn","btn-primary"],["btnCheckbox","","formControlName","right","tabindex","0","role","button",1,"btn","btn-primary"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.nI1(2,"json"),e.k0s(),e.DNE(3,O,8,7,"form",1)),2&l&&(e.R7$(),e.JRh(e.bMT(2,2,null==n.myForm?null:n.myForm.value)),e.R7$(2),e.Y8G("ngIf",n.myForm))},dependencies:[c.qT,c.BC,c.cb,c.j4,c.JD,r.bT,g,r.TG],encapsulation:2})}return i})();function j(i,V){if(1&i){const t=e.RV6();e.j41(0,"form",2)(1,"div",3)(2,"div",4)(3,"label",5),e.EFF(4,"A"),e.k0s(),e.j41(5,"label",6),e.EFF(6,"B"),e.k0s(),e.j41(7,"label",7),e.EFF(8,"C"),e.k0s()(),e.j41(9,"button",8),e.bIt("click",function(){e.eBV(t);const n=e.XpG();return e.Njj(null!=n.myForm&&n.myForm.disabled?null==n.myForm?null:n.myForm.enable():null==n.myForm?null:n.myForm.disable())}),e.EFF(10,"Enable/Disable"),e.k0s()()()}if(2&i){const t=e.XpG();e.Y8G("formGroup",t.myForm)}}let B=(()=>{class i{constructor(t){this.formBuilder=t}ngOnInit(){this.myForm=this.formBuilder.group({radio:"C"})}static#e=this.\u0275fac=function(l){return new(l||i)(e.rXU(c.ze))};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-radio-reactiveforms"]],decls:4,vars:4,consts:[[1,"card","card-block","card-header"],["class","form-inline d-flex align-items-center",3,"formGroup",4,"ngIf"],[1,"form-inline","d-flex","align-items-center",3,"formGroup"],[1,"form-group","mb-3"],["btnRadioGroup","","formControlName","radio",1,"btn-group"],["btnRadio","A",1,"btn","btn-primary","mb-0"],["btnRadio","B",1,"btn","btn-primary","mb-0"],["btnRadio","C",1,"btn","btn-primary","mb-0"],[1,"btn","btn-primary",3,"click"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.nI1(2,"json"),e.k0s(),e.DNE(3,j,11,1,"form",1)),2&l&&(e.R7$(),e.JRh(e.bMT(2,2,null==n.myForm?null:n.myForm.value)),e.R7$(2),e.Y8G("ngIf",n.myForm))},dependencies:[c.qT,c.BC,c.cb,c.j4,c.JD,r.bT,h,p,r.TG],encapsulation:2})}return i})(),M=(()=>{class i{constructor(){this.disabled=!1}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-disabled"]],decls:4,vars:1,consts:[["type","button",1,"btn","btn-primary",3,"disabled"],["type","button",1,"btn","btn-warning",3,"click"]],template:function(l,n){1&l&&(e.j41(0,"button",0),e.EFF(1,"Button"),e.k0s(),e.j41(2,"button",1),e.bIt("click",function(){return n.disabled=!n.disabled}),e.EFF(3,"Enable/Disable"),e.k0s()),2&l&&e.Y8G("disabled",n.disabled)},encapsulation:2})}return i})(),D=(()=>{class i{constructor(){this.singleModel="1"}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-custom-checkbox-value"]],decls:4,vars:2,consts:[[1,"card","card-block","card-header"],["type","button","btnCheckbox","","btnCheckboxTrue","1","btnCheckboxFalse","0",1,"btn","btn-primary",3,"ngModelChange","ngModel"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.k0s(),e.j41(2,"button",1),e.mxI("ngModelChange",function(a){return e.DH7(n.singleModel,a)||(n.singleModel=a),a}),e.EFF(3," Single Toggle\n"),e.k0s()),2&l&&(e.R7$(),e.JRh(n.singleModel),e.R7$(),e.R50("ngModel",n.singleModel))},dependencies:[c.BC,c.vS,g],encapsulation:2})}return i})(),y=(()=>{class i{constructor(){this.radioModel="Middle",this.radioModelDisabled="Middle",this.modelGroupDisabled=!1}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["demo-buttons-radio-with-group"]],decls:24,vars:6,consts:[[1,"card","card-block","card-header"],[1,"form-inline","d-flex","align-items-center"],["btnRadioGroup","",1,"btn-group",3,"ngModelChange","ngModel","disabled"],["btnRadio","Left",1,"btn","btn-success","mb-0"],["btnRadio","Middle",1,"btn","btn-success","mb-0"],["btnRadio","Another",1,"btn","btn-success","mb-0",3,"disabled"],["btnRadio","Right",1,"btn","btn-success","mb-0"],[1,"btn","btn-warning",3,"click"],["btnRadioGroup","","disabled","",1,"btn-group",3,"ngModelChange","ngModel"],["btnRadio","Left",1,"btn","btn-success"],["btnRadio","Middle",1,"btn","btn-success"],["btnRadio","Right",1,"btn","btn-success"]],template:function(l,n){1&l&&(e.j41(0,"pre",0),e.EFF(1),e.k0s(),e.j41(2,"div",1)(3,"div",2),e.mxI("ngModelChange",function(a){return e.DH7(n.radioModel,a)||(n.radioModel=a),a}),e.j41(4,"label",3),e.EFF(5,"Left"),e.k0s(),e.j41(6,"label",4),e.EFF(7,"Middle"),e.k0s(),e.j41(8,"label",5),e.EFF(9,"Disabled"),e.k0s(),e.j41(10,"label",6),e.EFF(11,"Right"),e.k0s()(),e.j41(12,"button",7),e.bIt("click",function(){return n.modelGroupDisabled=!n.modelGroupDisabled}),e.EFF(13,"Enable/Disable"),e.k0s()(),e.j41(14,"pre",0),e.EFF(15),e.k0s(),e.j41(16,"div",1)(17,"div",8),e.mxI("ngModelChange",function(a){return e.DH7(n.radioModelDisabled,a)||(n.radioModelDisabled=a),a}),e.j41(18,"label",9),e.EFF(19,"Left"),e.k0s(),e.j41(20,"label",10),e.EFF(21,"Middle"),e.k0s(),e.j41(22,"label",11),e.EFF(23,"Right"),e.k0s()()()),2&l&&(e.R7$(),e.JRh(n.radioModel||"null"),e.R7$(2),e.R50("ngModel",n.radioModel),e.Y8G("disabled",n.modelGroupDisabled),e.R7$(5),e.Y8G("disabled",!0),e.R7$(7),e.JRh(n.radioModelDisabled||"null"),e.R7$(2),e.R50("ngModel",n.radioModelDisabled))},dependencies:[c.BC,c.vS,h,p],encapsulation:2})}return i})();const I=[{name:"Overview",anchor:"overview",tabName:"overview",outlet:b.xK,content:[{title:"Basic",anchor:"basic",component:o(46747),html:o(57475),outlet:C},{title:"Checkbox",anchor:"checkbox",description:"Checkbox-like buttons set with variable states",component:o(21391),html:o(16567),outlet:R},{title:"Custom checkbox value",anchor:"custom-checkbox-value",component:o(93207),html:o(53615),outlet:D},{title:"Checkbox with Reactive Forms",anchor:"checkbox-reactiveforms",description:"Checkbox buttons with ReactiveForms",component:o(33657),html:o(53517),outlet:v},{title:"Radio with radio group",anchor:"radio-button-with-group",description:'Radio buttons with checked/unchecked states. Radio buttons used together with abtnRadioGroup
can be\nused in template driven and reactive forms.\nThey follow the W3C WAI-AIRA design pattern for radio groups.\nMeaning\nngModel
binding with several buttons.\n This works only for template driven forms and is not generally advised. But there are use cases were this might be useful, e.g. in tables.\n In terms of accessibility the buttons in the group can not be selected with the arrow keys, but individually reached by using the tab key\n and then be toggled by using the space key. You can check out the demo below.",component:o(32951),html:o(77436),outlet:F},{title:"Uncheckable Radio",anchor:"uncheckable-radio-button",component:o(92695),html:o(687),outlet:k},{title:"Radio with Reactive Forms",anchor:"radio-reactiveforms",description:"Radio buttons with ReactiveForms. Example below shows how to use radio buttons with reactive\n forms. Please be aware that for reactive forms it's required to use btnRadioGroup
directive along with\n btnRadio
's",component:o(6299),html:o(44387),outlet:B},{title:"Disabled Buttons",anchor:"disabled-buttons",component:o(35165),html:o(95217),outlet:M}]},{name:"Installation",anchor:"api-reference",tabName:"api",outlet:b.Mg,usage:o(84704),importInfo:'ng add ngx-bootstrap --component buttons',content:[{title:"ButtonCheckboxDirective",anchor:"button-checkbox-directive",outlet:b.r2},{title:"ButtonRadioDirective",anchor:"button-radio-directive",outlet:b.r2},{title:"ButtonRadioGroupDirective",anchor:"button-radio-group-directive",outlet:b.r2}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:b.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:C},{title:"Checkbox",anchor:"checkbox-ex",outlet:R},{title:"Custom checkbox value",anchor:"custom-checkbox-value-ex",outlet:D},{title:"Checkbox with Reactive Forms",anchor:"checkbox-reactiveforms-ex",outlet:v},{title:"Radio with radio group",anchor:"radio-button-with-group-ex",outlet:y},{title:"Radio without explicit group",anchor:"radio-button-explicit-group-ex",outlet:F},{title:"Uncheckable Radio",anchor:"uncheckable-radio-button-ex",outlet:k},{title:"Radio with Reactive Forms",anchor:"radio-reactiveforms-ex",outlet:B},{title:"Disabled Buttons",anchor:"disabled-buttons-ex",outlet:M}]}];var w=o(86223),L=o(52439);let E=(()=>{class i{constructor(){this.name="Buttons",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/buttons",this.componentContent=I}static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275cmp=e.VBU({type:i,selectors:[["buttons-section"]],decls:6,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(l,n){1&l&&(e.j41(0,"demo-section",0)(1,"p"),e.EFF(2,"There are two directives that can make a group of buttons behave like a set of checkboxes, radio buttons, or a hybrid where radio buttons can be unchecked."),e.k0s(),e.j41(3,"p"),e.EFF(4,"The easiest way to add the buttons component to your app (will be added to the root module)"),e.k0s(),e.nrm(5,"docs-section",1),e.k0s()),2&l&&(e.Y8G("name",n.name)("src",n.src)("componentContent",n.componentContent),e.R7$(5),e.Y8G("content",n.componentContent))},dependencies:[w.q,L.C],encapsulation:2,changeDetection:0})}return i})();const P=[{path:"",component:E}];let _=(()=>{class i{static#e=this.\u0275fac=function(l){return new(l||i)};static#t=this.\u0275mod=e.$C({type:i});static#n=this.\u0275inj=e.G2t({imports:[c.YN,c.X1,r.MD,b.ky,T.iI.forChild(P),U]})}return i})()},57475:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='\n'},46747:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-buttons-basic',\n templateUrl: './basic.html'\n})\nexport class DemoButtonsBasicComponent {}\n"},53517:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='{{myForm?.value | json}}\n\n'},33657:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r="import { Component, OnInit } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-buttons-checkbox-reactiveforms',\n templateUrl: './checkbox-reactiveforms.html'\n})\nexport class DemoButtonsCheckboxReactiveFormsComponent implements OnInit {\n myForm?: UntypedFormGroup;\n\n constructor(private formBuilder: UntypedFormBuilder) {}\n\n ngOnInit() {\n this.myForm = this.formBuilder.group({\n left: false,\n middle: true,\n right: false\n });\n }\n}\n"},16567:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='
{{checkModel | json}}\n\n
{{singleModel}}\n\n'},93207:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-custom-checkbox-value',\n templateUrl: './custom-checkbox-value.html'\n})\nexport class DemoButtonsCustomCheckboxValueComponent {\n singleModel = '1';\n}\n"},95217:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='\n\n\n'},35165:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-buttons-disabled',\n templateUrl: './disabled.html'\n})\nexport class DemoButtonsDisabledComponent {\n disabled = false;\n}\n"},44387:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='
{{ myForm?.value | json }}\n\n'},6299:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r="import { Component, OnInit } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-buttons-radio-reactiveforms',\n templateUrl: './radio-reactiveforms.html'\n})\nexport class DemoButtonsRadioReactiveFormsComponent implements OnInit {\n myForm?: UntypedFormGroup;\n\n constructor(private formBuilder: UntypedFormBuilder) {}\n\n ngOnInit() {\n this.myForm = this.formBuilder.group({\n radio: 'C'\n });\n }\n}\n"},705:(u,s,o)=>{o.r(s),o.d(s,{default:()=>r});const r='
{{radioModel || \'null\'}}\n
{{radioModelDisabled || \'null\'}}\n
{{radioModel || \'null\'}}\n
{{uncheckableRadioModel || \'null\'}}\n
Add captions to your slides easily with the .carousel-caption
\n element within any <slide>
. Place just about any optional HTML within there\n and it will be automatically aligned and formatted.
If noPause
is set to false
\n , carousel autoplay will be stopped when carousel receives hover.
If pauseOnFocus
is set to true
\n , carousel autoplay will be stopped when carousel receives focus.
Nulla vitae elit libero, a pharetra augue mollis interdum.
\nNulla vitae elit libero, a pharetra augue mollis interdum.
\nNulla vitae elit libero, a pharetra augue mollis interdum.
\n\n You can set specific index to start from it\n
\n\n If `true` - carousel indicators indicate slides chunks works ONLY if singleSlideOffset = FALSE\n
\n\n There is ability to shift slide not only by amount of all visible slides but also for one item\n
\n{{slidesChangeMessage}}\n'},82098:(c,a,l)=>{l.r(a),l.d(a,{default:()=>o});const o="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-carousel-multilist',\n templateUrl: './multilist.html'\n})\nexport class DemoCarouselMultilistComponent {\n itemsPerSlide = 3;\n singleSlideOffset = false;\n noWrap = false;\n\n slidesChangeMessage = '';\n\n slides = [\n {image: 'assets/images/nature/1.jpg'},\n {image: 'assets/images/nature/2.jpg'},\n {image: 'assets/images/nature/3.jpg'},\n {image: 'assets/images/nature/4.jpg'},\n {image: 'assets/images/nature/5.jpg'},\n {image: 'assets/images/nature/6.jpg'},\n {image: 'assets/images/nature/7.jpg'},\n {image: 'assets/images/nature/8.jpg'},\n {image: 'assets/images/nature/1.jpg'},\n {image: 'assets/images/nature/2.jpg'}\n ];\n\n onSlideRangeChange(indexes: number[]|void): void {\n this.slidesChangeMessage = `Slides have been switched: ${indexes}`;\n }\n}\n"},34858:(c,a,l)=>{l.r(a),l.d(a,{default:()=>o});const o='
{{slideChangeMessage}}\n'},10646:(c,a,l)=>{l.r(a),l.d(a,{default:()=>o});const o="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-carousel-slide-changed-event',\n templateUrl: './slide-changed-event.html'\n})\nexport class DemoCarouselSlideChangedEventComponent {\n slideChangeMessage = '';\n\n slides: {image: string; text?: string}[] = [\n {image: 'assets/images/nature/7.jpg'},\n {image: 'assets/images/nature/5.jpg'},\n {image: 'assets/images/nature/3.jpg'}\n ];\n\n log(event: number) {\n // simple hack for expression has been changed error\n setTimeout(() => {\n this.slideChangeMessage = `Slide has been switched: ${event}`;\n });\n }\n}\n"},95595:(c,a,l)=>{l.r(a),l.d(a,{default:()=>o});const o="### Standalone component usage\nimport { CarouselModule } from 'ngx-bootstrap/carousel';\n\n@Component({\n imports: [\n CarouselModule,\n ...\n]\n})\nexport class AppComponent(){}\n\n\n### Module usage\nimport { CarouselModule } from 'ngx-bootstrap/carousel';\n\n@NgModule({\n imports: [CarouselModule,...]\n})\nexport class AppModule(){}\n"}}]); \ No newline at end of file diff --git a/444.cb63b95cd325ca57.js b/444.cb63b95cd325ca57.js new file mode 100644 index 0000000000..3ab124e751 --- /dev/null +++ b/444.cb63b95cd325ca57.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[444],{12444:(g,r,a)=>{a.r(r),a.d(r,{DemoSortableModule:()=>L,SortableSectionComponent:()=>S});var m=a(84341),p=a(60177),I=a(8681),e=a(54438);let T=(()=>{class s{static forRoot(){return s}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275mod=e.$C({type:s});static#n=this.\u0275inj=e.G2t({})}return s})();var h=a(37472),j=a(21413);let b=(()=>{class s{constructor(){this.onCapture=new j.B}dragStart(o){this.draggableItem=o}getItem(){return this.draggableItem}captureItem(o,n){return this.draggableItem&&this.draggableItem.overZoneIndex!==o&&(this.draggableItem.lastZoneIndex=this.draggableItem.overZoneIndex,this.draggableItem.overZoneIndex=o,this.onCapture.next(this.draggableItem),this.draggableItem=Object.assign({},this.draggableItem,{overZoneIndex:o,i:n})),this.draggableItem}onCaptureItem(){return this.onCapture}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275prov=e.jDH({token:s,factory:s.\u0275fac,providedIn:"platform"})}return s})();const _=(s,d)=>[s,d],F=(s,d)=>({item:s,index:d});function x(s,d){if(1&s){const o=e.RV6();e.j41(0,"div",4),e.bIt("dragover",function(t){e.eBV(o);const l=e.XpG();return e.Njj(l.onItemDragover(t,0))})("dragenter",function(t){e.eBV(o);const l=e.XpG();return e.Njj(l.cancelEvent(t))}),e.EFF(1),e.k0s()}if(2&s){const o=e.XpG();e.Y8G("ngClass",o.placeholderClass)("ngStyle",o.placeholderStyle),e.R7$(),e.JRh(o.placeholderItem)}}function y(s,d){}function D(s,d){if(1&s){const o=e.RV6();e.j41(0,"div",5),e.bIt("dragstart",function(t){const l=e.eBV(o),i=l.$implicit,c=l.index,N=e.XpG();return e.Njj(N.onItemDragstart(t,i,c))})("dragend",function(t){e.eBV(o);const l=e.XpG();return e.Njj(l.resetActiveItem(t))})("dragover",function(t){const l=e.eBV(o).index,i=e.XpG();return e.Njj(i.onItemDragover(t,l))})("dragenter",function(t){e.eBV(o);const l=e.XpG();return e.Njj(l.cancelEvent(t))}),e.DNE(1,y,0,0,"ng-template",6),e.k0s()}if(2&s){const o=d.$implicit,n=d.index,t=e.XpG(),l=e.sdS(4);e.Y8G("ngClass",e.l_i(5,_,t.itemClass,n===t.activeItem?t.itemActiveClass:""))("ngStyle",t.getItemStyle(n===t.activeItem)),e.BMQ("aria-grabbed",n===t.activeItem),e.R7$(),e.Y8G("ngTemplateOutlet",t.itemTemplate||l)("ngTemplateOutletContext",e.l_i(8,F,o,n))}}function E(s,d){1&s&&e.EFF(0),2&s&&e.JRh(d.item.value)}let u=(()=>{class s{static#e=this.globalZoneIndex=0;get items(){return this._items}set items(o){this._items=o;const n=this.items.map(t=>t.initData);this.onChanged(n),this.onChange.emit(n)}constructor(o){this.wrapperClass="",this.wrapperStyle={},this.itemClass="",this.itemStyle={},this.itemActiveClass="",this.itemActiveStyle={},this.placeholderClass="",this.placeholderStyle={},this.placeholderItem="",this.onChange=new e.bkB,this.showPlaceholder=!1,this.activeItem=-1,this.onTouched=Function.prototype,this.onChanged=Function.prototype,this._items=[],this.transfer=o,this.currentZoneIndex=s.globalZoneIndex++,this.transfer.onCaptureItem().subscribe(n=>this.onDrop(n))}onItemDragstart(o,n,t){this.initDragstartEvent(o),this.onTouched(),this.transfer.dragStart({event:o,item:n,i:t,initialIndex:t,lastZoneIndex:this.currentZoneIndex,overZoneIndex:this.currentZoneIndex})}onItemDragover(o,n){if(!this.transfer.getItem())return;o.preventDefault();const t=this.transfer.captureItem(this.currentZoneIndex,this.items.length);let l=[];t&&(l=this.items.length?t.i>n?[...this.items.slice(0,n),t.item,...this.items.slice(n,t.i),...this.items.slice(t.i+1)]:[...this.items.slice(0,t.i),...this.items.slice(t.i+1,n+1),t.item,...this.items.slice(n+1)]:[t.item],this.items=l,t.i=n,this.activeItem=n,this.updatePlaceholderState())}cancelEvent(o){!this.transfer.getItem()||!o||o.preventDefault()}onDrop(o){o&&o.overZoneIndex!==this.currentZoneIndex&&o.lastZoneIndex===this.currentZoneIndex&&(this.items=this.items.filter((n,t)=>t!==o.i),this.updatePlaceholderState()),this.resetActiveItem()}resetActiveItem(o){this.cancelEvent(o),this.activeItem=-1}registerOnChange(o){this.onChanged=o}registerOnTouched(o){this.onTouched=o}writeValue(o){this.items=o?o.map((n,t)=>({id:t,initData:n,value:this.fieldName?n[this.fieldName]:n})):[],this.updatePlaceholderState()}updatePlaceholderState(){this.showPlaceholder=!this._items.length}getItemStyle(o){return o?Object.assign({},this.itemStyle,this.itemActiveStyle):this.itemStyle}initDragstartEvent(o){o.dataTransfer?.setData("Text","placeholder")}static#t=this.\u0275fac=function(n){return new(n||s)(e.rXU(b))};static#n=this.\u0275cmp=e.VBU({type:s,selectors:[["bs-sortable"]],inputs:{fieldName:"fieldName",wrapperClass:"wrapperClass",wrapperStyle:"wrapperStyle",itemClass:"itemClass",itemStyle:"itemStyle",itemActiveClass:"itemActiveClass",itemActiveStyle:"itemActiveStyle",placeholderClass:"placeholderClass",placeholderStyle:"placeholderStyle",placeholderItem:"placeholderItem",itemTemplate:"itemTemplate"},outputs:{onChange:"onChange"},exportAs:["bs-sortable"],standalone:!0,features:[e.Jv_([{provide:m.kq,useExisting:(0,e.Rfq)(()=>s),multi:!0},b]),e.aNF],decls:5,vars:4,consts:[["defItemTemplate",""],[3,"dragover","dragenter","drop","mouseleave","ngClass","ngStyle"],[3,"ngClass","ngStyle","dragover","dragenter",4,"ngIf"],["draggable","true","aria-dropeffect","move",3,"ngClass","ngStyle","dragstart","dragend","dragover","dragenter",4,"ngFor","ngForOf"],[3,"dragover","dragenter","ngClass","ngStyle"],["draggable","true","aria-dropeffect","move",3,"dragstart","dragend","dragover","dragenter","ngClass","ngStyle"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(n,t){if(1&n){const l=e.RV6();e.j41(0,"div",1),e.bIt("dragover",function(c){return e.eBV(l),e.Njj(t.cancelEvent(c))})("dragenter",function(c){return e.eBV(l),e.Njj(t.cancelEvent(c))})("drop",function(c){return e.eBV(l),e.Njj(t.resetActiveItem(c))})("mouseleave",function(c){return e.eBV(l),e.Njj(t.resetActiveItem(c))}),e.DNE(1,x,2,3,"div",2)(2,D,2,11,"div",3),e.k0s(),e.DNE(3,E,1,1,"ng-template",null,0,e.C5r)}2&n&&(e.Y8G("ngClass",t.wrapperClass)("ngStyle",t.wrapperStyle),e.R7$(),e.Y8G("ngIf",t.showPlaceholder),e.R7$(),e.Y8G("ngForOf",t.items))},dependencies:[p.YU,p.B3,p.bT,p.pM,p.T3],encapsulation:2})}return s})(),v=(()=>{class s{constructor(){this.itemStringsLeft=["Windstorm","Bombasto","Magneta","Tornado"],this.itemStringsRight=["Mr. O","Tomato"]}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275cmp=e.VBU({type:s,selectors:[["basic-demo"]],decls:14,vars:8,consts:[[1,"row"],[1,"col-xs-6","col-6","col-md-5","col-lg-3"],["itemClass","sortable-item","itemActiveClass","sortable-item-active","placeholderItem","Drag here","placeholderClass","placeholderStyle text-center","wrapperClass","sortable-wrapper",3,"ngModelChange","ngModel"],[1,"code-preview"]],template:function(n,t){1&n&&(e.j41(0,"div",0)(1,"div",1)(2,"bs-sortable",2),e.mxI("ngModelChange",function(i){return e.DH7(t.itemStringsLeft,i)||(t.itemStringsLeft=i),i}),e.k0s()(),e.j41(3,"div",1)(4,"bs-sortable",2),e.mxI("ngModelChange",function(i){return e.DH7(t.itemStringsRight,i)||(t.itemStringsRight=i),i}),e.k0s()()(),e.j41(5,"div",0)(6,"div",1)(7,"pre",3),e.EFF(8),e.nI1(9,"json"),e.k0s()(),e.j41(10,"div",1)(11,"pre",3),e.EFF(12),e.nI1(13,"json"),e.k0s()()()),2&n&&(e.R7$(2),e.R50("ngModel",t.itemStringsLeft),e.R7$(2),e.R50("ngModel",t.itemStringsRight),e.R7$(4),e.SpI("model: ",e.bMT(9,4,t.itemStringsLeft),""),e.R7$(4),e.SpI("model: ",e.bMT(13,6,t.itemStringsRight),""))},dependencies:[m.BC,m.vS,u,p.TG],encapsulation:2})}return s})(),C=(()=>{class s{constructor(){this.itemObjectsLeft=[{id:1,name:"Windstorm"},{id:2,name:"Bombasto"},{id:3,name:"Magneta"}],this.itemObjectsRight=[{id:4,name:"Tornado"},{id:5,name:"Mr. O"},{id:6,name:"Tomato"}]}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275cmp=e.VBU({type:s,selectors:[["complex-datamodel-demo"]],decls:14,vars:8,consts:[[1,"row"],[1,"col-xs-6","col-6","col-md-5","col-lg-3"],["fieldName","name","itemClass","sortable-item","itemActiveClass","sortable-item-active","placeholderItem","Drag here","placeholderClass","placeholderStyle text-center","wrapperClass","sortable-wrapper",3,"ngModelChange","ngModel"],[1,"code-preview"]],template:function(n,t){1&n&&(e.j41(0,"div",0)(1,"div",1)(2,"bs-sortable",2),e.mxI("ngModelChange",function(i){return e.DH7(t.itemObjectsLeft,i)||(t.itemObjectsLeft=i),i}),e.k0s()(),e.j41(3,"div",1)(4,"bs-sortable",2),e.mxI("ngModelChange",function(i){return e.DH7(t.itemObjectsRight,i)||(t.itemObjectsRight=i),i}),e.k0s()()(),e.j41(5,"div",0)(6,"div",1)(7,"pre",3),e.EFF(8),e.nI1(9,"json"),e.k0s()(),e.j41(10,"div",1)(11,"pre",3),e.EFF(12),e.nI1(13,"json"),e.k0s()()()),2&n&&(e.R7$(2),e.R50("ngModel",t.itemObjectsLeft),e.R7$(2),e.R50("ngModel",t.itemObjectsRight),e.R7$(4),e.SpI("model: ",e.bMT(9,4,t.itemObjectsLeft),""),e.R7$(4),e.SpI("model: ",e.bMT(13,6,t.itemObjectsRight),""))},dependencies:[m.BC,m.vS,u,p.TG],encapsulation:2})}return s})();function R(s,d){if(1&s&&(e.j41(0,"span"),e.EFF(1),e.k0s()),2&s){const o=d.item,n=d.index;e.R7$(),e.Lme("",n,": ",o.value,"")}}let f=(()=>{class s{constructor(){this.itemStringsLeft=["Windstorm","Bombasto","Magneta","Tornado"],this.itemStringsRight=["Mr. O","Tomato"]}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275cmp=e.VBU({type:s,selectors:[["custom-item-template-demo"]],decls:16,vars:9,consts:[["itemTemplate",""],[1,"row"],[1,"col-xs-6","col-6","col-md-5","col-lg-3"],["itemClass","sortable-item","itemActiveClass","sortable-item-active","placeholderItem","Drag here","placeholderClass","placeholderStyle text-center","wrapperClass","sortable-wrapper",3,"ngModelChange","ngModel","itemTemplate"],["itemClass","sortable-item","itemActiveClass","sortable-item-active","placeholderItem","Drag here","placeholderClass","placeholderStyle text-center","wrapperClass","sortable-wrapper",3,"ngModelChange","ngModel"],[1,"code-preview"]],template:function(n,t){if(1&n){const l=e.RV6();e.DNE(0,R,2,2,"ng-template",null,0,e.C5r),e.j41(2,"div",1)(3,"div",2)(4,"bs-sortable",3),e.mxI("ngModelChange",function(c){return e.eBV(l),e.DH7(t.itemStringsLeft,c)||(t.itemStringsLeft=c),e.Njj(c)}),e.k0s()(),e.j41(5,"div",2)(6,"bs-sortable",4),e.mxI("ngModelChange",function(c){return e.eBV(l),e.DH7(t.itemStringsRight,c)||(t.itemStringsRight=c),e.Njj(c)}),e.k0s()()(),e.j41(7,"div",1)(8,"div",2)(9,"pre",5),e.EFF(10),e.nI1(11,"json"),e.k0s()(),e.j41(12,"div",2)(13,"pre",5),e.EFF(14),e.nI1(15,"json"),e.k0s()()()}if(2&n){const l=e.sdS(1);e.R7$(4),e.R50("ngModel",t.itemStringsLeft),e.Y8G("itemTemplate",l),e.R7$(2),e.R50("ngModel",t.itemStringsRight),e.R7$(4),e.SpI("model: ",e.bMT(11,5,t.itemStringsRight),""),e.R7$(4),e.SpI("model: ",e.bMT(15,7,t.itemStringsRight),"")}},dependencies:[m.BC,m.vS,u,p.TG],encapsulation:2})}return s})(),M=(()=>{class s{static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275cmp=e.VBU({type:s,selectors:[["demo-accessibility"]],decls:26,vars:0,consts:[["href","https://www.w3.org/TR/wai-aria-1.1/#aria-dropeffect"],[1,"highlighter-rouge"]],template:function(n,t){1&n&&(e.j41(0,"p"),e.EFF(1,"You can use "),e.j41(2,"code"),e.EFF(3,'aria-dropeffect="..."'),e.k0s(),e.EFF(4," and "),e.j41(5,"code"),e.EFF(6,"aria-grabbed"),e.k0s(),e.EFF(7," for "),e.j41(8,"code"),e.EFF(9,".sortable-item"),e.k0s(),e.EFF(10,". When you start drag item "),e.j41(11,"code"),e.EFF(12,"aria-grabbed"),e.k0s(),e.EFF(13," must have "),e.j41(14,"code"),e.EFF(15,"true"),e.k0s(),e.EFF(16," state. "),e.j41(17,"code"),e.EFF(18,"aria-dropeffect"),e.k0s(),e.EFF(19," property is defined depending on the grabbed object."),e.k0s(),e.j41(20,"p"),e.EFF(21,"But be careful, these attributes are "),e.j41(22,"a",0)(23,"code",1),e.EFF(24,"deprecated"),e.k0s()(),e.EFF(25,"."),e.k0s())},encapsulation:2})}return s})();const w=[{name:"Overview",anchor:"overview",tabName:"overview",outlet:h.xK,content:[{title:"Basic",anchor:"basic",component:a(49013),html:a(953),outlet:v},{title:"Complex data model",anchor:"complexDatamodel",component:a(90661),html:a(34185),outlet:C},{title:"Custom item template",anchor:"itemTemplate",component:a(87782),html:a(81050),outlet:f},{title:"Accessibility",anchor:"accessibility",outlet:M}]},{name:"Installation",anchor:"api-reference",tabName:"api",outlet:h.Mg,usage:a(68901),importInfo:'ng add ngx-bootstrap --component sortable',content:[{title:"SortableComponent",anchor:"sortable-component",outlet:h.r2}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:h.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:v},{title:"Complex data model",anchor:"complexDatamodel-ex",outlet:C},{title:"Custom item template",anchor:"itemTemplate-ex",outlet:f}]}];var B=a(86223),A=a(52439);let S=(()=>{class s{constructor(){this.name="Sortable",this.src="https://github.com/valor-software/ngx-bootstrap/blob/development/src/sortable",this.componentContent=w}static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275cmp=e.VBU({type:s,selectors:[["sortable-section"]],decls:15,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(n,t){1&n&&(e.j41(0,"demo-section",0)(1,"p"),e.EFF(2,"The "),e.j41(3,"strong"),e.EFF(4,"sortable component"),e.k0s(),e.EFF(5," represents a list of items, with ability to sort them or move to another container via drag&drop. Input collection isn't mutated by the component, so events "),e.j41(6,"code"),e.EFF(7,"ngModelChange"),e.k0s(),e.EFF(8,", "),e.j41(9,"code"),e.EFF(10,"onChange"),e.k0s(),e.EFF(11," are using new collections."),e.k0s(),e.j41(12,"p"),e.EFF(13,"The easiest way to add the sortable component to your app (will be added to the root module)"),e.k0s(),e.nrm(14,"docs-section",1),e.k0s()),2&n&&(e.Y8G("name",t.name)("src",t.src)("componentContent",t.componentContent),e.R7$(14),e.Y8G("content",t.componentContent))},dependencies:[B.q,A.C],styles:["\n .sortable-item {\n padding: 6px 12px;\n margin-bottom: 4px;\n font-size: 14px;\n line-height: 1.4em;\n text-align: center;\n cursor: grab;\n border: 1px solid transparent;\n border-radius: 4px;\n border-color: #adadad;\n }\n\n .sortable-item-active {\n background-color: #e6e6e6;\n box-shadow: inset 0 3px 5px rgba(0,0,0,.125);\n }\n\n .sortable-wrapper {\n min-height: 150px;\n }\n "],encapsulation:2,changeDetection:0})}return s})();const O=[{path:"",component:S}];let L=(()=>{class s{static#e=this.\u0275fac=function(n){return new(n||s)};static#t=this.\u0275mod=e.$C({type:s});static#n=this.\u0275inj=e.G2t({imports:[p.MD,m.YN,h.ky,T,I.iI.forChild(O)]})}return s})()},953:(g,r,a)=>{a.r(r),a.d(r,{default:()=>m});const m='
model: {{ itemStringsLeft | json }}\n
model: {{ itemStringsRight | json }}\n
model: {{ itemObjectsLeft | json }}\n
model: {{ itemObjectsRight | json }}\n
model: {{ itemStringsRight | json }}\n
model: {{ itemStringsRight | json }}\n
Note: If you installed ngx-bootstrap not via ng add command, you will need to perform a several actions
\nNotable change is additional css for it "/datepicker/bs-datepicker.css"
There are two ways of adding css:
\n<link rel="stylesheet"\n href="https://unpkg.com/ngx-bootstrap/datepicker/bs-datepicker.css">
to your\n index.html
dist/ngx-bootstrap/datepicker/bs-datepicker.css
via package bundler\n like Angular CLI, if you\'re using one.\n with initial state set by bsInlineValue
property
isAnimated
config option",outlet:Ha},{title:"Adaptive position",anchor:"adaptive-position",component:r(12126),html:r(8290),description:"You can enable adaptive position via adaptivePosition
option in bsConfig
You can easily change the date format by specifying the dateInputFormat
\n in [bsConfig]
\n
To set your own date format you can use variety of formats provided by\n moment.js
\nThe following examples show how to use several date formats inside a form:\n
YYYY-MM-DD
MM/DD/YYYY
MMMM Do YYYY,h:mm:ss a
Hide the datepicker on page scroll.
\n ",outlet:Ta},{title:"Themes",anchor:"themes",component:r(2790),html:r(44346),description:"\nDatepicker comes with some default color schemes.\n You can change it by manipulating containerClass
property in bsConfig
object
There are 6 color schemes: theme-default
, theme-green
, theme-blue
,\n theme-dark-blue
, theme-red
, theme-orange
Datepicker can use different locales.
It's possible to change a locale by calling\n use
\n method of BsLocaleService
, list of available locales is in dropdown below.
To use a different locale, you have to import it from ngx-bootstrap/chronos
first, then\n define it in your @NgModule
using function defineLocale
Example:
\nimport { defineLocale } from 'ngx-bootstrap/chronos';
import { deLocale } from 'ngx-bootstrap/locale';
defineLocale('de', deLocale);
\n You can set min and max date of datepicker/daterangepicker using minDate
and\n maxDate
properties
In the following example minDate
is set to yesterday and maxDate
\n to the current day in the next week
You can set which days of the week should be disabled with daysDisabled
\n
In the following example daysDisabled
is set with an array which disabled Saturday and Sunday.\n Sunday is considered the first day of the week and thus has the value 0
You can set which dates should be disabled with datesDisabled
In the following example datesDisabled
is set with an array to disable 2020-02-05 and 2020-02-09.
NOTE: DO NOT USE this functionality with datesEnabled
at the same time
You can set which dates should be enable with datesEnabled
In the following example datesEnabled
is set with an array to enable 2020-02-06, 2020-02-08 and 2020-02-11. All other dates are disabled
NOTE: DO NOT USE this functionality with datesDisabled
at the same time
You can configure, how many months you want to show for daterangepicker via displayMonths
in BsDaterangepickerConfig.
With displayOneMonthRange
you can show only one month for two cases
You can set min view mode of datepicker using minMode
property
In the following example minMode
is set to 'month'
If you want to disable datepicker's or daterangepicker's content set isDisabled
property to true
If you want to add custom class to current day datepicker's content set value to customTodayClass
option in bsConfig
Datepicker and daterangepicker can be used in forms. Keep in mind that\n value of ngModel
is Date
object for datepicker and array of 2\n Date
objects for daterangepicker
Allows to return focus to input of datepicker or daterangepicker after the date or daterange selection
",outlet:ja},{title:"Manual triggering",anchor:"triggers-manual",component:r(41750),html:r(94058),description:"You can manage datepicker's state by using its show()
, hide()
\n and toggle()
methods
Add placement
property if you want to change placement
You can manage datepicker's options by using its setConfig()
method
You can subscribe to datepicker's visibility events
",outlet:Xa},{title:"Value change event",anchor:"value-change-event",component:r(29518),html:r(1266),description:"You can subscribe to datepicker's value change event (bsValueChange
).
You can configure the datepicker via its bsConfig
option
You can enable dates from other months via selectFromOtherMonth
option in bsConfig
You can enable ability to select a week number (first day of the week will be selected) via selectWeek
option in bsConfig
You can enable ability to select a week number (range with first weekday - last weekday will be selected) via selectWeekRange
option in bsConfig
Datepicker closes after outside click by default. To change\n this behavior, use outsideClick
property.
Datepicker can be shown or hidden by changing isOpen
property
Use different triggers ( for example keydown
, mouseenter
and\n dblclick
) to interact with datepicker
Style dates with custom classes
",outlet:Fa},{title:"Tooltip for selected dates",anchor:"tooltip-for-selected-dates",component:r(95562),html:r(13806),description:"",outlet:Qa},{title:"Quick select ranges",anchor:"quick-select-ranges",component:r(27522),html:r(88022),description:"Quick select ranges can be added to Daterangepicker using ranges
Pick some date from second month and it wont change to the next month
",outlet:ai},{title:"Previous month in Daterangepicker",anchor:"daterangepicker-previous-month",component:r(36744),html:r(18776),description:"Pick previous & current month instead of current & next month.When daterange selected and related to current month,\n daterangepicker will works by default, with current & next month
",outlet:Ja},{title:"Show Today Button",anchor:"datepicker-show-today-button",component:r(90472),html:r(66200),description:"Display an optional 'Today' button that will automatically select today's date.
",outlet:ti},{title:"Show Clear Button",anchor:"datepicker-show-clear-button",component:r(28616),html:r(67224),description:"Display an optional 'Clear' button that will automatically clear date.
",outlet:ni},{title:"Start view",anchor:"start-view",component:r(60600),html:r(53576),description:"Add startView
property if you want to change start view
Max date range after first date selection can be added to Daterangepicker using maxDateRange
.
If you also use maxDate
property, you can't select second date, which exceeds value of maxDate
.
withTimepicker
config option",outlet:oi},{title:"Close behavior with timepicker changes",anchor:"close-behavior",component:r(84301),html:r(43873),description:"If you use datepicker with timepicker together, you are able to set keepDatepickerOpened
config option and keep datepicker opened until date isn't changed",outlet:li},{title:"Don't overwrite dates out of rule",anchor:"keep-dates-out-of-rules",component:r(91531),html:r(7891),description:"If you use datepicker with rules (minDate, maxDate) you can set config property keepDatesOutOfRules
to true to avoid overwriting invalid dates. Default value is false.
bsValue
property sets initial state in this example
ngModel
property sets two-way data binding in this example
maxDate
is today
minDate
month is equal to maxDate
month
Saturday and Sunday are not selectable
\n \nSaturday and Sunday are selectable
\n \nSaturday and Sunday are not selectable
\n \nSaturday and Sunday are selectable
\n \n{{datepickerModel}}\n
{{daterangepickerModel}}
Outside click closes the datepicker in this example
\n \nOutside click doesn\'t close the datepicker in this example
\n \nThe datepicker\'s placement is right
\n \nThe datepicker\'s placement is top
\n \nThe datepicker\'s placement is bottom
\n \nThe datepicker\'s placement is left
\n \nAlso works with selectFromOtherMonth
option, which allows to select weeks which started on previous\n month
If first day of the week is disabled, the next one will be selected.
\n\nTwo first days of the each week are disabled
\n \nIf all days in week are disabled, you can\'t select this week
\n\nAlso works with selectFromOtherMonth
option, which allows to select weeks which started on previous\n month
If first day of the week is disabled, the next one will be selected.
\n\nTwo first days of the each week are disabled
\n \nIf all days in week are disabled, you can\'t select this week
\n\nThe datepicker\'s start view is day (default)
\n \nThe datepicker\'s start view is month
\n \nThe datepicker\'s start view is year
\n \nHover over the input to open the datepicker
\n \nFocus on input and press any key to open the datepicker
\n \n\u0421lick twice on input to open the datepicker
\n \nChanged date is {{data | date}}\n
{{message}}\n
Text in meridian labels can be customized by using meridians
input property
isValid
event emits true if a value is a valid data.\n Enter an invalid data to see error
Time is: {{myTime}}\n'},6455:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-arrowkeys',\n templateUrl: './arrowkeys.html'\n})\nexport class DemoTimepickerArrowkeysComponent {\n allowArrowKeys = true;\n myTime = new Date();\n}\n"},97987:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{mytime}}\n'},29467:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-basic',\n templateUrl: './basic.html'\n})\nexport class DemoTimepickerBasicComponent {\n mytime: Date = new Date();\n}\n"},79001:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{mytime}}\n'},41429:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\nimport { TimepickerConfig } from 'ngx-bootstrap/timepicker';\n\n// such override allows to keep some initial values\n\nexport function getTimepickerConfig(): TimepickerConfig {\n return Object.assign(new TimepickerConfig(), {\n hourStep: 2,\n minuteStep: 10,\n showMeridian: false,\n readonlyInput: false,\n mousewheel: true,\n showMinutes: true,\n showSeconds: false,\n labelHours: 'Hours',\n labelMinutes: 'Minutes',\n labelSeconds: 'Seconds'\n });\n}\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-config',\n templateUrl: './config.html',\n providers: [{ provide: TimepickerConfig, useFactory: getTimepickerConfig }]\n})\nexport class DemoTimepickerConfigComponent {\n mytime?: string;\n}\n"},91059:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{mytime}}\n'},48267:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-custom-meridian',\n templateUrl: './custom-meridian.html'\n})\nexport class DemoTimepickerCustomMeridianComponent {\n mytime: Date = new Date();\n meridians = ['AM(Midnight to Noon)', 'PM(Noon to Midnight)'];\n}\n"},54751:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Illustrates custom validation, you have to select time between 11:00 and 12:59
\n\n\n Time is: {{myTime}}\n\n
Time is: {{mytime}}\n\n
Time is: {{mytime}}\n
Invalid time format\n\n\n\n'},85159:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\nimport { TimepickerConfig } from 'ngx-bootstrap/timepicker';\n\nexport function getTimepickerConfig(): TimepickerConfig {\n return Object.assign(new TimepickerConfig(), {\n allowEmptyTime: true\n });\n}\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-dynamic',\n templateUrl: './dynamic.html',\n providers: [{ provide: TimepickerConfig, useFactory: getTimepickerConfig }]\n})\nexport class DemoTimepickerDynamicComponent {\n mytime: Date | undefined = new Date();\n isValid?: boolean;\n\n update(): void {\n const time = new Date();\n time.setHours(14);\n time.setMinutes(0);\n\n this.mytime = time;\n }\n\n changed(): void {\n console.log(`Time changed to: ${this.mytime}`);\n }\n\n clear(): void {\n this.mytime = void 0;\n }\n}\n"},25025:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{myTime}}\n
Invalid time format\n\n\n'},86253:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\nimport { TimepickerConfig } from 'ngx-bootstrap/timepicker';\n\nexport function getTimepickerConfig(): TimepickerConfig {\n return Object.assign(new TimepickerConfig(), {\n allowEmptyTime: true\n });\n}\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-empty-date',\n templateUrl: './empty-date.html',\n providers: [{ provide: TimepickerConfig, useFactory: getTimepickerConfig }]\n})\nexport class DemoTimepickerEmptyDateComponent {\n allowEmptyTime = true;\n myTime?: Date = new Date();\n isValid?: boolean;\n\n clear(): void {\n this.myTime = void 0;\n }\n}\n"},43777:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{ form.get(\'myControl\')?.value }}\n
\n Time is: {{myTime}}\n\n
Time is: {{mytime}}\n\n
Time is: {{myTime}}\n'},51799:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-min-max',\n templateUrl: './min-max.html'\n})\nexport class DemoTimepickerMinMaxComponent {\n myTime: Date = new Date();\n minTime: Date = new Date();\n maxTime: Date = new Date();\n\n constructor() {\n this.minTime.setHours(8);\n this.minTime.setMinutes(0);\n this.maxTime.setHours(23);\n this.maxTime.setMinutes(55);\n }\n}\n"},19313:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{myTime}}\n'},6557:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-mousewheel',\n templateUrl: './mousewheel.html'\n})\nexport class DemoTimepickerMousewheelComponent {\n allowMouseWheel = true;\n myTime = new Date();\n}\n"},96515:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m='
Time is: {{myTime}}\n\n\n\n'},28645:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-timepicker-seconds',\n templateUrl: './toggle-minutes-seconds.html'\n})\nexport class DemoTimepickerToggleMinutesSecondsComponent {\n myTime: Date = new Date();\n showMin = true;\n showSec = true;\n\n toggleMinutes(): void {\n this.showMin = !this.showMin;\n }\n\n toggleSeconds(): void {\n this.showSec = !this.showSec;\n }\n\n}\n"},47744:(c,i,t)=>{t.r(i),t.d(i,{default:()=>m});const m="### Standalone component usage\nimport { TimepickerModule } from 'ngx-bootstrap/timepicker';\n\n@Component({\n standalone: true,\n imports: [TimepickerModule,...]\n})\nexport class AppComponent(){}\n\n### Module usage\nimport { TimepickerModule } from 'ngx-bootstrap/timepicker';\n\n@NgModule({\n imports: [TimepickerModule,...]\n})\nexport class AppModule(){}\n"}}]); \ No newline at end of file diff --git a/546.cfeaea3fb5c3ed81.js b/546.cfeaea3fb5c3ed81.js new file mode 100644 index 0000000000..32537106e3 --- /dev/null +++ b/546.cfeaea3fb5c3ed81.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[546],{43546:(p,s,o)=>{o.r(s),o.d(s,{DemoTypeaheadModule:()=>un,TypeaheadSectionComponent:()=>fe});var l=o(60177),h=o(84341),Te=o(8681);const Se={\u00c1:"A",\u0102:"A",\u1eae:"A",\u1eb6:"A",\u1eb0:"A",\u1eb2:"A",\u1eb4:"A",\u01cd:"A",\u00c2:"A",\u1ea4:"A",\u1eac:"A",\u1ea6:"A",\u1ea8:"A",\u1eaa:"A",\u00c4:"A",\u01de:"A",\u0226:"A",\u01e0:"A",\u1ea0:"A",\u0200:"A",\u00c0:"A",\u1ea2:"A",\u0202:"A",\u0100:"A",\u0104:"A",\u00c5:"A",\u01fa:"A",\u1e00:"A",\u023a:"A",\u00c3:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY",\u1e02:"B",\u1e04:"B",\u0181:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0106:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0108:"C",\u010a:"C",\u0187:"C",\u023b:"C",\u010e:"D",\u1e10:"D",\u1e12:"D",\u1e0a:"D",\u1e0c:"D",\u018a:"D",\u1e0e:"D",\u01f2:"D",\u01c5:"D",\u0110:"D",\u018b:"D",\u01f1:"DZ",\u01c4:"DZ",\u00c9:"E",\u0114:"E",\u011a:"E",\u0228:"E",\u1e1c:"E",\u00ca:"E",\u1ebe:"E",\u1ec6:"E",\u1ec0:"E",\u1ec2:"E",\u1ec4:"E",\u1e18:"E",\u00cb:"E",\u0116:"E",\u1eb8:"E",\u0204:"E",\u00c8:"E",\u1eba:"E",\u0206:"E",\u0112:"E",\u1e16:"E",\u1e14:"E",\u0118:"E",\u0246:"E",\u1ebc:"E",\u1e1a:"E",\ua76a:"ET",\u1e1e:"F",\u0191:"F",\u01f4:"G",\u011e:"G",\u01e6:"G",\u0122:"G",\u011c:"G",\u0120:"G",\u0193:"G",\u1e20:"G",\u01e4:"G",\u1e2a:"H",\u021e:"H",\u1e28:"H",\u0124:"H",\u2c67:"H",\u1e26:"H",\u1e22:"H",\u1e24:"H",\u0126:"H",\u00cd:"I",\u012c:"I",\u01cf:"I",\u00ce:"I",\u00cf:"I",\u1e2e:"I",\u0130:"I",\u1eca:"I",\u0208:"I",\u00cc:"I",\u1ec8:"I",\u020a:"I",\u012a:"I",\u012e:"I",\u0197:"I",\u0128:"I",\u1e2c:"I",\ua779:"D",\ua77b:"F",\ua77d:"G",\ua782:"R",\ua784:"S",\ua786:"T",\ua76c:"IS",\u0134:"J",\u0248:"J",\u1e30:"K",\u01e8:"K",\u0136:"K",\u2c69:"K",\ua742:"K",\u1e32:"K",\u0198:"K",\u1e34:"K",\ua740:"K",\ua744:"K",\u0139:"L",\u023d:"L",\u013d:"L",\u013b:"L",\u1e3c:"L",\u1e36:"L",\u1e38:"L",\u2c60:"L",\ua748:"L",\u1e3a:"L",\u013f:"L",\u2c62:"L",\u01c8:"L",\u0141:"L",\u01c7:"LJ",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u0143:"N",\u0147:"N",\u0145:"N",\u1e4a:"N",\u1e44:"N",\u1e46:"N",\u01f8:"N",\u019d:"N",\u1e48:"N",\u0220:"N",\u01cb:"N",\u00d1:"N",\u01ca:"NJ",\u00d3:"O",\u014e:"O",\u01d1:"O",\u00d4:"O",\u1ed0:"O",\u1ed8:"O",\u1ed2:"O",\u1ed4:"O",\u1ed6:"O",\u00d6:"O",\u022a:"O",\u022e:"O",\u0230:"O",\u1ecc:"O",\u0150:"O",\u020c:"O",\u00d2:"O",\u1ece:"O",\u01a0:"O",\u1eda:"O",\u1ee2:"O",\u1edc:"O",\u1ede:"O",\u1ee0:"O",\u020e:"O",\ua74a:"O",\ua74c:"O",\u014c:"O",\u1e52:"O",\u1e50:"O",\u019f:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u00d5:"O",\u1e4c:"O",\u1e4e:"O",\u022c:"O",\u01a2:"OI",\ua74e:"OO",\u0190:"E",\u0186:"O",\u0222:"OU",\u1e54:"P",\u1e56:"P",\ua752:"P",\u01a4:"P",\ua754:"P",\u2c63:"P",\ua750:"P",\ua758:"Q",\ua756:"Q",\u0154:"R",\u0158:"R",\u0156:"R",\u1e58:"R",\u1e5a:"R",\u1e5c:"R",\u0210:"R",\u0212:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua73e:"C",\u018e:"E",\u015a:"S",\u1e64:"S",\u0160:"S",\u1e66:"S",\u015e:"S",\u015c:"S",\u0218:"S",\u1e60:"S",\u1e62:"S",\u1e68:"S",\u0164:"T",\u0162:"T",\u1e70:"T",\u021a:"T",\u023e:"T",\u1e6a:"T",\u1e6c:"T",\u01ac:"T",\u1e6e:"T",\u01ae:"T",\u0166:"T",\u2c6f:"A",\ua780:"L",\u019c:"M",\u0245:"V",\ua728:"TZ",\u00da:"U",\u016c:"U",\u01d3:"U",\u00db:"U",\u1e76:"U",\u00dc:"U",\u01d7:"U",\u01d9:"U",\u01db:"U",\u01d5:"U",\u1e72:"U",\u1ee4:"U",\u0170:"U",\u0214:"U",\u00d9:"U",\u1ee6:"U",\u01af:"U",\u1ee8:"U",\u1ef0:"U",\u1eea:"U",\u1eec:"U",\u1eee:"U",\u0216:"U",\u016a:"U",\u1e7a:"U",\u0172:"U",\u016e:"U",\u0168:"U",\u1e78:"U",\u1e74:"U",\ua75e:"V",\u1e7e:"V",\u01b2:"V",\u1e7c:"V",\ua760:"VY",\u1e82:"W",\u0174:"W",\u1e84:"W",\u1e86:"W",\u1e88:"W",\u1e80:"W",\u2c72:"W",\u1e8c:"X",\u1e8a:"X",\u00dd:"Y",\u0176:"Y",\u0178:"Y",\u1e8e:"Y",\u1ef4:"Y",\u1ef2:"Y",\u01b3:"Y",\u1ef6:"Y",\u1efe:"Y",\u0232:"Y",\u024e:"Y",\u1ef8:"Y",\u0179:"Z",\u017d:"Z",\u1e90:"Z",\u2c6b:"Z",\u017b:"Z",\u1e92:"Z",\u0224:"Z",\u1e94:"Z",\u01b5:"Z",\u0132:"IJ",\u0152:"OE",\u1d00:"A",\u1d01:"AE",\u0299:"B",\u1d03:"B",\u1d04:"C",\u1d05:"D",\u1d07:"E",\ua730:"F",\u0262:"G",\u029b:"G",\u029c:"H",\u026a:"I",\u0281:"R",\u1d0a:"J",\u1d0b:"K",\u029f:"L",\u1d0c:"L",\u1d0d:"M",\u0274:"N",\u1d0f:"O",\u0276:"OE",\u1d10:"O",\u1d15:"OU",\u1d18:"P",\u0280:"R",\u1d0e:"N",\u1d19:"R",\ua731:"S",\u1d1b:"T",\u2c7b:"E",\u1d1a:"R",\u1d1c:"U",\u1d20:"V",\u1d21:"W",\u028f:"Y",\u1d22:"Z",\u00e1:"a",\u0103:"a",\u1eaf:"a",\u1eb7:"a",\u1eb1:"a",\u1eb3:"a",\u1eb5:"a",\u01ce:"a",\u00e2:"a",\u1ea5:"a",\u1ead:"a",\u1ea7:"a",\u1ea9:"a",\u1eab:"a",\u00e4:"a",\u01df:"a",\u0227:"a",\u01e1:"a",\u1ea1:"a",\u0201:"a",\u00e0:"a",\u1ea3:"a",\u0203:"a",\u0101:"a",\u0105:"a",\u1d8f:"a",\u1e9a:"a",\u00e5:"a",\u01fb:"a",\u1e01:"a",\u2c65:"a",\u00e3:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay",\u1e03:"b",\u1e05:"b",\u0253:"b",\u1e07:"b",\u1d6c:"b",\u1d80:"b",\u0180:"b",\u0183:"b",\u0275:"o",\u0107:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0109:"c",\u0255:"c",\u010b:"c",\u0188:"c",\u023c:"c",\u010f:"d",\u1e11:"d",\u1e13:"d",\u0221:"d",\u1e0b:"d",\u1e0d:"d",\u0257:"d",\u1d91:"d",\u1e0f:"d",\u1d6d:"d",\u1d81:"d",\u0111:"d",\u0256:"d",\u018c:"d",\u0131:"i",\u0237:"j",\u025f:"j",\u0284:"j",\u01f3:"dz",\u01c6:"dz",\u00e9:"e",\u0115:"e",\u011b:"e",\u0229:"e",\u1e1d:"e",\u00ea:"e",\u1ebf:"e",\u1ec7:"e",\u1ec1:"e",\u1ec3:"e",\u1ec5:"e",\u1e19:"e",\u00eb:"e",\u0117:"e",\u1eb9:"e",\u0205:"e",\u00e8:"e",\u1ebb:"e",\u0207:"e",\u0113:"e",\u1e17:"e",\u1e15:"e",\u2c78:"e",\u0119:"e",\u1d92:"e",\u0247:"e",\u1ebd:"e",\u1e1b:"e",\ua76b:"et",\u1e1f:"f",\u0192:"f",\u1d6e:"f",\u1d82:"f",\u01f5:"g",\u011f:"g",\u01e7:"g",\u0123:"g",\u011d:"g",\u0121:"g",\u0260:"g",\u1e21:"g",\u1d83:"g",\u01e5:"g",\u1e2b:"h",\u021f:"h",\u1e29:"h",\u0125:"h",\u2c68:"h",\u1e27:"h",\u1e23:"h",\u1e25:"h",\u0266:"h",\u1e96:"h",\u0127:"h",\u0195:"hv",\u00ed:"i",\u012d:"i",\u01d0:"i",\u00ee:"i",\u00ef:"i",\u1e2f:"i",\u1ecb:"i",\u0209:"i",\u00ec:"i",\u1ec9:"i",\u020b:"i",\u012b:"i",\u012f:"i",\u1d96:"i",\u0268:"i",\u0129:"i",\u1e2d:"i",\ua77a:"d",\ua77c:"f",\u1d79:"g",\ua783:"r",\ua785:"s",\ua787:"t",\ua76d:"is",\u01f0:"j",\u0135:"j",\u029d:"j",\u0249:"j",\u1e31:"k",\u01e9:"k",\u0137:"k",\u2c6a:"k",\ua743:"k",\u1e33:"k",\u0199:"k",\u1e35:"k",\u1d84:"k",\ua741:"k",\ua745:"k",\u013a:"l",\u019a:"l",\u026c:"l",\u013e:"l",\u013c:"l",\u1e3d:"l",\u0234:"l",\u1e37:"l",\u1e39:"l",\u2c61:"l",\ua749:"l",\u1e3b:"l",\u0140:"l",\u026b:"l",\u1d85:"l",\u026d:"l",\u0142:"l",\u01c9:"lj",\u017f:"s",\u1e9c:"s",\u1e9b:"s",\u1e9d:"s",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u1d6f:"m",\u1d86:"m",\u0144:"n",\u0148:"n",\u0146:"n",\u1e4b:"n",\u0235:"n",\u1e45:"n",\u1e47:"n",\u01f9:"n",\u0272:"n",\u1e49:"n",\u019e:"n",\u1d70:"n",\u1d87:"n",\u0273:"n",\u00f1:"n",\u01cc:"nj",\u00f3:"o",\u014f:"o",\u01d2:"o",\u00f4:"o",\u1ed1:"o",\u1ed9:"o",\u1ed3:"o",\u1ed5:"o",\u1ed7:"o",\u00f6:"o",\u022b:"o",\u022f:"o",\u0231:"o",\u1ecd:"o",\u0151:"o",\u020d:"o",\u00f2:"o",\u1ecf:"o",\u01a1:"o",\u1edb:"o",\u1ee3:"o",\u1edd:"o",\u1edf:"o",\u1ee1:"o",\u020f:"o",\ua74b:"o",\ua74d:"o",\u2c7a:"o",\u014d:"o",\u1e53:"o",\u1e51:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u00f5:"o",\u1e4d:"o",\u1e4f:"o",\u022d:"o",\u01a3:"oi",\ua74f:"oo",\u025b:"e",\u1d93:"e",\u0254:"o",\u1d97:"o",\u0223:"ou",\u1e55:"p",\u1e57:"p",\ua753:"p",\u01a5:"p",\u1d71:"p",\u1d88:"p",\ua755:"p",\u1d7d:"p",\ua751:"p",\ua759:"q",\u02a0:"q",\u024b:"q",\ua757:"q",\u0155:"r",\u0159:"r",\u0157:"r",\u1e59:"r",\u1e5b:"r",\u1e5d:"r",\u0211:"r",\u027e:"r",\u1d73:"r",\u0213:"r",\u1e5f:"r",\u027c:"r",\u1d72:"r",\u1d89:"r",\u024d:"r",\u027d:"r",\u2184:"c",\ua73f:"c",\u0258:"e",\u027f:"r",\u015b:"s",\u1e65:"s",\u0161:"s",\u1e67:"s",\u015f:"s",\u015d:"s",\u0219:"s",\u1e61:"s",\u1e63:"s",\u1e69:"s",\u0282:"s",\u1d74:"s",\u1d8a:"s",\u023f:"s",\u0261:"g",\u1d11:"o",\u1d13:"o",\u1d1d:"u",\u0165:"t",\u0163:"t",\u1e71:"t",\u021b:"t",\u0236:"t",\u1e97:"t",\u2c66:"t",\u1e6b:"t",\u1e6d:"t",\u01ad:"t",\u1e6f:"t",\u1d75:"t",\u01ab:"t",\u0288:"t",\u0167:"t",\u1d7a:"th",\u0250:"a",\u1d02:"ae",\u01dd:"e",\u1d77:"g",\u0265:"h",\u02ae:"h",\u02af:"h",\u1d09:"i",\u029e:"k",\ua781:"l",\u026f:"m",\u0270:"m",\u1d14:"oe",\u0279:"r",\u027b:"r",\u027a:"r",\u2c79:"r",\u0287:"t",\u028c:"v",\u028d:"w",\u028e:"y",\ua729:"tz",\u00fa:"u",\u016d:"u",\u01d4:"u",\u00fb:"u",\u1e77:"u",\u00fc:"u",\u01d8:"u",\u01da:"u",\u01dc:"u",\u01d6:"u",\u1e73:"u",\u1ee5:"u",\u0171:"u",\u0215:"u",\u00f9:"u",\u1ee7:"u",\u01b0:"u",\u1ee9:"u",\u1ef1:"u",\u1eeb:"u",\u1eed:"u",\u1eef:"u",\u0217:"u",\u016b:"u",\u1e7b:"u",\u0173:"u",\u1d99:"u",\u016f:"u",\u0169:"u",\u1e79:"u",\u1e75:"u",\u1d6b:"ue",\ua778:"um",\u2c74:"v",\ua75f:"v",\u1e7f:"v",\u028b:"v",\u1d8c:"v",\u2c71:"v",\u1e7d:"v",\ua761:"vy",\u1e83:"w",\u0175:"w",\u1e85:"w",\u1e87:"w",\u1e89:"w",\u1e81:"w",\u2c73:"w",\u1e98:"w",\u1e8d:"x",\u1e8b:"x",\u1d8d:"x",\u00fd:"y",\u0177:"y",\u00ff:"y",\u1e8f:"y",\u1ef5:"y",\u1ef3:"y",\u01b4:"y",\u1ef7:"y",\u1eff:"y",\u0233:"y",\u1e99:"y",\u024f:"y",\u1ef9:"y",\u017a:"z",\u017e:"z",\u1e91:"z",\u0291:"z",\u2c6c:"z",\u017c:"z",\u1e93:"z",\u0225:"z",\u1e95:"z",\u1d76:"z",\u1d8e:"z",\u0290:"z",\u01b6:"z",\u0240:"z",\ufb00:"ff",\ufb03:"ffi",\ufb04:"ffl",\ufb01:"fi",\ufb02:"fl",\u0133:"ij",\u0153:"oe",\ufb06:"st",\u2090:"a",\u2091:"e",\u1d62:"i",\u2c7c:"j",\u2092:"o",\u1d63:"r",\u1d64:"u",\u1d65:"v",\u2093:"x"};function S(i){return i?i.replace(/[^A-Za-z0-9[\] ]/g,function(m){return Se[m]||m}):""}function I(i,m=" ",t="",a){let n=[];if(a){const r=i.split(new RegExp(`([${a}]+)`,"g")),c=r[r.length-1];c>""&&(m&&t?n=W(c,m,t):n.push(c))}else n=W(i,m,t);return n}function W(i,m,t){const a=[],d=i.split(new RegExp(`(?:[${t}])([^${t}]+)(?:[${t}])|([^${m}]+)`,"g")),r=d.length;let c;const g=new RegExp(`[${t}]+`,"g");for(let y=0;y
showMinutes: {{showMin}}
showSeconds: {{showSec}}
isAnimated
input or config option",outlet:j},{title:"Adaptive position",anchor:"adaptive-position",description:"\n You can enable adaptive position via adaptivePosition
input or config option
Use http request to search for data. If you need to handle http error, do this inside tap
operator.\n Enter search value several times (10-15), and after a few success responses API should return an error\n (GitHub limit for requests)
Set config property cancelRequestOnFocusLost
to true
if you want to cancel async request on focus lost event
Use typeaheadWaitMs
to set minimal waiting time after last character typed\n before typeahead kicks-in. In example a search begins with delay in 1 second
Typeahead can be used in template-driven forms. Keep in mind that value of ngModel
is\n string
Typeahead can be used in reactive forms
\n ",component:o(70083),html:o(66523),outlet:q},{title:"Grouping results",anchor:"grouping-results",component:o(99903),html:o(91207),outlet:ne},{title:"Ignore spaces and order",anchor:"single-world",component:o(57023),html:o(53735),description:'\nAfter setting typeaheadSingleWords
input property to true
\n order of typed symbols and spaces between them will be ignored. For example, "zona ari"\n will match with "Arizona"
Set the word delimiter by typeaheadPhraseDelimiters
to match exact phrase.\n This is demo with delimeters "&
" and ",
"
Returns an option on which user lost a focus. To reproduce start typing the name of the state, then focus\n on one of the options with mouse or arrow keys and click outside of the typeahead
\n ",component:o(13719),html:o(56591),outlet:re},{title:"Append to body",anchor:"container",description:"\ncontainer
is an input property specifying the element the typeahead should be appended to.
Used to display the state when no matches were found. To see message\n "No Results Found" enter the value that doesn\'t match anything from the list
\n ',component:o(93855),html:o(91591),outlet:se},{title:"Scrollable",anchor:"scrollable",component:o(94815),html:o(93223),outlet:he},{title:"Latinize",anchor:"latinize",description:"\nUse typeaheadLatinize
property for matching latin symbols. If it is set\n to true
the word s\xfaper would match super and vice versa.
typeaheadOnSelect
event is fired when an option was selected.\n Returns an object with this option.
typeaheadOnPreview
event is fired when an option was highlighted.\n Returns an object with this option.
Minimal number of characters that needs to be entered before typeahead kicks in. When set to 0, typeahead shows on focus with full list of options.
\n ",component:o(80295),html:o(53343),outlet:ie},{title:"Show results on blur",anchor:"show-on-blur",description:"\nUse input property typeaheadHideResultsOnBlur
or config property hideResultsOnBlur
\n to prevent hiding typeahead's results until a user doesn't choose an item
Use input property typeaheadIsFirstItemActive
or config property isFirstItemActive
to make the first item active/inactive
Use typeaheadSelectFirstItem
property to make the first item in options list unselectable by tab and enter.
Use typeaheadOrderBy
property to order your result by a certain field and in certain direction
Set typeaheadMultipleSearch
input property to true
\n and provide the multiple search delimiter by typeaheadMultipleSearchDelimiters
\n to be able to search typeahead again after using one of the provided delimiters. Default delimiter\n is ",
" if typeaheadMultipleSearchDelimiters
is not used.\n After picking a first value from typeahead\n dropdown, type ",
" or "|
" and then next value can be searched.\n This is demo with delimeters ",
" and "|
"
Model: {{selected | json}}\n'},92331:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-adaptive-position',\n templateUrl: './adaptive-position.html'\n})\nexport class DemoTypeaheadAdaptivePositionComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},72167:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},79967:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-animated',\n templateUrl: './animated.html'\n})\nexport class DemoTypeaheadAnimatedComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},10895:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{ search | json }}\n\n\n\n
Model: {{ asyncSelected | json }}\n\n\n'},10947:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\nimport { Observable, of, Subscriber } from 'rxjs';\nimport { mergeMap } from 'rxjs/operators';\nimport { DataSourceType } from '../interfaces/typeahead.interfaces';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-async',\n templateUrl: './async.html'\n})\nexport class DemoTypeaheadAsyncComponent {\n asyncSelected?: string;\n dataSource: Observable
Model: {{selected | json}}\n\n'},26499:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-basic',\n templateUrl: './basic.html'\n})\nexport class DemoTypeaheadBasicComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},93685:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{asyncSelected | json}}\n\n\n
Model: {{selected | json}}\n\n\n'},83263:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-container',\n templateUrl: './container.html'\n})\nexport class DemoTypeaheadContainerComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},27807:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},83431:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-delay',\n templateUrl: './delay.html'\n})\nexport class DemoTypeaheadDelayComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},43149:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},35929:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-dropup',\n templateUrl: './dropup.html'\n})\nexport class DemoTypeaheadDropupComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},22475:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{customSelected | json}}\n\n'},22707:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\nimport { DataSourceType } from '../interfaces/typeahead.interfaces';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-field',\n templateUrl: './field.html'\n})\nexport class DemoTypeaheadFieldComponent {\n customSelected?: string;\n statesComplex: DataSourceType[] = [\n { id: 1, name: 'Alabama', region: 'South' },\n { id: 2, name: 'Alaska', region: 'West' },\n { id: 3, name: 'Arizona', region: 'West' },\n { id: 4, name: 'Arkansas', region: 'South' },\n { id: 5, name: 'California', region: 'West' },\n { id: 6, name: 'Colorado', region: 'West' },\n { id: 7, name: 'Connecticut', region: 'Northeast' },\n { id: 8, name: 'Delaware', region: 'South' },\n { id: 9, name: 'Florida', region: 'South' },\n { id: 10, name: 'Georgia', region: 'South' },\n { id: 11, name: 'Hawaii', region: 'West' },\n { id: 12, name: 'Idaho', region: 'West' },\n { id: 13, name: 'Illinois', region: 'Midwest' },\n { id: 14, name: 'Indiana', region: 'Midwest' },\n { id: 15, name: 'Iowa', region: 'Midwest' },\n { id: 16, name: 'Kansas', region: 'Midwest' },\n { id: 17, name: 'Kentucky', region: 'South' },\n { id: 18, name: 'Louisiana', region: 'South' },\n { id: 19, name: 'Maine', region: 'Northeast' },\n { id: 21, name: 'Maryland', region: 'South' },\n { id: 22, name: 'Massachusetts', region: 'Northeast' },\n { id: 23, name: 'Michigan', region: 'Midwest' },\n { id: 24, name: 'Minnesota', region: 'Midwest' },\n { id: 25, name: 'Mississippi', region: 'South' },\n { id: 26, name: 'Missouri', region: 'Midwest' },\n { id: 27, name: 'Montana', region: 'West' },\n { id: 28, name: 'Nebraska', region: 'Midwest' },\n { id: 29, name: 'Nevada', region: 'West' },\n { id: 30, name: 'New Hampshire', region: 'Northeast' },\n { id: 31, name: 'New Jersey', region: 'Northeast' },\n { id: 32, name: 'New Mexico', region: 'West' },\n { id: 33, name: 'New York', region: 'Northeast' },\n { id: 34, name: 'North Dakota', region: 'Midwest' },\n { id: 35, name: 'North Carolina', region: 'South' },\n { id: 36, name: 'Ohio', region: 'Midwest' },\n { id: 37, name: 'Oklahoma', region: 'South' },\n { id: 38, name: 'Oregon', region: 'West' },\n { id: 39, name: 'Pennsylvania', region: 'Northeast' },\n { id: 40, name: 'Rhode Island', region: 'Northeast' },\n { id: 41, name: 'South Carolina', region: 'South' },\n { id: 42, name: 'South Dakota', region: 'Midwest' },\n { id: 43, name: 'Tennessee', region: 'South' },\n { id: 44, name: 'Texas', region: 'South' },\n { id: 45, name: 'Utah', region: 'West' },\n { id: 46, name: 'Vermont', region: 'Northeast' },\n { id: 47, name: 'Virginia', region: 'South' },\n { id: 48, name: 'Washington', region: 'South' },\n { id: 49, name: 'West Virginia', region: 'South' },\n { id: 50, name: 'Wisconsin', region: 'Midwest' },\n { id: 51, name: 'Wyoming', region: 'West' }\n ];\n}\n"},52055:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},18127:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-first-item-active',\n templateUrl: './first-item-active.html'\n})\nexport class DemoTypeaheadFirstItemActiveComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},3161:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{model | json}}\n\n\n'},12117:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-form',\n templateUrl: './form.html'\n})\nexport class DemoTypeaheadFormComponent {\n model = {\n address: '312 Sundown Lane',\n state: null\n };\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},91207:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{groupSelected | json}}\n\n'},99903:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\nimport { DataSourceType } from '../interfaces/typeahead.interfaces';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-grouping',\n templateUrl: './grouping.html'\n})\nexport class DemoTypeaheadGroupingComponent {\n groupSelected?: string;\n statesComplex: DataSourceType[] = [\n { id: 1, name: 'Alabama', region: 'South' },\n { id: 2, name: 'Alaska', region: 'West' },\n { id: 3, name: 'Arizona', region: 'West' },\n { id: 4, name: 'Arkansas', region: 'South' },\n { id: 5, name: 'California', region: 'West' },\n { id: 6, name: 'Colorado', region: 'West' },\n { id: 7, name: 'Connecticut', region: 'Northeast' },\n { id: 8, name: 'Delaware', region: 'South' },\n { id: 9, name: 'Florida', region: 'South' },\n { id: 10, name: 'Georgia', region: 'South' },\n { id: 11, name: 'Hawaii', region: 'West' },\n { id: 12, name: 'Idaho', region: 'West' },\n { id: 13, name: 'Illinois', region: 'Midwest' },\n { id: 14, name: 'Indiana', region: 'Midwest' },\n { id: 15, name: 'Iowa', region: 'Midwest' },\n { id: 16, name: 'Kansas', region: 'Midwest' },\n { id: 17, name: 'Kentucky', region: 'South' },\n { id: 18, name: 'Louisiana', region: 'South' },\n { id: 19, name: 'Maine', region: 'Northeast' },\n { id: 21, name: 'Maryland', region: 'South' },\n { id: 22, name: 'Massachusetts', region: 'Northeast' },\n { id: 23, name: 'Michigan', region: 'Midwest' },\n { id: 24, name: 'Minnesota', region: 'Midwest' },\n { id: 25, name: 'Mississippi', region: 'South' },\n { id: 26, name: 'Missouri', region: 'Midwest' },\n { id: 27, name: 'Montana', region: 'West' },\n { id: 28, name: 'Nebraska', region: 'Midwest' },\n { id: 29, name: 'Nevada', region: 'West' },\n { id: 30, name: 'New Hampshire', region: 'Northeast' },\n { id: 31, name: 'New Jersey', region: 'Northeast' },\n { id: 32, name: 'New Mexico', region: 'West' },\n { id: 33, name: 'New York', region: 'Northeast' },\n { id: 34, name: 'North Dakota', region: 'Midwest' },\n { id: 35, name: 'North Carolina', region: 'South' },\n { id: 36, name: 'Ohio', region: 'Midwest' },\n { id: 37, name: 'Oklahoma', region: 'South' },\n { id: 38, name: 'Oregon', region: 'West' },\n { id: 39, name: 'Pennsylvania', region: 'Northeast' },\n { id: 40, name: 'Rhode Island', region: 'Northeast' },\n { id: 41, name: 'South Carolina', region: 'South' },\n { id: 42, name: 'South Dakota', region: 'Midwest' },\n { id: 43, name: 'Tennessee', region: 'South' },\n { id: 44, name: 'Texas', region: 'South' },\n { id: 45, name: 'Utah', region: 'West' },\n { id: 46, name: 'Vermont', region: 'Northeast' },\n { id: 47, name: 'Virginia', region: 'South' },\n { id: 48, name: 'Washington', region: 'South' },\n { id: 49, name: 'West Virginia', region: 'South' },\n { id: 50, name: 'Wisconsin', region: 'Midwest' },\n { id: 51, name: 'Wyoming', region: 'West' }\n ];\n}\n"},49231:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},57175:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-item-template',\n templateUrl: './item-template.html'\n})\nexport class DemoTypeaheadItemTemplateComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},71409:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},6653:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-latinize',\n templateUrl: './latinize.html'\n})\nexport class DemoTypeaheadLatinizeComponent {\n selected?: string;\n frenchWords: string[] = [\n 'popularis\xe9',\n 'fran\xe7ais',\n 'int\xe9ress\xe9',\n 'g\xe9n\xe9rateur',\n 'r\xe9pandue',\n 'r\xe9p\xe9tition',\n 's\xfaper'\n ];\n}\n"},66499:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n\n
Model: {{selected | json}}\n\n'},80295:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-min-length',\n templateUrl: './min-length.html'\n})\nexport class DemoTypeaheadMinLengthComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},70087:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},29407:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-multiple-search',\n templateUrl: './multiple-search.html'\n})\nexport class DemoTypeaheadMultipleSearchComponent {\n selected?: string;\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},91591:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n
Model: {{selected | json}}\n
Option on blur: {{optionOnBlur | json}}\n\n\n'},13719:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\nimport { TypeaheadMatch, TypeaheadConfig } from 'ngx-bootstrap/typeahead';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-on-blur',\n templateUrl: './on-blur.html',\n providers: [{ provide: TypeaheadConfig, useValue: { selectItemOnBlur: true, hideResultsOnBlur: true } }]\n})\nexport class DemoTypeaheadOnBlurComponent {\n selected?: string;\n optionOnBlur?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n\n typeaheadOnBlur(event?: TypeaheadMatch
Model: {{selectedValue | json}}\n
Selected option: {{selectedOption | json}}\n
Model: {{selected | json}}\n\n'},53543:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-phrase-delimiters',\n templateUrl: './phrase-delimiters.html'\n})\nexport class DemoTypeaheadPhraseDelimitersComponent {\n selected?: string;\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},66523:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{myForm.value.state | json}}\n\n\n'},70083:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup } from '@angular/forms';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-reactive-form',\n templateUrl: './reactive-form.html'\n})\nexport class DemoTypeaheadReactiveFormComponent {\n stateCtrl = new UntypedFormControl();\n\n myForm = new UntypedFormGroup({\n state: this.stateCtrl\n });\n\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},93223:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},94815:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-scrollable',\n templateUrl: './scrollable.html'\n})\nexport class DemoTypeaheadScrollableComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},27819:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='
Model: {{selected | json}}\n\n'},11059:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-selected-first-item',\n templateUrl: './selected-first-item.html'\n})\nexport class DemotypeaheadSelectFirstItemComponent {\n selected?: string;\n states: string[] = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},92679:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='\n
\n typeaheadHideResultsOnBlur: {{typeaheadHideResultsOnBlur}}\n Model: {{selected | json}}\n\n\n'},42559:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-show-on-blur',\n templateUrl: './show-on-blur.html'\n})\nexport class DemoTypeaheadShowOnBlurComponent {\n typeaheadHideResultsOnBlur = false;\n selected?: string;\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},53735:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l='\n
\n typeaheadSingleWords: {{typeaheadSingleWords}}\n Model: {{selected | json}}\n\n\n'},57023:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-typeahead-single-world',\n templateUrl: './single-world.html'\n})\nexport class DemoTypeaheadSingleWorldComponent {\n typeaheadSingleWords = true;\n selected?: string;\n states = [\n 'Alabama',\n 'Alaska',\n 'Arizona',\n 'Arkansas',\n 'California',\n 'Colorado',\n 'Connecticut',\n 'Delaware',\n 'Florida',\n 'Georgia',\n 'Hawaii',\n 'Idaho',\n 'Illinois',\n 'Indiana',\n 'Iowa',\n 'Kansas',\n 'Kentucky',\n 'Louisiana',\n 'Maine',\n 'Maryland',\n 'Massachusetts',\n 'Michigan',\n 'Minnesota',\n 'Mississippi',\n 'Missouri',\n 'Montana',\n 'Nebraska',\n 'Nevada',\n 'New Hampshire',\n 'New Jersey',\n 'New Mexico',\n 'New York',\n 'North Dakota',\n 'North Carolina',\n 'Ohio',\n 'Oklahoma',\n 'Oregon',\n 'Pennsylvania',\n 'Rhode Island',\n 'South Carolina',\n 'South Dakota',\n 'Tennessee',\n 'Texas',\n 'Utah',\n 'Vermont',\n 'Virginia',\n 'Washington',\n 'West Virginia',\n 'Wisconsin',\n 'Wyoming'\n ];\n}\n"},41704:(p,s,o)=>{o.r(s),o.d(s,{default:()=>l});const l="### Standalone component usage\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\n@Component({\n standalone: true,\n imports: [\n BrowserAnimationsModule,\n TypeaheadModule,\n ...\n ]\n})\nexport class AppComponent(){}\n\n### Module usage\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\n\n@NgModule({\n imports: [\n BrowserAnimationsModule,\n TypeaheadModule,\n ...\n ]\n})\nexport class AppModule(){}\n"}}]); \ No newline at end of file diff --git a/648.191424c53e08bc03.js b/648.191424c53e08bc03.js new file mode 100644 index 0000000000..dfc81b18c1 --- /dev/null +++ b/648.191424c53e08bc03.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[648],{78648:(d,o,n)=>{n.r(o),n.d(o,{CollapseSectionComponent:()=>F,DemoCollapseModule:()=>j});var a=n(60177),f=n(84341),E=n(8681),y=n(65972),r=n(37472),e=n(54438),m=n(31029);let h=(()=>{class t{constructor(){this.isCollapsed=!1}static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275cmp=e.VBU({type:t,selectors:[["collapse-demo-animation"]],decls:6,vars:3,consts:[["type","button","aria-controls","collapseBasic",1,"btn","btn-primary",3,"click"],["id","collapseBasic",3,"collapse","isAnimated"],[1,"well","well-lg","card","card-block","card-header"]],template:function(l,s){1&l&&(e.j41(0,"button",0),e.bIt("click",function(){return s.isCollapsed=!s.isCollapsed}),e.EFF(1,"Toggle collapse\n"),e.k0s(),e.nrm(2,"hr"),e.j41(3,"div",1)(4,"div",2),e.EFF(5,"Some content"),e.k0s()()),2&l&&(e.BMQ("aria-expanded",!s.isCollapsed),e.R7$(3),e.Y8G("collapse",s.isCollapsed)("isAnimated",!0))},dependencies:[m.D],encapsulation:2})}return t})(),C=(()=>{class t{constructor(){this.isCollapsed=!1}static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275cmp=e.VBU({type:t,selectors:[["collapse-demo"]],decls:6,vars:2,consts:[["type","button","aria-controls","collapseBasic",1,"btn","btn-primary",3,"click"],["id","collapseBasic",3,"collapse"],[1,"well","well-lg","card","card-block","card-header"]],template:function(l,s){1&l&&(e.j41(0,"button",0),e.bIt("click",function(){return s.isCollapsed=!s.isCollapsed}),e.EFF(1,"Toggle collapse\n"),e.k0s(),e.nrm(2,"hr"),e.j41(3,"div",1)(4,"div",2),e.EFF(5,"Some content"),e.k0s()()),2&l&&(e.BMQ("aria-expanded",!s.isCollapsed),e.R7$(3),e.Y8G("collapse",s.isCollapsed))},dependencies:[m.D],encapsulation:2})}return t})(),b=(()=>{class t{constructor(){this.isCollapsed=!1,this.message="expanded"}collapsed(){this.message="collapsed"}collapses(){this.message="collapses"}expanded(){this.message="expanded"}expands(){this.message="expands"}static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275cmp=e.VBU({type:t,selectors:[["collapse-demo-events"]],decls:11,vars:4,consts:[[1,"row"],[1,"col-md-3"],["type","button","aria-controls","collapseEvent",1,"btn","btn-primary",3,"click"],[1,"col-md-9"],[1,"card","card-block","card-header"],["id","collapseEvent",3,"collapses","expands","collapsed","expanded","isAnimated","collapse"],[1,"well","well-lg","card","card-block","card-header"]],template:function(l,s){1&l&&(e.j41(0,"div",0)(1,"div",1)(2,"button",2),e.bIt("click",function(){return s.isCollapsed=!s.isCollapsed}),e.EFF(3,"Toggle collapse "),e.k0s()(),e.j41(4,"div",3)(5,"pre",4),e.EFF(6),e.k0s()()(),e.nrm(7,"hr"),e.j41(8,"div",5),e.bIt("collapses",function(){return s.collapses()})("expands",function(){return s.expands()})("collapsed",function(){return s.collapsed()})("expanded",function(){return s.expanded()}),e.j41(9,"div",6),e.EFF(10,"Some content"),e.k0s()()),2&l&&(e.R7$(2),e.BMQ("aria-expanded",!s.isCollapsed),e.R7$(4),e.SpI("Event: ",s.message,""),e.R7$(2),e.Y8G("isAnimated",!0)("collapse",s.isCollapsed))},dependencies:[m.D],encapsulation:2})}return t})(),D=(()=>{class t{static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275cmp=e.VBU({type:t,selectors:[["demo-accessibility"]],decls:37,vars:0,consts:[[1,"highlighter-rouge"]],template:function(l,s){1&l&&(e.j41(0,"p"),e.EFF(1,"Be sure to add "),e.j41(2,"code",0),e.EFF(3,"aria-expanded"),e.k0s(),e.EFF(4," to the control element. This attribute explicitly conveys the current state of the collapsible element tied to the control to screen readers and similar assistive technologies. If the collapsible element is closed by default, the attribute on the control element should have a value of "),e.j41(5,"code",0),e.EFF(6,'aria-expanded="false"'),e.k0s(),e.EFF(7,". If you\u2019ve set the collapsible element to be open by default using the "),e.j41(8,"code",0),e.EFF(9,"show"),e.k0s(),e.EFF(10," class, set "),e.j41(11,"code",0),e.EFF(12,'aria-expanded="true"'),e.k0s(),e.EFF(13," on the control instead. The plugin will automatically toggle this attribute on the control based on whether or not the collapsible element has been opened or closed. If the control element\u2019s HTML element is not a button (e.g., an "),e.j41(14,"code",0),e.EFF(15,""),e.k0s(),e.EFF(16," or "),e.j41(17,"code",0),e.EFF(18,"
isAnimated
input option",outlet:h},{title:"Events",anchor:"events",component:n(1143),html:n(65487),description:"Collapse directive exposes 4 events: collapses
, that fires when a collapse was triggered (animation start),\n collapsed
, that fires when a content was hidden (animation finished),\n expands
, that fires when a expansion was triggered (animation start)\n and expanded
, that fires when a content was shown",outlet:b},{title:"Manual toggle",anchor:"manual-toggle",component:n(28407),html:n(83983),outlet:v},{title:"Inline display",anchor:"inline-display",component:n(66649),html:n(19533),outlet:g},{title:"Accessibility",anchor:"accessibility",outlet:D}]},{name:"Installation",anchor:"api-reference",tabName:"api",usage:n(70976),importInfo:'ng add ngx-bootstrap --component collapse',outlet:r.Mg,content:[{title:"CollapseDirective",anchor:"collapse-directive",outlet:r.r2}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:r.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:C},{title:"With animation",anchor:"animated-ex",outlet:h},{title:"Events",anchor:"events-ex",outlet:b},{title:"Manual toggle",anchor:"manual-toggle-ex",outlet:v},{title:"Inline display",anchor:"inline-display-ex",outlet:g}]}];var k=n(86223),B=n(52439);let F=(()=>{class t{constructor(){this.name="Collapse",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/collapse",this.componentContent=T}static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275cmp=e.VBU({type:t,selectors:[["collapse-section"]],decls:12,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(l,s){1&l&&(e.j41(0,"demo-section",0)(1,"p"),e.EFF(2,"Collapse component allows you to toggle content on your pages with a bit of JavaScript and some classes. Flexible component that utilizes a handful of classes (from the "),e.j41(3,"strong"),e.EFF(4,"required transitions component"),e.k0s(),e.EFF(5,"("),e.j41(6,"em"),e.EFF(7,"not yet implemented"),e.k0s(),e.EFF(8,")) for easy toggle behavior."),e.k0s(),e.j41(9,"p"),e.EFF(10,"The easiest way to add the collapse component to your app (will be added to the root module)"),e.k0s(),e.nrm(11,"docs-section",1),e.k0s()),2&l&&(e.Y8G("name",s.name)("src",s.src)("componentContent",s.componentContent),e.R7$(11),e.Y8G("content",s.componentContent))},dependencies:[k.q,B.C],encapsulation:2,changeDetection:0})}return t})();const A=[{path:"",component:F}];let j=(()=>{class t{static#e=this.\u0275fac=function(l){return new(l||t)};static#n=this.\u0275mod=e.$C({type:t});static#t=this.\u0275inj=e.G2t({imports:[y.G,a.MD,f.YN,r.ky,E.iI.forChild(A)]})}return t})()},98255:(d,o,n)=>{n.r(o),n.d(o,{default:()=>a});const a='\nEvent: {{message}}\n
Click headers to expand/collapse content that is broken into logical sections, much\n like tabs.
",component:o(46856),html:o(86552),outlet:A},{title:"With animation",anchor:"animated-accordion",description:"Use input property or config property isAnimated
to enable/disable animation
Accordion with isOpenChange
event listener.
Some content
\nSome content
\nSome content
\nSome content
\nSome content
\nSome content
\nContent 1
\nContent 2
\n\n \n
\n\naccordion 1
\naccordion 2
\n\n \n
\n\nThe body of the accordion group grows to fit the contents
\n \n \naccordion 2
\naccordion 3
\n\n \n
\n\naccordion 1
\naccordion 2
\naccordion 3
\nContent 1
\nContent 2
\nSome content
\nSome content
\nSome content
\naccordion 1
\naccordion 3
\naccordion 1
\naccordion 2
\nBootstrap 4 doesn't have justified classes
",outlet:F},{title:"Custom class",anchor:"tabs-custom-class",component:n(4162),html:n(33526),outlet:v},{title:"Select event",anchor:"select-event",component:n(16784),html:n(37552),description:"You can subscribe to tab's select
event
Tabs can be enabled or disabled by changing disabled
input property
\n \n
\nThe Component inside the Tab is rendered, when the tab is activated and destroyed when the tab is left.
\nChange quantity of tabs by manipulating tabs array
\n \n \nYou can select tabs directly from component
\n\n \n \n
\nEvent select is fired. The heading of the selected tab is: {{value}}\n
Lorem Ipsum is simply dummy text of the printing and typesetting industry.\n Lorem Ipsum has been the industry\'s standard dummy text ever since the 1500s,\n when an unknown printer took a galley of type and scrambled it to make a type specimen book.
\nIt has survived not only five centuries, but also the leap into electronic typesetting,\n remaining essentially unchanged. It was popularised in the 1960s with the release of\n Letraset sheets containing Lorem Ipsum passages
\nWrap the dropdown\u2019s toggle (your button or link) and the dropdown menu within\n dropdown
. Dropdowns can be triggered from <a>
or <button>
\n elements to better fit your potential needs.
Any <button>
can became a dropdown toggle with few markup changes.\n Here\u2019s how dropdown works with single button
isAnimated
input or config option",outlet:R},{title:"Trigger by tag ",anchor:"anchor-trigger",component:o(30163),html:o(72043),outlet:y},{title:"Split button dropdowns",anchor:"split-button",component:o(121),html:o(46637),description:"Similarly, create split button dropdowns with virtually the same markup as single\n button dropdowns, but with the addition of .dropdown-toggle-split
for proper spacing\n around the dropdown caret.
Dropdown can be triggered by show
, hide
and\n toggle
methods from directive\n
\n Use method toggle(true)
if you want to toggle the dropdown or toggle(false)
\n if you want to only close opened dropdown.\n
Dropdown can be shown or hidden by changing isOpen
input property
Use isDisabled
property to make dropdown disabled.
Add a disabled
class to <a>
to make it as disabled.
By default, a dropdown menu is automatically positioned 100% from the top and along\n the left side of its parent. Add class .dropdown-menu-right
to a dropdownMenu
\n to right align the dropdown menu.
By default, a dropdown menu closes on document click, even if you clicked on an element inside the dropdown.\n Use [insideClick]="true"
to allow click inside the dropdown
Append dropdown to body by adding container="body"
to the parent element.
To make dropdown's menu appear above toggle element set dropup
property as true
Separate groups of related menu items with a .dropdown-divider
for bootstrap 4.
Dropdown allows you to use any html markup inside of it
",outlet:O},{title:"Configuring defaults",anchor:"config-defaults",component:o(71563),html:o(659),description:"It is possible to override default dropdown config partially or completely.
",outlet:U},{title:"Visibility Events",anchor:"visibility-events",component:o(75889),html:o(89653),description:"You can subscribe to dropdown's visibility events
",outlet:x},{title:"State change event",anchor:"state-change-event",component:o(33605),html:o(19657),description:"You can subscribe to dropdown's state change event (isOpenChange
).
Use autoClose
property to change dropdown's default behavior
Default behavior: dropdown closes after outside click or pressing ESC
\nThis dropdown won\'t be closed after outside click or pressing ESC
\nThe dropdown is {{text}}\n
{{message}}\n
Four positioning options are available: top
, right
,\n bottom
, and left
. Besides that, auto
option may be\n used to detect a position that fits the component on the screen.
You can disable adaptive position via adaptivePosition
input or config option
Use the focus
trigger to dismiss tooltips on the next click\n that the user makes.
Pass a string as tooltip content
",outlet:E},{title:"Custom content template",anchor:"custom-content-template",component:o(21085),html:o(32241),description:'Create <ng-template #myId>
with any html allowed by Angular,\n and provide template ref [tooltip]="myId"
as tooltip content
By using [innerHtml]
inside ng-template
you\n can display any dynamic html
When you have some styles on a parent element that interfere with a tooltip,\n you\u2019ll want to specify a container="body"
so that the tooltip\u2019s HTML will be\n appended to body. This will help to avoid rendering problems in more complex components\n (like our input groups, button groups, etc) or inside elements with overflow: hidden
You can manage tooltip using its show()
, hide()
and toggle()
methods.\n If you want to manage tooltip\'s state manually, use triggers=""
Hold on cursor above button for 0,5 second or more to see delayed tooltip
",outlet:C}]},{name:"Installation",anchor:"api-reference",tabName:"api",outlet:m.Mg,usage:o(4470),importInfo:'ng add ngx-bootstrap --component tooltip',content:[{title:"TooltipDirective",anchor:"tooltip-directive",outlet:m.r2},{title:"TooltipConfig",anchor:"tooltip-config",outlet:m.TJ}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:m.xK,content:[{title:"Basic",anchor:"basic-ex",outlet:g},{title:"Placement",anchor:"placement-ex",outlet:F},{title:"Disable adaptive position",anchor:"adaptive-position-ex",outlet:b},{title:"Dismiss on next click",anchor:"dismiss-ex",outlet:v},{title:"Dynamic Content",anchor:"dynamic-content-ex",outlet:E},{title:"Custom content template",anchor:"custom-content-template-ex",outlet:T},{title:"Dynamic Html",anchor:"dynamic-html-ex",outlet:D},{title:"Append to body",anchor:"append-to-body-ex",outlet:h},{title:"Configuring defaults",anchor:"config-defaults-ex",outlet:y},{title:"Custom triggers",anchor:"triggers-custom-ex",outlet:A},{title:"Manual triggering",anchor:"triggers-manual-ex",outlet:U},{title:"Component level styling",anchor:"styling-local-ex",outlet:P},{title:"Custom class",anchor:"custom-class-ex",outlet:f},{title:"Tooltip with delay",anchor:"tooltip-delay-ex",outlet:C}]}];var K=o(86223),X=o(52439);let x=(()=>{class e{constructor(){this.name="Tooltip",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/tooltip",this.componentContent=S}static#t=this.\u0275fac=function(l){return new(l||e)};static#o=this.\u0275cmp=t.VBU({type:e,selectors:[["tooltip-section"]],decls:6,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(l,c){1&l&&(t.j41(0,"demo-section",0)(1,"p"),t.EFF(2,"Inspired by the excellent Tipsy jQuery plugin written by Jason Frame. Tooltips are an updated version, which don\u2019t rely on images, use CSS3 for animations, and much more."),t.k0s(),t.j41(3,"p"),t.EFF(4,"The easiest way to add the tooltip component to your app (will be added to the root module)"),t.k0s(),t.nrm(5,"docs-section",1),t.k0s()),2&l&&(t.Y8G("name",c.name)("src",c.src)("componentContent",c.componentContent),t.R7$(5),t.Y8G("content",c.componentContent))},dependencies:[K.q,X.C],encapsulation:2,changeDetection:0})}return e})();const W=[{path:"",component:x}];let H=(()=>{class e{static#t=this.\u0275fac=function(l){return new(l||e)};static#o=this.\u0275mod=t.$C({type:e});static#n=this.\u0275inj=t.G2t({imports:[s.MD,O.YN,m.ky,d.Ss,j.iI.forChild(W)]})}return e})()},28053:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s='\n\n\n'},16881:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-adaptive-position',\n templateUrl: './adaptive-position.html'\n})\nexport class DemoTooltipAdaptivePositionComponent {}\n"},2549:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s='\n\n'},31217:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-basic',\n templateUrl: './basic.html'\n})\nexport class DemoTooltipBasicComponent {}\n"},84457:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s='\n\n'},13925:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-class',\n templateUrl: './class.html'\n})\nexport class DemoTooltipClassComponent {}\n"},64803:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s='\n'},37947:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\nimport { TooltipConfig } from 'ngx-bootstrap/tooltip';\n\n// such override allows to keep some initial values\n\nexport function getAlertConfig(): TooltipConfig {\n return Object.assign(new TooltipConfig(), {\n placement: 'right',\n container: 'body',\n delay: 500\n });\n}\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-config',\n templateUrl: './config.html',\n providers: [{ provide: TooltipConfig, useFactory: getAlertConfig }]\n})\nexport class DemoTooltipConfigComponent {}\n"},64265:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s=' \n\n'},61285:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-container',\n templateUrl: './container.html'\n})\nexport class DemoTooltipContainerComponent {}\n"},32241:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s='Desktop
\n \nMobile
\n \n\n \n This text has attached tooltip\n \n
\n\n\n\n\n\n'},67113:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="import { Component } from '@angular/core';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'demo-tooltip-triggers-manual',\n templateUrl: './triggers-manual.html'\n})\nexport class DemoTooltipTriggersManualComponent {}\n"},4470:(a,n,o)=>{o.r(n),o.d(n,{default:()=>s});const s="### Standalone component usage\nimport { TooltipModule } from 'ngx-bootstrap/timepicker';\n\n@Component({\n standalone: true,\n imports: [TooltipModule,...]\n})\nexport class AppComponent(){}\n\n### Module usage\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\n\n@NgModule({\n imports: [TooltipModule,...]\n})\nexport class AppModule(){}\n"}}]); \ No newline at end of file diff --git a/90.b2ebde120ef580f4.js b/90.b2ebde120ef580f4.js new file mode 100644 index 0000000000..c371ce7725 --- /dev/null +++ b/90.b2ebde120ef580f4.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkngx_bootstrap_docs=self.webpackChunkngx_bootstrap_docs||[]).push([[90],{41090:(g,s,i)=>{i.r(s),i.d(s,{DemoRatingModule:()=>G,RatingSectionComponent:()=>F});var r=i(60177),d=i(84341),E=i(8681),n=i(54438);let R=(()=>{class e{constructor(){this.ariaLabel="rating"}static#n=this.\u0275fac=function(o){return new(o||e)};static#t=this.\u0275prov=n.jDH({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();const T=(e,m)=>({index:e,value:m});function _(e,m){1&e&&n.EFF(0),2&e&&n.JRh(m.indexEnter
to select the value, after this, the rating state will be changed to readonly.",anchor:"select-on-enter",component:i(51709),html:i(60561),outlet:v},{title:"Configuring defaults",anchor:"demo-rating-config",component:i(40011),html:i(12499),outlet:b}]},{name:"Installation",anchor:"api-reference",tabName:"api",usage:i(48710),importInfo:'ng add ngx-bootstrap --component rating',outlet:h.Mg,content:[{title:"RatingComponent",anchor:"rating-component",outlet:h.r2},{title:"RatingConfig",anchor:"rating-config",outlet:h.TJ}]},{name:"Examples",anchor:"examples",tabName:"examples",outlet:h.xK,content:[{title:"Basic rating",anchor:"rating-basic-ex",outlet:f},{title:"Dynamic rating",anchor:"rating-dynamic-ex",outlet:C},{title:"Custom icons",anchor:"rating-custom-ex",outlet:y},{title:"Select on enter",anchor:"select-on-enter-ex",outlet:v},{title:"Configuring defaults",anchor:"demo-rating-config-ex",outlet:b}]}];var L=i(86223),V=i(52439);let F=(()=>{class e{constructor(){this.name="Rating",this.src="https://github.com/valor-software/ngx-bootstrap/tree/development/src/rating",this.componentContent=U}static#n=this.\u0275fac=function(o){return new(o||e)};static#t=this.\u0275cmp=n.VBU({type:e,selectors:[["rating-section"]],decls:6,vars:4,consts:[[3,"name","src","componentContent"],[3,"content"]],template:function(o,t){1&o&&(n.j41(0,"demo-section",0)(1,"p"),n.EFF(2,"Rating component that will take care of visualising a star rating bar"),n.k0s(),n.j41(3,"p"),n.EFF(4,"The easiest way to add the rating component to your app (will be added to the root module)"),n.k0s(),n.nrm(5,"docs-section",1),n.k0s()),2&o&&(n.Y8G("name",t.name)("src",t.src)("componentContent",t.componentContent),n.R7$(5),n.Y8G("content",t.componentContent))},dependencies:[L.q,V.C],encapsulation:2,changeDetection:0})}return e})();const P=[{path:"",component:F}];let G=(()=>{class e{static#n=this.\u0275fac=function(o){return new(o||e)};static#t=this.\u0275mod=n.$C({type:e});static#e=this.\u0275inj=n.G2t({imports:[r.MD,d.YN,h.ky,M,E.iI.forChild(P)]})}return e})()},28581:(g,s,i)=>{i.r(s),i.d(s,{default:()=>r});const r='Rate: {{rate}}\n
Rate: {{rate}}\n
(Rate: {{x}})\n
(Rate: {{y}})\n
Rate: {{rate}}; Readonly is: {{isReadonly}}; Hovering over: {{overStar || "none"}}\n
Rating: {{rate}}; Readonly is: {{isReadonly}};\n
Open a modal from service.
\nTo be able to open modals from service, inject BsModalService
to your constructor.
Then, call\n .show()
method of modal service. Pass a TemplateRef
or a component as a first argument and\n config as a second (optionally).
.show()
method returns an instance of BsModalRef
\n class with .hide()
method and content
property where you'll find a component\n which you've passed to service.
Creating a modal with component just as easy as it is with template. Just pass your component\n in .show()
method as in example, and don't forget to include your component to\n entryComponents
of your NgModule
If you passed a component\n to .show()
you can get access to opened modal by injecting BsModalRef
. Also you can pass data\n in your modal by adding initialState
field in config. See example for more info
Nested modals are supported
",outlet:x},{title:"Scrolling long content",anchor:"scrolling-long-content",component:s(58525),html:s(31121),outlet:ee},{title:"Events",anchor:"service-events",component:s(42699),html:s(25235),description:"\nModal service events. Modal service exposes 4 events: onShow
, onShown
,\n onHide
, onHidden
.\n See usage example below.
onHide
and onHidden
events emit dismiss reason. Possible values are\n backdrop-click
, esc
or {id: number | string}
if modal was closed by direct call of\n hide()
method
Modal ref events. ModalRef exposes 2 events: onHide
and onHidden
. Note,\n onShow
and onShown
are not options because they have already fired by the time\n the ModalRef is created.\n See usage example below.
onHide
and onHidden
events emit dismiss reason. Possible values are\n backdrop-click
, esc
or {id: number | string}
if modal was closed by direct call of\n hide()
method
Modal with opportunity to confirm
or decline
.
There is possibility to add custom css class to a modal.\n See the demo below to learn how to use it
",outlet:U},{title:"Animation option",anchor:"service-disable-animation",component:s(84756),html:s(32116),description:"There is animation option that you can configure.
",outlet:W},{title:"Esc closing option",anchor:"service-disable-esc-closing",component:s(50692),html:s(20740),description:"There is closing by Esc button option that you can configure.
",outlet:L},{title:"Modal window with tooltip and popover",anchor:"modal-with-popups",component:s(52855),html:s(61071),description:"Tooltips
and popovers
can be placed within modals as needed. When modals are closed, any tooltips
and popovers
within are also automatically dismissed.
There is backdrop options that you can configure.
",outlet:X},{title:"Change class",anchor:"change-class",component:s(46456),html:s(67944),description:"Calling setClass method to change modal's window class
",outlet:K},{title:"Close interceptor",anchor:"service-with-interceptor",component:s(28983),html:s(58127),description:"When opening a modal with a component, you can provide an interceptor which will be triggered\n whenever the modal try to close, allowing you to block the disappearance of a modal.
",outlet:ne},{title:"Directive examples",anchor:"directive-section",description:"Also you can use directive instead of service. See the demos below
"},{title:"Static modal",anchor:"directive-static",component:s(93205),html:s(50073),outlet:G},{title:"Optional sizes",anchor:"directive-sizes",component:s(30359),html:s(87727),outlet:z},{title:"Child modal",anchor:"directive-child",component:s(40759),html:s(847),description:"Control modal from parent component
",outlet:J},{title:"Nested modals",anchor:"directive-nested",component:s(40535),html:s(83503),description:"Open a modal from another modal
",outlet:Y},{title:"Modal events",anchor:"directive-events",component:s(90187),html:s(79795),description:"ModalDirective
exposes 4 events: onShow
, onShown
,\n onHide
, onHidden
. See usage example below.
\n $event
is an instance of ModalDirective
. There you may\n find some useful properties like isShown
, dismissReason
, etc.\n
For example, you may want to know which one of user's actions caused closing of a modal.\n Just get the value of dismissReason
,
possible values are backdrop-click
,\n esc
or null
if modal was closed by direct call of hide()
method
Show modal right after it has been initialized. This allows you to keep DOM clean by only\n appending visible modals to the DOM using *ngIf
directive.
It can also be useful if you want your modal component to perform some initialization operations, but\n want to defer that until user actually sees modal content. I.e. for a "Select e-mail recipient" modal\n you might want to defer recipient list loading until the modal is shown.
',outlet:Z},{title:"Accessibility",anchor:"accessibility",component:s(79811),html:s(54491),description:'\n\n Be sure to add id=""
attribute to your title and description\n in the template to make your modal works according to accessibility. The aria-labelledby
\n attribute establishes relationships between the modal and its title (only if the title has id attribute). The element\n containing the modal\'s description is referenced by aria-describedby
attribute.\n The dialog does not need aria-describedby
since there is no static\n text that describes it.\n
\n Use modal options to set aria-labelledby
and\n aria-describedby
attributes.\n
{{message}}\n\n
{{message}}\n
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Cumque delectus enim esse excepturi, impedit,\n iste magnam officia optio, quam quis quisquam saepe sint unde velit vitae! Animi in iusto ut?
\n \n \nLorem ipsum dolor sit amet, consectetur adipisicing elit. Cumque delectus enim esse excepturi, impedit,\n iste magnam officia optio, quam quis quisquam saepe sint unde velit vitae! Animi in iusto ut?
\n{{message}}\n
Do you want to confirm?
\n \n \n{{message}}\n
Do you really want to close?
\n \n \nSmall modal window have small width on screens only above 768px(boostrap3) and 576px(bootstrap4)
\n\n\n