dolfo-angular 1.208.0 → 1.210.0

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.
package/package.json CHANGED
@@ -1,11 +1,12 @@
1
1
  {
2
2
  "name": "dolfo-angular",
3
- "version": "1.208.0",
3
+ "version": "1.210.0",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^21.2.9",
6
6
  "@angular/core": "^21.2.9",
7
7
  "@angular/forms": "^21.2.9",
8
- "@angular/platform-browser": "^21.2.9"
8
+ "@angular/platform-browser": "^21.2.9",
9
+ "@angular/router": "^21.2.14"
9
10
  },
10
11
  "dependencies": {
11
12
  "tslib": "^2.8.1"
@@ -6,8 +6,12 @@ import * as i10 from '@angular/forms';
6
6
  import { FormControl, ValidatorFn, ValidationErrors, ControlValueAccessor, Validator, AbstractControl, FormGroup, FormGroupDirective } from '@angular/forms';
7
7
  import * as i9 from '@angular/common';
8
8
  import { DecimalPipe } from '@angular/common';
9
+ import { CanActivate, ActivatedRouteSnapshot, Router } from '@angular/router';
9
10
  import * as _angular_platform_browser from '@angular/platform-browser';
10
11
  import { DomSanitizer } from '@angular/platform-browser';
12
+ import * as _angular_common_http from '@angular/common/http';
13
+ import { HttpRequest, HttpHandlerFn } from '@angular/common/http';
14
+ import * as dolfo_angular from 'dolfo-angular';
11
15
 
12
16
  type ButtonColor = "primary" | "secondary" | "white" | "error" | "warning" | "success" | "info";
13
17
  type ButtonSize = "small" | "large";
@@ -204,6 +208,34 @@ interface OnClick {
204
208
  onClick: EventEmitter<MouseEvent>;
205
209
  }
206
210
 
211
+ declare const ROUTE_CHECK_SERVICE: InjectionToken<CheckRoute<unknown>>;
212
+ interface CheckRoute<T> {
213
+ load$: () => Observable<T>;
214
+ checkRoute: (path: string) => Promise<boolean> | Observable<boolean>;
215
+ }
216
+
217
+ declare enum StoreLists {
218
+ EMPTY = 0
219
+ }
220
+ type StorageListType = {
221
+ [StoreLists.EMPTY]: null;
222
+ };
223
+ declare enum StorageValues {
224
+ TOKEN = "token",
225
+ LANG = "lang"
226
+ }
227
+ interface IStore {
228
+ readonly pressingCtrl: boolean;
229
+ readonly lists: {
230
+ [k in StoreLists]?: StorageListType[k][];
231
+ };
232
+ readonly entities: {
233
+ [x: string]: any;
234
+ };
235
+ }
236
+ declare const MAX_DEVICE_SIZE = 750;
237
+ declare const MAX_SMALL_DEVICE = 500;
238
+
207
239
  interface ILanguage {
208
240
  readonly name: string;
209
241
  readonly locale: string;
@@ -276,6 +308,21 @@ declare class DialogService {
276
308
  static ɵprov: i0.ɵɵInjectableDeclaration<DialogService>;
277
309
  }
278
310
 
311
+ declare class DialogUtilsService {
312
+ private dialogService;
313
+ private translateService;
314
+ constructor(dialogService: DialogService, translateService: TranslateService);
315
+ showLoading$: <T, T2>(obs: (res: T2) => Observable<T>) => rxjs.OperatorFunction<T2, T>;
316
+ hideLoading: () => void;
317
+ closeLatestDialog: () => void;
318
+ closeWithAction: <T>(data: T) => void;
319
+ openDialogComponent: (component: DialogComponentInput) => Observable<dolfo_angular.DialogOutput>;
320
+ openDialog: (input: IDialogInput) => Observable<dolfo_angular.DialogOutput>;
321
+ askConfirmAndLoad: <T>(input: Pick<IDialogInput, "title" | "message" | "hideCloseX" | "width">, obs: (resp: DialogActionType) => Observable<T>, getDialogResp?: boolean) => Observable<T>;
322
+ static ɵfac: i0.ɵɵFactoryDeclaration<DialogUtilsService, never>;
323
+ static ɵprov: i0.ɵɵInjectableDeclaration<DialogUtilsService>;
324
+ }
325
+
279
326
  declare class NotificationService {
280
327
  private notification$;
281
328
  private history$;
@@ -299,6 +346,30 @@ declare class PopoverService {
299
346
  static ɵprov: i0.ɵɵInjectableDeclaration<PopoverService>;
300
347
  }
301
348
 
349
+ declare class RouteCheckService implements CanActivate {
350
+ private storeService;
351
+ private routeService;
352
+ canActivate({ routeConfig }: ActivatedRouteSnapshot): false | rxjs.Observable<boolean>;
353
+ static ɵfac: i0.ɵɵFactoryDeclaration<RouteCheckService, never>;
354
+ static ɵprov: i0.ɵɵInjectableDeclaration<RouteCheckService>;
355
+ }
356
+
357
+ declare class StoreService extends Subscriptable {
358
+ private appInitialized;
359
+ constructor();
360
+ private store$;
361
+ addList: <K extends StoreLists>(key: K, list: StorageListType[K][]) => void;
362
+ getList: <K extends StoreLists>(key: K) => StorageListType[K][];
363
+ addEntity: (key: string, entity: any) => void;
364
+ getEntity: <T>(key: string) => T;
365
+ setCtrlKey: (pressingCtrl: boolean) => void;
366
+ isPressingCtrl: () => boolean;
367
+ isInitialized: () => boolean;
368
+ initialize: () => void;
369
+ static ɵfac: i0.ɵɵFactoryDeclaration<StoreService, never>;
370
+ static ɵprov: i0.ɵɵInjectableDeclaration<StoreService>;
371
+ }
372
+
302
373
  declare class TooltipService {
303
374
  private tooltip$;
304
375
  showTooltip: (input: ITooltip) => void;
@@ -522,9 +593,21 @@ declare class PopoverDirective extends Subscriptable {
522
593
  static ɵdir: i0.ɵɵDirectiveDeclaration<PopoverDirective, "[dolfoPopover]", never, { "content": { "alias": "dolfoPopover"; "required": true; }; "context": { "alias": "dolfoPopoverContext"; "required": false; }; "direction": { "alias": "direction"; "required": false; }; }, {}, never, never, false, never>;
523
594
  }
524
595
 
596
+ declare class NavigateDirective extends Subscriptable {
597
+ private elementRef;
598
+ url: string;
599
+ private isLink;
600
+ private publicUrl;
601
+ constructor(storeService: StoreService, router: Router, elementRef: ElementRef<HTMLElement>);
602
+ ngOnChanges(changes: SimpleChanges<this>): void;
603
+ private openBlank;
604
+ static ɵfac: i0.ɵɵFactoryDeclaration<NavigateDirective, never>;
605
+ static ɵdir: i0.ɵɵDirectiveDeclaration<NavigateDirective, "[dolfoNavigate]", never, { "url": { "alias": "dolfoNavigate"; "required": true; }; }, {}, never, never, false, never>;
606
+ }
607
+
525
608
  declare class DirectivesModule {
526
609
  static ɵfac: i0.ɵɵFactoryDeclaration<DirectivesModule, never>;
527
- static ɵmod: i0.ɵɵNgModuleDeclaration<DirectivesModule, [typeof ContextMenuDirective, typeof ScrollDragDirective, typeof TooltipDirective, typeof PopoverDirective], never, [typeof ContextMenuDirective, typeof ScrollDragDirective, typeof TooltipDirective, typeof PopoverDirective]>;
610
+ static ɵmod: i0.ɵɵNgModuleDeclaration<DirectivesModule, [typeof ContextMenuDirective, typeof ScrollDragDirective, typeof TooltipDirective, typeof PopoverDirective, typeof NavigateDirective], never, [typeof ContextMenuDirective, typeof ScrollDragDirective, typeof TooltipDirective, typeof PopoverDirective, typeof NavigateDirective]>;
528
611
  static ɵinj: i0.ɵɵInjectorDeclaration<DirectivesModule>;
529
612
  }
530
613
 
@@ -750,5 +833,9 @@ declare class GridModule {
750
833
  static ɵinj: i0.ɵɵInjectorDeclaration<GridModule>;
751
834
  }
752
835
 
753
- export { AutocompleteComponent, BaseFormInput, ButtonComponent, CONTEXT_MENU_DESTROY_TOKEN, ColumnAlign, ColumnDataType, ComboboxComponent, ContextMenuComponent, ContextMenuDirective, ContextMenuService, DatepickerComponent, DialogActionType, DialogComponent, DialogContentComponent, DialogFooterComponent, DialogHeaderComponent, DialogLayoutComponent, DialogLayoutModule, DialogService, DirectivesModule, FormComponent, FormModule, Formable, GridComponent, GridConfig, GridModule, ICON_COMPONENT, IconComponent, IconWrapperComponent, InputCheckboxComponent, InputContainerComponent, InputRadioComponent, InputTextComponent, LANGUAGE_TOKEN, LayoutModule, LoaderComponent, NotificationComponent, NotificationService, OverlayManager, POPOVER_DESTROY_TOKEN, PopoverComponent, PopoverDirective, PopoverService, ScrollDragDirective, Subscriptable, TOOLTIP_DESTROY_TOKEN, TRANSLATE_STORAGE_KEY, TooltipComponent, TooltipDirective, TooltipService, TranslatePipe, TranslateService, isDeepEqual, passwordValidator, provideDolfoLanguages };
754
- export type { AutocompleteConfig, ButtonColor, ButtonSize, ComboInput, ComboOption, ContextMenuItem, DialogComponentInput, DialogFooterButton, DialogForm, DialogIcon, DialogOutput, DialogType, GridAction, GridColumn, IContextMenu, IDialogInput, IGridConfig, ILanguage, ILanguageToken, INotificationInput, IPopover, ITooltip, IconName, InputType, NotificationAction, NotificationType, OnBlur, OnClick, OnFocus, TooltipDirection };
836
+ declare const authInterceptor: (req: HttpRequest<unknown>, next: HttpHandlerFn) => rxjs.Observable<_angular_common_http.HttpEvent<unknown>>;
837
+
838
+ declare const errorInterceptor: (req: HttpRequest<unknown>, next: HttpHandlerFn) => rxjs.Observable<_angular_common_http.HttpEvent<unknown>>;
839
+
840
+ export { AutocompleteComponent, BaseFormInput, ButtonComponent, CONTEXT_MENU_DESTROY_TOKEN, ColumnAlign, ColumnDataType, ComboboxComponent, ContextMenuComponent, ContextMenuDirective, ContextMenuService, DatepickerComponent, DialogActionType, DialogComponent, DialogContentComponent, DialogFooterComponent, DialogHeaderComponent, DialogLayoutComponent, DialogLayoutModule, DialogService, DialogUtilsService, DirectivesModule, FormComponent, FormModule, Formable, GridComponent, GridConfig, GridModule, ICON_COMPONENT, IconComponent, IconWrapperComponent, InputCheckboxComponent, InputContainerComponent, InputRadioComponent, InputTextComponent, LANGUAGE_TOKEN, LayoutModule, LoaderComponent, MAX_DEVICE_SIZE, MAX_SMALL_DEVICE, NavigateDirective, NotificationComponent, NotificationService, OverlayManager, POPOVER_DESTROY_TOKEN, PopoverComponent, PopoverDirective, PopoverService, ROUTE_CHECK_SERVICE, RouteCheckService, ScrollDragDirective, StorageValues, StoreLists, StoreService, Subscriptable, TOOLTIP_DESTROY_TOKEN, TRANSLATE_STORAGE_KEY, TooltipComponent, TooltipDirective, TooltipService, TranslatePipe, TranslateService, authInterceptor, errorInterceptor, isDeepEqual, passwordValidator, provideDolfoLanguages };
841
+ export type { AutocompleteConfig, ButtonColor, ButtonSize, CheckRoute, ComboInput, ComboOption, ContextMenuItem, DialogComponentInput, DialogFooterButton, DialogForm, DialogIcon, DialogOutput, DialogType, GridAction, GridColumn, IContextMenu, IDialogInput, IGridConfig, ILanguage, ILanguageToken, INotificationInput, IPopover, IStore, ITooltip, IconName, InputType, NotificationAction, NotificationType, OnBlur, OnClick, OnFocus, StorageListType, TooltipDirection };