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

rich_editor कवर
पैकेज विवरणv0.5.0

rich_editor

Flutter के लिए एक WYSIWYG संपादक, जिसमें समर्थित प्रारूपण विकल्पों का एक अमूल्य सेट है।

AndroidiOSmacOSWindows
30-दिन डाउनलोड
1 हज़ार
लाइक
93
Pub अंक
150

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

flutter pub add rich_editor

पैकेज अवलोकन

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

Flutter के लिए एक WYSIWYG संपादक जो मजबूत, तिरछा, सूचियाँ, लिंक और अधिक के साथ समृद्ध पाठ स्वरूपण का समर्थन करता है। उन ऐप्स में बिना किसी दिक्कत के एकीकरण के लिए डिज़ाइन किया गया है जिन्हें उन्नत पाठ इनपुट की आवश्यकता होती है, इसमें स्वरूपित सामग्री बनाने के लिए एक साफ और आसान इंटरफ़ेस है। विस्तार के लिए डिज़ाइन किया गया है, इसमें कस्टम स्टाइल और प्लगइन का समर्थन है। पैकेज को सक्रिय रूप से बनाए रखा जा रहा है और यह Android, iOS, macOS और Windows प्लेटफ़ॉर्म पर सभी के लिए सुविधाजनक है।

उपयोग

  • नोट-टेकिंग ऐप्स में रिच टेक्स्ट कंटेंट बनाना
  • ब्लॉग या लेख संपादक बनाना
  • उपयोगकर्ता-उत्पादित सामग्री फॉर्म का कार्यान्वयन
  • सहयोगात्मक दस्तावेज़ उपकरण विकसित करना
  • प्रारूपित संदेश इंटरफ़ेस सक्षम करें

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

  • रियल-टाइम वाईएसआईवाईजी संपादन
  • विस्तृत प्रारूपण विकल्प (बोल्ड, इटैलिक, अंडरलाइन आदि)
  • लिंक, छवि और सूचियों के लिए समर्थन
  • कस्टमाइज़ करने योग्य टूलबार और थीम
  • क्रॉस-प्लेटफॉर्म संगतता

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

  • सामग्री-समृद्ध Flutter एप्लिकेशन बनाने वाले डेवलपर्स
  • उपयोगकर्ता-मित्र टेक्स्ट संपादन की आवश्यकता वाले ऐप्स
  • मार्कडाउन या एचटीएमएल आउटपुट की आवश्यकता वाले प्रोजेक्ट
  • बहु-प्लेटफॉर्म टेक्स्ट संपादक पर काम कर रही टीमें

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

  • जटिल स्टाइलिंग के लिए अतिरिक्त कॉन्फ़िगरेशन की आवश्यकता हो सकती है
  • बड़े दस्तावेज़ों के साथ प्रदर्शन में भिन्नता हो सकती है
  • सीमित आंतरिक छवि अपलोड हैंडलिंग
  • Flutter के रेंडरिंग मॉडल की समझ की आवश्यकता है

मूल README

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

✨ rich_editor

pub package pub points

WYSIWYG editor for Flutter with a rich set of supported formatting options.

Based on https://github.com/dankito/RichTextEditor, but for Flutter.

✨ Features

  • [x] Bold, Italic, Underline, Strike through, Subscript, Superscript
  • [x] Heading 1 - 6, Text body, Preformatted, Block quote
  • [x] Font (reads all system fonts) (Android only)
  • [x] Font Size
  • [x] Text Color
  • [x] Text Background Color
  • [x] Highlight text
  • [x] Justify Left, Center, Right, Blockquote
  • [x] Indent, Outdent
  • [x] Undo, Redo
  • [x] Unordered List (Bullets)
  • [x] Ordered List (Numbers)
  • [x] Insert local or remote Image
  • [x] Insert Link
  • [x] Insert Checkbox
  • [ ] Search
  • [ ] Icon indicators

📸 Screenshots

Usage

      // Insert widget into tree
      RichEditor(
        key: keyEditor,
        value: 'initial html here',
        editorOptions: RichEditorOptions(
          placeholder: 'Start typing',
          // backgroundColor: Colors.blueGrey, // Editor's bg color
          // baseTextColor: Colors.white,
          // editor padding
          padding: EdgeInsets.symmetric(horizontal: 5.0),
          // font name
          baseFontFamily: 'sans-serif',
          // Position of the editing bar (BarPosition.TOP or BarPosition.BOTTOM)
          barPosition: BarPosition.TOP,
        ),
        // You can return a Link (maybe you need to upload the image to your
        // storage before displaying in the editor or you can also use base64
        getImageUrl: (image) {
          String link = 'https://avatars.githubusercontent.com/u/24323581?v=4';
          String base64 = base64Encode(image.readAsBytesSync());
          String base64String = 'data:image/png;base64, $base64';
          return base64String;
        },
      )

Get current HTML from editor

String? html = await keyEditor.currentState?.getHtml();
print(html);

Set Focus and Unfocus

await keyEditor.currentState?.focus();
await keyEditor.currentState?.unFocus();

Clear Editor content

await keyEditor.currentState?.clear();
Custom Toolbar

If you're interested in creating your own toolbar check the custom_toolbar_demo.dart in the example

License

Copyright 2021 JideGuru

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

श्रेणियाँ

निर्भरताएँ

निर्भरता सूची 4 आइटम

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

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