|
2 | 2 | <ul class="nav nav-tabs mt-2" id="myTab" role="tablist"> |
3 | 3 | <li class="nav-item"> |
4 | 4 | <a |
5 | | - class="nav-link active nav-active text-black font-weight-bold" |
| 5 | + class="nav-link nav-active text-black font-weight-bold" |
| 6 | + [ngClass]="{ active: activeTab === 'customer-information' }" |
6 | 7 | id="customer-information-tab" |
7 | 8 | data-toggle="tab" |
8 | 9 | href="#customer-information" |
9 | 10 | role="tab" |
10 | 11 | aria-controls="customer-information" |
| 12 | + (click)="showTab('customer-information')" |
11 | 13 | >Customer information</a |
12 | 14 | > |
13 | 15 | </li> |
14 | 16 | <li class="nav-item"> |
15 | 17 | <a |
16 | 18 | class="nav-link text-black font-weight-bold" |
17 | | - [ngClass]="{ 'nav-active': areTabsActive, disabled: !areTabsActive }" |
| 19 | + [ngClass]="{ 'nav-active': areTabsActive, disabled: !areTabsActive, active: activeTab === 'projects-type' }" |
18 | 20 | id="projects-type-tab" |
19 | 21 | data-toggle="tab" |
20 | 22 | href="#projectsType" |
21 | 23 | role="tab" |
22 | 24 | aria-controls="projects-type" |
| 25 | + (click)="showTab('projects-type')" |
23 | 26 | >Project types</a |
24 | 27 | > |
25 | 28 | </li> |
26 | 29 | <li class="nav-item"> |
27 | 30 | <a |
28 | 31 | class="nav-link text-black font-weight-bold" |
29 | | - [ngClass]="{ 'nav-active': areTabsActive, disabled: !areTabsActive }" |
| 32 | + [ngClass]="{ 'nav-active': areTabsActive, disabled: !areTabsActive, active: activeTab === 'projects' }" |
30 | 33 | id="projects-tab" |
31 | 34 | data-toggle="tab" |
32 | 35 | href="#projects" |
33 | 36 | role="tab" |
34 | 37 | aria-controls="projects" |
| 38 | + (click)="showTab('projects')" |
35 | 39 | >Projects</a |
36 | 40 | > |
37 | 41 | </li> |
38 | 42 | </ul> |
39 | 43 | <div class="tab-content" id="myTabContent"> |
40 | 44 | <div |
41 | | - class="tab-pane fade show active mt-3" |
| 45 | + class="tab-pane fade mt-3" |
| 46 | + [ngClass]="{ 'show active': activeTab === 'customer-information' }" |
42 | 47 | id="customer-information" |
43 | 48 | role="tabpanel" |
44 | 49 | aria-labelledby="customer-information-tab" |
|
48 | 53 | (changeValueAreTabsActives)="activeTabs($event)" |
49 | 54 | ></app-create-customer> |
50 | 55 | </div> |
51 | | - <div class="tab-pane fade mt-3" id="projects" role="tabpanel" aria-labelledby="projects-tab"> |
52 | | - <div class="container mb-1"> |
53 | | - <app-create-project></app-create-project> |
54 | | - <app-project-list></app-project-list> |
55 | | - </div> |
56 | | - </div> |
57 | | - <div class="tab-pane fade mt-3" id="projectsType" role="tabpanel" aria-labelledby="projects-type-tab"> |
| 56 | + <div |
| 57 | + class="tab-pane fade mt-3" |
| 58 | + [ngClass]="{ 'show active': activeTab === 'projects-type' }" |
| 59 | + id="projectsType" |
| 60 | + role="tabpanel" |
| 61 | + aria-labelledby="projects-type-tab" |
| 62 | + > |
58 | 63 | <div class="container"> |
59 | 64 | <app-create-project-type></app-create-project-type> |
60 | 65 | <app-project-type-list></app-project-type-list> |
61 | 66 | </div> |
62 | 67 | </div> |
| 68 | + <div |
| 69 | + class="tab-pane fade mt-3" |
| 70 | + [ngClass]="{ 'show active': activeTab === 'projects' }" |
| 71 | + id="projects" |
| 72 | + role="tabpanel" |
| 73 | + aria-labelledby="projects-tab" |
| 74 | + > |
| 75 | + <div class="container mb-1"> |
| 76 | + <app-create-project></app-create-project> |
| 77 | + <app-project-list></app-project-list> |
| 78 | + </div> |
| 79 | + </div> |
63 | 80 | </div> |
64 | 81 | </div> |
0 commit comments