import Component from '@glimmer/component'; import { action } from '@ember/object'; import { tracked } from "@glimmer/tracking"; export default class ChapterNavComponent extends Component { @tracked currentChapter; constructor(...args) { super(...args); } @action showVerses(book, chapter) { this.args.showVerses(book, chapter); this.currentChapter = chapter; } @action isChapterActive(chapter) { return chapter === this.currentChapter; } }