braft-extensions icon indicating copy to clipboard operation
braft-extensions copied to clipboard

Table 的下拉菜单按钮会将 Form 表单提交

Open xushre opened this issue 2 years ago • 1 comments

<button disabled={!this.state.rows || !this.state.columns} className="button primary" onClick={this.confirmInsert}>{this.props.language.insertTable}</button>

建议在 button 上设置 type 属性

xushre avatar Jan 16 '23 07:01 xushre

可以在BraftEditor组件的onChange事件首行加入document.querySelector('.bf-table-dropdown-control button')?.setAttribute?.('type', 'button');来解决此问题。

ZhouYing-JOEY avatar Aug 07 '23 02:08 ZhouYing-JOEY