[Library | Trunk]: Fix a bug on input component. Change dashboard user mini
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@57979 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
afd964abcb
commit
91b0b75246
|
@ -43,6 +43,7 @@ export class InputComponent implements OnInit, OnDestroy {
|
|||
ngOnInit(): void {
|
||||
this.initValue = HelperFunctions.copy(this.formControl.value);
|
||||
this.formControl.valueChanges.subscribe(value => {
|
||||
value = (value === '')?null:value;
|
||||
if(this.initValue === value) {
|
||||
this.formControl.markAsPristine();
|
||||
}
|
||||
|
|
|
@ -111,31 +111,28 @@ import {EnvProperties} from '../utils/properties/env-properties';
|
|||
</ul>
|
||||
</li>
|
||||
</ng-container>
|
||||
|
||||
<ng-container *ngIf="dashboard">
|
||||
<a *ngIf="!loggedIn" [class]="'loginLink '+colors" (click)="logIn()">
|
||||
Sign in <span class=" uk-margin-small-left uk-margin-small-right uk-icon">
|
||||
<a *ngIf="!loggedIn" class="login" (click)="logIn()">
|
||||
Sign in <span class="uk-margin-small-left uk-margin-small-right uk-icon">
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" ratio="1">
|
||||
<circle [attr.class]="'loginLink userBox '+colors" cx="9.9" cy="6.4" r="4.4" stroke-width="1.1"></circle>
|
||||
<path [attr.class]="'loginLink userBox '+colors"
|
||||
d="M1.5,19 C2.3,14.5 5.8,11.2 10,11.2 C14.2,11.2 17.7,14.6 18.5,19.2" stroke-width="1.1"></path>
|
||||
</svg> </span>
|
||||
<circle cx="9.9" cy="6.4" r="4.4" stroke-width="1.1"></circle>
|
||||
<path d="M1.5,19 C2.3,14.5 5.8,11.2 10,11.2 C14.2,11.2 17.7,14.6 18.5,19.2" stroke-width="1.1"></path>
|
||||
</svg></span>
|
||||
</a>
|
||||
<a *ngIf="loggedIn" class="user_action_image uk-icon">
|
||||
<a *ngIf="loggedIn" class="uk-icon">
|
||||
<svg height="60" width="60">
|
||||
<circle [attr.class]="'userBox '+colors" cx="30" cy="30" r="20" stroke-width="2"></circle>
|
||||
<text *ngIf="firstLetters" [attr.class]="'userBox '+colors" x="50%" y="50%" text-anchor="middle" dy=".4em"
|
||||
<circle cx="30" cy="30" r="20" stroke-width="2"></circle>
|
||||
<text *ngIf="firstLetters" x="50%" y="50%" text-anchor="middle" dy=".4em"
|
||||
font-size="1.5em">
|
||||
{{firstLetters}}
|
||||
</text>
|
||||
<svg *ngIf="!firstLetters" ratio="1" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" width="20"
|
||||
x="20">
|
||||
<circle [attr.class]="'icon userBox '+colors" cx="9.9" cy="6.4" r="4.4" stroke-width="1.1"></circle>
|
||||
<path [attr.class]="'icon userBox '+colors"
|
||||
d="M1.5,19 C2.3,14.5 5.8,11.2 10,11.2 C14.2,11.2 17.7,14.6 18.5,19.2" stroke-width="1.1"></path>
|
||||
<circle cx="9.9" cy="6.4" r="4.4" stroke-width="1.1"></circle>
|
||||
<path d="M1.5,19 C2.3,14.5 5.8,11.2 10,11.2 C14.2,11.2 17.7,14.6 18.5,19.2" stroke-width="1.1"></path>
|
||||
</svg>
|
||||
</svg>
|
||||
<i [class]="'material-icons md-'+colors">keyboard_arrow_down</i>
|
||||
<i class="material-icons">keyboard_arrow_down</i>
|
||||
</a>
|
||||
<div *ngIf="loggedIn" uk-dropdown="mode: click; offset: -2; delay-hide: 0; flip: false; pos: bottom-right"
|
||||
#userMenu
|
||||
|
@ -166,7 +163,6 @@ export class UserMiniComponent implements OnInit, OnChanges {
|
|||
@Input() public mobileView: boolean = false;
|
||||
public firstLetters: string = "";
|
||||
@Input() public dashboard: boolean = false;
|
||||
@Input() public colors: string = "light"; // 'dark' on light background - 'light' on dark background
|
||||
public server: boolean = true;
|
||||
public routerHelper: RouterHelper = new RouterHelper();
|
||||
@Input() userMenuItems;
|
||||
|
|
Loading…
Reference in New Issue