simple_formatted_text 0.0.1+1 icon indicating copy to clipboard operation
simple_formatted_text: ^0.0.1+1 copied to clipboard

Simple formatted text. Made to be configured with the string, like MD but simplest

Animated switch


Simple text widget to show formated text, including link text
Simple formatted text was made to allow you to customize text style with special chars.

style: lint


Quick Start #

Import this library into your project:

simple_formatted_text: ^latest_version

Or do:

$ flutter pub add simple_formatted_text

Basic Implementation #


SimpleFormattedText("Text with *bold* word")

More possibilities

  • Open URL

      SimpleFormattedText(    
          "Open [Google](https://google.com/) to search things",
          onLinkTap: (link) {
              // .. do stuff, not need to be only web links
              url_launch(link);
          },
      )
    

    Animated switch


  • Text actions, with different text style

      SimpleFormattedText(
          "Do [action 1](action 1) or [action 2](action 2)",
          linkTextStyle: TextStyle(color: Colors.green),
          onLinkTap: (actionStr) {
              switch(actionStr) {
                  case "action 1":
                      //...
                      break;
                  case "action 2":
                      //...
                      break;
              },
          },
      )
    

    Animated switch


  • Change color and size, with an initial textstyle

      SimpleFormattedText(    
          "This is a _[big and red](addSize:4,color:#FFFF0000)_ string",
          style: TextStyle(color: Colors.deepPurple, fontSize: 20),
      )
    

    Animated switch


9
likes
140
pub points
21%
popularity

Publisher

verified publisher iconvazquezmarcos.es

Simple formatted text. Made to be configured with the string, like MD but simplest

Repository (GitHub)

Documentation

API reference

License

Icon for licenses.MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on simple_formatted_text