Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tooltip disappearing after upgrade from 0.36.4 to 0.55 on dragging #1114

Closed
Sesa1988 opened this issue Aug 5, 2022 · 2 comments
Closed

Tooltip disappearing after upgrade from 0.36.4 to 0.55 on dragging #1114

Sesa1988 opened this issue Aug 5, 2022 · 2 comments
Labels
enhancement New feature or request Fundamental

Comments

@Sesa1988
Copy link

Sesa1988 commented Aug 5, 2022

I have a weird issue on a real device and release mode.

If I drag from left to right pretty fast over my line chart the tooltip is visible for a small amount of time and disappears.
After the second or third drag everything works as expected and the tooltip is following the line without disappearing.
Its laggy as well even on release mode what wasn't on the previous version.

lineTouchData: LineTouchData(
        getTouchLineStart: (barData, index) => -double.infinity,
        getTouchLineEnd: (barData, index) => double.infinity,
        touchTooltipData: LineTouchTooltipData(
          tooltipBgColor: PlatformHelper.isDesktop()
              ? primaryColor.withOpacity(0.8)
              : primaryColor,
          fitInsideHorizontally: true,
          tooltipMargin: PlatformHelper.isDesktop() ? 20 : 0,
          showOnTopOfTheChartBoxArea: PlatformHelper.isDesktop() ? false : true,
          getTooltipItems: (touchedSpots) {
            return touchedSpots
                .map((e) => LineTooltipItem(
                      '${MarketFormat.getMarketChartTooltipPriceString(e.y, selectedCurrency.currency, true)} \n\n ${DateFormat.yMd(Platform.localeName).format(points[e.spotIndex].time.toLocal())} \n ${DateFormat.jm(Platform.localeName).format(points[e.spotIndex].time.toLocal())}',
                      const TextStyle(color: Colors.white, fontSize: 14),
                    ))
                .toList();
          },
        ),
        touchCallback: (LineTouchResponse touchResponse) {},
        handleBuiltInTouches: true,
        getTouchedSpotIndicator: (barData, spotIndexes) {
          return _touchIndicator(
              barData, spotIndexes, primaryColor, scaffoldColor);
        },
      ),

Has someone this issue as well?

@Sesa1988 Sesa1988 changed the title Tooltip disappearing after upgrade from 0.36.4 to 0.55 Tooltip disappearing after upgrade from 0.36.4 to 0.55 on dragging Aug 5, 2022
@Divinoart
Copy link

I had similar issue and dropped a quick solution here

@imaNNeo
Copy link
Owner

imaNNeo commented Jan 26, 2023

Fixed in 0.60.0. Check it out!
You can also follow this thread to learn more about it: #1127

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Fundamental
Projects
None yet
Development

No branches or pull requests

3 participants