aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/site/src/components/RightPage1.vue
blob: 5b93ea89ffbaf1cd6e9c40d6f5e72b93406d7ede (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<script lang="ts">
import axios from "axios";

export default {
  data() {
    return {
      ChangeLogTagName: "beta",
      ChangeLogMessage: 'testChangeLogMessage',
    }
  },
  props: {
    title: {
      type: String,
      default: "1",
    },
    msg: {
      type: String,
      require: true
    },
    date: {
      type: Date,
      default: new Date('2024-07-14T12:00:00Z')
    }
  },
  methods: {
    getChangeLog() {
      axios.get('https://api.github.com/repos/HydroRoll-Team/HydroRoll/releases/latest').then(res => {
        this.ChangeLogTagName = res.data['tag_name'];
        this.ChangeLogMessage = res.data['body'];
        console.log(res.data);
      })
    }
  },
  beforeMount() {
    this.getChangeLog()
  }
}
</script>


<template>
  <div class="details" style="overflow-y:scroll;overflow-x:hidden;height:100%">
    <h3>
      {{ title }}
    </h3>
    <v-md-preview :text="ChangeLogMessage"></v-md-preview>
  </div>
</template>


<style scoped>


h3 {
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 0.4rem;
  color: var(--color-heading);
}

.details {
  flex: 1;
  margin-left: 1rem;
}
</style>