mirror of
https://iceshrimp.dev/iceshrimp/iceshrimp
synced 2025-01-19 12:02:55 +09:00
Better share template
This commit is contained in:
parent
b665906196
commit
39256a1c13
@ -28,9 +28,10 @@ export default Vue.extend({
|
|||||||
computed: {
|
computed: {
|
||||||
template(): string {
|
template(): string {
|
||||||
let t = '';
|
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.text) t += `${text}\n`;
|
||||||
if (this.url) t += `${url}`;
|
if (!this.title && this.url) t += `${url}`;
|
||||||
return t.trim();
|
return t.trim();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -28,9 +28,10 @@ export default Vue.extend({
|
|||||||
computed: {
|
computed: {
|
||||||
template(): string {
|
template(): string {
|
||||||
let t = '';
|
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.text) t += `${text}\n`;
|
||||||
if (this.url) t += `${url}`;
|
if (!this.title && this.url) t += `${url}`;
|
||||||
return t.trim();
|
return t.trim();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user