Skip to content

Commit

Permalink
fix(textarea): 修复textarea组件样式展示问题
Browse files Browse the repository at this point in the history
修复textarea组件样式展示问题

Tencent#727
  • Loading branch information
mokywu committed Apr 13, 2022
1 parent b565cfe commit 6778a2f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/textarea/textarea.tsx
Expand Up @@ -163,7 +163,9 @@ export default Vue.extend({
style={this.textareaStyle}
ref="refTextareaElem"
></textarea>
{this.maxcharacter && <span class={`${name}__limit`}>{`${this.characterNumber}/${this.maxcharacter}`}</span>}
{this.maxcharacter ? (
<span class={`${name}__limit`}>{`${this.characterNumber}/${this.maxcharacter}`}</span>
) : null}
{!this.maxcharacter && this.maxlength ? (
<span class={`${name}__limit`}>{`${this.value ? String(this.value)?.length : 0}/${this.maxlength}`}</span>
) : null}
Expand Down

0 comments on commit 6778a2f

Please sign in to comment.