@ts-core/angular 11.0.84 → 11.0.88

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.
@@ -7,7 +7,7 @@ export declare abstract class LoginBaseService<E = any, U = any, V = any> extend
7
7
  protected _loginData: V;
8
8
  protected _isLoggedIn: boolean;
9
9
  constructor();
10
- protected loginByParam(param?: any): Promise<U>;
10
+ protected loginByParam<T = any>(param?: T): Promise<U>;
11
11
  protected loginByFunction(sidReturnFunction: (...params: any[]) => Promise<U>): Promise<U>;
12
12
  protected loginBySid(): Promise<void>;
13
13
  protected reset(): void;
@@ -17,13 +17,13 @@ export declare abstract class LoginBaseService<E = any, U = any, V = any> extend
17
17
  protected abstract getSavedSid(): string;
18
18
  protected abstract parseLoginResponse(response: U): void;
19
19
  protected parseLoginErrorResponse(error: ExtendedError): void;
20
+ protected parseLogoutErrorResponse(error: ExtendedError): void;
20
21
  protected parseLoginSidResponse(response: V): void;
21
22
  protected parseLoginSidErrorResponse(error: ExtendedError): void;
22
23
  abstract login(param: any): void;
23
- abstract registration(param: any): void;
24
24
  loginByResponse(param: U): Promise<void>;
25
25
  tryLoginBySid(): boolean;
26
- logout(): void;
26
+ logout(): Promise<void>;
27
27
  isCanLoginWithSid(): boolean;
28
28
  destroy(): void;
29
29
  get logined(): Observable<V>;
@@ -1,7 +1,7 @@
1
- import { ActivatedRouteSnapshot, CanActivate, RouterStateSnapshot } from '@angular/router';
1
+ import { CanActivate } from '@angular/router';
2
2
  import { LoginBaseService } from './LoginBaseService';
3
- export declare class LoginGuard implements CanActivate {
4
- private login;
3
+ import { LoginRequireResolver } from './LoginRequireResolver';
4
+ export declare class LoginGuard extends LoginRequireResolver implements CanActivate {
5
5
  constructor(login: LoginBaseService);
6
- canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): boolean;
6
+ canActivate(): boolean;
7
7
  }
@@ -1,7 +1,7 @@
1
- import { ActivatedRouteSnapshot, Resolve, RouterStateSnapshot } from '@angular/router';
1
+ import { Resolve } from '@angular/router';
2
2
  import { LoginBaseService } from './LoginBaseService';
