This commit is contained in:
Adina Țeudan 2022-06-20 21:53:51 +03:00
parent 5eba24b0da
commit dc22950f4d
5 changed files with 11 additions and 12 deletions

View File

@ -88,4 +88,4 @@
}
}
]
}
}

View File

@ -4,11 +4,9 @@ Install submodule at `{libs,projects}/common-ui`.
Install dependencies:
- ```sh
yarn add keycloak-angular keycloak-js ngx-toastr @biesbjerg/ngx-translate-extract-marker @ngx-translate/core @ngx-translate/http-loader dayjs lodash-es ngx-translate-messageformat-compiler
```
- `yarn add @types/lodash-es -D`
- `ng add @angular/material`
- `yarn add keycloak-angular keycloak-js ngx-toastr @biesbjerg/ngx-translate-extract-marker @ngx-translate/core @ngx-translate/http-loader dayjs lodash-es ngx-translate-messageformat-compiler messageformat`
- `yarn add @types/lodash-es -D`
- `ng add @angular/material`
In `app.module.ts` add:
@ -52,3 +50,5 @@ section:
"allowSyntheticDefaultImports": true
},
```
Make sure `noImplicitOverride` is **not** set to `true`.

View File

@ -1,9 +1,8 @@
import { ChangeDetectionStrategy, Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { IconButtonTypes } from '../../buttons';
import { Required } from '../../utils';
@Component({
selector: 'iqser-empty-state',
selector: 'iqser-empty-state [text]',
templateUrl: './empty-state.component.html',
styleUrls: ['./empty-state.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
@ -11,7 +10,7 @@ import { Required } from '../../utils';
export class EmptyStateComponent implements OnInit {
readonly iconButtonTypes = IconButtonTypes;
@Input() @Required() text!: string;
@Input() text!: string;
@Input() icon?: string;
@Input() showButton = true;
@Input() buttonIcon = 'iqser:plus';

View File

@ -8,7 +8,7 @@ import { ToasterActions, ToasterOptions } from '../../services';
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class ToastComponent extends Toast {
constructor(protected readonly _toastrService: ToastrService, override readonly toastPackage: ToastPackage) {
constructor(protected readonly _toastrService: ToastrService, readonly toastPackage: ToastPackage) {
super(_toastrService, toastPackage);
}

View File

@ -6,12 +6,12 @@ import { HttpUrlEncodingCodec } from '@angular/common/http';
* See: https://github.com/angular/angular/issues/11058#issuecomment-247367318
*/
export class CustomHttpUrlEncodingCodec extends HttpUrlEncodingCodec {
override encodeKey(k: string): string {
encodeKey(k: string): string {
const kk = super.encodeKey(k);
return kk.replace(/\+/gi, '%2B');
}
override encodeValue(v: string): string {
encodeValue(v: string): string {
const vv = super.encodeValue(v);
return vv.replace(/\+/gi, '%2B');
}