When calling clear() on UIFileupload, I expected the placeholder to be cleared as well.
Use case:
I want an upload button that
always displays "Upload", and not the name of the selected file
possible to select the same file twice in a row
The latter can be solved with clear() today, but it appears that the only way I can reset the placeholder today is by setting this.$refs.upload.hasSelection = false, but that's dirty and undocumented.
With this patch, I can call clear() in the change or input event handler, and both 1 and 2 are satisfied.
When calling
clear()
onUIFileupload
, I expected the placeholder to be cleared as well.Use case: I want an upload button that
The latter can be solved with
clear()
today, but it appears that the only way I can reset the placeholder today is by settingthis.$refs.upload.hasSelection = false
, but that's dirty and undocumented.With this patch, I can call
clear()
in thechange
orinput
event handler, and both 1 and 2 are satisfied.