2000calories / flutter_easy_rich_text

The EasyRichText widget provides an easy way to use RichText.
https://pub.dev/packages/easy_rich_text
MIT License
80 stars 33 forks source link

Web: Safari compatibility #9

Closed HBHXTRA closed 3 years ago

HBHXTRA commented 4 years ago

When I run my code in safari it shows a grey or green canvas with nothing it. Just a container grey or green.

2000calories commented 3 years ago

Can you post your code?

HBHXTRA commented 3 years ago

Sure.

import 'package:easy_rich_text/easy_rich_text.dart'; import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; import 'package:get/get.dart';

class Logo extends StatelessWidget { final Color color; final bool large; const Logo({Key key, this.color, this.large}) : super(key: key);

@override Widget build(BuildContext context) { return Container( child: Hero( tag: 'logo', child: Material( color: Colors.transparent, child: FittedBox( fit: BoxFit.scaleDown, child: EasyRichText( 'T3 by TEST', defaultStyle: Get.textTheme.headline6 .copyWith(color: Get.theme.colorScheme.onSurface), patternList: [ EasyRichTextPattern( targetString: '3', matchWordBoundaries: false, style: TextStyle(color: Get.theme.colorScheme.primary), ), EasyRichTextPattern( subScript: true, targetString: 'by TEST', style: TextStyle(color: Get.textTheme.caption.color), ), ], ), ), ), ), ); } }

Even without Hero

2000calories commented 3 years ago

Hi HBHXTRA, I did not figure it out. Have you tried the built-in RichText widget? Is it works?

HBHXTRA commented 3 years ago

No. I’ll give a try

2000calories commented 3 years ago

Any update?

HBHXTRA commented 3 years ago

Works well with the OOB but with this plugin does not work on safari

On Sat, 12 Dec 2020 at 12:46, hans.huang notifications@github.com wrote:

Any update?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/2000calories/flutter_easy_rich_text/issues/9#issuecomment-743744234, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADVKTCGJVTIAAPBRNOHCE4LSUNJZZANCNFSM4TT34BMA .

2000calories commented 3 years ago

Sorry no idea😂