GithubHelp home page GithubHelp logo

javierbyte / control-user-cursor Goto Github PK

View Code? Open in Web Editor NEW
1.1K 19.0 52.0 354 KB

Small experiment to 'control' the user cursor with JavaScript and CSS.

Home Page: https://javier.xyz/control-user-cursor

License: BSD 3-Clause "New" or "Revised" License

HTML 14.35% JavaScript 63.59% CSS 22.07%
experiment javascript js cursor ui ux

control-user-cursor's Introduction

control-user-cursor's People

Contributors

javierbyte avatar jwilk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

control-user-cursor's Issues

Sluggish

The cursor seems to be a little sluggish though.

Cursor persists on window losing focus

Hi Javierbyte,

Not sure if it's an issue that's worth fixing, but ALT-TAB highlights how you have achieved this ( great work by the way! )

Hitting ALT-TAB shows me the standard DEBIAN black cursor, and slightly offset from that, your white cursor. I guess you could put in a keyhook for that, and hide the extra cursor until the mouse moves again?

If I move my mouse onto another screen then release ALT, it then looks like I have two cursors.

Hope this helps!

David

Real cursor still visible on Firefox Linux

As title; cursor is still visible on Firefox (52.0.2 (64-bit) on Arch Linux).
But works as expected on Chromium on same OS.
Also works correctly on FF and Chrome on Debian.
Clever stuff, I like it πŸ‘

Unmasked by macOS notifications and ⌘β‡₯

In this example I set a notification to fire after 5 seconds. When it does, the true cursor is unmasked and we get two.

I thought this to be related to focus being stolen, but it seems to be stolen in a very particular way.

If we ⌘β‡₯ to another app, we can indeed beat the effect, but the cursor duplication is nothing but a momentary blip.

Anyway, don’t take this as a bug report, as your work is an experiment, but I thought you might like to know some of the limitations/ways to beat it, if you haven’t encountered them already.

Real cursor is a black box

It appears like real cursor is supposed to be invisible. In my case on in Windows on Chrome the real cursor appears like a black box.

for api design

I liked the idea itself, it might be useful on UIs for older people who have problems with clicking on small objects with the mouse. Just add some gravity to the button hah :-)

Noticed on your readme what's your roadmap and would like to suggest to keep in mind that some users will want to use it with ReactJs, Angular or similar, where you do not always have document object (server side render) and document object might be the worst way to select DOM (using virtual DOM framework).

Just plan ahead and write the simple wrapper for DOM selection, which could be replaced by other developers who write JS with some virtual DOM frameworks.

Fun πŸ‘

Cursor is invisible in IE11

In IE11 (Windows 10), mousing over the demo page hides the cursor entirely:
plvud0jl06

http://recordit.co/PLVUD0jl06

Other than that, it seems to work pretty much the same across the 'latest' versions of other Windows browsers.

(Whether or not IE11 still counts as 'latest' these days is up for debate)

Increase gravity

πŸš€
Could be cool of you could increase gravity on elements.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.