diff --git a/CHANGELOG.md b/CHANGELOG.md
index 23ef150..b5abce3 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,5 @@
+## [2.11.6]
+Potential fix https://github.com/caseyryan/flutter_multi_formatter/issues/114
## [2.11.5]
Added Luhn algorithm to validate card numbers
## [2.11.4]
diff --git a/example/ios/Runner.xcodeproj/project.pbxproj b/example/ios/Runner.xcodeproj/project.pbxproj
index da8244c..3847f4e 100644
--- a/example/ios/Runner.xcodeproj/project.pbxproj
+++ b/example/ios/Runner.xcodeproj/project.pbxproj
@@ -140,6 +140,7 @@
TargetAttributes = {
97C146ED1CF9000F007C117D = {
CreatedOnToolsVersion = 7.3.1;
+ DevelopmentTeam = ZR8BB8SA45;
LastSwiftMigration = 1100;
};
};
@@ -296,6 +297,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ DEVELOPMENT_TEAM = ZR8BB8SA45;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -428,6 +430,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ DEVELOPMENT_TEAM = ZR8BB8SA45;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -455,6 +458,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ DEVELOPMENT_TEAM = ZR8BB8SA45;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
diff --git a/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
new file mode 100644
index 0000000..18d9810
--- /dev/null
+++ b/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
@@ -0,0 +1,8 @@
+
+
+
+
+ IDEDidComputeMac32BitWarning
+
+
+
diff --git a/example/lib/pages/money_format_page.dart b/example/lib/pages/money_format_page.dart
index ed9a803..0996c0a 100644
--- a/example/lib/pages/money_format_page.dart
+++ b/example/lib/pages/money_format_page.dart
@@ -49,7 +49,7 @@ class _MoneyFormatPageState extends State {
),
keyboardType: TextInputType.numberWithOptions(
decimal: true,
- signed: true,
+ // signed: true,
),
inputFormatters: [
CurrencyInputFormatter(
diff --git a/example/pubspec.lock b/example/pubspec.lock
index e168bb8..231ecd2 100644
--- a/example/pubspec.lock
+++ b/example/pubspec.lock
@@ -89,7 +89,7 @@ packages:
path: ".."
relative: true
source: path
- version: "2.11.5"
+ version: "2.11.6"
flutter_test:
dependency: "direct dev"
description: flutter
diff --git a/lib/formatters/currency_input_formatter.dart b/lib/formatters/currency_input_formatter.dart
index a869e63..180dda5 100644
--- a/lib/formatters/currency_input_formatter.dart
+++ b/lib/formatters/currency_input_formatter.dart
@@ -40,7 +40,7 @@ class CurrencySymbols {
static const String EURO_SIGN = '€';
static const String POUND_SIGN = '£';
static const String YEN_SIGN = '¥';
- static const String ETHERIUM_SIGN = 'Ξ';
+ static const String ETHEREUM_SIGN = 'Ξ';
static const String BITCOIN_SIGN = 'Ƀ';
static const String SWISS_FRANK_SIGN = '₣';
static const String RUBLE_SIGN = '₽';
@@ -55,7 +55,7 @@ class CurrencyInputFormatter extends TextInputFormatter {
final int? maxTextLength;
final ValueChanged? onValueChange;
- bool _printDebugInfo = false;
+ bool _printDebugInfo = true;
/// [thousandSeparator] specifies what symbol will be used to separate
/// each block of 3 digits, e.g. [ThousandSeparator.Comma] will format
@@ -67,7 +67,7 @@ class CurrencyInputFormatter extends TextInputFormatter {
/// added in front of the resulting string. E.g. $ or €
/// some of the signs are available via constants like [CurrencySymbols.EURO_SIGN]
/// but you can basically add any string instead of it. The main rule is that the string
- /// must not contain digits, preiods, commas and dashes
+ /// must not contain digits, periods, commas and dashes
/// [trailingSymbol] is the same as leading but this symbol will be added at the
/// end of your resulting string like 1,250€ instead of €1,250
/// [useSymbolPadding] adds a space between the number and trailing / leading symbols
@@ -371,7 +371,12 @@ class CurrencyInputFormatter extends TextInputFormatter {
longerString: newText,
shorterString: oldText,
);
- if (_containsMantissaSeparator(newChars)) {
+
+ /// [hasWrongSeparator] is an attempt to fix this
+ /// https://github.com/caseyryan/flutter_multi_formatter/issues/114
+ /// Not sure if it will have some side effect
+ final hasWrongSeparator = newText.contains(',.');
+ if (_containsMantissaSeparator(newChars) || hasWrongSeparator) {
return true;
}
}
diff --git a/pubspec.yaml b/pubspec.yaml
index 2742ce4..970d05c 100644
--- a/pubspec.yaml
+++ b/pubspec.yaml
@@ -1,6 +1,6 @@
name: flutter_multi_formatter
description: A package of formatters for international phone numbers, credit / debit cards and a masked formatter
-version: 2.11.5
+version: 2.11.6
homepage: https://github.com/caseyryan/flutter_multi_formatter
environment: