mirror of
https://github.com/flarum/framework.git
synced 2024-11-25 17:57:04 +08:00
Avoid submitting forms with MarkdownButton
Add type="button" to the component so that it won't submit if placed inside a form. Fixes https://github.com/flarum/core/issues/2875
This commit is contained in:
parent
f9d97b60d5
commit
7f37e36241
|
@ -11,6 +11,7 @@ export default class MarkdownButton extends Component {
|
|||
const button = (
|
||||
<button
|
||||
className="Button Button--icon Button--link"
|
||||
type="button"
|
||||
data-hotkey={this.attrs.hotkey}
|
||||
onkeydown={this.keydown.bind(this)}
|
||||
onclick={this.attrs.onclick}
|
||||
|
|
Loading…
Reference in New Issue
Block a user