Closed N0tExisting closed 2 years ago
Ah, the idea was that the default styles would only be applied if class
were not provided. However, the assignment of the class isn't there and I need to add a slot.
I didn't realize that svelte doesn't recognize classes assigned to components. I'll switch it over to a slot
. The default styles on the component were just meant to be a standin.
In the meantime, use the action.
<div use:filedrop={options} on:filedrop={(e) => {files = e.detail.files}}></div>
Switching it to a label
is causing an issue with the action, which erroneously assumes the container is a div or some other element that doesn't propagate click to the input.
Thank you for the pr. Your changes have been published.
Currently the component height is hardcoded at
200px
which is anoying as it is way to high for my purposes and might be to small for other people.I've made a PR (#3)