A Flutter package to make your text selectable for web and non-selectable for native builds.

Last update: Jun 9, 2022

PlatformText

A Flutter package to make your text selectable for web and non-selectable for native builds.

pipeline status coverage report latest release

Features

PlatformText returns Text or SelectableText widget depending on the platform it's running on.

Getting started

Follow official installation guide. see more...

Usage

PlatformText supports two constructors/widget classes: Text and SelectableText.

To migrate existing code just replace Text/SelectableText widget with PlatformText.

PlatformText('Hello mom!');
PlatformText.rich(
  TextSpan(
    text: 'Hello',
    children: <TextSpan>[
      TextSpan(
        text: ' beautiful ',
        style: TextStyle(fontStyle: FontStyle.italic),
      ),
      TextSpan(
        text: 'mom!',
        style: TextStyle(fontWeight: FontWeight.bold),
      ),
    ],
  ),
);

Support

If you like my package you can buy me a coffee.

buymeacoffee.com/rozpo.dev

Additional information

  • Package maintainer: Piotr Rozpończyk rozpo.dev
  • Technical writer: Dawid Ratusz
  • Bug reporting: issues
  • Source code: gitlab

GitHub

https://github.com/rozpo/platform_text
You might also like...

Grad text package - A Flutter Widget to draw gradients into text

Grad text package - A Flutter Widget to draw gradients into text

grad_text A Flutter Widget to draw gradients into text.(Null safe) Demo Install

Jan 31, 2022

Flutter native ads - Show AdMob Native Ads use PlatformView

Flutter native ads - Show AdMob Native Ads use PlatformView

flutter_native_ads Flutter plugin for AdMob Native Ads. Compatible with Android and iOS using PlatformView. Android iOS Getting Started Android Androi

May 25, 2022

react-native native module for In App Purchase.

react-native native module for In App Purchase.

Documentation Published in website. Announcement Version 8.0.0 is currently in release candidate. The module is completely rewritten with Kotlin and S

Jun 29, 2022

dna, dart native access. A lightweight dart to native super channel plugin

dna, dart native access. A lightweight dart to native super channel plugin, You can use it to invoke any native code directly in contextual and chained dart code.

Jul 22, 2021

Easy-to-make native ads in flutter using AdMOB SDK.

native_admob_flutter Easy-to-make ads in Flutter with Google's AdMob SDK. English | Português Get started To get started with Native Ads for Flutter,

May 2, 2022

Learn to make beautiful, native apps for Android & iOS

Learn to make beautiful, native apps for Android & iOS

name title subtitle description speaker flutter Flutter Learn to make beautiful, native apps for Android & iOS Flutter is a cross-platform, mobile dev

Nov 4, 2019

Detectable text field - Flutter Text widgets with detection features

Detectable text field - Flutter Text widgets with detection features

detectable_text_field Text widgets with detection features. You can detect hasht

Feb 2, 2022

Utils and widgets to make your flutter apps and websites fully responsive.

Utils and widgets to make your flutter apps and websites fully responsive.

Super Responsive A responsive library for Flutter that is easy to use and easy to read makes your app look great on all devices makes your app more re

Mar 18, 2022

Related

Masked text field - A flutter package for masked text field for formet your text and good UI
Masked text field - A flutter package for masked text field for formet your text and good UI

Masked Text Field Masked Text Field Features A package for masked text field for

May 27, 2022
This is a flutter app which uses the Bitrise Api(https://api-docs.bitrise.io/) to show the bitrise projects and builds and lets you download your artifacts.
This is a flutter app which uses the Bitrise Api(https://api-docs.bitrise.io/) to show the bitrise projects and builds and lets you download your artifacts.

Bitrise Artifact Downloader Introduction ??‍♂️ This is a flutter app which uses the Bitrise Api(https://api-docs.bitrise.io/) to show the bitrise proj

Apr 30, 2021
Flutter's compute function made available for all non-Flutter Dart programs

compute Flutter's compute function made available for all non-Flutter Dart programs The compute package takes Flutter's compute function and makes it

Mar 31, 2022
Meal-App-flutter - Meal App builds with flutter
Meal-App-flutter - Meal App builds with flutter

Meal App - flutter In our complete chat app. I create a nice clean archetecture

Feb 2, 2022
Flutter package that provide selectable items in list like Column
Flutter package that provide selectable items in list like Column

vertical_picker vertical_picker is flutter package that you can use it as item selector. users with this package be able to select item that is in ver

Jun 17, 2022
Selectable Circle where colors can be customized and a child widget can be defined
Selectable Circle where colors can be customized and a child widget can be defined

selectable_circle A Flutter package for an Circle that can be Selected with animation. How to use SelectableCircle( width: 80.0, onSelected: (

Sep 29, 2021
Let's create a selectable Flutter Navigation Drawer with routing that highlights the current item within the Flutter Sidebar Menu.
Let's create a selectable Flutter Navigation Drawer with routing that highlights the current item within the Flutter Sidebar Menu.

Flutter Tutorial - Sidebar Menu & Selectable Navigation Drawer Let's create a selectable Flutter Navigation Drawer with routing that highlights the cu

Mar 7, 2022
An Instagram like text editor Flutter widget that helps you to change your text style.
An Instagram like text editor Flutter widget that helps you to change your text style.

TextEditor An instagram like text editor widget for flutter Show some ❤️ and star the repo to support the project Features Edit TextStyle object font

Jun 21, 2022
A text field that displays text on different languages based on your selection.

translatable_text_field A text field that displays text on different languages based on your selection. Its basic idea is that you place this fields i

Mar 13, 2022
how to Integrating facebook audience network to flutter app for banner, interstitial, rewarded, native and native banner

fb_ads_flutter_12 A new Flutter project. Getting Started Watch the complite tutorial for integrating Facebook ads into the Flutter app in our Youtube

Feb 12, 2022