@solid-primitives/mouse
Advanced tools
Comparing version 2.0.4 to 2.0.5
import { Position, MaybeAccessor } from '@solid-primitives/utils'; | ||
import { Accessor } from 'solid-js'; | ||
declare type MouseSourceType = "mouse" | "touch" | null; | ||
declare type MousePosition = Position & { | ||
type MouseSourceType = "mouse" | "touch" | null; | ||
type MousePosition = Position & { | ||
sourceType: MouseSourceType; | ||
}; | ||
declare type MousePositionInside = MousePosition & { | ||
type MousePositionInside = MousePosition & { | ||
isInside: boolean; | ||
@@ -66,3 +66,3 @@ }; | ||
*/ | ||
declare const getPositionToScreen: (_pageX: number, _pageY: number) => Position; | ||
declare const getPositionToScreen: (pageX: number, pageY: number) => Position; | ||
@@ -69,0 +69,0 @@ interface MousePositionOptions extends UseTouchOptions, FollowTouchOptions { |
@@ -42,3 +42,3 @@ import '@solid-primitives/event-listener'; | ||
}; | ||
var getPositionToScreen = (_pageX, _pageY) => DEFAULT_MOUSE_POSITION ; | ||
var getPositionToScreen = () => DEFAULT_MOUSE_POSITION ; | ||
function createMousePosition(target, options = {}) { | ||
@@ -45,0 +45,0 @@ { |
{ | ||
"name": "@solid-primitives/mouse", | ||
"version": "2.0.4", | ||
"version": "2.0.5", | ||
"description": "A collection of Solid Primitives, that capture current mouse cursor position, and help to deal with common related usecases.", | ||
@@ -27,5 +27,12 @@ "author": "Damian Tarnawski <gthetarnav@gmail.com>", | ||
"types": "./dist/index.d.ts", | ||
"browser": { | ||
"./dist/server.js": "./dist/index.js", | ||
"./dist/server.cjs": "./dist/index.cjs" | ||
}, | ||
"exports": { | ||
"worker": { | ||
"import": "./dist/server.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/server.js" | ||
}, | ||
"require": "./dist/server.cjs" | ||
@@ -35,21 +42,39 @@ }, | ||
"development": { | ||
"import": "./dist/dev.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/dev.js" | ||
}, | ||
"require": "./dist/dev.cjs" | ||
}, | ||
"import": "./dist/index.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/index.js" | ||
}, | ||
"require": "./dist/index.cjs" | ||
}, | ||
"deno": { | ||
"import": "./dist/server.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/server.js" | ||
}, | ||
"require": "./dist/server.cjs" | ||
}, | ||
"node": { | ||
"import": "./dist/server.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/server.js" | ||
}, | ||
"require": "./dist/server.cjs" | ||
}, | ||
"development": { | ||
"import": "./dist/dev.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/dev.js" | ||
}, | ||
"require": "./dist/dev.cjs" | ||
}, | ||
"import": "./dist/index.js", | ||
"import": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/index.js" | ||
}, | ||
"require": "./dist/index.cjs" | ||
@@ -68,20 +93,17 @@ }, | ||
"devDependencies": { | ||
"@solid-primitives/raf": "^2.1.4", | ||
"solid-js": "^1.6.0" | ||
"@solid-primitives/raf": "^2.1.5" | ||
}, | ||
"dependencies": { | ||
"@solid-primitives/event-listener": "^2.2.4", | ||
"@solid-primitives/rootless": "^1.2.1", | ||
"@solid-primitives/utils": "^4.0.0" | ||
"@solid-primitives/event-listener": "^2.2.5", | ||
"@solid-primitives/rootless": "^1.2.2", | ||
"@solid-primitives/utils": "^4.0.1" | ||
}, | ||
"browser": { | ||
"./dist/server.cjs": "./dist/index.cjs", | ||
"./dist/server.js": "./dist/index.js" | ||
}, | ||
"peerDependencies": { | ||
"solid-js": "^1.6.0" | ||
}, | ||
"typesVersions": {}, | ||
"scripts": { | ||
"start": "vite serve dev --host", | ||
"dev": "vite serve dev", | ||
"page": "vite build dev", | ||
"build": "jiti ../../scripts/build.ts --ssr --dev", | ||
@@ -88,0 +110,0 @@ "test": "vitest -c ../../configs/vitest.config.ts", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1
35018
734