mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-11-25 12:39:03 +08:00
add link to single demo page
This commit is contained in:
parent
5213069bb4
commit
d7fd11c1d0
@ -24,7 +24,10 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="demo__meta">
|
||||
<div class="demo__name">
|
||||
<g-link class="demo__name" :to="`/demos/${name}`" v-if="isDevelopment">
|
||||
Demo/{{ name }}
|
||||
</g-link>
|
||||
<div class="demo__name" v-else>
|
||||
Demo/{{ name }}
|
||||
</div>
|
||||
<a class="demo__link" :href="githubUrl" target="_blank">
|
||||
@ -67,8 +70,12 @@ export default {
|
||||
return this.files[this.currentIndex]
|
||||
},
|
||||
|
||||
isDevelopment() {
|
||||
return process.env.NODE_ENV === 'development'
|
||||
},
|
||||
|
||||
githubUrl() {
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
if (this.isDevelopment) {
|
||||
return `vscode://file${this.cwd}/src/demos/${this.name}/${this.files[0].name}`
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user