New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@acanto/core-forms

Package Overview
Dependencies
Maintainers
1
Versions
55
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@acanto/core-forms - npm Package Compare versions

Comparing version 0.0.20 to 0.0.21

18

base.js
import ajax from "@acanto/core-ajax";
import { getPostData, getFormData } from "@acanto/core-fillform/helpers";
import { $ } from "@acanto/core-dom";
import { $, getDataAttr } from "@acanto/core-dom";
import Validation from "./validation";

@@ -15,2 +15,3 @@ import scrollTo from "@acanto/core-scroll/scrollTo";

const $form = /** @type {HTMLFormElement} */ ($(selector, $root));
$root = $root || $form;
const $submit = /** @type {HTMLButtonElement} */ ($(

@@ -24,9 +25,10 @@ "[type='submit']",

};
const hasAjaxSubmit = !!getDataAttr($form, "ajax-submit");
// init form validation
const validation = Validation($form, {
onerror: handleInvalidSubmit,
onsuccess: handleValidSubmit,
});
const validationOptions = { onerror: handleInvalidSubmit };
if (hasAjaxSubmit) validationOptions.onsuccess = handleValidSubmit;
const validation = Validation($form, validationOptions);
/**

@@ -50,8 +52,4 @@ * Handle invalid submission attempt (before sending to server)

* Handle valid submit
*
* @param {Event} event
*/
function handleValidSubmit(event) {
event.preventDefault();
function handleValidSubmit() {
onSubmitStart();

@@ -58,0 +56,0 @@

{
"name": "@acanto/core-forms",
"version": "0.0.20",
"version": "0.0.21",
"author": "Acanto <info@acanto.net> (https://acanto.agency/)",

@@ -31,3 +31,3 @@ "license": "ISC",

],
"gitHead": "cf1139977b72cc52ac4d695156b5f0cfd12abb26"
"gitHead": "b16d6ca996dd00482d7499252f13660cf1ea560a"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc