-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: change flags name to lowercase in flags api #149
Conversation
🦋 Changeset detectedLatest commit: 5a821e8 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Bundle Size Report
|
🟢 No Change | 🗑 File Deleted | 🆕 New File | 📈 Size Increased | 👍 Size Reduced |
---|
Parsed (kb) | |||||
---|---|---|---|---|---|
🚦 | File Name | Base | PR | Diff | % |
📈 | cjs/index.js |
146.22 |
147.04 |
|
0.56 |
📈 | esm/index.min.js |
52.8 |
53.32 |
|
0.98 |
📈 | umd/index.js |
166.76 |
167.81 |
|
0.63 |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #149 +/- ##
=======================================
Coverage 96.52% 96.53%
=======================================
Files 48 48
Lines 662 663 +1
Branches 162 162
=======================================
+ Hits 639 640 +1
Misses 23 23 ☔ View full report in Codecov by Sentry. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
@@ -662,7 +662,7 @@ | |||
"SGD": { | |||
"name": "Singapore Dollar", | |||
"minor_unit": "2", | |||
"symbol": "$" | |||
"symbol": "S$" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't change this right now.
This first needs to be consistent with all apis.. formatNumber, formatNumberByParts.. and others
packages/i18nify-js/src/modules/phoneNumber/data/phoneFormatterMapper.json
Outdated
Show resolved
Hide resolved
"FW": "^\\+590\\s\\d{2}\\s\\d{2}\\s\\d{2}\\s\\d{2}$", | ||
"YT-UNF": "^(?:\\+262)?\\d{9}$", | ||
"TF": "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What happens in empty string regex ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Below are all the utilities that use this and their behaviours in such cases.
For such cases:
-
isValidPhoneNumber
- For phoneNumber = '', countryCode = 'UM', isValidPhoneNumber(phoneNumber, countryCode) returns false
- For phoneNumber = '7394926646', countryCode = 'UM', isValidPhoneNumber(phoneNumber, countryCode) returns true
- For phoneNumber = '+917394926646', countryCode = 'UM', isValidPhoneNumber(phoneNumber, countryCode) returns true
-
detectCountryAndDialCodeFromPhone
- no changes
Description
This PR changes the country codes to lower case in flags api.
Changes Made
List the main changes made in this pull request.
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Additional Notes
Any additional information that would be helpful for the reviewer.
Checklist:
Reviewer Checklist
PR Title Format
Format:
<type>: <subject>
Types can be as follows:
feat
: (new feature for the user, not a new feature for build script)fix
: (bug fix for the user, not a fix to a build script)docs
: (changes to the documentation)style
: (formatting, missing semi colons, etc; no production code change)refactor
: (refactoring production code, eg. renaming a variable)test
: (adding missing tests, refactoring tests; no production code change)chore
: (updating grunt tasks etc; no production code change)