Skip to content

Commit

Permalink
Added a hint for tasks targets
Browse files Browse the repository at this point in the history
  • Loading branch information
c0rv4x committed Oct 22, 2018
1 parent 061ce9e commit 6e3d0d9
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions app/src/common/tasks_buttons/components/ButtonTasks.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import _ from 'lodash'
import React from 'react'
import { Dropdown } from 'semantic-ui-react';
import { Dropdown, Icon, Popup } from 'semantic-ui-react';

import InnerModal from './InnerModal.jsx'

Expand Down Expand Up @@ -45,14 +45,24 @@ class ButtonsTasks extends React.Component {

render() {
var i = -1;
const items = this.props.tasks.map((task) => {
let items = [
<Dropdown.Item key="task_hint" >
<Popup
on="hover"
content="Tasks will be launched against all targets, which correspond to the filter you specified"
trigger={<span>Specify targets<Icon name="question" /></span>}
>
</Popup>
</Dropdown.Item>
]
items = items.concat(this.props.tasks.map((task) => {
i++;
return (
<Dropdown.Item key={i} onClick={() => { this.change_current_task(task)}} >
{task.name}
</Dropdown.Item>
)
});
}));

return (
<span>
Expand Down

0 comments on commit 6e3d0d9

Please sign in to comment.