import React from 'react';
export interface DividerProps {
/** Divider orientation - horizontal separates vertical content, vertical separates horizontal content */
orientation?: 'horizontal' | 'vertical';
/** Stroke weight - controls visual thickness */
weight?: 'thin' | 'regular' | 'strong';
/** Color variant - gray (default), base for high contrast (adapts to theme), green for brand emphasis */
color?: 'gray' | 'base' | 'green';
/** Additional CSS classes */
className?: string;
/** Whether the divider is purely decorative (hides from screen readers) */
decorative?: boolean;
}
/**
* BDS Divider Component
*
* A visual separator component following the XRPL Brand Design System.
* Provides clear visual separation between sections, elements, or content groups.
*
* @example
* // Horizontal divider (default)
*
*
* // Vertical divider between columns
*
*
* // Strong green divider for emphasis
*
*
* // Thin base divider (high contrast - adapts to theme)
*
*/
export const Divider: React.FC = ({
orientation = 'horizontal',
weight = 'regular',
color = 'gray',
className = '',
decorative = true,
}) => {
// Build class names using BEM with bds namespace
const classNames = [
'bds-divider',
`bds-divider--${orientation}`,
`bds-divider--${weight}`,
`bds-divider--${color}`,
className,
]
.filter(Boolean)
.join(' ');
return (
);
};
export default Divider;