import React from "react"; import { connect } from "react-redux"; // Here we import the rc-slider class just to get it's type. // We expect the Typescript compiler to not actually include this in the bundle. import RcSlider from "rc-slider"; // @ts-ignore import SliderComponent from "rc-slider/lib/Slider"; import { setPlaylistScrollPosition } from "../../actionCreators"; import { getVisibleTrackIds, getPlaylistScrollPosition } from "../../selectors"; import { AppState, Dispatch } from "../../types"; // Here we inform TypeScript to use the default export's type for our partial import. const Slider = SliderComponent as typeof RcSlider; interface StateProps { playlistScrollPosition: number; allTracksAreVisible: boolean; } interface DispatchProps { setPlaylistScrollPosition: (value: number) => void; } const Handle = () =>
; const ScrollBar = (props: StateProps & DispatchProps) => (