import React from "react"; // hooks import useEstimateOption from "hooks/use-estimate-option"; // ui import { CustomSelect } from "components/ui"; // icons import { PlayIcon } from "@heroicons/react/24/outline"; type Props = { value: number | null; onChange: (val: number | null) => void; disabled?: boolean; }; export const SidebarEstimateSelect: React.FC = ({ value, onChange, disabled = false }) => { const { isEstimateActive, estimatePoints } = useEstimateOption(); if (!isEstimateActive) return null; return ( {estimatePoints?.find((e) => e.key === value)?.value ?? "No estimate"} } onChange={onChange} disabled={disabled} > <> None {estimatePoints && estimatePoints.map((point) => ( <> {point.value} ))} ); };