Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@goji/core

Package Overview
Dependencies
Maintainers
2
Versions
120
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@goji/core - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

10

dist/cjs/events.js

@@ -25,4 +25,8 @@ "use strict";

triggerEvent(e) {
var _a;
processingEventBeforeDispatch(e);
const { currentTarget, timeStamp } = e;
const { currentTarget, timeStamp, timestamp } = e;
// some events, like 'input' of `textarea`, use `timestamp` instead of `timeStamp`
// https://github.com/airbnb/goji-js/issues/208
const fixedTimeStamp = (_a = timeStamp !== null && timeStamp !== void 0 ? timeStamp : timestamp) !== null && _a !== void 0 ? _a : undefined;
const id = currentTarget.dataset.gojiId;

@@ -35,5 +39,5 @@ const type = (0, camelCase_1.default)(`on-${(e.type || '').toLowerCase()}`);

e.stopPropagation = () => {
instance.stopPropagation(type, timeStamp !== null && timeStamp !== void 0 ? timeStamp : undefined);
instance.stopPropagation(type, fixedTimeStamp);
};
instance.triggerEvent(type, timeStamp !== null && timeStamp !== void 0 ? timeStamp : undefined, e);
instance.triggerEvent(type, fixedTimeStamp, e);
}

@@ -40,0 +44,0 @@ }

@@ -21,4 +21,8 @@ import camelCase from 'lodash/camelCase';

triggerEvent(e) {
var _a;
processingEventBeforeDispatch(e);
const { currentTarget, timeStamp } = e;
const { currentTarget, timeStamp, timestamp } = e;
// some events, like 'input' of `textarea`, use `timestamp` instead of `timeStamp`
// https://github.com/airbnb/goji-js/issues/208
const fixedTimeStamp = (_a = timeStamp !== null && timeStamp !== void 0 ? timeStamp : timestamp) !== null && _a !== void 0 ? _a : undefined;
const id = currentTarget.dataset.gojiId;

@@ -31,5 +35,5 @@ const type = camelCase(`on-${(e.type || '').toLowerCase()}`);

e.stopPropagation = () => {
instance.stopPropagation(type, timeStamp !== null && timeStamp !== void 0 ? timeStamp : undefined);
instance.stopPropagation(type, fixedTimeStamp);
};
instance.triggerEvent(type, timeStamp !== null && timeStamp !== void 0 ? timeStamp : undefined, e);
instance.triggerEvent(type, fixedTimeStamp, e);
}

@@ -36,0 +40,0 @@ }

{
"name": "@goji/core",
"version": "1.2.0",
"version": "1.3.0",
"description": "GojiJS Core",

@@ -55,3 +55,3 @@ "main": "dist/cjs/index.js",

},
"gitHead": "767c49b6394029c27de14b5b5128f0d0396aa9d1"
"gitHead": "17ce8e45566bd0c67c5597368010fe9a4b2eb405"
}

@@ -26,3 +26,8 @@ import camelCase from 'lodash/camelCase';

processingEventBeforeDispatch(e);
const { currentTarget, timeStamp } = e;
const { currentTarget, timeStamp, timestamp } = e;
// some events, like 'input' of `textarea`, use `timestamp` instead of `timeStamp`
// https://github.com/airbnb/goji-js/issues/208
const fixedTimeStamp = timeStamp ?? timestamp ?? undefined;
const id = currentTarget.dataset.gojiId;

@@ -37,6 +42,6 @@ const type = camelCase(`on-${(e.type || '').toLowerCase()}`);

e.stopPropagation = () => {
instance.stopPropagation(type, timeStamp ?? undefined);
instance.stopPropagation(type, fixedTimeStamp);
};
instance.triggerEvent(type, timeStamp ?? undefined, e);
instance.triggerEvent(type, fixedTimeStamp, e);
}

@@ -43,0 +48,0 @@ }

Sorry, the diff of this file is not supported yet

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