@hmcts/rpx-xui-common-lib 2.0.11 → 2.0.12
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/esm2020/lib/components/cookie-banner/cookie-banner.component.mjs +33 -27
- package/esm2020/lib/services/feature-toggle/feature-toggle.service.mjs +5 -1
- package/esm2020/lib/services/feature-toggle/launch-darkly.service.mjs +9 -5
- package/fesm2015/hmcts-rpx-xui-common-lib.mjs +40 -24
- package/fesm2015/hmcts-rpx-xui-common-lib.mjs.map +1 -1
- package/fesm2020/hmcts-rpx-xui-common-lib.mjs +40 -24
- package/fesm2020/hmcts-rpx-xui-common-lib.mjs.map +1 -1
- package/lib/components/cookie-banner/cookie-banner.component.d.ts +4 -5
- package/lib/services/feature-toggle/feature-toggle.service.d.ts +1 -0
- package/lib/services/feature-toggle/launch-darkly.service.d.ts +2 -1
- package/package.json +1 -1
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import { EventEmitter, OnInit } from '@angular/core';
|
|
2
|
-
import { FeatureToggleService } from '../../services';
|
|
3
2
|
import { CookieService } from '../../services/cookie/cookie.service';
|
|
4
3
|
import * as i0 from "@angular/core";
|
|
5
4
|
export declare class CookieBannerComponent implements OnInit {
|
|
6
5
|
private readonly cookieService;
|
|
7
|
-
private readonly featureToggleService;
|
|
8
6
|
identifier: string;
|
|
9
7
|
appName: string;
|
|
8
|
+
enableDynatrace: boolean;
|
|
10
9
|
rejectionNotifier: EventEmitter<any>;
|
|
11
10
|
acceptanceNotifier: EventEmitter<any>;
|
|
12
11
|
isCookieBannerVisible: boolean;
|
|
13
|
-
|
|
14
|
-
constructor(cookieService: CookieService,
|
|
12
|
+
readonly window: any;
|
|
13
|
+
constructor(cookieService: CookieService, window: any);
|
|
15
14
|
ngOnInit(): void;
|
|
16
15
|
acceptCookie(): void;
|
|
17
16
|
rejectCookie(): void;
|
|
@@ -21,5 +20,5 @@ export declare class CookieBannerComponent implements OnInit {
|
|
|
21
20
|
notifyAcceptance(): void;
|
|
22
21
|
private getExpiryDate;
|
|
23
22
|
static ɵfac: i0.ɵɵFactoryDeclaration<CookieBannerComponent, never>;
|
|
24
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<CookieBannerComponent, "xuilib-cookie-banner", never, { "identifier": "identifier"; "appName": "appName"; }, { "rejectionNotifier": "rejectionNotifier"; "acceptanceNotifier": "acceptanceNotifier"; }, never, never, false, never>;
|
|
23
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CookieBannerComponent, "xuilib-cookie-banner", never, { "identifier": "identifier"; "appName": "appName"; "enableDynatrace": "enableDynatrace"; }, { "rejectionNotifier": "rejectionNotifier"; "acceptanceNotifier": "acceptanceNotifier"; }, never, never, false, never>;
|
|
25
24
|
}
|
|
@@ -6,6 +6,7 @@ export declare class FeatureToggleService {
|
|
|
6
6
|
isEnabled(_feature: string): Observable<boolean>;
|
|
7
7
|
getValue<R>(_key: string, _defaultValue: R): Observable<R>;
|
|
8
8
|
getValueOnce<R>(_key: string, _defaultValue: R): Observable<R>;
|
|
9
|
+
getValueSync<R>(feature: string, defaultValue: R): R;
|
|
9
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<FeatureToggleService, never>;
|
|
10
11
|
static ɵprov: i0.ɵɵInjectableDeclaration<FeatureToggleService>;
|
|
11
12
|
}
|
|
@@ -9,7 +9,7 @@ export declare class LaunchDarklyService implements FeatureToggleService {
|
|
|
9
9
|
private user;
|
|
10
10
|
private clientId;
|
|
11
11
|
initialize(user: FeatureUser, clientId: string): void;
|
|
12
|
-
isEnabled(feature: string): Observable<boolean>;
|
|
12
|
+
isEnabled(feature: string, defaultValue?: boolean): Observable<boolean>;
|
|
13
13
|
getArray<R = any>(feature: string): Observable<R[]>;
|
|
14
14
|
getValue<R>(feature: string, defaultValue: R): Observable<R>;
|
|
15
15
|
/**
|
|
@@ -22,6 +22,7 @@ export declare class LaunchDarklyService implements FeatureToggleService {
|
|
|
22
22
|
* @param defaultValue R
|
|
23
23
|
*/
|
|
24
24
|
getValueOnce<R>(feature: string, defaultValue: R): Observable<R>;
|
|
25
|
+
getValueSync<R>(feature: string, defaultValue: R): R;
|
|
25
26
|
static ɵfac: i0.ɵɵFactoryDeclaration<LaunchDarklyService, never>;
|
|
26
27
|
static ɵprov: i0.ɵɵInjectableDeclaration<LaunchDarklyService>;
|
|
27
28
|
}
|