3
3
  export declare class LoginRequireResolver implements Resolve<void> {
4
4
  protected login: LoginBaseService;
5
5
  constructor(login: LoginBaseService);
6
- resolve(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Promise<void>;
6
+ resolve(): Promise<void>;
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ts-core/angular",
3
- "version": "11.0.84",
3
+ "version": "11.0.88",
4
4
  "description": "Modules for frontend based on angular",
5
5
  "main": "bundles/ts-core-angular.umd.js",
6
6
  "author": {
@@ -21,8 +21,8 @@
21
21
  "@angular/platform-browser": "^11.2.14",
22
22
  "@angular/platform-browser-dynamic": "^11.2.14",
23
23
  "@angular/router": "^11.2.14",
24
- "@ts-core/common": "^1.0.184",
25
- "@ts-core/frontend": "^1.0.43",
24
+ "@ts-core/common": "^1.0.185",
25
+ "@ts-core/frontend": "^1.0.44",
26
26
  "@types/numeral": "0.0.25",
27
27
  "bootstrap": "^4.6.1",
28
28
  "css-element-queries": "1.2.0",
@@ -92,10 +92,13 @@
92
92
  border-top-left-radius: $border-radius !important;
93
93
  border-bottom-left-radius: $border-radius !important;
94
94
  }
95
+
96
+ .rounded-circle {
97
+ border-radius: 50% !important;
98
+ }
95
99
  }
96
100
 
97
101
  @mixin vi-mat-theme-bootstrap-border-mixin($infix, $width, $color) {
98
-
99
102
  // Transparent
100
103
  .border-transparent {
101
104
  border-width: $width;
@@ -1,8 +1,8 @@
1
1
  import { ElementRef } from '@angular/core';
2
- import { ThemeService } from '@ts-core/frontend/theme';
2
+ import { ThemeAssetService, ThemeService } from '@ts-core/frontend/theme';
3
3
  import { ThemeAssetDirective } from './ThemeAssetDirective';
4
4
  export declare class ThemeAssetBackgroundDirective extends ThemeAssetDirective {
5
- constructor(element: ElementRef, theme: ThemeService);
5
+ constructor(element: ElementRef, theme: ThemeService, themeAsset: ThemeAssetService);
6
6
  protected commitSourceProperties(): void;
7
7
  protected removeSourceProperties(): void;
8
8
  }
@@ -1,8 +1,9 @@
1
1
  import { ElementRef } from '@angular/core';
2
2
  import { Destroyable } from '@ts-core/common';
3
- import { Theme, ThemeService } from '@ts-core/frontend/theme';
3
+ import { Theme, ThemeAssetService, ThemeService } from '@ts-core/frontend/theme';
4
4
  export declare abstract class ThemeAssetDirective<T extends HTMLElement = HTMLElement> extends Destroyable {
5
5
  protected theme: ThemeService;
6
+ protected themeAsset: ThemeAssetService;
6
7
  protected _name: string;
7
8
  protected _extension: string;
8
9
  protected _isFile: boolean;
@@ -10,16 +11,17 @@ export declare abstract class ThemeAssetDirective<T extends HTMLElement = HTMLEl
10
11
  protected _isVideo: boolean;
11
12
  protected _isSound: boolean;
12
13
  protected _isBackground: boolean;
14
+ protected _isIgnoreTheme: boolean;
13
15
  protected source: string;
14
16
  protected element: T;
15
17
  private isTriedThemeDefault;
16
- constructor(element: ElementRef, theme: ThemeService);
18
+ constructor(element: ElementRef, theme: ThemeService, themeAsset: ThemeAssetService);
17
19
  protected getSource(id: string): string;
18
20
  private errorLoadingHandler;
19
21
  protected errorHandler(event: ErrorEvent): void;
20
22
  protected setSourceProperties(): void;
21
23
  protected getSourceId(theme: Theme): string;
22
- protected getDefaultSourceId(theme: Theme): string;
24
+ protected getDefaultSourceId(): string;
23
25
  protected abstract commitSourceProperties(): void;
24
26
  protected abstract removeSourceProperties(): void;
25
27
  destroy(): void;
@@ -33,6 +35,8 @@ export declare abstract class ThemeAssetDirective<T extends HTMLElement = HTMLEl
33
35
  get isImage(): boolean;
34
36
  set isBackground(value: boolean);
35
37
  get isBackground(): boolean;
38
+ set isIgnoreTheme(value: boolean);
39
+ get isIgnoreTheme(): boolean;
36
40
  get name(): string;
37
41
  set name(value: string);
38
42
  get extension(): string;
@@ -1,8 +1,8 @@
1
1
  import { ElementRef } from '@angular/core';
2
- import { ThemeService } from '@ts-core/frontend/theme';
2
+ import { ThemeAssetService, ThemeService } from '@ts-core/frontend/theme';
3
3
  import { ThemeAssetDirective } from './ThemeAssetDirective';
4
4
  export declare class ThemeAssetImageDirective extends ThemeAssetDirective<HTMLImageElement> {
5
- constructor(element: ElementRef, theme: ThemeService);
5
+ constructor(element: ElementRef, theme: ThemeService, themeAsset: ThemeAssetService);
6
6
  protected commitSourceProperties(): void;
7
7
  protected removeSourceProperties(): void;
8
8
  }
@@ -1,8 +1,9 @@
1
1
  import { InjectionToken, ModuleWithProviders } from '@angular/core';
2
2
  import { ICookieService } from '@ts-core/frontend/cookie';
3
- import { IThemeServiceOptions, ThemeService } from '@ts-core/frontend/theme';
3
+ import { IThemeServiceOptions, ThemeService, ThemeAssetService } from '@ts-core/frontend/theme';
4
4
  export declare class ThemeModule {
5
5
  static forRoot(options?: IThemeServiceOptions): ModuleWithProviders<ThemeModule>;
6
6
  }
7
7
  export declare function themeServiceFactory(cookie: ICookieService, options?: IThemeServiceOptions): ThemeService;
8
+ export declare function themeAssetServiceFactory(theme: ThemeService): ThemeAssetService;
8
9
  export declare const THEME_OPTIONS: InjectionToken<IThemeServiceOptions>;