Socket
Book a DemoInstallSign in
Socket

@mmgj/react-invisibutton

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mmgj/react-invisibutton

Accessible and invisible wrapper element.

latest
Source
npmnpm
Version
1.0.2
Version published
Weekly downloads
1
-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

@mmgj/react-invisibutton

Accessible yet invisible wrapper for blinged out clickables

Wraps a DOM element in <button> tags stripped of all visible styles.

Install

  npm i @mmgj/react-invisibutton

or

  yarn add @mmgj/react-invisibutton

Usage

  import InvisiButton from '@mmgj/react-invisibutton';
  ...

  <InvisiButton onClick={clickHandler}>
    <div style={{ /* Crazy stuff here */}}> Click me!</div>
  </InvisiButton>

Props

PropTypeDefaultDescription
onClickfunc() => false;Click handler
childrennode*required*Any renderable element
styleobject{}Styles for the button element
type'button', 'submit' or 'reset''button'Override the button type
className'string'''Additional classes for button element 1

1 The button element ships with the class name invisibutton__reset by default. I really hope this isn't your favorite class name.

FAQs

Package last updated on 04 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts