@wolkabout/commons 0.3.5 → 0.3.6

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.
@@ -52,7 +52,7 @@ import * as i4$5 from '@angular/material/tabs';
52
52
  import { MatTabsModule } from '@angular/material/tabs';
53
53
  import { DragDropModule } from '@angular/cdk/drag-drop';
54
54
  import * as i0 from '@angular/core';
55
- import { NgModule, InjectionToken, inject, Injectable, DOCUMENT, Inject, Input, Directive, forwardRef, HostListener, PLATFORM_ID, Pipe, signal, TemplateRef, ViewChild, ContentChild, Optional, Self, Component, input, computed, untracked, viewChild, afterNextRender, effect, output, afterRenderEffect, contentChild } from '@angular/core';
55
+ import { NgModule, InjectionToken, inject, Injectable, DOCUMENT, Inject, Input, Directive, forwardRef, HostListener, PLATFORM_ID, Pipe, signal, TemplateRef, ViewChild, ContentChild, Optional, Self, Component, input, computed, untracked, viewChild, afterNextRender, effect, output, afterRenderEffect, contentChild, ChangeDetectionStrategy } from '@angular/core';
56
56
  import { BehaviorSubject, catchError, of, switchMap, EMPTY, tap, filter, map, combineLatestWith, take, from, concatMap, first, forkJoin, distinctUntilChanged, fromEvent, withLatestFrom, shareReplay, merge, Subject, takeUntil, combineLatest } from 'rxjs';
57
57
  import { jwtDecode } from 'jwt-decode';
58
58
  import { loadRemoteModule } from '@angular-architects/native-federation';
@@ -7727,11 +7727,44 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
7727
7727
  args: ['window:keydown', ['$event']]
7728
7728
  }], leftDrawerConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "leftDrawerConfig", required: true }] }], rightDrawerConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "rightDrawerConfig", required: false }] }], backdropConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "backdropConfig", required: true }] }], dialogConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "dialogConfig", required: false }] }], fullScreenConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullScreenConfig", required: false }] }], leftDrawerToggled: [{ type: i0.Output, args: ["leftDrawerToggled"] }], rightDrawerToggled: [{ type: i0.Output, args: ["rightDrawerToggled"] }] } });
7729
7729
 
