Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ie11 / Win7 - upload click does not work #29

Open
mousemke opened this issue Mar 5, 2019 · 4 comments
Open

ie11 / Win7 - upload click does not work #29

mousemke opened this issue Mar 5, 2019 · 4 comments
Labels
help wanted Extra attention is needed needs investigation

Comments

@mousemke
Copy link
Contributor

mousemke commented Mar 5, 2019

this is about the clickable area. it was a button my case, but i was able top reproduce this in the droppable demo site.

drag and drop works fine, but i am unable to click any clickable areas to upload a file.

i actually fixed this in my own project by moving away from droppable (sorry ^^). the fix is that the clickable area needs to be a label linking (htmlFor => id) to the file upload input component. then the click on the button styled label will trigger the native upload input

@mousemke
Copy link
Contributor Author

mousemke commented Mar 5, 2019

ie11 in windows 7, but not ie11 in windows 10. this was also confirmed by the fact that both of these ie11s had different version numbers

@lifenautjoe lifenautjoe added the help wanted Extra attention is needed label Mar 9, 2019
@lifenautjoe
Copy link
Owner

Aha. Will fix this as soon as I can.

Thanks!

@lifenautjoe lifenautjoe added bug Something isn't working and removed bug Something isn't working labels Mar 9, 2019
@lifenautjoe
Copy link
Owner

lifenautjoe commented Mar 9, 2019

Actually, not sure how to fix this.

Introducing an html element dynamically on the website would probably break layout/css of existing webpages.

Will try some things.

@mousemke
Copy link
Contributor Author

mousemke commented Mar 9, 2019

what i ened up doing (button from material ui, but you could just as easily just use a label

      <div
        ref={el => (this.dropTargetField = el)}
        className={`${classes.dropTarget} ${className ? className : ''}`}
      >
        <div className={classes.content}>
          <input
            type="file"
            multiple
            id={`dropTarget-label-button-${dropTargetStrings.length}`}
            className={classes.hiddenInput}
            onChange={e => this.processDroppedFile([...e.target.files])}
          />
          <Button
            label={buttonText}
            fullWidth
            component="label"
            htmlFor={`dropTarget-label-button-${dropTargetStrings.length}`}
            variant={buttonVariant}
          >
            {buttonText}
          </Button>
          {children || null}
        </div>
        <div className={classes.dropMask}>
          <div className={classes.dropMaskText}>
              {dropMaskText}
          </div>
        </div>
      </div>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed needs investigation
Projects
None yet
Development

No branches or pull requests

2 participants