Closed longb1997 closed 2 months ago
OverlapWidget
cannot be bigger than the parent view.
I think you should be implementing this the other way around.
The OverlapWidget
is a container in which you can place items. See the docs https://saleksovski.github.io/react-native-android-widget/docs/primitives/overlap-widget
<OverlapWidget style={{ height: 'match_parent', width: 'match_parent' }}>
{hours.map((hour, index) => (
<FlexWidget
style={{
width: 'match_parent',
height: hourHeight,
marginTop: index * hourHeight,
...additionalStyles,
}}
/>
))}
{events.map((event, index) => (
<FlexWidget
style={{
width: widgetWidth / 4,
marginLeft: 20,
marginTop: eventTopOffset,
...additionalStyles,
}}
>
// event info
</FlexWidget>
))}
</OverlapWidget>
or
<OverlapWidget style={{ height: 'match_parent', width: 'match_parent' }}>
<FlexWidget style={{ ... }}>
{hours.map((hour) => (
<FlexWidget
style={{
width: 'match_parent',
height: hourHeight,
...additionalStyles,
}}
/>
))}
</FlexWidget>
{events.map((event, index) => (
<FlexWidget
style={{
width: widgetWidth / 4,
marginTop: eventTopOffset,
...additionalStyles,
}}
>
// event info
</FlexWidget>
))}
</OverlapWidget>
Hi there, i have using OverlapWidget to show a list of items, and each item is an OverlapWidget
I want do something like this:
But my OverlapWidget's height is limited by the parent height, so that means it will be clipped if its height is higher than the parent height.