added input
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
Title
|
||||
</h3>
|
||||
<span class="col-span-1 text-right text-xs font-extrabold text-yellow-900 bg-amber-50 px-2 py-1 rounded-lg">
|
||||
+8 pts
|
||||
{{ tag() }}
|
||||
</span>
|
||||
</div>
|
||||
<p class="text-[11px] text-gray-500 leading-relaxed">Description</p>
|
||||
@@ -18,7 +18,7 @@
|
||||
fill="clear"
|
||||
class="m-0 p-0 min-h-0 text-[11px] font-black bg-black text-white rounded-3xl"
|
||||
style="--padding-top: 4px; --padding-bottom: 4px;">
|
||||
Voir ⭢
|
||||
{{ action() }}
|
||||
</ion-button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import {Component, input} from '@angular/core';
|
||||
import {IonicModule} from "@ionic/angular";
|
||||
|
||||
@Component({
|
||||
@@ -9,10 +9,8 @@ import {IonicModule} from "@ionic/angular";
|
||||
IonicModule
|
||||
]
|
||||
})
|
||||
export class ChallengeCardComponent implements OnInit {
|
||||
|
||||
constructor() { }
|
||||
|
||||
ngOnInit() {}
|
||||
|
||||
}
|
||||
export class ChallengeCardComponent {
|
||||
action = input.required<string>();
|
||||
tag = input.required<string>();
|
||||
color = input.required<string>();
|
||||
}
|
||||
@@ -17,16 +17,16 @@
|
||||
<ion-content style="--background: #f7f6f2;">
|
||||
<div class="mt-4">
|
||||
<app-title-part textInfo="Défi bonus du jour"></app-title-part>
|
||||
<app-challenge-card></app-challenge-card>
|
||||
<app-challenge-card action="Regarder" tag="+1 pts" color=""></app-challenge-card>
|
||||
</div>
|
||||
|
||||
<div class="mt-4">
|
||||
<app-title-part textInfo="Vote en attente"></app-title-part>
|
||||
<app-challenge-card></app-challenge-card>
|
||||
<app-challenge-card action="Voir" tag="Vote" color=""></app-challenge-card>
|
||||
</div>
|
||||
|
||||
<div class="mt-4">
|
||||
<app-title-part textInfo="Défis en cours"></app-title-part>
|
||||
<app-challenge-card></app-challenge-card>
|
||||
<app-challenge-card action="Participer" tag="Défis" color=""></app-challenge-card>
|
||||
</div>
|
||||
</ion-content>
|
||||
|
||||
Reference in New Issue
Block a user