-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Andrei Firsov
committed
Oct 10, 2018
1 parent
55aee81
commit 607856b
Showing
13 changed files
with
195 additions
and
279 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import React from 'react'; | ||
|
||
export default (asStory) => { | ||
asStory('MOLECULES/Menu', module, (story, { Menu }) => { | ||
story | ||
.add('with some items', () => ( | ||
<Menu.Plate> | ||
<Menu.Item>Tramman</Menu.Item> | ||
<Menu.Item>Gripman</Menu.Item> | ||
<Menu.Item>Proalliance</Menu.Item> | ||
</Menu.Plate> | ||
)); | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import React from 'react'; | ||
|
||
import { createStyledTag, createTheme } from '../../utils'; | ||
import { Paper } from '../../atoms/'; | ||
|
||
type MenuPlateProps = {| | ||
children?: React$Node, | ||
|}; | ||
|
||
const NAME = 'menuPlate'; | ||
|
||
const theme = createTheme(NAME, {}); | ||
|
||
const StyledTag = createStyledTag(NAME, () => ({ | ||
display: 'flex', | ||
flexDirection: 'column', | ||
boxSizing: 'border-box', | ||
paddingTop: '.8rem', | ||
paddingBottom: '.8rem', | ||
overflow: 'hidden', | ||
})); | ||
|
||
const MenuPlate = ({ children, ...rest }: MenuPlateProps) => ( | ||
<Paper padding="none" borderRadius="all"> | ||
<StyledTag tagName="div" { ...rest } > | ||
{ children } | ||
</StyledTag> | ||
</Paper> | ||
); | ||
|
||
MenuPlate.displayName = 'Menu.Plate'; | ||
|
||
export { MenuPlate, theme }; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
|
||
export { Rating } from './Rating'; | ||
export { ButtonGroup } from './ButtonGroup'; | ||
export { Menu } from './Menu'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
// @flow | ||
|
||
import { theme as buttonGroupTheme } from './ButtonGroup'; | ||
import { theme as menuTheme } from './Menu'; | ||
|
||
export const theme = { | ||
...buttonGroupTheme, | ||
...menuTheme, | ||
}; |
Oops, something went wrong.