Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | import useCurrentTask from "../../../hooks/playbooks/task/useCurrentTask"; import { unsupportedConnctorTypeOptions } from "../../../utils/playbook/unsupportedConnctorTypeOptions"; import SelectConnectorOption from "../../Playbooks/task/source/SelectConnectorOption"; import SelectTaskType from "./SelectTaskType"; type AddMetricSourcePropTypes = { id: string; }; function AddMetricSource({ id }: AddMetricSourcePropTypes) { const [task] = useCurrentTask(id); Iif (!task) return; return ( <div className="flex flex-col gap-2"> <SelectTaskType id={task.id ?? ""} /> {task.source && !unsupportedConnctorTypeOptions.includes(task?.type ?? "") && ( <div className="flex gap-2 items-center"> <SelectConnectorOption id={task.id} /> </div> )} </div> ); } export default AddMetricSource; |