Skip to content

Commit 544335f

Browse files
committed
docs: update Readme
1 parent 6cad6e1 commit 544335f

File tree

2 files changed

+30
-25
lines changed

2 files changed

+30
-25
lines changed

README.md

+30-25
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,27 @@
55
![coverage][coverage_badge]
66
![pub points][pub_points_badge]
77

8-
Whatsapp like text formatting for you!!
9-
This supports the input to be formatted with different formatters.
10-
Text style that will support bold, italic and underline text.
11-
12-
i.e.
13-
1. Bold Text will be wrapped in \*asterisk\*
14-
2. Italic Text will be wrapped in \_underscore\_
15-
3. Underline Text will be wrapped in \~tilde\~
16-
4. Bold, Italic and Underline Text will be wrapped in \*asterisk\* \_underscore\_ \~tilt\~
8+
- Make text formatting backend driven (if needed) with one widget!!
9+
- Whatsapp like formatting with some addons!!
10+
(input looks something like this)
11+
12+
🌟 Usage 🌟
13+
BOLD
14+
→ Hello, \*World!*
15+
ITALIC
16+
→ Hello, \_World!_
17+
STRIKETHROUGH
18+
→ Hello, \~World!~
19+
UNDERLINE
20+
→ Hello, //World!//
21+
MONOSPACE
22+
→ Hello, \`World!`
23+
LINK
24+
[google.com|https://google.com]  
1725

1826

1927
### Preview
20-
<img width="488" alt="Screenshot 2022-12-13 at 11 56 28" src="https://user-images.githubusercontent.com/35066779/207242541-c8bfd00e-0b81-47ce-9bf3-b280e3d63162.png">
28+
<img width="488" alt="Screenshot 2022-12-13 at 11 56 28" src="/preview.png">
2129

2230

2331

@@ -41,33 +49,30 @@ flutter packages get
4149
---
4250

4351

44-
Usage
52+
🌟 Usage 🌟
4553

4654
```dart
4755
import 'package:typeset/typeset.dart';
4856
4957
TypeSet(inputText: 'Hello, *World!*');
5058
// returns 'World' with bold text
5159
52-
TypeSet(inputText: 'Hello, _World_!');
60+
TypeSet(inputText: 'Hello, _World!_');
5361
// returns 'World' with italic text
5462
55-
TypeSet(inputText: 'Hello, ~World~!');
56-
// returns 'World' with underline text
63+
TypeSet(inputText: 'Hello, ~World!~');
64+
// returns 'World' with strikethrough text
5765
58-
TypeSet(inputText: '*Hello*, _World_ ~World~!');
59-
// returns 'Hello' with bold text, 'World' with italic text and 'World' with underline text
66+
TypeSet(inputText: 'Hello //World!//');
67+
// returns 'World' with underline text
6068
61-
//TypeSet also has a style property which can be used to style the text
62-
TypeSet(inputText: 'Hello, *World!*', style: TextStyle(color: Colors.red));
63-
// returns 'World' with bold text and red color
69+
TypeSet(inputText: 'Hello, `World!`');
70+
// returns 'World' with monospace text
6471
65-
//OR
72+
TypeSet(inputText: '[google.com|https://google.com]');
73+
// returns 'google.com' with link to google.com
6674
67-
//use the simple extension
68-
'Hello, *World!*'.typeset();
69-
//this also comes with style
70-
'Hello, *World!*'.typeset(style: TextStyle(color: Colors.red,),);
75+
///TypeSet also has every property which the Text.rich() has, so you can configure accordingly
7176
7277
```
7378

@@ -92,7 +97,7 @@ Please file feature requests and bugs at the [issue tracker][tracker].
9297
[tracker]: https://github.com/rohanjsh/typeset/issues
9398
[pub_badge]: https://img.shields.io/pub/v/typeset.svg
9499
[pub_link]: https://pub.dev/packages/typeset
95-
[coverage_badge]: https://img.shields.io/badge/coverage-100%25-green.svg
100+
[coverage_badge]: /coverage_badge.svg
96101
[build_badge]: https://img.shields.io/github/workflow/status/rohanjsh/typeset/ci.svg
97102
[pub_points_badge]: https://img.shields.io/pub/points/typeset
98103

preview.png

339 KB
Loading

0 commit comments

Comments
 (0)