react-dropzone 14.3.2 → 14.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/es/index.js CHANGED
@@ -701,6 +701,7 @@ export function useDropzone() {
701
701
  dispatch({
702
702
  acceptedFiles: acceptedFiles,
703
703
  fileRejections: fileRejections,
704
+ isDragReject: fileRejections.length > 0,
704
705
  type: "setFiles"
705
706
  });
706
707
 
@@ -898,7 +899,16 @@ export function useDropzone() {
898
899
  multiple: multiple,
899
900
  type: "file",
900
901
  style: {
901
- display: "none"
902
+ border: 0,
903
+ clip: "rect(0, 0, 0, 0)",
904
+ clipPath: "inset(50%)",
905
+ height: "1px",
906
+ margin: "0 -1px -1px 0",
907
+ overflow: "hidden",
908
+ padding: 0,
909
+ position: "absolute",
910
+ width: "1px",
911
+ whiteSpace: "nowrap"
902
912
  },
903
913
  onChange: composeHandler(composeEventHandlers(onChange, onDropCb)),
904
914
  onClick: composeHandler(composeEventHandlers(onClick, onInputElementClick)),
@@ -956,7 +966,8 @@ function reducer(state, action) {
956
966
  case "setFiles":
957
967
  return _objectSpread(_objectSpread({}, state), {}, {
958
968
  acceptedFiles: action.acceptedFiles,
959
- fileRejections: action.fileRejections
969
+ fileRejections: action.fileRejections,
970
+ isDragReject: action.isDragReject
960
971
  });
961
972
 
962
973
  case "reset":