2020-09-26 00:09:20 +00:00
|
|
|
<template lang="html">
|
2020-09-28 23:27:42 +00:00
|
|
|
<div>
|
2020-09-26 00:24:18 +00:00
|
|
|
<b-jumbotron
|
2020-10-05 18:42:04 +00:00
|
|
|
:header="$t('about.title')"
|
|
|
|
:lead="$t('about.subtitle')"
|
2020-10-14 00:08:56 +00:00
|
|
|
:bg-variant="nightMode ? 'dark' : ''"
|
|
|
|
:text-variant="nightMode ? 'white' : ''"
|
|
|
|
:border-variant="nightMode ? 'dark' : ''"
|
2020-09-26 00:24:18 +00:00
|
|
|
header-level="5"
|
|
|
|
fluid
|
2020-09-28 23:27:42 +00:00
|
|
|
>
|
|
|
|
<div v-if="repo">
|
|
|
|
<b-button
|
|
|
|
size="sm"
|
|
|
|
href="https://github.com/romancm/gamebrary/subscription"
|
|
|
|
target="_blank"
|
|
|
|
>
|
2020-10-05 18:42:04 +00:00
|
|
|
{{ $t('gitHub.watch') }} <b-badge variant="light">{{ repo.watchers }}</b-badge>
|
2020-09-28 23:27:42 +00:00
|
|
|
</b-button>
|
|
|
|
|
|
|
|
<b-button
|
|
|
|
size="sm"
|
|
|
|
href="https://github.com/romancm/gamebrary"
|
|
|
|
target="_blank"
|
|
|
|
>
|
2020-10-05 18:42:04 +00:00
|
|
|
{{ $t('gitHub.star') }} <b-badge variant="light">{{ repo.stargazers_count }}</b-badge>
|
2020-09-28 23:27:42 +00:00
|
|
|
</b-button>
|
|
|
|
|
|
|
|
<b-button
|
|
|
|
size="sm"
|
|
|
|
href="https://github.com/romancm/gamebrary/fork"
|
|
|
|
target="_blank"
|
|
|
|
>
|
2020-10-05 18:42:04 +00:00
|
|
|
{{ $t('gitHub.fork') }} <b-badge variant="light">{{ repo.forks }}</b-badge>
|
2020-09-28 23:27:42 +00:00
|
|
|
</b-button>
|
|
|
|
|
|
|
|
<b-button
|
|
|
|
size="sm"
|
|
|
|
href="https://github.com/romancm/gamebrary/issues"
|
|
|
|
target="_blank"
|
|
|
|
>
|
2020-10-05 18:42:04 +00:00
|
|
|
{{ $t('gitHub.issues') }} <b-badge variant="light">{{ repo.open_issues }}</b-badge>
|
2020-09-28 23:27:42 +00:00
|
|
|
</b-button>
|
|
|
|
</div>
|
|
|
|
</b-jumbotron>
|
2020-09-26 00:09:20 +00:00
|
|
|
|
2020-09-26 00:24:18 +00:00
|
|
|
<b-container>
|
|
|
|
<vue-markdown
|
|
|
|
class="w-100"
|
|
|
|
v-if="readme"
|
|
|
|
:source="readme"
|
|
|
|
/>
|
|
|
|
</b-container>
|
2020-09-28 23:27:42 +00:00
|
|
|
</div>
|
2020-09-26 00:09:20 +00:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import VueMarkdown from 'vue-markdown';
|
2020-10-14 00:08:56 +00:00
|
|
|
import { mapGetters } from 'vuex';
|
2020-09-26 00:09:20 +00:00
|
|
|
|
|
|
|
export default {
|
|
|
|
components: {
|
|
|
|
VueMarkdown,
|
|
|
|
},
|
|
|
|
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
readme: null,
|
|
|
|
repo: null,
|
|
|
|
};
|
|
|
|
},
|
|
|
|
|
|
|
|
computed: {
|
2020-10-14 00:08:56 +00:00
|
|
|
...mapGetters(['nightMode']),
|
|
|
|
|
2020-09-26 00:09:20 +00:00
|
|
|
currentYear() {
|
|
|
|
return new Date().getFullYear();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
mounted() {
|
|
|
|
this.load();
|
|
|
|
},
|
|
|
|
|
|
|
|
methods: {
|
|
|
|
async load() {
|
|
|
|
this.readme = await this.$store.dispatch('LOAD_GITHUB_README');
|
|
|
|
this.repo = await this.$store.dispatch('LOAD_GITHUB_REPOSITORY');
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
</script>
|