@norwegian/core-components 6.41.0 → 6.42.1
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/esm2022/lib/components/page-header/models/wallet.model.mjs +2 -0
- package/esm2022/lib/components/page-header/page-header.component.mjs +6 -3
- package/esm2022/lib/components/page-header/page-header.module.mjs +8 -5
- package/esm2022/lib/components/page-header/wallet/wallet.component.mjs +42 -0
- package/esm2022/lib/components/page-header-old/page-header-old.component.mjs +3 -3
- package/esm2022/lib/components/tag/tag.component.mjs +4 -9
- package/fesm2022/norwegian-core-components.mjs +373 -342
- package/fesm2022/norwegian-core-components.mjs.map +1 -1
- package/lib/components/page-header/models/wallet.model.d.ts +19 -0
- package/lib/components/page-header/page-header.component.d.ts +8 -1
- package/lib/components/page-header/page-header.module.d.ts +9 -6
- package/lib/components/page-header/wallet/wallet.component.d.ts +20 -0
- package/lib/components/tag/tag.component.d.ts +5 -11
- package/package.json +1 -1
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { LinkModel } from '../../../core';
|
|
2
|
+
export interface WalletModel {
|
|
3
|
+
spennBalance?: number;
|
|
4
|
+
cashpointsBalance?: number;
|
|
5
|
+
rewardNumber?: string;
|
|
6
|
+
urls?: WalletUrls;
|
|
7
|
+
texts?: WalletTexts;
|
|
8
|
+
}
|
|
9
|
+
export interface WalletUrls {
|
|
10
|
+
myTravelsUrl?: LinkModel;
|
|
11
|
+
signOutUrl?: LinkModel;
|
|
12
|
+
}
|
|
13
|
+
export interface WalletTexts {
|
|
14
|
+
rewardPoints: string;
|
|
15
|
+
rewardNumber: string;
|
|
16
|
+
notAvailable: string;
|
|
17
|
+
cashPointsDescription: string;
|
|
18
|
+
spennDescription?: string;
|
|
19
|
+
}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
import { OnDestroy, ElementRef, AfterViewInit, ChangeDetectorRef, EventEmitter } from '@angular/core';
|
|
6
6
|
import { NasComponentBase } from '../../core';
|
|
7
7
|
import { IconListModel } from '../icon-list';
|
|
8
|
+
import { WalletModel } from './models/wallet.model';
|
|
8
9
|
import * as i0 from "@angular/core";
|
|
9
10
|
/**
|
|
10
11
|
* @description
|
|
@@ -96,6 +97,12 @@ export declare class PageHeaderComponent extends NasComponentBase implements OnD
|
|
|
96
97
|
* links to display with icon in header.
|
|
97
98
|
*/
|
|
98
99
|
links: Array<IconListModel>;
|
|
100
|
+
/**
|
|
101
|
+
* @property Input
|
|
102
|
+
* @description
|
|
103
|
+
* Model to display wallet component in header
|
|
104
|
+
*/
|
|
105
|
+
walletModel: WalletModel;
|
|
99
106
|
/**
|
|
100
107
|
* @property Output
|
|
101
108
|
* @description
|
|
@@ -116,5 +123,5 @@ export declare class PageHeaderComponent extends NasComponentBase implements OnD
|
|
|
116
123
|
redirectToUrl(): string;
|
|
117
124
|
setBrandingCSSClass(): "disable-link" | "branding";
|
|
118
125
|
static ɵfac: i0.ɵɵFactoryDeclaration<PageHeaderComponent, never>;
|
|
119
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<PageHeaderComponent, "nas-page-header", never, { "menuText": { "alias": "menuText"; "required": false; }; "closeText": { "alias": "closeText"; "required": false; }; "searchText": { "alias": "searchText"; "required": false; }; "searchForm": { "alias": "searchForm"; "required": false; }; "displayProfile": { "alias": "displayProfile"; "required": false; }; "reward": { "alias": "reward"; "required": false; }; "disableFrontPageUrl": { "alias": "disableFrontPageUrl"; "required": false; }; "isAuthenticated": { "alias": "isAuthenticated"; "required": false; }; "frontPageUrl": { "alias": "frontPageUrl"; "required": false; }; "useRouterLink": { "alias": "useRouterLink"; "required": false; }; "nozindex": { "alias": "nozindex"; "required": false; }; "logOutLink": { "alias": "logOutLink"; "required": false; }; "profileLink": { "alias": "profileLink"; "required": false; }; "links": { "alias": "links"; "required": false; }; }, { "openChange": "openChange"; }, never, ["*"], false, never>;
|
|
126
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PageHeaderComponent, "nas-page-header", never, { "menuText": { "alias": "menuText"; "required": false; }; "closeText": { "alias": "closeText"; "required": false; }; "searchText": { "alias": "searchText"; "required": false; }; "searchForm": { "alias": "searchForm"; "required": false; }; "displayProfile": { "alias": "displayProfile"; "required": false; }; "reward": { "alias": "reward"; "required": false; }; "disableFrontPageUrl": { "alias": "disableFrontPageUrl"; "required": false; }; "isAuthenticated": { "alias": "isAuthenticated"; "required": false; }; "frontPageUrl": { "alias": "frontPageUrl"; "required": false; }; "useRouterLink": { "alias": "useRouterLink"; "required": false; }; "nozindex": { "alias": "nozindex"; "required": false; }; "logOutLink": { "alias": "logOutLink"; "required": false; }; "profileLink": { "alias": "profileLink"; "required": false; }; "links": { "alias": "links"; "required": false; }; "walletModel": { "alias": "walletModel"; "required": false; }; }, { "openChange": "openChange"; }, never, ["*"], false, never>;
|
|
120
127
|
}
|
|
@@ -2,13 +2,16 @@ import * as i0 from "@angular/core";
|
|
|
2
2
|
import * as i1 from "./page-header.component";
|
|
3
3
|
import * as i2 from "./hamburger/hamburger.component";
|
|
4
4
|
import * as i3 from "./search/search.component";
|
|
5
|
-
import * as i4 from "
|
|
6
|
-
import * as i5 from "
|
|
7
|
-
import * as i6 from "
|
|
8
|
-
import * as i7 from "
|
|
9
|
-
import * as i8 from "
|
|
5
|
+
import * as i4 from "./wallet/wallet.component";
|
|
6
|
+
import * as i5 from "@angular/common";
|
|
7
|
+
import * as i6 from "../icon/icon.module";
|
|
8
|
+
import * as i7 from "../../core/directives/nas-class/nas-class.module";
|
|
9
|
+
import * as i8 from "@angular/router";
|
|
10
|
+
import * as i9 from "../button/button.module";
|
|
11
|
+
import * as i10 from "../tag/tag.module";
|
|
12
|
+
import * as i11 from "../button-new/button-new.module";
|
|
10
13
|
export declare class PageHeaderModule {
|
|
11
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<PageHeaderModule, never>;
|
|
12
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<PageHeaderModule, [typeof i1.PageHeaderComponent, typeof i2.HamburgerComponent, typeof i3.SearchComponent], [typeof
|
|
15
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<PageHeaderModule, [typeof i1.PageHeaderComponent, typeof i2.HamburgerComponent, typeof i3.SearchComponent, typeof i4.WalletComponent], [typeof i5.CommonModule, typeof i6.IconModule, typeof i7.NasClassModule, typeof i8.RouterModule, typeof i9.ButtonModule, typeof i10.TagModule, typeof i11.ButtonNewModule], [typeof i1.PageHeaderComponent]>;
|
|
13
16
|
static ɵinj: i0.ɵɵInjectorDeclaration<PageHeaderModule>;
|
|
14
17
|
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { NasComponentBase } from '../../../core';
|
|
2
|
+
import { WalletModel } from '../models/wallet.model';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class WalletComponent extends NasComponentBase {
|
|
5
|
+
/**
|
|
6
|
+
* @property Input
|
|
7
|
+
* @description
|
|
8
|
+
* Model to define the wallet in the header
|
|
9
|
+
*/
|
|
10
|
+
walletModel: WalletModel;
|
|
11
|
+
showContent: boolean;
|
|
12
|
+
get pointsBalance(): number;
|
|
13
|
+
get pointsDescription(): string;
|
|
14
|
+
get icon(): string;
|
|
15
|
+
constructor();
|
|
16
|
+
onClickToggleContent(): void;
|
|
17
|
+
myTravelsPage(): boolean;
|
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WalletComponent, never>;
|
|
19
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<WalletComponent, "nas-wallet", never, { "walletModel": { "alias": "walletModel"; "required": false; }; }, {}, never, never, false, never>;
|
|
20
|
+
}
|
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Norwegian Air Shuttle. All Rights Reserved.
|
|
4
|
-
*/
|
|
5
|
-
import { OnInit } from '@angular/core';
|
|
6
1
|
import { NasComponentBase } from '../../core';
|
|
7
2
|
import { ClassModel } from '../../core/models/class.model';
|
|
8
3
|
import * as i0 from "@angular/core";
|
|
@@ -10,7 +5,7 @@ import * as i0 from "@angular/core";
|
|
|
10
5
|
* @description
|
|
11
6
|
* Norwegian alert Tag | Dialogs and Modals
|
|
12
7
|
*/
|
|
13
|
-
export declare class TagComponent extends NasComponentBase
|
|
8
|
+
export declare class TagComponent extends NasComponentBase {
|
|
14
9
|
/**
|
|
15
10
|
* @description
|
|
16
11
|
* Used to determine that you want to show a tag
|
|
@@ -20,10 +15,10 @@ export declare class TagComponent extends NasComponentBase implements OnInit {
|
|
|
20
15
|
*
|
|
21
16
|
*/
|
|
22
17
|
/**
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
* @property Input
|
|
19
|
+
* @description
|
|
20
|
+
* Boolean to give the tag info.
|
|
21
|
+
*/
|
|
27
22
|
info: boolean;
|
|
28
23
|
/**
|
|
29
24
|
* @property Input
|
|
@@ -68,7 +63,6 @@ export declare class TagComponent extends NasComponentBase implements OnInit {
|
|
|
68
63
|
*/
|
|
69
64
|
iconType: string;
|
|
70
65
|
constructor();
|
|
71
|
-
ngOnInit(): void;
|
|
72
66
|
getClasses(element?: string, modifiers?: any): Array<ClassModel>;
|
|
73
67
|
getModifiers(): Array<string>;
|
|
74
68
|
getTagClass(): string;
|