-
Notifications
You must be signed in to change notification settings - Fork 2
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
Change avatar dynamically #2
Comments
In the previous code, props.avatar was not responsive, and in the latest version, I fixed this issue |
Thanks working 100%. How can I reset the image position and zoom when I re-open my component? Like avatar property, is width/height/top/left also dynamic properties, in other words watches? |
Currently, resetting these properties outside of the component is not supported. Width/height/top/left are not dynamic properties. I recommend adding a key to the component and updating the key when these properties need to be recharged. This may result in some performance loss, but there is currently no other way to do so |
Thanks, I am not so clued up with vue. Will apreciate it if you can maybe show me a small sample of how this can be done. |
codesandboxyou can see the demo preview/APP.vue
|
Thanks, 100% working now. You can close this ticket. |
I have a vue 3 app.
I have a data value (Base64 string) that changes dynamically in code.
data:image/png;base64,xxxx
How can I set the avatar property to the base64 string (and nor a url) before the Avatar Editor opens?
Seems that avatar property is only getting set once the component setup.
I have tried:
But even if I change this.selectedAvatar to the new Base64 string, it still does not show
The text was updated successfully, but these errors were encountered: