Compare commits

...

3 Commits

Author SHA1 Message Date
Harshil Jani
067b0038ef
Merge 44416a7491 into 4373fe0346 2024-04-22 19:40:55 +05:30
vr-varad
4373fe0346
Added default banner for profile (#145)
Co-authored-by: vr-varad <varadgupta21#gmail.com>
2024-04-22 13:30:09 +02:00
Harshil-Jani
44416a7491 Fix the features not working on page
Signed-off-by: Harshil-Jani <harshiljani2002@gmail.com>
2024-04-11 16:49:34 +05:30
3 changed files with 11 additions and 5 deletions

View File

@ -2,8 +2,9 @@
<!-- <div [style.background-image]="utilities.getBannerBackgroundStyle(profile.banner)" class="profile-banner"></div> -->
<div class="profile-banner">
<img class="profile-banner-image" [src]="profile.banner" />
</div>
<img class="profile-banner-image" [src]="profile.banner || 'https://i.pinimg.com/564x/0b/a3/d6/0ba3d60362c7e6d256cfc1f37156bad9.jpg'" />
</div>
<div class="profile-page-header">
<div class="profile-page-header-left">

View File

@ -1,4 +1,4 @@
<div class="profile-widget">
<app-event-header [pubkey]="pubkey"></app-event-header>
<app-profile-actions [pubkey]="pubkey"></app-profile-actions>
<app-profile-actions [pubkey]="pubkey" [profile]="profile"></app-profile-actions>
</div>

View File

@ -1,7 +1,7 @@
import { Component, Input } from '@angular/core';
import { ProfileService } from 'src/app/services/profile';
import { Utilities } from 'src/app/services/utilities';
import { NostrProfile } from '../../services/interfaces';
import { NostrProfile, NostrProfileDocument } from '../../services/interfaces';
@Component({
selector: 'app-profile-widget',
@ -13,8 +13,13 @@ export class ProfileWidgetComponent {
profileName = '';
tooltip = '';
profile!: NostrProfileDocument;
constructor(private profiles: ProfileService, private utilities: Utilities) {}
ngOnInit() {}
async ngOnInit() {
if(this.pubkey){
this.profile = await this.profiles.getProfile(this.pubkey)
}
}
}