Skip to content

Commit c9f23b0

Browse files
committed
fixes #30: bad type definition for tooltipLabel
1 parent 1215492 commit c9f23b0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-bootstrap-range-slider",
3-
"version": "3.0.5",
3+
"version": "3.0.6",
44
"description": "A range slider component with tooltips for React Bootstrap that extends the HTML input (type=range) element.",
55
"keywords": [
66
"react",

src/RangeSlider.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React, { useCallback, useState, MouseEvent, TouchEvent, ChangeEvent, Ref } from 'react';
1+
import React, { useCallback, useState, MouseEvent, TouchEvent, ChangeEvent, Ref, ReactElement } from 'react';
22
import PropTypes from 'prop-types';
33
import classNames from 'classnames';
44

@@ -62,7 +62,7 @@ interface RangeSliderProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'o
6262
inputProps?: Partial<React.InputHTMLAttributes<HTMLInputElement>>;
6363
tooltip?: 'auto' | 'on' | 'off';
6464
tooltipPlacement?: 'top' | 'bottom';
65-
tooltipLabel?: (value: number) => string;
65+
tooltipLabel?: (value: number) => string | ReactElement;
6666
tooltipStyle?: React.CSSProperties;
6767
tooltipProps?: Partial<React.HTMLAttributes<HTMLDivElement>>;
6868
bsPrefix?: string;

0 commit comments

Comments
 (0)