पैकेज, रिपॉज़िटरी और ऐप श्रेणियाँ खोजें

hashtagable कवर
पैकेज विवरणv2.3.0+1

hashtagable

हैशटैग सजाए गए पाठ को लागू करने के लिए विजेट्स और कार्यक्रम। `#` से शुरू होने वाले शब्दों को ट्विटर की तरह सजाता है।

30-दिन डाउनलोड
151
लाइक
136
Pub अंक
70

पैकेज इंस्टॉल करें

flutter pub add hashtagable

पैकेज अवलोकन

सार्वजनिक जानकारी से बना चयन मार्गदर्शन। केवल संदर्भ हेतु।

एक फ्लटर पैकेज जो हैशटैग-सजाए गए टेक्स्ट के निर्माण की अनुमति देता है, जैसे ट्विटर के स्टाइलिंग में होता है। यह विशेष उपकरण और उपयोगिता कार्यों को प्रदान करता है जो स्वचालित रूप से '#' प्रतीक से शुरू होने वाले शब्दों की पहचान करते हैं और उन्हें स्टाइल करते हैं, जिससे सोशल मीडिया-आधारित टेक्स्ट प्रदर्शन में सुधार होता है। उपयोगकर्ता द्वारा उत्पन्न सामग्री में बातचीत या दृश्य रूप से अलग हैशटैग की आवश्यकता वाले ऐप्स के लिए आदर्श है। पैकेज को एक सरल कमांड के माध्यम से आसानी से एकीकृत किया जा सकता है और यह ओपन-सोर्स है, GitHub पर स्थापित है। वर्तमान में कोई प्लेटफॉर्म-विशिष्ट सीमाएँ नहीं हैं, लेकिन उन्नत स्टाइलिंग की आवश्यकता के लिए अतिरिक्त कस्टमाइजेशन की आवश्यकता हो सकती है।

उपयोग

  • सोशल मीडिया ऐप फीड्स
  • उपयोगकर्ता टिप्पणी अनुभाग
  • हैशटैग ट्रैकिंग इंटरफेस
  • इंटरैक्टिव टेक्स्ट इनपुट फ़ील्ड्स
  • सामग्री टैगिंग प्रणाली

मुख्य विशेषताएँ

  • स्वचालित हैशटैग डिटेक्शन
  • ट्विटर-शैली हैशटैग स्टाइलिंग
  • कस्टमाइज़ किए जा सकने वाले सजावट विकल्प
  • pub के माध्यम से सरल एकीकरण
  • ओपन-सोर्स कोडबेस

इनके लिए उपयुक्त

  • सोशल प्लेटफॉर्म बनाने वाले डेवलपर्स
  • उपयोगकर्ता-उत्पादित सामग्री वाले ऐप
  • मेटाडेटा हाइलाइटिंग के साथ टेक्स्ट रेंडरिंग
  • दृश्य टैग अंतर की आवश्यकता वाले उपयोगकर्ता इंटरफेस
  • हल्के टेक्स्ट डेकोरेशन का उपयोग करने वाले प्रोजेक्ट

विचार योग्य बातें

  • मूल टैग स्टाइलिंग तक सीमित
  • टैप पर कोई बिल्ट-इन नेविगेशन नहीं है
  • किन्हीं किनारे के मामलों के लिए कस्टम हैंडलिंग की आवश्यकता हो सकती है
  • बाहरी GitHub भंडार पर निर्भर करता है
  • स्रोत कोड के अलावा कोई आधिकारिक डॉक्यूमेंटेशन नहीं

मूल README

संबंधित सोर्स रिपॉज़िटरी के मूल README का स्नैपशॉट। नवीनतम सामग्री के लिए रिपॉज़िटरी देखें।

All Contributors

hashtagable

test pub package License: MIT

Widgets and functions to implement hashTag decorated text.

Detects the words start with # like a Twitter.

RPReplay_Final1599932903

Usage

  • As TextField

You can use HashTagTextField to decorate input text.

    HashTagTextField(
    decoratedStyle: TextStyle(fontSize: 14, color: Colors.blue),
    basicStyle: TextStyle(fontSize: 14, color: Colors.black),
    ),

decoratedStyle is the textStyle of tagged text. basicStyle is for untagged text.

Other arguments are basically same as those of material TextField

  • As ReadOnlyText

If you want to decorate the text only to display, HashTagText will help you.

    HashTagText(
        text: "#Welcome to #hashtagable \n This is #ReadOnlyText",
        decoratedStyle: TextStyle(fontSize: 22,color:Colors.red),
        basicStyle: TextStyle(fontSize: 22,color:Colors.black),
        onTap: (text) {
          print(text);
        },
    )

The argument onTap(String) is called when user tapped a hashTag.

You can add some actions in this callback with the tapped hashTag.

Customize with useful functions

  • Check if the text has hashTags
   print(hasHashtags("Hello #World")); 
   // true
   
   print(hasHashtags("Hello World"));
   // false
   
  • Extract hashTags from text
   final List<String> hashTags = extractHashTags("#Hello World #Flutter Dart #Thank you");
   // ["#Hello", "#Flutter", "#Thank"]

Tips

  • DetectableTextField is published as a refinement of this package. hashtagale forces you to use hashtag, but this one allows you to detect anything you want.

  • If you also want to decorate At sign, you can do that by adding the argument decorateAtSign: true.

    HashTagText(
        text: "#Hello World @flutter_developers",
        decoratedStyle: TextStyle(fontSize: 14,color:Colors.red),
        basicStyle: TextStyle(fontSize: 14,color:Colors.black),
        onTap: (text) {
          print(text);
        },
        decorateAtSign: true,
    )

Then HashTagText and HashtagTextField come to decorate the words start with # or @.

  • The decoration rules are almost same as twitter. It does not decorate the tags which contain emoji or symbol. It needs space before # (or @) to decorate.
  • Supported Languages are English, Japanese, Korean, Spanish, Arabic, Thai, Norwegian and German.

If you have any requests or questions, please feel free to ask on github.


Contributors: Santa Takahashi, Matheus Perez, Marcel Schneider, Ho Kim, Burak

Contributors ✨

Thanks goes to these wonderful people (emoji key):

JorisObert
JorisObert

💻

This project follows the all-contributors specification. Contributions of any kind welcome!

श्रेणियाँ

सोर्स रिपॉज़िटरी

इस पैकेज का उपयोग करने वाले प्रोजेक्ट

अभी कोई डेटा उपलब्ध नहीं है।