From 7c2a406727539173c6c445d956b4129730d44a6b Mon Sep 17 00:00:00 2001 From: CatHood0 Date: Tue, 20 Aug 2024 07:54:36 -0400 Subject: [PATCH] Release 1.1.3 --- CHANGELOG.md | 7 +++++++ README.md | 34 +++++++++++++++++----------------- pubspec.yaml | 2 +- 3 files changed, 25 insertions(+), 18 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 719608e..1b4fc0e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## 1.1.3 + +* Chore: deprecated `removeEmptyWordsOnTokenize` and `removeAllEmptyWords` since are useless +* Chore: deprecated `LanguageDicPriorityOrder` and it was replaced by `StrategyLanguageSearchOrder` +* Fix: `italian` contains not used english words +* Feat: added more words for `Deutsch` and `Spanish` dictionaries + ## 1.1.2 * Fix: bad state after close controllers diff --git a/README.md b/README.md index fb682d1..5112002 100644 --- a/README.md +++ b/README.md @@ -10,18 +10,18 @@ - **Customizable Error Handling**: Optionally use custom gesture recognizers for wrong words, enabling custom interactions. - **Stream-based State Management**: Provides a stream of updates for spell-checking states, allowing reactive UI updates. -## Current languages supported by default (more will be added in future releases) +## Current languages supported (more languages will be added in future releases) The package already have a default list of words for these languages: -* German - de -* English - en -* Spanish - es -* French - fr -* Italian - it -* Norwegian - no -* Portuguese - pt -* Swedish - sv +* German - `de` +* English - `en` +* Spanish - `es` +* French - `fr` +* Italian - `it` +* Norwegian - `no` +* Portuguese - `pt` +* Swedish - `sv` ## Getting Started @@ -55,7 +55,6 @@ Use the `check()` method to analyze a `String` for spelling errors: ```dart List? result = spellChecker.check( 'Your text here', - removeEmptyWordsOnTokenize: true, ); ``` @@ -130,6 +129,7 @@ When you add a custom language you will need to call `registerLanguage()` and pa ### Customization Options * **checkBuilder**: Use the checkBuilder() method for a custom widget-based approach to handling spelling errors. +* **setNewStrategy**: Use the setNewStrategy() method to modify the current value to change the behvarior if the dictionary is reloaded. * **customLongPressRecognizerOnWrongSpan**: Attach custom gesture recognizers to wrong words for tailored interactions. ### Caching @@ -151,7 +151,7 @@ _Note: this functions let us dispose the controllers using `disposeControllers() ```dart late StreamSubscription subscription; -subscription = SimpleSpellChecker(language: '') +subscription = spellChecker .checkStream( 'Your text here', removeEmptyWordsOnTokenize: true, @@ -166,12 +166,12 @@ or ```dart late StreamSubscription subscription; -subscription = SimpleSpellChecker(language: '').checkBuilderStream( - 'Your text here', - builder: (word, isWrong) { - return Text(word, style: TextStyle(color: isWrong ? Colors.red : null)); - }, - removeEmptyWordsOnTokenize: true, +subscription = spellChecker + .checkBuilderStream( + 'Your text here', + builder: (word, isWrong) { + return Text(word, style: TextStyle(color: isWrong ? Colors.red : null)); + }, ).listen( (List data) {}, ); diff --git a/pubspec.yaml b/pubspec.yaml index 5040b2d..a83bf02 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: simple_spell_checker description: "A simple and powerful spell checker, allowing developers to detect and highlight spelling errors in text" -version: 1.1.2 +version: 1.1.3 homepage: https://github.com/CatHood0/simple_spell_checker/ issue_tracker: https://github.com/CatHood0/simple_spell_checker/issues documentation: https://github.com/CatHood0/simple_spell_checker