File tree Expand file tree Collapse file tree 7 files changed +13
-16
lines changed Expand file tree Collapse file tree 7 files changed +13
-16
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ const routes: Routes = [
13
13
loadChildren : ( ) => import ( "./pages/auth/auth.module" ) . then ( m => m . AuthModule )
14
14
} ,
15
15
{
16
- path : "post " ,
16
+ path : "posts " ,
17
17
loadChildren : ( ) => import ( "./pages/post/post.module" ) . then ( m => m . PostModule )
18
18
} ,
19
19
{
@@ -22,7 +22,7 @@ const routes: Routes = [
22
22
} ,
23
23
{
24
24
path : "" ,
25
- redirectTo : "post " ,
25
+ redirectTo : "posts " ,
26
26
pathMatch : "full" ,
27
27
}
28
28
]
Original file line number Diff line number Diff line change 29
29
< a routerLink ="./user/profile " class ="block duration-150 hover:bg-indigo-700 hover:rounded-t-lg hover:text-white px-4 py-3 transition-colors ">
30
30
Mi perfil
31
31
</ a >
32
- < a routerLink ="./user/news " class ="block duration-150 hover:bg-indigo-700 hover:text-white px-4 py-3 transition-colors ">
33
- Mis noticias
32
+ < a routerLink ="./user/posts " class ="block duration-150 hover:bg-indigo-700 hover:text-white px-4 py-3 transition-colors ">
33
+ Mis publicaciones
34
34
</ a >
35
- < a (click) ="logout() " routerLink ="./news " class ="block duration-150 hover:bg-indigo-700 hover:rounded-b-lg hover:text-white px-4 py-3 transition-colors ">
35
+ < a (click) ="logout() " routerLink ="./posts " class ="block duration-150 hover:bg-indigo-700 hover:rounded-b-lg hover:text-white px-4 py-3 transition-colors ">
36
36
Cerrar sesión
37
37
</ a >
38
38
</ div >
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ <h2 class="font-bold pb-2 text-3xl text-center text-indigo-700">
39
39
</ div >
40
40
< div >
41
41
< button
42
- class ="btn-success w-full "
42
+ class ="btn-success disabled:bg-indigo-400 disabled:hover:bg-indigo-400 w-full "
43
43
[disabled] ="loginForm.invalid "
44
44
type ="submit "
45
45
>
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ export class LoginPageComponent {
28
28
. subscribe ( {
29
29
next : ( ) => {
30
30
this . loading = false ;
31
- this . router . navigateByUrl ( "/user/news " ) ;
31
+ this . router . navigateByUrl ( "/user/posts " ) ;
32
32
} ,
33
33
error : ( ) => {
34
34
this . loading = false ;
Original file line number Diff line number Diff line change 2
2
< h2 > Mis Publicaciones</ h2 >
3
3
</ div >
4
4
< div class ="bg-white border-b-2 border-indigo-100 border-solid font-medium px-16 py-3 text-slate-700 text-xss ">
5
- Inicio / < a routerLink ="/user/post "> Publicaciones</ a >
5
+ Inicio / < a routerLink ="/user/posts "> Publicaciones</ a >
6
6
</ div >
7
7
< section class ="gap-y-10 grid ">
8
8
< div class ="mb-8 text-right ">
9
- < a routerLink ="/user/post /create ">
9
+ < a routerLink ="/user/posts /create ">
10
10
< button class ="btn-success ">
11
11
Nuevo
12
12
</ button >
Original file line number Diff line number Diff line change @@ -11,16 +11,13 @@ import { Post } from "../../../core/interfaces/post.interface";
11
11
styleUrl : "./list-post-page.component.scss" ,
12
12
} )
13
13
export class ListPostPageComponent implements OnInit {
14
+ private postService = inject ( PostService ) ;
14
15
private toastrService = inject ( ToastrService ) ;
15
16
16
17
public idPost : string = "" ;
17
18
public isOpen : boolean = false ;
18
19
public listPosts : Post [ ] = [ ] ;
19
20
20
- constructor (
21
- private postService : PostService
22
- ) { }
23
-
24
21
ngOnInit ( ) : void {
25
22
this . loadPosts ( ) ;
26
23
}
Original file line number Diff line number Diff line change @@ -14,17 +14,17 @@ const routes: Routes = [
14
14
component : ProfilePageComponent
15
15
} ,
16
16
{
17
- path : "post " ,
17
+ path : "posts " ,
18
18
canActivate : [ isAuthenticatedGuard ] ,
19
19
component : ListPostPageComponent
20
20
} ,
21
21
{
22
- path : "post /create" ,
22
+ path : "posts /create" ,
23
23
canActivate : [ isAuthenticatedGuard ] ,
24
24
component : FormPostPageComponent
25
25
} ,
26
26
{
27
- path : "post /:id" ,
27
+ path : "posts /:id" ,
28
28
canActivate : [ isAuthenticatedGuard ] ,
29
29
component : FormPostPageComponent
30
30
} ,
You can’t perform that action at this time.
0 commit comments