<commit_before><template>

  <div class="top">
    <nav-link
      :to="recentLink"
      :active="pageName === Constants.PageNames.RECENT"
      :text="$tr('recent')"
    />
    <nav-link
      :to="topicsLink"
      :active="pageName === Constants.PageNames.TOPICS"
      :text="$tr('topics')"
    />
    <nav-link
      :to="examsLink"
      :active="pageName === Constants.PageNames.EXAMS"
      :text="$tr('exams')"
    />
    <nav-link
      :to="learnersLink"
      :active="pageName === Constants.PageNames.LEARNERS"
      :text="$tr('learners')"
    />
    <nav-link
      :to="groupsLink"
      :active="pageName === Constants.PageNames.GROUPS"
      :text="$tr('groups')"
    />
  </div>

</template>


<script>

  const Constants = require('../../constants');

  module.exports = {
    $trNameSpace: 'top-nav',
    $trs: {
      recent: 'Recent',
      topics: 'Topics',
      exams: 'Exams',
      learners: 'Learners',
      groups: 'Groups',
    },
    components: {
      'nav-link': require('./nav-link'),
    },
    computed: {
      Constants() {
        return Constants;
      },
      recentLink() {
        return {
          name: Constants.PageNames.RECENT,
          params: { class_id: this.classId },
        };
      },
      topicsLink() {
        return {
          name: Constants.PageNames.TOPICS,
          params: { class_id: this.classId },
        };
      },
      examsLink() {
        return {
          name: Constants.PageNames.EXAMS,
          params: { class_id: this.classId },
        };
      },
      learnersLink() {
        return {
          name: Constants.PageNames.LEARNERS,
          params: { class_id: this.classId },
        };
      },
      groupsLink() {
        return {
          name: Constants.PageNames.GROUPS,
          params: { class_id: this.classId },
        };
      },
    },
    vuex: {
      getters: {<commit_msg>move check to a method<commit_after><template>

  <div class="top">
    <nav-link
      :to="recentLink"
      :active="isActive(Constants.PageNames.RECENT)"
      :text="$tr('recent')"
    />
    <nav-link
      :to="topicsLink"
      :active="isActive(Constants.PageNames.TOPICS)"
      :text="$tr('topics')"
    />
    <nav-link
      :to="examsLink"
      :active="isActive(Constants.PageNames.EXAMS)"
      :text="$tr('exams')"
    />
    <nav-link
      :to="learnersLink"
      :active="isActive(Constants.PageNames.LEARNERS)"
      :text="$tr('learners')"
    />
    <nav-link
      :to="groupsLink"
      :active="isActive(Constants.PageNames.GROUPS)"
      :text="$tr('groups')"
    />
  </div>

</template>


<script>

  const Constants = require('../../constants');

  module.exports = {
    $trNameSpace: 'top-nav',
    $trs: {
      recent: 'Recent',
      topics: 'Topics',
      exams: 'Exams',
      learners: 'Learners',
      groups: 'Groups',
    },
    components: {
      'nav-link': require('./nav-link'),
    },
    computed: {
      Constants() {
        return Constants;
      },
      recentLink() {
        return {
          name: Constants.PageNames.RECENT,
          params: { class_id: this.classId },
        };
      },
      topicsLink() {
        return {
          name: Constants.PageNames.TOPICS,
          params: { class_id: this.classId },
        };
      },
      examsLink() {
        return {
          name: Constants.PageNames.EXAMS,
          params: { class_id: this.classId },
        };
      },
      learnersLink() {
        return {
          name: Constants.PageNames.LEARNERS,
          params: { class_id: this.classId },
        };
      },
      groupsLink() {
        return {
          name: Constants.PageNames.GROUPS,
          params: { class_id: this.classId },
        };
      },
    },
    methods: {
      isActive(thatPageName) {
        return this.pageName === thatPageName;
      },
    },
    vuex: {
      getters: {
{'fraction_non_alphanumeric': 0.16404841617306207, 'fraction_numerical': 0.0, 'mean_word_length': 1.822674418604651, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4438035', 'n_tokens_mistral': 1287, 'n_tokens_neox': 1270, 'n_words': 188}