Initial commit
This commit is contained in:
18
node_modules/react-select/lib/utils/blockEvent.js
generated
vendored
Normal file
18
node_modules/react-select/lib/utils/blockEvent.js
generated
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
exports.default = function (event) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
if (event.target.tagName !== 'A' || !('href' in event.target)) {
|
||||
return;
|
||||
}
|
||||
if (event.target.target) {
|
||||
window.open(event.target.href, event.target.target);
|
||||
} else {
|
||||
window.location.href = event.target.href;
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user