@morozeckiy/dd-lib 0.2.30 → 0.2.38

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.
Files changed (37) hide show
  1. package/assets/images/svg/print.svg +12 -0
  2. package/esm2022/lib/core/dialog/dialog-config.mjs +2 -2
  3. package/esm2022/lib/core/index.mjs +2 -4
  4. package/esm2022/lib/core/toast/index.mjs +5 -0
  5. package/esm2022/lib/core/toast/toast/toast-animations.mjs +9 -0
  6. package/esm2022/lib/core/toast/toast/toast.component.mjs +58 -0
  7. package/esm2022/lib/core/toast/toast-config.mjs +24 -0
  8. package/esm2022/lib/core/toast/toast-ref.mjs +15 -0
  9. package/esm2022/lib/core/toast/toast.service.mjs +41 -109
  10. package/esm2022/lib/lib-button/lib-button.component.mjs +1 -1
  11. package/esm2022/lib/lib-loader/lib-loader.component.mjs +6 -3
  12. package/esm2022/lib/lib-search-input/lib-search-input.component.mjs +2 -2
  13. package/esm2022/lib/lib-select/lib-select.component.mjs +2 -2
  14. package/esm2022/lib/svg-icons/svg-icon.model.mjs +6 -1
  15. package/fesm2022/morozeckiy-dd-lib.mjs +141 -175
  16. package/fesm2022/morozeckiy-dd-lib.mjs.map +1 -1
  17. package/lib/core/index.d.ts +1 -3
  18. package/lib/core/services/validators.service.d.ts +2 -2
  19. package/lib/core/toast/index.d.ts +4 -0
  20. package/lib/core/toast/toast/toast-animations.d.ts +5 -0
  21. package/lib/core/toast/toast/toast.component.d.ts +21 -0
  22. package/lib/core/toast/toast-config.d.ts +23 -0
  23. package/lib/core/toast/toast-ref.d.ts +8 -0
  24. package/lib/core/toast/toast.service.d.ts +13 -29
  25. package/lib/lib-loader/lib-loader.component.d.ts +2 -1
  26. package/lib/svg-icons/svg-icon.model.d.ts +8 -1
  27. package/morozeckiy-dd-lib-0.2.32.tgz +0 -0
  28. package/morozeckiy-dd-lib-0.2.33.tgz +0 -0
  29. package/morozeckiy-dd-lib-0.2.34.tgz +0 -0
  30. package/morozeckiy-dd-lib-0.2.35.tgz +0 -0
  31. package/morozeckiy-dd-lib-0.2.36.tgz +0 -0
  32. package/morozeckiy-dd-lib-0.2.37.tgz +0 -0
  33. package/morozeckiy-dd-lib-0.2.38.tgz +0 -0
  34. package/package.json +1 -1
  35. package/morozeckiy-dd-lib-0.2.27.tgz +0 -0
  36. package/morozeckiy-dd-lib-0.2.29.tgz +0 -0
  37. package/morozeckiy-dd-lib-0.2.30.tgz +0 -0
@@ -18,9 +18,7 @@ export * from './directives/resize-textarea.directive';
18
18
  export * from './tooltip/tooltip.directive';
19
19
  export * from './tooltip/tooltip.component';
20
20
  export * from './directives/triangle.directive';
21
- export * from './toast/toast.service';
22
- export * from './toast/toast-placeholder/toast-placeholder.component';
23
- export * from './toast/toast-base/toast-base.component';
21
+ export * from './toast/index';
24
22
  export * from './dialog/dialog.service';
25
23
  export * from './dialog/dialog-config';
26
24
  export * from './dialog/dialog-ref';
@@ -1,4 +1,4 @@
1
- import { AbstractControl, ValidationErrors, Validators } from '@angular/forms';
1
+ import { AbstractControl, ValidationErrors } from '@angular/forms';
2
2
  import { Observable } from 'rxjs';
3
3
  import * as i0 from "@angular/core";
