mirror of
https://github.com/kokonect-link/cherrypick
synced 2024-12-13 14:18:26 +09:00
返信先プレビューなどではURLプレビューを表示しないように
This commit is contained in:
parent
d89b97a771
commit
1af9efe54e
@ -4,7 +4,6 @@
|
|||||||
<a class="reply" v-if="post.replyId">%fa:reply%</a>
|
<a class="reply" v-if="post.replyId">%fa:reply%</a>
|
||||||
<mk-post-html :ast="post.ast" :i="os.i"/>
|
<mk-post-html :ast="post.ast" :i="os.i"/>
|
||||||
<a class="rp" v-if="post.repostId" :href="`/post:${post.repostId}`">RP: ...</a>
|
<a class="rp" v-if="post.repostId" :href="`/post:${post.repostId}`">RP: ...</a>
|
||||||
<mk-url-preview v-for="url in urls" :url="url" :key="url"/>
|
|
||||||
</div>
|
</div>
|
||||||
<details v-if="post.media">
|
<details v-if="post.media">
|
||||||
<summary>({{ post.media.length }}つのメディア)</summary>
|
<summary>({{ post.media.length }}つのメディア)</summary>
|
||||||
@ -21,18 +20,7 @@
|
|||||||
import Vue from 'vue';
|
import Vue from 'vue';
|
||||||
|
|
||||||
export default Vue.extend({
|
export default Vue.extend({
|
||||||
props: ['post'],
|
props: ['post']
|
||||||
computed: {
|
|
||||||
urls(): string[] {
|
|
||||||
if (this.post.ast) {
|
|
||||||
return this.post.ast
|
|
||||||
.filter(t => (t.type == 'url' || t.type == 'link') && !t.silent)
|
|
||||||
.map(t => t.url);
|
|
||||||
} else {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user