@mintplayer/ng-bootstrap 13.1.16 → 13.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2326,6 +2326,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
2326
2326
 
2327
2327
  class BsNavbarComponent {
2328
2328
  constructor() {
2329
+ this.expandButtonTemplate = null;
2329
2330
  this.isExpanded$ = new BehaviorSubject(false);
2330
2331
  }
2331
2332
  toggleExpanded() {
@@ -2335,10 +2336,10 @@ class BsNavbarComponent {
2335
2336
  }
2336
2337
  }
2337
2338
  BsNavbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2338
- BsNavbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: BsNavbarComponent, selector: "bs-navbar", viewQueries: [{ propertyName: "nav", first: true, predicate: ["nav"], descendants: true }], ngImport: i0, template: "<nav #nav class=\"navbar navbar-expand-md position-fixed navbar-dark bg-dark\">\n <div class=\"container-fluid\">\n <div class=\"d-flex w-100 w-md-auto\">\n <ng-content select=\"bs-navbar-brand\"></ng-content>\n <button (click)=\"toggleExpanded()\" class=\"navbar-toggler align-self-end\" type=\"button\">\n <span class=\"navbar-toggler-icon\"></span>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n</nav>", styles: [":host ::ng-deep+*{padding-top:56px}nav{left:0;top:0;right:0;z-index:10}@media (min-width: 768px){.mx-md-unset{margin-left:0!important;margin-right:0!important}.w-md-auto{width:auto!important}}\n"] });
2339
+ BsNavbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: BsNavbarComponent, selector: "bs-navbar", viewQueries: [{ propertyName: "nav", first: true, predicate: ["nav"], descendants: true }], ngImport: i0, template: "<nav #nav class=\"navbar navbar-expand-md position-fixed navbar-dark bg-dark\">\n <div class=\"container-fluid\">\n <div class=\"d-flex w-100 w-md-auto\">\n <ng-content select=\"bs-navbar-brand\"></ng-content>\n <button (click)=\"toggleExpanded()\" title=\"Expand/collapse menu\" class=\"align-self-end\" [class.navbar-toggler]=\"!expandButtonTemplate\" [class.bg-transparent]=\"expandButtonTemplate\" [class.shadow-none]=\"expandButtonTemplate\" [class.border-0]=\"expandButtonTemplate\" type=\"button\">\n <ng-container *ngTemplateOutlet=\"expandButtonTemplate ?? defaultExpandButton; context: { state: (isExpanded$ | async) ? 'open' : 'closed' }\"></ng-container>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n</nav>\n\n<ng-template #defaultExpandButton>\n <span class=\"navbar-toggler-icon\"></span>\n</ng-template>", styles: [":host ::ng-deep+*{padding-top:56px}nav{left:0;top:0;right:0;z-index:10}@media (min-width: 768px){.mx-md-unset{margin-left:0!important;margin-right:0!important}.w-md-auto{width:auto!important}}\n"], directives: [{ type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], pipes: { "async": i1.AsyncPipe } });
2339
2340
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarComponent, decorators: [{
2340
2341
  type: Component,
2341
- args: [{ selector: 'bs-navbar', template: "<nav #nav class=\"navbar navbar-expand-md position-fixed navbar-dark bg-dark\">\n <div class=\"container-fluid\">\n <div class=\"d-flex w-100 w-md-auto\">\n <ng-content select=\"bs-navbar-brand\"></ng-content>\n <button (click)=\"toggleExpanded()\" class=\"navbar-toggler align-self-end\" type=\"button\">\n <span class=\"navbar-toggler-icon\"></span>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n</nav>", styles: [":host ::ng-deep+*{padding-top:56px}nav{left:0;top:0;right:0;z-index:10}@media (min-width: 768px){.mx-md-unset{margin-left:0!important;margin-right:0!important}.w-md-auto{width:auto!important}}\n"] }]
2342
+ args: [{ selector: 'bs-navbar', template: "<nav #nav class=\"navbar navbar-expand-md position-fixed navbar-dark bg-dark\">\n <div class=\"container-fluid\">\n <div class=\"d-flex w-100 w-md-auto\">\n <ng-content select=\"bs-navbar-brand\"></ng-content>\n <button (click)=\"toggleExpanded()\" title=\"Expand/collapse menu\" class=\"align-self-end\" [class.navbar-toggler]=\"!expandButtonTemplate\" [class.bg-transparent]=\"expandButtonTemplate\" [class.shadow-none]=\"expandButtonTemplate\" [class.border-0]=\"expandButtonTemplate\" type=\"button\">\n <ng-container *ngTemplateOutlet=\"expandButtonTemplate ?? defaultExpandButton; context: { state: (isExpanded$ | async) ? 'open' : 'closed' }\"></ng-container>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n</nav>\n\n<ng-template #defaultExpandButton>\n <span class=\"navbar-toggler-icon\"></span>\n</ng-template>", styles: [":host ::ng-deep+*{padding-top:56px}nav{left:0;top:0;right:0;z-index:10}@media (min-width: 768px){.mx-md-unset{margin-left:0!important;margin-right:0!important}.w-md-auto{width:auto!important}}\n"] }]
2342
2343
  }], propDecorators: { nav: [{
2343
2344
  type: ViewChild,
2344
2345
  args: ['nav']
@@ -2389,7 +2390,9 @@ class BsNavbarNavComponent {
2389
2390
  //#endregion
2390
2391
  onWindowResize() {
2391
2392
  this.isResizing$.next(true);
2392
- this.windowWidth$.next(window.innerWidth);
2393
+ if (typeof window !== 'undefined') {
2394
+ this.windowWidth$.next(window.innerWidth);
2395
+ }
2393
2396
  }
2394
2397
  }
2395
2398
  BsNavbarNavComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarNavComponent, deps: [{ token: BsNavbarComponent }], target: i0.ɵɵFactoryTarget.Component });
@@ -2605,6 +2608,56 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
2605
2608
  args: ['class.mx-auto']
2606
2609
  }] } });
