1.3.1 • Published 4 years ago

@gunawanedy/react-button-slider v1.3.1

Weekly downloads
276
License
MIT
Repository
github
Last release
4 years ago

react-button-slider

Wrap all your buttons or any component in react-button-slider and it will be horizontally scrollable without any scrollbar

Example Example

Installation

npm

npm i @gunawanedy/react-button-slider

yarn

yarn add @gunawanedy/react-button-slider

Example

import React from 'react';

import ReactButtonSlider from '@gunawanedy/react-button-slider';

const App = () => {
  return (
    <>
      <ReactButtonSlider>
        {/*you can add styling for your button*/}
        <button>Category 1</button>
        <button>Category 2</button>
        <button>Category 3</button>
        <button>Category 4</button>
      </ReactButtonSlider>
      <main className="content">
        <h1>Your Contents</h1>
      </main>
    </>
  );
};

export default App;

Props

NameTypeDefaultDescription
Childrenanyany component or element
overscrollTransitionstringtransform .3s cubic-bezier(.25,.8,.5,1)css transition property
dragAccelerationnumber1drag acceleration
1.3.1

4 years ago

1.3.0

4 years ago

1.2.2

4 years ago

1.2.1

4 years ago

1.2.0

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.2

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago