@aedawes/component-library
v1.0.16
Published
This is a library of components that I have created for use in my projects. The components are written in React and are designed to be reusable and customizable. The library includes components for common UI elements such as buttons, forms, and modals.
Downloads
1,127
Readme
Component Library
This is a library of components that I have created for use in my projects. The components are written in React and are designed to be reusable and customizable. The library includes components for common UI elements such as buttons, forms, and modals.
Installation
To install the library, run the following command:
npm i @aedawes/component-library
Components
Navbar
The Navbar component is a simple navigation bar that can be customized with different links and styles. It includes a Brand name, and a list of links. It is fully responsive across screen sizes and can be easily customized with CSS. It also includes an animated drawer for mobile and tablet sized devices rather than a traditional navbar.
Navbar props:
brand
: The name of the brand or website given as a string.routes
: An array of objects containing the text and URL for each route in the navbar.
Example usage:
import React from 'react';
import Navbar from '@aedawes/component-library/dist/components/Navbar/Navbar';
export default function App() {
const routes = [
{ path: '/home', name: 'Home' },
{ path: '/about', name: 'About' },
{ path: '/contact', name: 'Contact' }
];
return (
<Navbar brandName="My Website" routes={routes} />
);
}
Note: For updating CSS properties, use the developer tools to inspect the elements and find the appropriate class names to override.