2607
2610
 
2611
+ class BsExpandButtonDirective {
2612
+ constructor(navbar, templateRef) {
2613
+ navbar.expandButtonTemplate = templateRef;
2614
+ }
2615
+ }
2616
+ BsExpandButtonDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsExpandButtonDirective, deps: [{ token: BsNavbarComponent }, { token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
2617
+ BsExpandButtonDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.1", type: BsExpandButtonDirective, selector: "[bsExpandButton]", ngImport: i0 });
2618
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsExpandButtonDirective, decorators: [{
2619
+ type: Directive,
2620
+ args: [{
2621
+ selector: '[bsExpandButton]'
2622
+ }]
2623
+ }], ctorParameters: function () { return [{ type: BsNavbarComponent }, { type: i0.TemplateRef }]; } });
2624
+
2625
+ class BsNavbarTogglerComponent {
2626
+ constructor() {
2627
+ //#region State
2628
+ this._state = 'closed';
2629
+ this.stateChange = new EventEmitter();
2630
+ }
2631
+ get state() {
2632
+ return this._state;
2633
+ }
2634
+ set state(value) {
2635
+ this._state = value;
2636
+ this.stateChange.emit(this._state);
2637
+ }
2638
+ //#endregion
2639
+ toggleState() {
2640
+ switch (this._state) {
2641
+ case 'open':
2642
+ this.state = 'closed';
2643
+ break;
2644
+ default:
2645
+ this.state = 'open';
2646
+ break;
2647
+ }
2648
+ }
2649
+ }
2650
+ BsNavbarTogglerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarTogglerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2651
+ BsNavbarTogglerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: BsNavbarTogglerComponent, selector: "bs-navbar-toggler", inputs: { state: "state" }, outputs: { stateChange: "stateChange" }, ngImport: i0, template: "<div class=\"navbar-toggler float-left\" [ngClass]=\"state\" id=\"navbar-toggler\" (click)=\"toggleState()\">\n <div></div>\n <div></div>\n <div></div>\n</div>", styles: [":host{align-self:start;position:absolute;top:0;right:0;padding:.5rem .75rem}.navbar-toggler{padding:.25rem;border:none}.navbar-toggler>div{width:25px;height:2px;background:#BBB;margin:6px 0;transition:.4s}.navbar-toggler.open>div:nth-of-type(1){transform:rotate(-45deg) translate(-7px,5px)}.navbar-toggler.open>div:nth-of-type(2){opacity:0}.navbar-toggler.open>div:nth-of-type(3){transform:rotate(45deg) translate(-6px,-4px)}@media (min-width: 768px){.navbar-toggler.auto>div:nth-of-type(1){transform:rotate(-45deg) translate(-7px,5px)}.navbar-toggler.auto>div:nth-of-type(2){opacity:0}.navbar-toggler.auto>div:nth-of-type(3){transform:rotate(45deg) translate(-6px,-4px)}}\n"], directives: [{ type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
2652
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarTogglerComponent, decorators: [{
2653
+ type: Component,
2654
+ args: [{ selector: 'bs-navbar-toggler', template: "<div class=\"navbar-toggler float-left\" [ngClass]=\"state\" id=\"navbar-toggler\" (click)=\"toggleState()\">\n <div></div>\n <div></div>\n <div></div>\n</div>", styles: [":host{align-self:start;position:absolute;top:0;right:0;padding:.5rem .75rem}.navbar-toggler{padding:.25rem;border:none}.navbar-toggler>div{width:25px;height:2px;background:#BBB;margin:6px 0;transition:.4s}.navbar-toggler.open>div:nth-of-type(1){transform:rotate(-45deg) translate(-7px,5px)}.navbar-toggler.open>div:nth-of-type(2){opacity:0}.navbar-toggler.open>div:nth-of-type(3){transform:rotate(45deg) translate(-6px,-4px)}@media (min-width: 768px){.navbar-toggler.auto>div:nth-of-type(1){transform:rotate(-45deg) translate(-7px,5px)}.navbar-toggler.auto>div:nth-of-type(2){opacity:0}.navbar-toggler.auto>div:nth-of-type(3){transform:rotate(45deg) translate(-6px,-4px)}}\n"] }]
2655
+ }], propDecorators: { stateChange: [{
2656
+ type: Output
2657
+ }], state: [{
2658
+ type: Input
2659
+ }] } });
2660
+
2608
2661
  class BsNavbarModule {
2609
2662
  }
