mirror of
https://github.com/bringout/oca-ocb-security.git
synced 2026-04-21 15:32:07 +02:00
19.0 vanilla
This commit is contained in:
parent
20ddc1b4a3
commit
c0efcc53f5
1162 changed files with 125577 additions and 105287 deletions
|
|
@ -0,0 +1,23 @@
|
|||
import { Interaction } from "@web/public/interaction";
|
||||
import { registry } from "@web/core/registry";
|
||||
|
||||
import { addLoadingEffect } from "@web/core/utils/ui";
|
||||
|
||||
export class Signup extends Interaction {
|
||||
static selector = ".oe_signup_form, .oe_reset_password_form";
|
||||
dynamicContent = {
|
||||
_root: { "t-on-submit": this.onSubmit },
|
||||
};
|
||||
|
||||
onSubmit() {
|
||||
const submitEl = this.el.querySelector('.oe_login_buttons > button[type="submit"]');
|
||||
if (submitEl && !submitEl.disabled) {
|
||||
const removeLoadingEffect = addLoadingEffect(submitEl);
|
||||
this.registerCleanup(removeLoadingEffect);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
registry
|
||||
.category("public.interactions")
|
||||
.add("auth_signup.signup", Signup);
|
||||
Loading…
Add table
Add a link
Reference in a new issue