Add dev commit links

This commit is contained in:
Dominik Korsa 2019-02-25 21:36:47 +01:00
parent d00737fd57
commit 22af59eede
3 changed files with 36 additions and 4 deletions

View file

@ -4,7 +4,8 @@
v-if="master"
:released="master.released"
:download="master.download"
:build="master.build" />
:build="master.build"
:commit-url="master.commitUrl" />
<home-download-dev-item
v-for="version in versions"
:key="version.id"
@ -15,7 +16,8 @@
:download="version.download"
:avatar="version.avatar"
:user="version.user"
:build="version.build" />
:build="version.build"
:commit="version.commit" />
<div v-if="versions === null" class="loading">Loading</div>
</div>
</template>
@ -39,6 +41,7 @@ export default {
released: build.body.finished_at,
download: build.body.public_install_page_url,
build: build.body.build_number,
commitUrl: build.body.commit_view_url,
};
},
async versions() {
@ -55,6 +58,7 @@ export default {
build: build.body.build_number,
avatar: release.user.avatar_url,
user: release.user.login,
commit: release.head.sha,
id: release.id,
};
}))).sort((a, b) => {

View file

@ -8,7 +8,13 @@
</div>
<div class="subheader">
<span class="build-number">{{ build }}</span>
<span class="released" :title="releasedString">{{ releasedRelativeString }}</span>
<a
class="released"
:title="releasedString"
:href="`https://github.com/wulkanowy/wulkanowy/pull/${number}/commits/${commit}`"
target="_blank">
{{ releasedRelativeString }}
</a>
<img class="avatar" :src="avatar" />
<span class="user">{{ user }}</span>
</div>
@ -55,6 +61,9 @@ export default {
user: {
type: String,
},
commit: {
type: String,
},
},
computed: {
releasedString() {
@ -133,6 +142,11 @@ export default {
.released {
margin-left: 4px;
color: #0006;
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
.avatar {

View file

@ -3,7 +3,13 @@
<div class="title">Najnowsza stabilna wersja DEV</div>
<div class="subheader">
<span class="build-number">{{ build }}</span>
<span class="released" :title="releasedString">{{ releasedRelativeString }}</span>
<a
class="released"
:title="releasedString"
:href="commitUrl"
target="_blank">
{{ releasedRelativeString }}
</a>
</div>
<div class="buttons">
<a class="download-button" :href="download" target="_blank" title="Download">
@ -30,6 +36,9 @@ export default {
download: {
type: String,
},
commitUrl: {
type: String,
},
},
computed: {
releasedString() {
@ -90,6 +99,11 @@ export default {
.released {
margin-left: 4px;
color: #0006;
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
}