https://github.com/chasefleming/react-override-ui
https://github.com/chasefleming/react-override-ui
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/chasefleming/react-override-ui
- Owner: chasefleming
- Created: 2019-05-06T14:11:34.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-05-17T00:30:51.000Z (about 7 years ago)
- Last Synced: 2025-07-07T01:02:42.875Z (about 1 year ago)
- Language: JavaScript
- Size: 555 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# react-override-ui
The goal of this library is to have a set of components that are:
* Easy to install via NPM
* Easy to override
Current UI components:
* **Modal**
* **Icon** (Uses font awesome icons. Not all icons are added. You may need to make a PR to add the ones you want if they don't exist)
* **Dropdown**
* **Menu** (only "lined" type currently supported)
In all components, you can pass an `options` object to override CSS.
For example:
```
const override = {
"borderBottom": "2px solid purple"
};
```
## Modal Example
```
import { Modal } from "react-override-ui";
this.onModalClose()}>
Modal Content Here
```
## Icon Example
```
import { Icon } from "react-override-ui";
```
## Dropdown Example
```
import { Dropdown } from "react-override-ui";
const dropdownItems = [
{
text: "Link",
icon: "link", // Icons not necessary, but are supported as menu items
clickHandler: () => // do something
},
{
text: "Preview",
icon: "eye",
clickHandler: () => // do something
}
];
{this.props.dropdownItems.map((item, index) => (
))}
```
## Menu Example
```
import { Menu } from "react-override-ui";
const menuOptions = {
type: "lined",
override: {
"borderBottom": "2px solid purple" // not necessary (example only)
}
};
{menuItemOptions.map((item, index) => (
this.setNavTab(item.url)}
/>
))}
```
## Card Example
```
import { Card } from "react-override-ui";
Card Header
Card Content
```