0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-24 23:48:13 -05:00

🐛 Fix unexpected file dialog when pressing <enter> on user screen (#833)

closes TryGhost/Ghost#8835
- adds `type="button"` attribute to the file dialog trigger button, the default type for buttons is "submit" which will be triggered by pressing `<enter>` in a form field
This commit is contained in:
Erik Hanchett 2017-08-21 01:55:03 -07:00 committed by Kevin Ansfield
parent 3138a5bb62
commit e2f6061a71

View file

@ -90,7 +90,7 @@
<form class="user-profile" novalidate="novalidate" autocomplete="off" {{action (perform save) on="submit"}}>
<figure class="user-cover" style={{coverImageBackground}}>
<button class="gh-btn gh-btn-default user-cover-edit" {{action "toggleUploadCoverModal"}}><span>Change Cover</span></button>
<button type="button" class="gh-btn gh-btn-default user-cover-edit" {{action "toggleUploadCoverModal"}}><span>Change Cover</span></button>
{{#if showUploadCoverModal}}
{{gh-fullscreen-modal "upload-image"
model=(hash model=user imageProperty="coverImage")