downshift-js / downshift
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,7 +293,7 @@
Loading
292 293
        dispatch({
293 294
          type: stateChangeTypes.ItemMouseMove,
294 295
          index,
295 -
          disabled
296 +
          disabled,
296 297
        })
297 298
      }
298 299
      const itemHandleClick = () => {
@@ -300,11 +301,8 @@
Loading
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],
Files Coverage
src 100.00%
Project Totals (18 files) 100.00%

No yaml found.

Create your codecov.yml to customize your Codecov experience

Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading