refacto des pages home, register, login, detail profile

This commit is contained in:
styve Lioumba
2025-11-15 10:31:11 +01:00
parent 0301a75e4d
commit 620b781219
16 changed files with 1106 additions and 453 deletions

View File

@@ -3,17 +3,21 @@ import { SearchComponent } from '@app/shared/features/search/search.component';
import { VerticalProfileListComponent } from '@app/shared/components/vertical-profile-list/vertical-profile-list.component';
import { UntilDestroy } from '@ngneat/until-destroy';
import { ProfileFacade } from '@app/ui/profiles/profile.facade';
import {LoadingComponent} from "@app/shared/components/loading/loading.component";
import {Router} from "@angular/router";
@Component({
selector: 'app-profile-list',
standalone: true,
imports: [SearchComponent, VerticalProfileListComponent],
imports: [SearchComponent, VerticalProfileListComponent, LoadingComponent],
templateUrl: './profile-list.component.html',
styleUrl: './profile-list.component.scss',
})
@UntilDestroy()
export class ProfileListComponent implements OnInit {
private readonly facade = inject(ProfileFacade);
private readonly router = inject(Router);
protected readonly profiles = this.facade.profiles;
protected readonly loading = this.facade.loading;
protected readonly error = this.facade.error;
@@ -21,4 +25,8 @@ export class ProfileListComponent implements OnInit {
ngOnInit() {
this.facade.load();
}
showNewQuery(newQuery: string) {
this.router.navigate(['/profiles'], { queryParams: { search: newQuery } });
}
}