diff --git a/src/pages/Experiments/TasksMenuBlock/TasksMenu/DraggableItem/index.js b/src/pages/Experiments/TasksMenuBlock/TasksMenu/DraggableItem/index.js index 2cce43970..b64caa371 100644 --- a/src/pages/Experiments/TasksMenuBlock/TasksMenu/DraggableItem/index.js +++ b/src/pages/Experiments/TasksMenuBlock/TasksMenu/DraggableItem/index.js @@ -2,6 +2,8 @@ import React, { useEffect, useMemo, memo } from 'react'; import PropTypes from 'prop-types'; import { DragSource } from 'react-dnd'; import { getEmptyImage } from 'react-dnd-html5-backend'; +import { LinkOutlined } from '@ant-design/icons'; + import { DragIndicatorComponent } from 'assets'; @@ -11,6 +13,7 @@ const MenuItem = ({ connectDragPreview, children, disabled, + tutorialUrl, }) => { const opacity = useMemo(() => (isDragging ? 0.6 : 1), [isDragging]); @@ -40,6 +43,13 @@ const MenuItem = ({
{children}
+ + {tutorialUrl && +
+ +
+ } + ); }; @@ -50,6 +60,7 @@ MenuItem.propTypes = { connectDragPreview: PropTypes.any, children: PropTypes.node, disabled: PropTypes.bool, + tutorialUrl: PropTypes.string, }; const DraggableItem = DragSource( @@ -88,6 +99,11 @@ DraggableItem.propTypes = { name: PropTypes.string.isRequired, icon: PropTypes.node.isRequired, handleSelect: PropTypes.func.isRequired, + tutorialUrl: PropTypes.string, }; +DraggableItem.defaultProps = { + tutorialUrl: '' +} + export default memo(DraggableItem); diff --git a/src/pages/Experiments/TasksMenuBlock/TasksMenu/index.js b/src/pages/Experiments/TasksMenuBlock/TasksMenu/index.js index c0bdef1a8..35fd6c2ff 100644 --- a/src/pages/Experiments/TasksMenuBlock/TasksMenu/index.js +++ b/src/pages/Experiments/TasksMenuBlock/TasksMenu/index.js @@ -80,6 +80,7 @@ const TasksMenu = ({ disabled={disabled} taskType={taskType} handleSelect={handleSelect} + tutorialUrl= {'https://google.com'} > {renderTooltip(name, description, uuid, title)} diff --git a/src/pages/Experiments/TasksMenuBlock/TasksMenu/style.less b/src/pages/Experiments/TasksMenuBlock/TasksMenu/style.less index d91e38b73..5e195993a 100644 --- a/src/pages/Experiments/TasksMenuBlock/TasksMenu/style.less +++ b/src/pages/Experiments/TasksMenuBlock/TasksMenu/style.less @@ -9,6 +9,14 @@ padding-left: 24px !important; + .icon-url { + position: relative; + } + .link-item-content-icon { + padding-left: 24px; + margin-left: auto; + } + &:active { background-color: transparent; }