feat(game): add blackjack game component and routing
Some checks failed
CI / Get Changed Files (pull_request) Successful in 6s
CI / Checkstyle Main (pull_request) Has been skipped
CI / prettier (pull_request) Successful in 16s
CI / eslint (pull_request) Failing after 43s
CI / test-build (pull_request) Successful in 46s

This commit is contained in:
Jan-Marlon Leibl 2025-03-26 13:26:38 +01:00
parent 32aa753452
commit eb153f4459
Signed by: jleibl
GPG key ID: 300B2F906DC6F1D5
12 changed files with 273 additions and 2 deletions

View file

@ -0,0 +1,31 @@
import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
import { CommonModule } from '@angular/common';
import { PlayingCardComponent } from '../playing-card/playing-card.component';
import { Card } from '../../models/card.model';
@Component({
selector: 'app-player-hand',
standalone: true,
imports: [CommonModule, PlayingCardComponent],
template: `
<div class="space-y-4">
<h3 class="section-heading text-2xl mb-4">Deine Karten</h3>
<div class="card p-6 !bg-green-500">
<div
class="flex justify-center gap-4 min-h-[160px] p-4 border-2 border-green-400 rounded-lg"
>
<app-playing-card
*ngFor="let card of cards"
[value]="card.value"
[suit]="card.suit"
[hidden]="card.hidden"
></app-playing-card>
</div>
</div>
</div>
`,
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class PlayerHandComponent {
@Input() cards: Card[] = [];
}