-
Notifications
You must be signed in to change notification settings - Fork 2
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
1 parent
6c328ec
commit afe954d
Showing
7 changed files
with
70 additions
and
6 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
27 changes: 27 additions & 0 deletions
27
src/main/resources/src/js/saiku/components/Dropdown/Dropdown.jsx
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,27 @@ | ||
'use strict'; | ||
|
||
var React = require('react'); | ||
var DropdownItem = require('./DropdownItem'); | ||
|
||
var Dropdown = React.createClass({ | ||
render: function() { | ||
var item = this.props.item; | ||
var dropdownItem; | ||
|
||
if (item && item.dropdown) { | ||
dropdownItem = item.dropdown.item.map(function(item) { | ||
return <li className={!item.visible ? 'hide' : ''}><a href={item.action}>{item.name}</a></li>; | ||
}); | ||
} | ||
|
||
return ( | ||
<ul id={item.drop} data-dropdown-content className="f-dropdown" aria-hidden="true"> | ||
{item.dropdown.item.map(function(item) { | ||
return <li className={!item.visible ? 'hide' : ''}><a href={item.action}>{item.name}</a></li>; | ||
})} | ||
</ul> | ||
); | ||
} | ||
}); | ||
|
||
module.exports = Dropdown; |
Empty file.
3 changes: 3 additions & 0 deletions
3
src/main/resources/src/js/saiku/components/Dropdown/README.md
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,3 @@ | ||
# react-dropdown | ||
|
||
Add options here. |
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
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