mirror of
https://github.com/Tencent/tmagic-editor.git
synced 2025-04-06 03:57:56 +08:00
fix(ui): 修复text组件在流式容器内无宽高问题
This commit is contained in:
parent
b915accb71
commit
695efc00a8
@ -52,9 +52,9 @@ export default defineComponent({
|
||||
render() {
|
||||
const className = this.config?.multiple ? 'magic-ui-text' : 'magic-ui-text magic-ui-text--single-line';
|
||||
if (typeof this.$slots?.default === 'function') {
|
||||
return h('span', { class: className }, [this.$slots?.default?.() || '']);
|
||||
return h('div', { class: className }, [this.$slots?.default?.() || '']);
|
||||
}
|
||||
return h('span', {
|
||||
return h('div', {
|
||||
class: className,
|
||||
...(this.displayText ? { innerHTML: this.displayText } : {}),
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user