diff options
Diffstat (limited to 'src/client')
| -rw-r--r-- | src/client/app/desktop/views/pages/share.vue | 5 | ||||
| -rw-r--r-- | src/client/app/mobile/views/pages/share.vue | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/src/client/app/desktop/views/pages/share.vue b/src/client/app/desktop/views/pages/share.vue index d20e6e864c..bed9ae395d 100644 --- a/src/client/app/desktop/views/pages/share.vue +++ b/src/client/app/desktop/views/pages/share.vue @@ -28,9 +28,10 @@ export default Vue.extend({ computed: { template(): string { let t = ''; - if (this.title) t += `【${title}】\n`; + if (this.title && this.url) t += `【[${title}](${url})】\n`; + if (this.title && !this.url) t += `【${title}】\n`; if (this.text) t += `${text}\n`; - if (this.url) t += `${url}`; + if (!this.title && this.url) t += `${url}`; return t.trim(); } }, diff --git a/src/client/app/mobile/views/pages/share.vue b/src/client/app/mobile/views/pages/share.vue index dbafc9e7ba..e238d325da 100644 --- a/src/client/app/mobile/views/pages/share.vue +++ b/src/client/app/mobile/views/pages/share.vue @@ -28,9 +28,10 @@ export default Vue.extend({ computed: { template(): string { let t = ''; - if (this.title) t += `【${title}】\n`; + if (this.title && this.url) t += `【[${title}](${url})】\n`; + if (this.title && !this.url) t += `【${title}】\n`; if (this.text) t += `${text}\n`; - if (this.url) t += `${url}`; + if (!this.title && this.url) t += `${url}`; return t.trim(); } }, |