Skip to content

White Box if rendered in an ExpansionTile [ only on iOS ] #124

Open
@akramaskar

Description

Hi everyone,

we are using the Echart in an item from a list builder. Each item is an ExpansionTile ( kind of an accordion widget: https://api.flutter.dev/flutter/material/ExpansionTile-class.html) and we got the problem that the chart is only rendered as a white box:

WhatsApp Image 2021-04-22 at 14 48 38

As you can see, when the chart is not in the view from the beginning (probably on initState) it's not getting rendered at all.
Different if we change the behaviour of the ExpansionTile to be expanded from the beginning. In that case, only the cards which are visible in the very beginning is getting rendered:

WhatsApp Image 2021-04-24 at 06 57 57

As far as I understand, the Echart is getting rendered using a Webview is that correct?
Since the webview has a controller object, a possible solution would be to rerender the chart when it's getting expanded (ontap) with something like this:

await _controller.reload();

Is there a way to access the controller or anyone here maybe got another solution for this?

Steps to reproduce:

  1. Create a column
  2. Put many ExpansionTile widgets so that it's filling more of the screen
  3. Put the echart as a children widget
  4. Set the initiallyExpanded to false
  5. Render on ios

Regards

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions