Get Started
Components
Dev Tools
More Guides
Divider
A Divider component is a simple UI element used to separate content within a layout, creating visual distinction between sections. It helps enhance the organization and readability of the interface by providing clear boundaries between different elements, such as text blocks, images, or other components. Dividers can be styled in various ways (solid, dashed, or dotted) and can vary in thickness and color to match the overall design of the application.
# Demo
Horizontal:
Vertical:
# Attributes
Name | Type | Default | Details |
---|---|---|---|
className | string | ' ' | You can customise by passing tailwind classes. |
orientation | vertical | horizontal | horizontal | You can pass divider orientation. |
# Usage
import { NDivider } from 'nayan';
const Divider = () => {
return (
<div>
<h1 className="text-text mb-3 text-lg">Horizontal:</h1>
<NDivider className="my-3" />
<h1 className="text-text mb-3 text-lg">Vertical:</h1>
<NDivider orientation="vertical" className="h-5" />
</div>
);
};
export default Divider;
# Tags