-
Hi! How are you? I wanted to ask about how could one create a put_column or put_row object using a list comprehension. The idea is to be able to create a layout based on the contents of a list, for example: fruits = [ {'name': 'apple', 'image' : image_path, .... }]
put_column(
[put_collapse(f['name'],[put_image(f['image'])] ) for f in fruits]
) The result I get is that if I click on one collapse to open it, all of the collapse instances are open (although their text is not desplayed unless I click on their respective collapse). Is there a way to fix this? Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
It seems like a bug. I am working on this. I will leave new comments when there are updates. |
Beta Was this translation helpful? Give feedback.
-
You can add Currently, the default behavior of Now, I don't think the current default behavior makes much sense. I will consider use |
Beta Was this translation helpful? Give feedback.
You can add
size='repeat(auto-fill, auto)'
toput_column()
.Currently, the default behavior of
put_column()
is that all items have same height. So when you expand aput_collapse()
, the height of other widgets also grow.Now, I don't think the current default behavior makes much sense. I will consider use
'repeat(auto-fill, auto)'
as the default value ofsize
input_collapse()
in next version.