4
4
  export declare class ValidatorsService {
@@ -10,7 +10,7 @@ export declare class ValidatorsService {
10
10
  static wrongLoginOrPswd(): ValidationErrors;
11
11
  static existLogin(): ValidationErrors;
12
12
  /** валидатор имени*/
13
- static getNameValid(): (typeof Validators.required)[];
13
+ static getNameValid(): import("@angular/forms").ValidatorFn[];
14
14
  /** валидатор email*/
15
15
  static getMailValid(el?: AbstractControl): Observable<ValidationErrors | null>;
16
16
  static ɵfac: i0.ɵɵFactoryDeclaration<ValidatorsService, never>;
@@ -0,0 +1,4 @@
1
+ export * from './toast.service';
2
+ export * from './toast/toast.component';
3
+ export * from './toast-config';
4
+ export * from './toast-ref';
@@ -0,0 +1,5 @@
1
+ import { AnimationTriggerMetadata } from '@angular/animations';
2
+ export declare const toastAnimations: {
3
+ readonly fadeToast: AnimationTriggerMetadata;
4
+ };
5
+ export type ToastAnimationState = 'default' | 'closing';
@@ -0,0 +1,21 @@
1
+ import { OnDestroy, OnInit } from '@angular/core';
2
+ import { ToastConfig, ToastData } from "../toast-config";
3
+ import { ToastRef } from "../toast-ref";
4
+ import { ToastAnimationState } from "./toast-animations";
5
+ import { BehaviorSubject } from "rxjs";
6
+ import * as i0 from "@angular/core";
7
+ export declare class ToastComponent implements OnInit, OnDestroy {
8
+ readonly data: ToastData;
9
+ readonly ref: ToastRef;
10
+ toastConfig: ToastConfig;
11
+ animationState: ToastAnimationState;
12
+ animationState$: BehaviorSubject<ToastAnimationState>;
13
+ private intervalId;
14
+ constructor(data: ToastData, ref: ToastRef, toastConfig: ToastConfig);
15
+ ngOnInit(): void;
16
+ ngOnDestroy(): void;
17
+ close(): void;
18
+ onFadeFinished(event: any): void;
19
+ static ɵfac: i0.ɵɵFactoryDeclaration<ToastComponent, never>;
20
+ static ɵcmp: i0.ɵɵComponentDeclaration<ToastComponent, "dd-toast", never, {}, {}, never, never, true, never>;
21
+ }
@@ -0,0 +1,23 @@
1
+ import { InjectionToken, Provider, TemplateRef } from '@angular/core';
2
+ export declare class ToastData {
3
+ type: ToastType;
4
+ title?: string;
5
+ description?: string;
6
+ template?: TemplateRef<any>;
7
+ templateContext?: {};
8
+ }
9
+ export type ToastType = 'warning' | 'info' | 'success' | 'danger';
10
+ export interface ToastConfig {
11
+ position?: {
12
+ top: number;
13
+ right: number;
14
+ };
15
+ animation?: {
16
+ fadeOut: number;
17
+ fadeIn: number;
18
+ };
19
+ interval?: number;
20
+ }
21
+ export declare const defaultToastConfig: ToastConfig;
22
+ export declare const TOAST_CONFIG_TOKEN: InjectionToken<ToastConfig>;
23
+ export declare const provideToast: (config?: Partial<ToastConfig>) => Provider[];
@@ -0,0 +1,8 @@
1
+ import { OverlayRef } from '@angular/cdk/overlay';
2
+ export declare class ToastRef {
3
+ private readonly overlay;
4
+ constructor(overlay: OverlayRef);
5
+ close(): void;
6
+ isVisible(): HTMLElement;
7
+ getPosition(): DOMRect;
8
+ }
@@ -1,35 +1,19 @@
1
- import { Injector, ViewContainerRef } from '@angular/core';
2
- import { Overlay } from '@angular/cdk/overlay';
3
- import { ToastData } from './toast-base/toast-base.component';
1
+ import { Injector } from '@angular/core';
2
+ import { Overlay } from "@angular/cdk/overlay";
3
+ import { ToastConfig, ToastData } from "./toast-config";
4
+ import { ToastRef } from "./toast-ref";
5
+ import { PortalInjector } from "@angular/cdk/portal";
4
6
  import * as i0 from "@angular/core";
5
- export declare enum ToastType {
6
- Warning = "warning_t",
7
- Success = "success_t",
8
- Info = "info_t",
9
- Danger = "danger_t"
10
- }
11
- export declare class ToastConfig {
12
- timeOut: number;
13
- constructor(config?: ToastConfig);
14
- }
15
7
  export declare class ToastService {
16
8
  private overlay;
17
- config: ToastConfig;
18
- private viewContainer;
19
- private counter;
20
- ddToastData: ToastData;
21
- private injector;
22
- private overlayRefs;
23
- constructor(overlay: Overlay);
24
- warning(title: string, description?: string): void;
25
- success(title: string, description?: string): void;
26
- danger(title: string, description?: string): void;
27
- info(title: string, description?: string): void;
28
- registerViewContainerRef(vcRef: ViewContainerRef): void;
29
- registerInjector(injector: Injector): void;
30
- destroyToast(id: number): void;
31
- private createToast;
32
- private getPositionStrategy;
9
+ private parentInjector;
10
+ protected toastConfig: ToastConfig;
11
+ private lastToast;
12
+ constructor(overlay: Overlay, parentInjector: Injector, toastConfig: ToastConfig);
13
+ show(data: ToastData): ToastRef;
14
+ getPositionStrategy(): import("@angular/cdk/overlay").GlobalPositionStrategy;
15
+ getPosition(): string;
16
+ getInjector(data: ToastData, toastRef: ToastRef, parentInjector: Injector): PortalInjector;
33
17
  static ɵfac: i0.ɵɵFactoryDeclaration<ToastService, never>;
34
18
  static ɵprov: i0.ɵɵInjectableDeclaration<ToastService>;
35
19
  }
@@ -1,6 +1,7 @@
1
1
  import * as i0 from "@angular/core";
2
2
  export declare class LibLoaderComponent {
3
3
  color: string;
4
+ size: 'big' | 'giant' | 'standard';
4
5
  static ɵfac: i0.ɵɵFactoryDeclaration<LibLoaderComponent, never>;
5
- static ɵcmp: i0.ɵɵComponentDeclaration<LibLoaderComponent, "dd-lib-loader", never, { "color": { "alias": "color"; "required": false; }; }, {}, never, never, true, never>;
6
+ static ɵcmp: i0.ɵɵComponentDeclaration<LibLoaderComponent, "dd-lib-loader", never, { "color": { "alias": "color"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, {}, never, never, true, never>;
6
7
  }
@@ -206,6 +206,10 @@ export declare const svgIconPrev: {
206
206
  name: 'prev';
207
207
  data: string;
208
208
  };
209
+ export declare const svgIconPrint: {
210
+ name: 'print';
211
+ data: string;
212
+ };
209
213
  export declare const svgIconPrinter: {
210
214
  name: 'printer';
211
215
  data: string;
@@ -306,7 +310,7 @@ export declare const svgIconWarningT: {
306
310
  name: 'warning_t';
307
311
  data: string;
308
312
  };
309
- export type svgIcon = 'actogone_accept' | 'all' | 'appgalery' | 'appstore' | 'arrow_down_red' | 'arrow_up_green' | 'back_arrow' | 'burger' | 'calendar' | 'check_green' | 'check_white' | 'circle_no' | 'clear' | 'close' | 'danger_t' | 'dd_m' | 'dd' | 'dobrodel' | 'down_chevron' | 'download' | 'eds_m' | 'eds' | 'entry' | 'error_hint' | 'esia' | 'eye_off' | 'eye' | 'filter' | 'googleapp' | 'grid' | 'health_m' | 'health' | 'info_t' | 'info_circle' | 'left_chevron' | 'list_search' | 'logout' | 'mail_exclamation' | 'max_filter' | 'moon' | 'my_m' | 'my' | 'news' | 'next' | 'paperclip' | 'pen_edit' | 'pgu_mo_m' | 'pgu_mo' | 'plug_d' | 'plug' | 'plus' | 'prev' | 'printer' | 'question_white_g' | 'question' | 'red_close' | 'right_chevron' | 'rustore' | 'search' | 'send' | 'set_avatar' | 'shared_logo' | 'small_round_loader' | 'sort' | 'star' | 'success_t' | 'sun' | 'tg' | 'toggle_arrow_left' | 'toggle_arrow_right' | 'trash' | 'trophy' | 'user_empty_d' | 'user_empty' | 'user' | 'vk' | 'warning_t';
313
+ export type svgIcon = 'actogone_accept' | 'all' | 'appgalery' | 'appstore' | 'arrow_down_red' | 'arrow_up_green' | 'back_arrow' | 'burger' | 'calendar' | 'check_green' | 'check_white' | 'circle_no' | 'clear' | 'close' | 'danger_t' | 'dd_m' | 'dd' | 'dobrodel' | 'down_chevron' | 'download' | 'eds_m' | 'eds' | 'entry' | 'error_hint' | 'esia' | 'eye_off' | 'eye' | 'filter' | 'googleapp' | 'grid' | 'health_m' | 'health' | 'info_t' | 'info_circle' | 'left_chevron' | 'list_search' | 'logout' | 'mail_exclamation' | 'max_filter' | 'moon' | 'my_m' | 'my' | 'news' | 'next' | 'paperclip' | 'pen_edit' | 'pgu_mo_m' | 'pgu_mo' | 'plug_d' | 'plug' | 'plus' | 'prev' | 'print' | 'printer' | 'question_white_g' | 'question' | 'red_close' | 'right_chevron' | 'rustore' | 'search' | 'send' | 'set_avatar' | 'shared_logo' | 'small_round_loader' | 'sort' | 'star' | 'success_t' | 'sun' | 'tg' | 'toggle_arrow_left' | 'toggle_arrow_right' | 'trash' | 'trophy' | 'user_empty_d' | 'user_empty' | 'user' | 'vk' | 'warning_t';
310
314
  export interface SvgIcon {
311
315
  name: svgIcon;
312
316
  data: string;
@@ -468,6 +472,9 @@ export declare const completeIconSet: ({
468
472
  } | {
469
473
  name: 'prev';
470
474
  data: string;
475
+ } | {
476
+ name: 'print';
477
+ data: string;
471
478
  } | {
472
479
  name: 'printer';
473
480
  data: string;
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@morozeckiy/dd-lib",
3
- "version": "0.2.30",
3
+ "version": "0.2.38",
4
4
  "repository": "https://gitlab.com/Morozeckiy/dd-lib",
5
5
  "publishConfig": {
6
6
  "access": "public"
Binary file
Binary file
Binary file