2610
2663
  BsNavbarModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
@@ -2615,7 +2668,9 @@ BsNavbarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version:
2615
2668
  DropdownToggleDirective,
2616
2669
  NavLinkDirective,
2617
2670
  NavbarContentDirective,
2618
- BsNavbarBrandComponent], imports: [CommonModule,
2671
+ BsNavbarBrandComponent,
2672
+ BsExpandButtonDirective,
2673
+ BsNavbarTogglerComponent], imports: [CommonModule,
2619
2674
  RouterModule,
2620
2675
  ClickOutsideModule], exports: [BsNavbarComponent,
2621
2676
  BsNavbarNavComponent,
@@ -2624,7 +2679,9 @@ BsNavbarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version:
2624
2679
  DropdownToggleDirective,
2625
2680
  NavLinkDirective,
2626
2681
  NavbarContentDirective,
2627
- BsNavbarBrandComponent] });
2682
+ BsNavbarBrandComponent,
2683
+ BsExpandButtonDirective,
2684
+ BsNavbarTogglerComponent] });
2628
2685
  BsNavbarModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsNavbarModule, imports: [[
2629
2686
  CommonModule,
2630
2687
  RouterModule,
@@ -2641,7 +2698,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
2641
2698
  DropdownToggleDirective,
2642
2699
  NavLinkDirective,
2643
2700
  NavbarContentDirective,
2644
- BsNavbarBrandComponent
2701
+ BsNavbarBrandComponent,
2702
+ BsExpandButtonDirective,
2703
+ BsNavbarTogglerComponent
2645
2704
  ],
2646
2705
  imports: [
2647
2706
  CommonModule,
@@ -2656,7 +2715,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
2656
2715
  DropdownToggleDirective,
2657
2716
  NavLinkDirective,
2658
2717
  NavbarContentDirective,
2659
- BsNavbarBrandComponent
2718
+ BsNavbarBrandComponent,
2719
+ BsExpandButtonDirective,
2720
+ BsNavbarTogglerComponent
2660
2721
  ]
2661
2722
  }]
