Skip to content

gillstrom/deku-submenu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

deku-submenu

A simple menu component for Deku

Install

$ npm install --save deku-submenu

Usage

import {Menu, MenuItem, SubMenu} from 'deku-submenu';

const render = () => {
	return (
		<div class='MyMenu'>
			<Menu class='CustomClass'>
				<SubMenu title='National Hockey League'>
					<SubMenu title='Eastern Conference'>
						<MenuItem>New York Rangers</MenuItem>
						<MenuItem>Ottawa Senators</MenuItem>
					</SubMenu>
					<SubMenu title='Western Conference'>
						<MenuItem>Los Angeles Kings</MenuItem>
						<MenuItem>San Jose Sharks</MenuItem>
					</SubMenu>
				</SubMenu>
				<SubMenu title='Swedish Hockey League' active>
					<MenuItem>Frölunda Indians</MenuItem>
					<MenuItem>Växjö Lakers</MenuItem>
				</SubMenu>
				<MenuItem active>Zamboni</MenuItem>
			</Menu>
		</div>
	);
};

export default {render};

License

MIT © Andreas Gillström