Skip to content

Commit

Permalink
chore: update the example to avoid similar issues again
Browse files Browse the repository at this point in the history
  • Loading branch information
rengert committed Nov 1, 2023
1 parent 363230e commit b98e918
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions src/app/components/table/table.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ <h3 translate>content.headline.static_data</h3>
[columns]="['name', 'level', 'type', 'health', 'birthday']"
[dataset]="data"
[pageSizeOptions]="[7, 14, 21]"
(deleteEvent)="die()"
(editEvent)="view()"
(deleteEvent)="die($event)"
(editEvent)="view($event)"
translateKey="hero.components.hero-list.">
</bpa-table>
</section>
Expand All @@ -26,8 +26,8 @@ <h3 translate>content.headline.no_paging</h3>
[dataset]="data"
[pageSizeOptions]="[7, 14, 21]"
[paging]="false"
(deleteEvent)="die()"
(editEvent)="view()"
(deleteEvent)="die($event)"
(editEvent)="view($event)"
translateKey="hero.components.hero-list.">
</bpa-table>
</section>
Expand All @@ -37,8 +37,8 @@ <h3 translate>content.headline.observables</h3>
[columns]="['name', 'level', 'type', 'health', 'birthday', 'custom']"
[dataset]="data$ | async"
progressBar="always"
(deleteEvent)="die()"
(editEvent)="view()"
(deleteEvent)="die($event)"
(editEvent)="view($event)"
translateKey="hero.components.hero-list.">
</bpa-table>
<h3 class="tw-p-4" translate>content.headline.options</h3>
Expand Down
8 changes: 4 additions & 4 deletions src/app/components/table/table.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,11 @@ export class TableComponent {
takeUntilDestroyed(),
);

protected die(): void {
alert('Die');
protected die(hero: Hero): void {
alert(`Die: ${hero.name}`);
}

protected view(): void {
alert('View');
protected view(hero: Hero): void {
alert(`View: ${hero.name}`);
}
}

0 comments on commit b98e918

Please sign in to comment.