2662
2723
  }] });
@@ -2840,7 +2901,7 @@ class BsScrollspyComponent {
2840
2901
  }
2841
2902
  }
2842
2903
  scrollToCurrentInSpy() {
2843
- if (window && (window.innerWidth >= 768)) {
2904
+ if ((typeof window !== 'undefined') && (window.innerWidth >= 768)) {
2844
2905
  if (this.activeDirective) {
2845
2906
  const index = this.directives.toArray().findIndex((v, i) => v === this.activeDirective);
2846
2907
  const anchor = this.anchors.get(index);
@@ -2851,10 +2912,12 @@ class BsScrollspyComponent {
2851
2912
  }
2852
2913
  }
2853
2914
  scrollToHeader(directive) {
2854
- const header = directive.element.nativeElement;
2855
- const offsetY = this.scrollOffsetService.getScrollOffset()[1];
2856
- const y = header.getBoundingClientRect().top + window.scrollY - offsetY + 1;
2857
- window.scrollTo({ top: y, behavior: 'smooth' });
2915
+ if (typeof window !== 'undefined') {
2916
+ const header = directive.element.nativeElement;
2917
+ const offsetY = this.scrollOffsetService.getScrollOffset()[1];
2918
+ const y = header.getBoundingClientRect().top + window.scrollY - offsetY + 1;
2919
+ window.scrollTo({ top: y, behavior: 'smooth' });
2920
+ }
2858
2921
  }
2859
2922
  }
2860
2923
  BsScrollspyComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsScrollspyComponent, deps: [{ token: BsScrollOffsetService }, { token: DOCUMENT }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
@@ -2965,7 +3028,9 @@ class BsSelect2Component {
2965
3028
  this.focus();
2966
3029
  }
2967
3030
  onResize() {
2968
- this.hostWidth$.next(this.itemsBox.nativeElement.offsetWidth);
3031
+ if (typeof window !== 'undefined') {
3032
+ this.hostWidth$.next(this.itemsBox.nativeElement.offsetWidth);
3033
+ }
2969
3034
  }
2970
3035
  focus() {
2971
3036
  this.searchBox.nativeElement.focus();
@@ -3413,7 +3478,9 @@ class BsTypeaheadComponent {
3413
3478
  this.textbox.nativeElement.focus();
3414
3479
  }
3415
3480
  onResize() {
3416
- this.hostWidth$.next(this.textbox.nativeElement.offsetWidth);
3481
+ if (typeof window !== 'undefined') {
3482
+ this.hostWidth$.next(this.textbox.nativeElement.offsetWidth);
3483
+ }
3417
3484
  }
3418
3485
  }
3419
3486
  BsTypeaheadComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: BsTypeaheadComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
@@ -3526,5 +3593,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
3526
3593
  * Generated bundle index. Do not edit.
3527
3594
  */
3528
3595
 
3529
- export { BsAccordionComponent, BsAccordionModule, BsAccordionTabComponent, BsAccordionTabHeaderComponent, BsAlertCloseComponent, BsAlertComponent, BsAlertModule, BsButtonTemplateDirective, BsCalendarComponent, BsCalendarModule, BsCardComponent, BsCardHeaderComponent, BsCardModule, BsCarouselComponent, BsCarouselImageDirective, BsCarouselModule, BsCodeSnippetComponent, BsCodeSnippetModule, BsContextMenuDirective, BsContextMenuModule, BsCopyDirective, BsCopyModule, BsDatatableColumnDirective, BsDatatableComponent, BsDatatableModule, BsDatepickerComponent, BsDatepickerModule, BsDropdownDirective, BsDropdownMenuDirective, BsDropdownModule, BsDropdownToggleDirective, BsFileUploadComponent, BsFileUploadModule, BsFileUploadTemplateDirective, BsFontColorPipe, BsFontColorPipeModule, BsFooterTemplateDirective, BsForDirective, BsForModule, BsFormatBytesModule, BsFormatBytesPipe, BsHeaderTemplateDirective, BsItemTemplateDirective, BsListGroupComponent, BsListGroupItemComponent, BsListGroupModule, BsModalBodyDirective, BsModalComponent, BsModalContentComponent, BsModalFooterDirective, BsModalHeaderDirective, BsModalModule, BsModalService, BsMultiselectComponent, BsMultiselectModule, BsNavbarBrandComponent, BsNavbarComponent, BsNavbarDropdownComponent, BsNavbarItemComponent, BsNavbarModule, BsNavbarNavComponent, BsPaginationComponent, BsPaginationModule, BsProgressBarComponent, BsProgressBarModule, BsProgressComponent, BsRatingComponent, BsRatingModule, BsRowTemplateDirective, BsScrollspyComponent, BsScrollspyDirective, BsScrollspyModule, BsSelect2Component, BsSelect2Module, BsSnackbarCloseDirective, BsSnackbarComponent, BsSnackbarModule, BsSnackbarService, BsTabControlComponent, BsTabControlModule, BsTabPageComponent, BsToggleButtonComponent, BsToggleButtonModule, BsTooltipDirective, BsTooltipModule, BsTypeaheadComponent, BsTypeaheadModule, Color, DatatableSettings, DropdownToggleDirective, NavLinkDirective, NavbarContentDirective, Position };
3596
+ export { BsAccordionComponent, BsAccordionModule, BsAccordionTabComponent, BsAccordionTabHeaderComponent, BsAlertCloseComponent, BsAlertComponent, BsAlertModule, BsButtonTemplateDirective, BsCalendarComponent, BsCalendarModule, BsCardComponent, BsCardHeaderComponent, BsCardModule, BsCarouselComponent, BsCarouselImageDirective, BsCarouselModule, BsCodeSnippetComponent, BsCodeSnippetModule, BsContextMenuDirective, BsContextMenuModule, BsCopyDirective, BsCopyModule, BsDatatableColumnDirective, BsDatatableComponent, BsDatatableModule, BsDatepickerComponent, BsDatepickerModule, BsDropdownDirective, BsDropdownMenuDirective, BsDropdownModule, BsDropdownToggleDirective, BsExpandButtonDirective, BsFileUploadComponent, BsFileUploadModule, BsFileUploadTemplateDirective, BsFontColorPipe, BsFontColorPipeModule, BsFooterTemplateDirective, BsForDirective, BsForModule, BsFormatBytesModule, BsFormatBytesPipe, BsHeaderTemplateDirective, BsItemTemplateDirective, BsListGroupComponent, BsListGroupItemComponent, BsListGroupModule, BsModalBodyDirective, BsModalComponent, BsModalContentComponent, BsModalFooterDirective, BsModalHeaderDirective, BsModalModule, BsModalService, BsMultiselectComponent, BsMultiselectModule, BsNavbarBrandComponent, BsNavbarComponent, BsNavbarDropdownComponent, BsNavbarItemComponent, BsNavbarModule, BsNavbarNavComponent, BsNavbarTogglerComponent, BsPaginationComponent, BsPaginationModule, BsProgressBarComponent, BsProgressBarModule, BsProgressComponent, BsRatingComponent, BsRatingModule, BsRowTemplateDirective, BsScrollspyComponent, BsScrollspyDirective, BsScrollspyModule, BsSelect2Component, BsSelect2Module, BsSnackbarCloseDirective, BsSnackbarComponent, BsSnackbarModule, BsSnackbarService, BsTabControlComponent, BsTabControlModule, BsTabPageComponent, BsToggleButtonComponent, BsToggleButtonModule, BsTooltipDirective, BsTooltipModule, BsTypeaheadComponent, BsTypeaheadModule, Color, DatatableSettings, DropdownToggleDirective, NavLinkDirective, NavbarContentDirective, Position };
3530
3597
  //# sourceMappingURL=mintplayer-ng-bootstrap.mjs.map