Flutter on tap not working on Html element view - flutter

The webpage I'm loading contains a HtmlElementView class which will load an URL. And I am having an action in app bar and when I am tapping on a option, It is not responding.
In the reference image the account settings option is clickable because it is outside the HtmlElementView but the others two options are not clickable because it is on top of the HtmlElementView. Help me with an solution for this.

There seems to be no in easy way of dealing with this in flutter.
So the best option is to use pub.dev/packages/pointer_interceptor
Thanks to #Pat9RB for finding this!

Related

Flutter Web: How to keep the navbar?

I have a basic layout for a webapp I'm trying to build with flutter. Basically there is a navbar on the left side of the screen and the content should fill the rest of the page.
Whenever a user clicks a link in the navbar, the content should update accordingly. I have an understanding on how this would work with the "old" Navigator and named routes. However, users need to be able to access certain content directly by url and the url may contain parameters, so do I have to use a Router?
From my (limited) understanding, I have to use MaterialApp.router to use a Router, but this will always redraw the WHOLE page, including the navbar.
Is there an option to update only the content part, without updating the surrounding layout?
Thanks in advance!
Go check out navigationRail in flutter, if that helps.

User gestures and back button are not working when using PageRouteBuilder

to achieve a fade transition I used a PageRouteBuilder()to build some of my routes.
I noticed however while testing the app that the back button on Android and The User gesture on IOS are not working to navigate back to previous route!
Is this the normal behavior of the PageRouteBuilder()? or am I maybe doing something wrong?
thanks a lot!
So as it turned out, in MaterialPageRoute() the PageTransitionBuilder is selected based on which platform the app is running on.
I was able to get it to work for Android by using the WillPopScope() widget, as I was using Nested Navigators.
However, on IOS for the back gesture they are using the private class _CupertinoBackGestureController and I don't think there is an easy way to achieve that at this moment!
Hope that helps whoever is facing the same thing and thanks again!
The popup to back button has nothing to do with PageRouteBuilder, but has something to do with how you are inserting the second page in the stack.
If you are using Navigator.pushNamed(context, <PageRouteBuilder>), this will keep the first page in the stack and the back button should work.
However, If you are using Navigator.pushNamedReplacement(context, <PageRouteBuilder>), it will remove the first page and push the second page to stack.
I'm currently experimenting with wrapping the page to be pushed in a GestureDetector, and then setting one of the onHorizontalDrag properties to pop the route. (I do this within the PageRouteBuilder itself, that way I can just pass in the page like normal when pushing.) This swipedetector package might replace the GestureDetector, or I might even experiment with this swipe_back_detector specifically made for custom routes made with PageRouteBuilder (see example they give).

How to show pages index in side when showing the pdf in uiwebview

In the above image, we can see the navigationbar and pages index(side) which can viewed when the user tapped the screen once and will be removed from superview, on another tap.
I added the navigationbar using tap gesture recogniser, but to show the pages index I didn't know what to do and even how to search in google?
Any help will be appreciated.
Since you have added the uiwebviewtag to your question, I guess you are using a uiwebview to read the pdf.
In this case, there is no way to add a sidebar with the page index.
The only way do it is to develop your own viewer using Quartz, or to use an existing library.

what event listener to add to radio button when page is swiped in Android?

I am working on a page controller application. My logic involves placing custom radio buttons at the bottom of one page.
I would like to create a listener on the radio button when the user swipes the page to move to the next. I am not aware exactly how to do this. I have attached an image to relay my idea.
Any thoughts would be greatly appreciated.
Thanks in advance.
See this example
You have to just go through this example.Its has different type of TabIndicator.So read it and play with it. Hope it help you

Integrate IPhone Safari like view in Android?

The main concept goes like this. I have four listviews with its own
data loaded at the same time. Only one listview will be visible to the
user. Now, when the user presses a button, not only the current
listview but also other three listviews should be minimized and then
user can just scroll just as in Gallery and select the listview that
one wants to open.
I hope you all have understood what I want.
Let me know if someone have some idea of implementing such a User
Interface in Android.
You can use either View.draw() or View.getDrawingCache() depending on what suits you best. Then just display them using Gallery or something similar.