瀏覽代碼

Live page fixture match details will be shown on click

master
kj1352 4 年之前
父節點
當前提交
c91eb1be87
共有 3 個檔案被更改,包括 24 行新增4 行删除
  1. +7
    -2
      src/app/live/live.page.html
  2. +15
    -0
      src/app/live/live.page.scss
  3. +2
    -2
      src/app/live/live.page.ts

+ 7
- 2
src/app/live/live.page.html 查看文件

@@ -80,7 +80,7 @@
</section> </section>
</li> </li>


<li class="collapsible-card" [ngClass]="{'active' : showFixtures}">
<li class="collapsible-card" [ngClass]="{'active' : showFixtures || !currentMatch || !currentMatch.Innings}">
<header> <header>
<label> Fixtures </label> <label> Fixtures </label>
<button (click)="showFixtures = !showFixtures"> <button (click)="showFixtures = !showFixtures">
@@ -90,9 +90,14 @@
</header> </header>


<section class="card"> <section class="card">

<p class="info">
<ion-icon name="information-circle-outline"></ion-icon> Tap the match card to know more
</p>

<ion-slides #slides [options]="slideOpts"> <ion-slides #slides [options]="slideOpts">
<ion-slide *ngFor="let fixture of fixtures">
<ion-slide *ngFor="let fixture of fixtures" (click)="showMatchDetails(fixture.match_id)">
<div class="image-holder"> <div class="image-holder">
<figure> <figure>
<img src="https://s3.ap-south-1.amazonaws.com/assets-kxip.sportz.io/prod/waf-images/91/55/a5/16-9/5PE9uqJSZw.jpg"> <img src="https://s3.ap-south-1.amazonaws.com/assets-kxip.sportz.io/prod/waf-images/91/55/a5/16-9/5PE9uqJSZw.jpg">


+ 15
- 0
src/app/live/live.page.scss 查看文件

@@ -176,6 +176,21 @@
padding: 15px; padding: 15px;
background-color: lighten($brand-blue, 1%); background-color: lighten($brand-blue, 1%);
border-radius: 7px; border-radius: 7px;

.info {
display: flex;
align-items: flex-start;
justify-content: flex-start;
margin: 0px;
font-style: italic;
font-size: 1rem;
color: white;

ion-icon {
width: 20px;
height: 20px;
}
}
} }


table { table {


+ 2
- 2
src/app/live/live.page.ts 查看文件

@@ -280,8 +280,8 @@ export class LivePage implements OnInit {
}); });
} }


showMatchDetails() {
this.router.navigate(['/match-details', { match_id: this.currentMatch.Matchdetail.Match.Id }]);
showMatchDetails(matchId?: string | number) {
this.router.navigate(['/match-details', { match_id: matchId ? matchId : this.currentMatch.Matchdetail.Match.Id }]);
} }


} }

Loading…
取消
儲存