adb-shared 5.0.20 → 5.0.22

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.
@@ -1543,6 +1543,48 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImpor
1543
1543
  }]
1544
1544
  }] });
1545
1545
 
1546
+ class AdbHelpButtonComponent {
1547
+ constructor(elementRef) {
1548
+ this.elementRef = elementRef;
1549
+ this.showHelp = false;
1550
+ }
1551
+ ngOnInit() {
1552
+ this.id = +Math.floor(Math.random() * Date.now());
1553
+ }
1554
+ onClick() {
1555
+ const node = this.elementRef.nativeElement.parentNode;
1556
+ if (node) {
1557
+ if (this.showHelp) {
1558
+ node.classList.remove('position-relative');
1559
+ }
1560
+ else {
1561
+ node.classList.add('position-relative');
1562
+ }
1563
+ }
1564
+ this.showHelp = !this.showHelp;
1565
+ }
1566
+ }
1567
+ /** @nocollapse */ AdbHelpButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbHelpButtonComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
1568
+ /** @nocollapse */ AdbHelpButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: AdbHelpButtonComponent, selector: "adb-help-button", ngImport: i0, template: "<div>\r\n <button type=\"button\" id=\"help-button\" tabindex=\"-1\" (adbClickOutside)=\"showHelp=false\" class=\"ms-auto btn btn-invisible p-0 w-auto text-info\" \r\n [attr.aria-controls]=\"id\" [attr.aria-expanded]=\"showHelp\" (click)=\"onClick()\">\r\n <span class=\"fas fa-question-circle \"></span>\r\n </button>\r\n</div>\r\n<div>\r\n <div *ngIf=\"showHelp\" [id]=\"id\" class=\"position-absolute start-0 w-100 adb-plate-primary text-start shadow \" style=\"z-index:4\">\r\n <div class=\"d-flex align-items-center\">\r\n <div><ng-content></ng-content></div>\r\n <div class=\"ms-auto align-self-start d-flex align-items-start\">\r\n <button type=\"button\" class=\"btn-close p-1\" data-bs-dismiss=\"modal\" aria-label=\"Close\" (click)=\"showHelp=false\"></button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>", directives: [{ type: ClickOutsideDirective, selector: "[adbClickOutside]", outputs: ["adbClickOutside"] }, { type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1569
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbHelpButtonComponent, decorators: [{
1570
+ type: Component,
1571
+ args: [{ selector: 'adb-help-button', template: "<div>\r\n <button type=\"button\" id=\"help-button\" tabindex=\"-1\" (adbClickOutside)=\"showHelp=false\" class=\"ms-auto btn btn-invisible p-0 w-auto text-info\" \r\n [attr.aria-controls]=\"id\" [attr.aria-expanded]=\"showHelp\" (click)=\"onClick()\">\r\n <span class=\"fas fa-question-circle \"></span>\r\n </button>\r\n</div>\r\n<div>\r\n <div *ngIf=\"showHelp\" [id]=\"id\" class=\"position-absolute start-0 w-100 adb-plate-primary text-start shadow \" style=\"z-index:4\">\r\n <div class=\"d-flex align-items-center\">\r\n <div><ng-content></ng-content></div>\r\n <div class=\"ms-auto align-self-start d-flex align-items-start\">\r\n <button type=\"button\" class=\"btn-close p-1\" data-bs-dismiss=\"modal\" aria-label=\"Close\" (click)=\"showHelp=false\"></button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>" }]
1572
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }]; } });
1573
+
1574
+ class AdbButtonsModule {
1575
+ }
1576
+ /** @nocollapse */ AdbButtonsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbButtonsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1577
+ /** @nocollapse */ AdbButtonsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbButtonsModule, declarations: [AdbHelpButtonComponent], imports: [CommonModule, AdbDirectivesModule], exports: [AdbHelpButtonComponent] });
1578
+ /** @nocollapse */ AdbButtonsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbButtonsModule, imports: [[CommonModule, AdbDirectivesModule]] });
1579
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: AdbButtonsModule, decorators: [{
1580
+ type: NgModule,
1581
+ args: [{
1582
+ imports: [CommonModule, AdbDirectivesModule],
1583
+ declarations: [AdbHelpButtonComponent],
1584
+ exports: [AdbHelpButtonComponent]
1585
+ }]
1586
+ }] });
1587
+
1546
1588
  /*
1547
1589
  * Public API Surface of artdata-shared
1548
1590
  */
@@ -1551,5 +1593,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImpor
1551
1593
  * Generated bundle index. Do not edit.
1552
1594
  */
1553
1595
 
1554
- export { ADBFooterComponent, ADBHeaderModule, ADBNavComponent, AdbConfirmModal, AdbDatePickerComponent, AdbDatePickerDirective, AdbDatePickerModule, AdbDirectivesModule, AdbDropdownDirective, AdbDropdownModule, AdbModalModule, AdbModalService, AdbPagersModule, AdbPipesModule, AdbToast, AdbToastModule, AdbToastService, ArtportalenFooterComponent, ArtportalenNavComponent, ArtportalenNavModule, ClickOutsideDirective, EmptyValuePipe, FileUploadDirective, FocusDirective, HighlightPipe2, InfiniteScrollComponent, LocaleDatePipe, NumberSpacingPipe, PagerComponent, PagerInlineComponent, RedListBadgeClassDirective, ToastType };
1596
+ export { ADBFooterComponent, ADBHeaderModule, ADBNavComponent, AdbButtonsModule, AdbConfirmModal, AdbDatePickerComponent, AdbDatePickerDirective, AdbDatePickerModule, AdbDirectivesModule, AdbDropdownDirective, AdbDropdownModule, AdbHelpButtonComponent, AdbModalModule, AdbModalService, AdbPagersModule, AdbPipesModule, AdbToast, AdbToastModule, AdbToastService, ArtportalenFooterComponent, ArtportalenNavComponent, ArtportalenNavModule, ClickOutsideDirective, EmptyValuePipe, FileUploadDirective, FocusDirective, HighlightPipe2, InfiniteScrollComponent, LocaleDatePipe, NumberSpacingPipe, PagerComponent, PagerInlineComponent, RedListBadgeClassDirective, ToastType };
1555
1597
  //# sourceMappingURL=adb-shared.mjs.map