Skip to content
This repository was archived by the owner on Mar 8, 2023. It is now read-only.

Commit e456c2d

Browse files
committed
Fixes #116
Signed-off-by: soupette <cyril.lpz@gmail.com>
1 parent 092bd6c commit e456c2d

File tree

1 file changed

+11
-2
lines changed
  • packages/buffetjs-core/src/components/TimePicker

1 file changed

+11
-2
lines changed

packages/buffetjs-core/src/components/TimePicker/index.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,13 @@
44
*
55
*/
66

7-
import React, { useEffect, useState, useRef, useMemo } from 'react';
7+
import React, {
8+
useCallback,
9+
useEffect,
10+
useState,
11+
useRef,
12+
useMemo,
13+
} from 'react';
814
import { isInteger, toNumber } from 'lodash';
915
import PropTypes from 'prop-types';
1016

@@ -232,6 +238,8 @@ function TimePicker(props) {
232238
updateTime(target.value);
233239
};
234240

241+
const handleChangeRadio = useCallback(() => {}, []);
242+
235243
const formatInputValue = time => {
236244
if (!seconds) {
237245
setInputVal(short(time));
@@ -277,7 +285,8 @@ function TimePicker(props) {
277285
<li key={option.value} ref={listRefs[option.value]}>
278286
<input
279287
type="radio"
280-
onChange={handleClick}
288+
onChange={handleChangeRadio}
289+
onClick={handleClick}
281290
value={option.value}
282291
id={option.value}
283292
name="time"

0 commit comments

Comments
 (0)