I’m making a Facebook or Instagram-esque quiz app where posts are created at runtime. This is fine with the cloning blocks, however when there are interactive components such as upvote, downvote, etc., I can’t reference or make changes to the specific clone.
I know that there’s something coming soon where the properties of components can be copied, but are there any workarounds for now?
I was just going to post a thing similar to yours:
I’d like to clone entire rows or columns that have multiple buttons and label inside but I don’t think that it’s possible to have a reference to them in any way right now unless you copy and position alla of them one by one, which is not that crazy now that I think about it, but it’s way more work that there would be needed with for example a name component block,
Here’s the ending comment on a problem I’m having that would have made me use way many blocks.
@renren66, Can you describe in some more detail what problems you are having with referencing or making changes to a specific clone? You should be able to change or reference the properties of a clone by using the appropriate blocks in the Any Component drawer, i.e. these blocks:
Perhaps I am misunderstand the problem that you are having, though.
This is the basic layout of the post. For example, what I want to do is to change the value of the label between the upvote and downvote buttons when the user clicks the corresponding button. However, as you can imagine, if there are multiple clones, I cannot reference the specific label to be changed.
I do know the workaround where the background picture/colour is referenced. But when the user clicks the upvote button, there is still no way reference the label next to it to make changes.
I think it’s unnecessarily technical and confusing to talk about UUIDs. I would prefer to think of it as the clone block actually returning the cloned component (or a reference to the component, if you want to get technical).
And just to be clear, while the clone block does use UUIDs, that should be considered an implementation detail and, in principle, could change.
and I’m also thinking about taking the ‘cloning pattern’ from an online database, so the name of the labels, the bgr picture, will be taken from there.
Update: my database idea is working, super cool.
Next I’ll face what happens when a button is pressed, but I think I have it figured out.
Right now (off topic I kno) I really need some help understanding how to secure the firebase database and then I’ll be a very happy thunker