mirror of
https://github.com/docusealco/docuseal
synced 2026-11-05 06:42:32 -05:00
remove onsubmit html event
This commit is contained in:
1 parent
df8e79683a
commit
3b18502d3d
6 files changed
+41
-16
No files matched your search
@@ -0,0 +1,21 @@
|
||||
export default class extends HTMLElement {
|
||||
connectedCallback () {
|
||||
this.button.disabled = false
|
||||
|
||||
this.form.addEventListener('submit', () => {
|
||||
this.button.disabled = true
|
||||
})
|
||||
}
|
||||
|
||||
disconnectedCallback () {
|
||||
this.button.disabled = false
|
||||
}
|
||||
|
||||
get button () {
|
||||
return this.querySelector('[type="submit"]')
|
||||
}
|
||||
|
||||
get form () {
|
||||
return this.querySelector('form') || this.closest('form')
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user