2.1.3 • Published 5 months ago

react-custom-cursors v2.1.3

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

React Custom Cursors

Custom cursors for React.

Installation

You can simply install React Custom Cursors either by yarn, npm or pnpm.

yarn

yarn add react-custom-cursors

npm

npm i react-custom-cursors

pnpm

pnpm add react-custom-cursors

Table of Contents

Cursor

Since Cursor component uses react hooks under the hood, you've got to use it inside a function component.

usage: <Cursor {...props} />

import React from "react";
import { Cursor } from "react-custom-cursors";

import "react-custom-cursors/dist/index.css";

function App() {
  /* your codes
   */
  return (
    <div className="app">
      <Cursor />
    </div>
  );
}

export default App;

API

PropTypeDefaultDescription
hasCursorbooleantrueIf true, cursor will be available
colorstring"#f00"It accepts all supported values by css
sizestring"md""xs", "sm", "md", "lg", xl"
speedstring"medium""slow", "medium", "fast"
shapestring"round""round", "triangle", "square", "pentagon", "hexagon", "heptagon", "octagon", "nonagon", "decagon", "star", "frame", "cross", "rhombus"
animationstring"none""none", "spin", "beat"
hoveringAnimationstring"none""none", "magnify"; won't work unless animation is set to "none".
hasDotbooleanfalseif true, dot will be available
dotColorstring"#fff"It accepts all supported values by css
isHollowbooleanfalseif true, the cursor would be hollow (currently for round cursor only)
zIndexnumber9999z-index attribute
mixBlendModebooleantrueif true, mix-blend-mode is set to "difference"

Website

Website

Feedback

If you have any feedback, please don't hesitate to reach out to me at 4rsh4vir4z4rf4r@gmail.com

Authors

License

MIT

2.1.2

5 months ago

2.1.1

5 months ago

2.1.3

5 months ago

2.1.0

5 months ago

2.0.2

12 months ago

2.0.1

12 months ago

2.0.0

12 months ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago