Skip to content

Commit

Permalink
chore: static page deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
Cordobo committed May 9, 2024
1 parent cc4e22a commit ec1a264
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
3 changes: 2 additions & 1 deletion projects/demo-app/src/app/app.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ <h4>Installation</h4>
</mat-card-content>

<mat-card-content>
<mat-tab-group animationDuration="0ms" [(selectedIndex)]="selectedIndex">
<mat-tab-group animationDuration="0ms" [selectedIndex]="selected.value"
(selectedIndexChange)="selected.setValue($event)">
<mat-tab label="HTML">
<h4>Copy & Paste this code</h4>
<p>
Expand Down
7 changes: 3 additions & 4 deletions projects/demo-app/src/app/app.component.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Component } from "@angular/core"
import { FormControl } from "@angular/forms"
import { MatSnackBar } from "@angular/material/snack-bar"
import { SafeUrl } from "@angular/platform-browser"
import {
Expand Down Expand Up @@ -58,7 +59,7 @@ export class AppComponent {

public qrCodeSrc!: SafeUrl

public selectedIndex: number
public selected = new FormControl(0)

public marginList: ListType
public scaleList: ListType
Expand All @@ -70,8 +71,6 @@ export class AppComponent {
public showImage: boolean

constructor(private _snackBar: MatSnackBar) {
this.selectedIndex = 0

this.showA11y = true
this.showColors = true
this.showCss = true
Expand Down Expand Up @@ -152,7 +151,7 @@ export class AppComponent {
}

setTabIndex(idx: number): boolean {
this.selectedIndex = idx
this.selected.setValue(idx)
return false
}

Expand Down

0 comments on commit ec1a264

Please sign in to comment.