downshift-js / downshift

Compare 78ce9e9 ... +0 ... 6bd18eb

Showing 1 of 2 files from the diff.

@@ -266,6 +266,7 @@
Loading
266 266
      refKey = 'ref',
267 267
      ref,
268 268
      onMouseMove,
269 +
      onMouseDown,
269 270
      onClick,
270 271
      onPress,
271 272
      disabled,
@@ -292,19 +293,16 @@
Loading
292 293
        dispatch({
293 294
          type: stateChangeTypes.ItemMouseMove,
294 295
          index,
295 -
          disabled
296 +
          disabled,
296 297
        })
297 298
      }
298 299
      const itemHandleClick = () => {
299 300
        dispatch({
300 301
          type: stateChangeTypes.ItemClick,
301 302
          index,
302 303
        })
303 -
304 -
        if (inputRef.current) {
305 -
          inputRef.current.focus()
306 -
        }
307 304
      }
305 +
      const itemHandleMouseDown = e => e.preventDefault()
308 306
309 307
      return {
310 308
        [refKey]: handleRefs(ref, itemNode => {
@@ -322,8 +320,9 @@
Loading
322 320
            itemHandleClick,
323 321
          ),
324 322
        }),
325 -
          onMouseMove: callAllEventHandlers(onMouseMove, itemHandleMouseMove),
326 -
          ...rest,
323 +
        onMouseMove: callAllEventHandlers(onMouseMove, itemHandleMouseMove),
324 +
        onMouseDown: callAllEventHandlers(onMouseDown, itemHandleMouseDown),
325 +
        ...rest,
327 326
      }
328 327
    },
329 328
    [dispatch, latest, shouldScrollRef, elementIds],

Everything is accounted for!

No changes detected that need to be reviewed.
What changes does Codecov check for?
Lines, not adjusted in diff, that have changed coverage data.
Files that introduced coverage data that had none before.
Files that have missing coverage data that once were tracked.
Files Coverage
src 100.00%
Project Totals (18 files) 100.00%
Loading