0.0.8 • Published 1 year ago
pablo-components v0.0.8
pablo-components
A library of reusable UI components for React.js and TypeScript projects. Installation
To install the library, run:
npm install pablo-components
Usage
To use a component, import it from the library and render it in your React.js application:
import { Button } from 'pablo-components';
function App() {
return (
<Button onClick={() => alert('Hello!')}>Click me!</Button>
);
}
You can customize the appearance of the Button component using the type and size props:
import { Button } from 'pablo-components';
function App() {
return (
<div>
<Button type="primary" size="small">Small primary button</Button>
<Button type="danger">Danger button</Button>
<Button type="transparent" size="large">Large transparent button</Button>
</div>
);
}
Available Components
- Button
- Modal
- Loader
A simple button component with customizable type and size.
Props:
onClick: function to be called when the button is clicked
children: content of the button (required)
type: type of the button (optional, defaults to "primary")
size: size of the button (optional, defaults to "medium")
Browsers support
IE / Edge | Firefox | Chrome | Safari | Opera |
---|---|---|---|---|
IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions |
Contributing
Contributions to the library are welcome! To contribute, please fork the repository and submit a pull request. License
This library is licensed under the MIT License.