@uploadthing/dropzone
Advanced tools
Comparing version 0.2.2-canary.d04cec4 to 0.2.2-canary.d850078
{ | ||
"name": "@uploadthing/dropzone", | ||
"version": "0.2.2-canary.d04cec4", | ||
"version": "0.2.2-canary.d850078", | ||
"type": "module", | ||
@@ -37,2 +37,12 @@ "license": "MIT", | ||
} | ||
}, | ||
"./svelte": { | ||
"import": { | ||
"types": "./svelte/index.d.ts", | ||
"default": "./svelte/index.js" | ||
}, | ||
"require": { | ||
"types": "./svelte/index.d.cts", | ||
"default": "./svelte/index.cjs" | ||
} | ||
} | ||
@@ -43,3 +53,4 @@ }, | ||
"react", | ||
"solid" | ||
"solid", | ||
"svelte" | ||
], | ||
@@ -64,6 +75,7 @@ "publishConfig": { | ||
"@uploadthing/tsconfig": "0.1.0", | ||
"bunchee": "^4.4.8", | ||
"bunchee": "^5.1.2", | ||
"eslint": "^8.57.0", | ||
"react": "18.2.0", | ||
"solid-js": "^1.8.15", | ||
"svelte": "^4.2.12", | ||
"typescript": "^5.4.2" | ||
@@ -73,3 +85,4 @@ }, | ||
"react": "^16.8.0 || ^17.0.0 || ^18.0.0", | ||
"solid-js": "^1.7.11" | ||
"solid-js": "^1.7.11", | ||
"svelte": "^4.2.12" | ||
}, | ||
@@ -82,2 +95,5 @@ "peerDependenciesMeta": { | ||
"optional": true | ||
}, | ||
"svelte": { | ||
"optional": true | ||
} | ||
@@ -84,0 +100,0 @@ }, |
@@ -41,6 +41,4 @@ import { fromEvent } from 'file-selector'; | ||
const root = rootRef(); | ||
if (root && root.contains(event.target)) { | ||
// If we intercepted an event for our instance, let it propagate down to the instance's onDrop handler | ||
return; | ||
} | ||
// If we intercepted an event for our instance, let it propagate down to the instance's onDrop handler | ||
if (root?.contains(event.target)) return; | ||
event.preventDefault(); | ||
@@ -166,7 +164,5 @@ dragTargets = []; | ||
const onKeyDown = (event)=>{ | ||
const root = rootRef(); | ||
// Ignore keyboard events bubbling up the DOM tree | ||
const root = rootRef(); | ||
if (!root || !root.isEqualNode(event.target)) { | ||
return; | ||
} | ||
if (!root?.isEqualNode(event.target)) return; | ||
if (isEnterOrSpace(event)) { | ||
@@ -173,0 +169,0 @@ event.preventDefault(); |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
83625
17
2064
4
9