7730
+ class BulkConfirmationDialogComponent {
7731
+ data;
7732
+ dialog;
7733
+ isDeleteMode = signal(true, ...(ngDevMode ? [{ debugName: "isDeleteMode" }] : []));
7734
+ action = signal('COMMON.DELETE_SELECTED', ...(ngDevMode ? [{ debugName: "action" }] : []));
7735
+ title = signal('COMMON.DELETE_SELECTED_TITLE', ...(ngDevMode ? [{ debugName: "title" }] : []));
7736
+ constructor(data, dialog) {
7737
+ this.data = data;
7738
+ this.dialog = dialog;
7739
+ if (data.isDeleteMode !== undefined) {
7740
+ this.isDeleteMode.set(data.isDeleteMode);
7741
+ }
7742
+ if (data.title) {
7743
+ this.title.set(data.title);
7744
+ }
7745
+ if (data.action) {
7746
+ this.action.set(data.action);
7747
+ }
7748
+ }
7749
+ confirm() {
7750
+ this.dialog.close(true);
7751
+ }
7752
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: BulkConfirmationDialogComponent, deps: [{ token: MAT_DIALOG_DATA }, { token: i1$5.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
7753
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: BulkConfirmationDialogComponent, isStandalone: true, selector: "app-delete-confirmation-dialog", ngImport: i0, template: "<div class=\"flex flex-col flex-auto gap-y-8 p-4 content\">\r\n <div class=\"text-lg\">{{ title() | translate: {entity: data.entity} }}</div>\r\n <div class=\"flex flex-col flex-auto gap-y-4\">\r\n <div class=\"flex flex-col flex-auto gap-y-4 max-h-96 overflow-hidden\">\r\n <div class=\"flex flex-col flex-auto gap-y-2\">\r\n <div>{{ 'COMMON.SELECTED_ITEMS' | translate: {entity: data.entity} }}</div>\r\n <mat-divider></mat-divider>\r\n </div>\r\n <div class=\"flex flex-col flex-auto gap-y-2 overflow-auto\">\r\n @for (item of data.items; track $index) {\r\n <div>{{ item }}</div>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"flex flex-row flex-auto gap-x-2 justify-end\">\r\n <button mat-button mat-dialog-close>{{ 'COMMON.CANCEL' | translate }}</button>\r\n <button [ngClass]=\" isDeleteMode() ? 'destructive-flat-button' : ''\" mat-flat-button\r\n (click)=\"confirm()\">{{ this.action() | translate: {count: data.items.length, entity: data.entity} }}\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".content{width:var(--medium-dialog-width)}\n"], dependencies: [{ kind: "ngmodule", type: SharedModule }, { kind: "component", type: i1$4.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: i1$5.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "component", type: i1$7.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "directive", type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
7754
+ }
7755
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: BulkConfirmationDialogComponent, decorators: [{
7756
+ type: Component,
7757
+ args: [{ selector: 'app-delete-confirmation-dialog', imports: [SharedModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex flex-col flex-auto gap-y-8 p-4 content\">\r\n <div class=\"text-lg\">{{ title() | translate: {entity: data.entity} }}</div>\r\n <div class=\"flex flex-col flex-auto gap-y-4\">\r\n <div class=\"flex flex-col flex-auto gap-y-4 max-h-96 overflow-hidden\">\r\n <div class=\"flex flex-col flex-auto gap-y-2\">\r\n <div>{{ 'COMMON.SELECTED_ITEMS' | translate: {entity: data.entity} }}</div>\r\n <mat-divider></mat-divider>\r\n </div>\r\n <div class=\"flex flex-col flex-auto gap-y-2 overflow-auto\">\r\n @for (item of data.items; track $index) {\r\n <div>{{ item }}</div>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"flex flex-row flex-auto gap-x-2 justify-end\">\r\n <button mat-button mat-dialog-close>{{ 'COMMON.CANCEL' | translate }}</button>\r\n <button [ngClass]=\" isDeleteMode() ? 'destructive-flat-button' : ''\" mat-flat-button\r\n (click)=\"confirm()\">{{ this.action() | translate: {count: data.items.length, entity: data.entity} }}\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".content{width:var(--medium-dialog-width)}\n"] }]
7758
+ }], ctorParameters: () => [{ type: undefined, decorators: [{
7759
+ type: Inject,
7760
+ args: [MAT_DIALOG_DATA]
7761
+ }] }, { type: i1$5.MatDialogRef }] });
7762
+
7730
7763
  // Config
7731
7764
 
7732
7765
  /**
7733
7766
  * Generated bundle index. Do not edit.
7734
7767
  */
7735
7768
 
7736
- export { AUTHENTICATION_CLIENT, AssetManager, AuthenticationService, AutocompleteChipsComponent, AutocompleteComponent, BasicTimeSeriesGraphComponent, COLORS, CUSTOM_PERIOD, CardLabeledValueComponent, ConfirmationDialogComponent, DEFAULT_LOCALE, DEFAULT_TIMEZONES, DEFAULT_TIME_ZONE, DataType, DateRangeInputComponent, DateTimeFormFieldComponent, DoubleDrawerLayoutComponent, DragDropFileUploadComponent, DurationPipe, FeatureRegistry, FullscreenService, GoogleMapComponent, IconComponent, IconRegistryService, ImageDisplayComponent, ImagePreviewComponent, LAST_ACTIVE_TAB_KEY, LOCALES, LabeledValueComponent, LoadedIconComponent, LoadingIndicatorDirective, LocalSortTableComponent, Locale, LocalizedNumberPipe, LocalizedNumericInputDirective, MILLISECONDS_IN_DAY, MapsLoaderService, MasterDetailsViewComponent, MessageTooltipDirective, MissingTranslationHelper, NavigationPersistenceService, NestedListDataControl, NestedListDataSource, NestedListViewComponent, NotificationService, OverflowClassDirective, PdfViewerComponent, PeriodErrorStateMatcher, PermissionsService, RELATIVE_TIME_PERIODS, RelativeTimePeriod, RequiresAllGlobalOrAssetPermissionsDirective, RequiresAllPermissionDirective, RequiresGlobalOrAsserPermissionDirective, RequiresPermissionDirective, ScrollIntoViewDirective, SharedModule, SimpleDatePipe, SimpleDateTimePipe, SimpleTimePipe, SortPipe, StandardListDataControl, StandardListDataSource, StandardListViewComponent, TIMEZONES, TabulatedChipViewComponent, TabulatedViewComponent, TenantPropertiesService, ThemeService, TreeComponent, TreeNodeComponent, USERS_TIME_ZONE, ValueDisplayComponent, ValueInputBooleanComponent, ValueInputColorComponent, ValueInputComponent, ValueInputDateComponent, ValueInputDurationComponent, ValueInputEnumComponent, ValueInputHexadecimalComponent, ValueInputLinkComponent, ValueInputLocationComponent, ValueInputNumericComponent, ValueInputStringComponent, ValueInputVectorComponent, ZoomControlsComponent, arrayToObject, chartThemeDark, chartThemeLight, daysAway, determineMagnitude, determineMinMaxValues, endOfPeriod, equalsByValue, externalUrlFormatValidator, fileOrExternalUrlRequired, fileSizeValidator, flatMap, flatten, format, formatDuration, generateRandomString, getDecimalPlaces, globalPermissionGuard, groupBy, hoursAway, isContextAccessible, lookUpPathPart, lookUpQueryParam, parseDateRangeInputPeriod, parseTimeInput, saveFile, scale, startOfMonth, startOfPeriod, startOfTheDay, startOfWeek, startOfYear, tenantHostUrlValidator, toDate, toEndOfMonth, toEndOfYear, toJsDate, toOffset, toStartOfMonth, toStartOfTheDay, toStartOfWeek, toStartOfYear, toTime, uniqueBy, uniqueFrom, validateAssetName, validateTypeAssetName };
7769
+ export { AUTHENTICATION_CLIENT, AssetManager, AuthenticationService, AutocompleteChipsComponent, AutocompleteComponent, BasicTimeSeriesGraphComponent, BulkConfirmationDialogComponent, COLORS, CUSTOM_PERIOD, CardLabeledValueComponent, ConfirmationDialogComponent, DEFAULT_LOCALE, DEFAULT_TIMEZONES, DEFAULT_TIME_ZONE, DataType, DateRangeInputComponent, DateTimeFormFieldComponent, DoubleDrawerLayoutComponent, DragDropFileUploadComponent, DurationPipe, FeatureRegistry, FullscreenService, GoogleMapComponent, IconComponent, IconRegistryService, ImageDisplayComponent, ImagePreviewComponent, LAST_ACTIVE_TAB_KEY, LOCALES, LabeledValueComponent, LoadedIconComponent, LoadingIndicatorDirective, LocalSortTableComponent, Locale, LocalizedNumberPipe, LocalizedNumericInputDirective, MILLISECONDS_IN_DAY, MapsLoaderService, MasterDetailsViewComponent, MessageTooltipDirective, MissingTranslationHelper, NavigationPersistenceService, NestedListDataControl, NestedListDataSource, NestedListViewComponent, NotificationService, OverflowClassDirective, PdfViewerComponent, PeriodErrorStateMatcher, PermissionsService, RELATIVE_TIME_PERIODS, RelativeTimePeriod, RequiresAllGlobalOrAssetPermissionsDirective, RequiresAllPermissionDirective, RequiresGlobalOrAsserPermissionDirective, RequiresPermissionDirective, ScrollIntoViewDirective, SharedModule, SimpleDatePipe, SimpleDateTimePipe, SimpleTimePipe, SortPipe, StandardListDataControl, StandardListDataSource, StandardListViewComponent, TIMEZONES, TabulatedChipViewComponent, TabulatedViewComponent, TenantPropertiesService, ThemeService, TreeComponent, TreeNodeComponent, USERS_TIME_ZONE, ValueDisplayComponent, ValueInputBooleanComponent, ValueInputColorComponent, ValueInputComponent, ValueInputDateComponent, ValueInputDurationComponent, ValueInputEnumComponent, ValueInputHexadecimalComponent, ValueInputLinkComponent, ValueInputLocationComponent, ValueInputNumericComponent, ValueInputStringComponent, ValueInputVectorComponent, ZoomControlsComponent, arrayToObject, chartThemeDark, chartThemeLight, daysAway, determineMagnitude, determineMinMaxValues, endOfPeriod, equalsByValue, externalUrlFormatValidator, fileOrExternalUrlRequired, fileSizeValidator, flatMap, flatten, format, formatDuration, generateRandomString, getDecimalPlaces, globalPermissionGuard, groupBy, hoursAway, isContextAccessible, lookUpPathPart, lookUpQueryParam, parseDateRangeInputPeriod, parseTimeInput, saveFile, scale, startOfMonth, startOfPeriod, startOfTheDay, startOfWeek, startOfYear, tenantHostUrlValidator, toDate, toEndOfMonth, toEndOfYear, toJsDate, toOffset, toStartOfMonth, toStartOfTheDay, toStartOfWeek, toStartOfYear, toTime, uniqueBy, uniqueFrom, validateAssetName, validateTypeAssetName };
7737
7770
  //# sourceMappingURL=wolkabout-commons.mjs.map