next-csrf
Version:
CSRF mitigation library for Next.js
12 lines (11 loc) • 423 B
JavaScript
// form[tabindex=0][disabled] should be focusable as the
// specification doesn't know the disabled attribute on the form element
// @specification https://www.w3.org/TR/html5/forms.html#the-form-element
export default {
element: 'form',
mutate: function mutate(element) {
element.setAttribute('tabindex', 0);
element.setAttribute('disabled', 'disabled');
}
};
//# sourceMappingURL=focus-form-disabled.js.map