nanka iroiro

This commit is contained in:
syuilo
2020-12-30 13:07:16 +09:00
parent 873d4bd707
commit 10cb15b000
8 changed files with 225 additions and 87 deletions

View File

@ -11,6 +11,11 @@ export default defineComponent({
required: false,
default: 'span',
},
textTag: {
type: String,
required: false,
default: null,
},
},
render() {
let str = this.src;
@ -32,6 +37,6 @@ export default defineComponent({
str = str.substr(nextBracketClose + 1);
}
return h(this.tag, parsed.map(x => typeof x === 'string' ? x : this.$slots[x.arg]()));
return h(this.tag, parsed.map(x => typeof x === 'string' ? (this.textTag ? h(this.textTag, x) : x) : this.$slots[x.arg]()));
}
});

View File

@ -1,6 +1,6 @@
<template>
<XWindow ref="window"
:initial-width="700"
:initial-width="500"
:initial-height="500"
:can-resize="true"
:close-right="true"