how to stop font size scaling in embedded browsers like Instagram and Facebook (flutter web)

18 Views Asked by At
return MediaQuery(
      data: MediaQuery.of(context).copyWith(
        textScaler: const TextScaler.linear(
            1.0), //so that the font size doesnot change depending on device font size
      ),
      child: MaterialApp.router(

i used this so that my website is not affected with the user device font size ... and it works just fine on all browsers ... but sadly when i open my flutter website on Facebook or Instagram browsers (when u use ur website url in Facebook and Instagram) it changes the websites font size and it disregards (textScaler: const TextScaler.linear(1.0))

i tried using

currenttextScaler=MediaQuery.of(context).textScaler;

and currenttextScaler was always equal to no scaling despite my website text font size changing so maybe there is some way else we can by pass this facebook instgram embedded browsers problem.

0

There are 0 best solutions below