get_children returns empty if nested parent does not have the same "lookup" parameter
Closed this issue · 1 comments
dfguerrerom commented
Assuming we have a nested element called desc_a
that we are aiming to retrieve:
list_ = sw.ListItem(
children=[
v.ListItemContent(
children=[
v.Card(
children=[
v.CardTitle(
children=[
"cm.calculation[indicator].title",
v.Spacer(),
]
),
sw.CardText(
# attributes={"id": f"desc_a"},
children=[
v.Html(
tag="span",
attributes={"id": f"desc_a"},
children=[
"cm.calculation[indicator].desc_active"
],
),
v.Spacer(),
v.Html(
tag="span",
attributes={"id": f"span_b"},
),
]
),
]
)
]
),
]
)
list_.get_children(id_="desc_a") will be empty..
list_.get_children(id_="desc_a")
12rambau commented
that's unrelated. If you add the lookup to CardText the get_children method will only return one single element. The issues lies in the fact that v.Html
are surprisingly NOT v.VuetifyWidget
. I will make a quick patch