You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On the linked demo the uppy dashboard loads with the the option {disabled: true}. If you click the button labeled 'Update the props object passed to uppy-dashboard' angular will update the object being passed to the '[props]' attribute of <uppy-dashboard> This can be seen by 'Props are' text being updated.
Expected behavior
I would expect updates to the [props] attribute of <uppy-dashboard> to be picked up; and for the new value of {disabled: false} to enable interactivity.
Actual behavior
The dashboard remains disabled.
As a workaround I've found that you can set the options directly as via an uppy.setOptions(); call. Passing in what are fundamentally dashboard options to the uppy object itself is very much Illegal according to the documented apis & types. But it does seem to work. This behavior can be seen by first pressing the 'Update the props object passed to uppy-dashboard' button to update the properties and then pressing the 'Directly apply the props via object call' to preform the workaround.
The text was updated successfully, but these errors were encountered:
bdirito
changed the title
@uppy/angular does not seem to be picking up changes to [props] attribute
@uppy/angular does not seem to be picking up changes to [props] attribute for <uppy-dashboard>
Apr 10, 2024
I would expect updates to the [props] attribute of <uppy-dashboard> to be picked up; and for the new value of {disabled: false} to enable interactivity.
Interestingly, the value is picked up, you can see if you replace the uppy.setOptions with
Then it works the same as calling uppy.setOptions(). The bug seems to be that Dashboard (and maybe other UI components are also affected) does not re-render when setOptions is called. On the Uppy class, some custom logic was added to take this behavior into account, maybe we should do the same on Dashboard/UIPlugin:
Initial checklist
Link to runnable example
https://stackblitz.com/edit/uppy-demo-ajunvm?file=src%2Fapp.component.ts
Steps to reproduce
On the linked demo the uppy dashboard loads with the the option
{disabled: true}
. If you click the button labeled 'Update the props object passed to uppy-dashboard' angular will update the object being passed to the '[props]' attribute of<uppy-dashboard>
This can be seen by 'Props are' text being updated.Expected behavior
I would expect updates to the
[props]
attribute of<uppy-dashboard>
to be picked up; and for the new value of{disabled: false}
to enable interactivity.Actual behavior
The dashboard remains disabled.
As a workaround I've found that you can set the options directly as via an
uppy.setOptions();
call. Passing in what are fundamentally dashboard options to theuppy
object itself is very much Illegal according to the documented apis & types. But it does seem to work. This behavior can be seen by first pressing the 'Update the props object passed to uppy-dashboard' button to update the properties and then pressing the 'Directly apply the props via object call' to preform the workaround.The text was updated successfully, but these errors were encountered: