Skip to content

The animation onClick or onHover event does not works #84

@DomV-cloud

Description

@DomV-cloud

I would like to use UseAnimation and icons as well. But animations are played only for non-click or non-hover icons (like activity etc..)

I followed steps for installations.

import React from "react";
import UseAnimations from "react-useanimations";
import github from 'react-useanimations/lib/github';

const App = () => (
  <UseAnimations animation={github} size={56} />
);

So my code looks like this:

import UseAnimations from "react-useanimations";
import menu2 from 'react-useanimations/lib/menu2';

export default function MobileMenu() {
  return (
   
            <UseAnimations
                animation={menu2}
                size={56}
                strokeColor="#B1986B"
                onClick={() => {
                   console.log("icon is clicked");
                  }}
            />
    
  )
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions