Cretezy / flutter_linkify

Turns text URLs and emails into clickable inline links in text for Flutter
https://pub.dartlang.org/packages/flutter_linkify
MIT License
262 stars 99 forks source link

A weird UI issue on iOS #106

Open 623637646 opened 2 years ago

623637646 commented 2 years ago

Example code:

import 'package:flutter/material.dart';
import 'package:flutter_linkify/flutter_linkify.dart';

void main() => runApp(LinkifyExample());

class LinkifyExample extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      title: 'flutter_linkify example',
      home: Scaffold(
        appBar: AppBar(
          title: Text('flutter_linkify example'),
        ),
        body: Linkify(
          style: const TextStyle(
            fontSize: 13,
          ),
          text:
              "a word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\na word\n\nGoogle :https://www.google.com",
        ),
      ),
    );
  }
}

UI:

Screenshot 2022-04-28 at 9 25 35 PM

Expected: The "Google" text and the link should be on the same line.

This issue only happens on iOS (Simulator + real device). It's good on Web and Android.

My environment: flutter_linkify version: 5.0.2 iOS version: 15+, iPhone 13 pro simulator and iPhone 8 plus real device.