pixel-react 1.15.13 → 1.15.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (304) hide show
  1. package/README.md +75 -75
  2. package/lib/_virtual/index10.js +2 -2
  3. package/lib/_virtual/index11.js +2 -2
  4. package/lib/_virtual/index12.js +2 -2
  5. package/lib/_virtual/index9.js +2 -2
  6. package/lib/assets/icons/navigate_to_pages.svg.js +6 -0
  7. package/lib/assets/icons/navigate_to_pages.svg.js.map +1 -0
  8. package/lib/assets/icons/spinner.svg.js +1 -1
  9. package/lib/assets/icons/spinner.svg.js.map +1 -1
  10. package/lib/components/Accordion/Accordion.d.ts +1 -1
  11. package/lib/components/Accordion/Accordion.js +5 -3
  12. package/lib/components/Accordion/Accordion.js.map +1 -1
  13. package/lib/components/Accordion/types.d.ts +1 -0
  14. package/lib/components/Editor/VariableDropdown.js +2 -2
  15. package/lib/components/Icon/iconList.js +2 -0
  16. package/lib/components/Icon/iconList.js.map +1 -1
  17. package/lib/components/InputWithDropdown/InputWithDropdown.js +4 -3
  18. package/lib/components/InputWithDropdown/InputWithDropdown.js.map +1 -1
  19. package/lib/index.cjs +9901 -3778
  20. package/lib/index.cjs.map +1 -1
  21. package/lib/index.d.ts +3 -2
  22. package/lib/node_modules/@date-fns/tz/date/index.js +1 -19
  23. package/lib/node_modules/@date-fns/tz/date/index.js.map +1 -1
  24. package/lib/node_modules/@date-fns/tz/date/mini.js +34 -6
  25. package/lib/node_modules/@date-fns/tz/date/mini.js.map +1 -1
  26. package/lib/node_modules/@date-fns/tz/tzName/index.js +40 -0
  27. package/lib/node_modules/@date-fns/tz/tzName/index.js.map +1 -0
  28. package/lib/node_modules/@date-fns/tz/tzOffset/index.js +6 -5
  29. package/lib/node_modules/@date-fns/tz/tzOffset/index.js.map +1 -1
  30. package/lib/node_modules/@monaco-editor/loader/lib/es/_virtual/_rollupPluginBabelHelpers.js +93 -98
  31. package/lib/node_modules/@monaco-editor/loader/lib/es/_virtual/_rollupPluginBabelHelpers.js.map +1 -1
  32. package/lib/node_modules/@monaco-editor/loader/lib/es/config/index.js +1 -1
  33. package/lib/node_modules/@monaco-editor/loader/lib/es/config/index.js.map +1 -1
  34. package/lib/node_modules/@monaco-editor/loader/lib/es/loader/index.js +15 -13
  35. package/lib/node_modules/@monaco-editor/loader/lib/es/loader/index.js.map +1 -1
  36. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/compose.js.map +1 -1
  37. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/curry.js.map +1 -1
  38. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/deepMerge.js.map +1 -1
  39. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/isObject.js.map +1 -1
  40. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/makeCancelable.js +1 -0
  41. package/lib/node_modules/@monaco-editor/loader/lib/es/utils/makeCancelable.js.map +1 -1
  42. package/lib/node_modules/@monaco-editor/loader/lib/es/validators/index.js +1 -2
  43. package/lib/node_modules/@monaco-editor/loader/lib/es/validators/index.js.map +1 -1
  44. package/lib/node_modules/janus-gateway/npm/dist/janus.es.js +26 -57
  45. package/lib/node_modules/janus-gateway/npm/dist/janus.es.js.map +1 -1
  46. package/lib/node_modules/js-beautify/js/src/css/beautifier.js +1 -1
  47. package/lib/node_modules/js-beautify/js/src/css/index.js +1 -1
  48. package/lib/node_modules/js-beautify/js/src/css/options.js +1 -1
  49. package/lib/node_modules/js-beautify/js/src/html/index.js +1 -1
  50. package/lib/node_modules/js-beautify/js/src/html/options.js +1 -1
  51. package/lib/node_modules/js-beautify/js/src/html/tokenizer.js +1 -1
  52. package/lib/node_modules/js-beautify/js/src/javascript/beautifier.js +1 -1
  53. package/lib/node_modules/js-beautify/js/src/javascript/index.js +1 -1
  54. package/lib/node_modules/js-beautify/js/src/javascript/options.js +1 -1
  55. package/lib/node_modules/js-beautify/js/src/javascript/tokenizer.js +1 -1
  56. package/lib/node_modules/jsencrypt/lib/JSEncrypt.js +246 -0
  57. package/lib/node_modules/jsencrypt/lib/JSEncrypt.js.map +1 -0
  58. package/lib/node_modules/jsencrypt/lib/JSEncryptRSAKey.js +325 -0
  59. package/lib/node_modules/jsencrypt/lib/JSEncryptRSAKey.js.map +1 -0
  60. package/lib/node_modules/jsencrypt/lib/index.js +6 -0
  61. package/lib/node_modules/jsencrypt/lib/index.js.map +1 -0
  62. package/lib/node_modules/jsencrypt/lib/lib/asn1js/asn1.js +570 -0
  63. package/lib/node_modules/jsencrypt/lib/lib/asn1js/asn1.js.map +1 -0
  64. package/lib/node_modules/jsencrypt/lib/lib/asn1js/base64.js +88 -0
  65. package/lib/node_modules/jsencrypt/lib/lib/asn1js/base64.js.map +1 -0
  66. package/lib/node_modules/jsencrypt/lib/lib/asn1js/hex.js +66 -0
  67. package/lib/node_modules/jsencrypt/lib/lib/asn1js/hex.js.map +1 -0
  68. package/lib/node_modules/jsencrypt/lib/lib/asn1js/int10.js +87 -0
  69. package/lib/node_modules/jsencrypt/lib/lib/asn1js/int10.js.map +1 -0
  70. package/lib/node_modules/jsencrypt/lib/lib/jsbn/base64.js +65 -0
  71. package/lib/node_modules/jsencrypt/lib/lib/jsbn/base64.js.map +1 -0
  72. package/lib/node_modules/jsencrypt/lib/lib/jsbn/jsbn.js +1700 -0
  73. package/lib/node_modules/jsencrypt/lib/lib/jsbn/jsbn.js.map +1 -0
  74. package/lib/node_modules/jsencrypt/lib/lib/jsbn/prng4.js +48 -0
  75. package/lib/node_modules/jsencrypt/lib/lib/jsbn/prng4.js.map +1 -0
  76. package/lib/node_modules/jsencrypt/lib/lib/jsbn/rng.js +77 -0
  77. package/lib/node_modules/jsencrypt/lib/lib/jsbn/rng.js.map +1 -0
  78. package/lib/node_modules/jsencrypt/lib/lib/jsbn/rsa.js +415 -0
  79. package/lib/node_modules/jsencrypt/lib/lib/jsbn/rsa.js.map +1 -0
  80. package/lib/node_modules/jsencrypt/lib/lib/jsbn/sha256.js +307 -0
  81. package/lib/node_modules/jsencrypt/lib/lib/jsbn/sha256.js.map +1 -0
  82. package/lib/node_modules/jsencrypt/lib/lib/jsbn/util.js +61 -0
  83. package/lib/node_modules/jsencrypt/lib/lib/jsbn/util.js.map +1 -0
  84. package/lib/node_modules/jsencrypt/lib/lib/jsrsasign/asn1-1.0.js +1559 -0
  85. package/lib/node_modules/jsencrypt/lib/lib/jsrsasign/asn1-1.0.js.map +1 -0
  86. package/lib/node_modules/libphonenumber-js/es6/AsYouType.js +115 -82
  87. package/lib/node_modules/libphonenumber-js/es6/AsYouType.js.map +1 -1
  88. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.js +68 -58
  89. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.js.map +1 -1
  90. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.js +36 -23
  91. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.js.map +1 -1
  92. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.js +13 -9
  93. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.js.map +1 -1
  94. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.js +226 -187
  95. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.js.map +1 -1
  96. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.js +21 -27
  97. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.js.map +1 -1
  98. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeParser.js +150 -117
  99. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeParser.js.map +1 -1
  100. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeState.js +57 -38
  101. package/lib/node_modules/libphonenumber-js/es6/AsYouTypeState.js.map +1 -1
  102. package/lib/node_modules/libphonenumber-js/es6/ParseError.js +70 -109
  103. package/lib/node_modules/libphonenumber-js/es6/ParseError.js.map +1 -1
  104. package/lib/node_modules/libphonenumber-js/es6/PhoneNumber.js +72 -57
  105. package/lib/node_modules/libphonenumber-js/es6/PhoneNumber.js.map +1 -1
  106. package/lib/node_modules/libphonenumber-js/es6/constants.js +15 -9
  107. package/lib/node_modules/libphonenumber-js/es6/constants.js.map +1 -1
  108. package/lib/node_modules/libphonenumber-js/es6/format.js +67 -93
  109. package/lib/node_modules/libphonenumber-js/es6/format.js.map +1 -1
  110. package/lib/node_modules/libphonenumber-js/es6/formatIncompletePhoneNumber.js +0 -1
  111. package/lib/node_modules/libphonenumber-js/es6/formatIncompletePhoneNumber.js.map +1 -1
  112. package/lib/node_modules/libphonenumber-js/es6/getCountries.js.map +1 -1
  113. package/lib/node_modules/libphonenumber-js/es6/helpers/RFC3966.js +0 -1
  114. package/lib/node_modules/libphonenumber-js/es6/helpers/RFC3966.js.map +1 -1
  115. package/lib/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.js +1 -1
  116. package/lib/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.js.map +1 -1
  117. package/lib/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.js +49 -10
  118. package/lib/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.js.map +1 -1
  119. package/lib/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js +20 -32
  120. package/lib/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js.map +1 -1
  121. package/lib/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js +5 -4
  122. package/lib/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js.map +1 -1
  123. package/lib/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js +25 -18
  124. package/lib/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js.map +1 -1
  125. package/lib/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js +12 -11
  126. package/lib/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map +1 -1
  127. package/lib/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js +13 -11
  128. package/lib/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js.map +1 -1
  129. package/lib/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js +21 -11
  130. package/lib/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js.map +1 -1
  131. package/lib/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js +12 -11
  132. package/lib/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js.map +1 -1
  133. package/lib/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.js +15 -12
  134. package/lib/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.js.map +1 -1
  135. package/lib/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.js +1 -1
  136. package/lib/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.js.map +1 -1
  137. package/lib/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js +4 -4
  138. package/lib/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js.map +1 -1
  139. package/lib/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js +59 -35
  140. package/lib/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js.map +1 -1
  141. package/lib/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js +2 -2
  142. package/lib/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js.map +1 -1
  143. package/lib/node_modules/libphonenumber-js/es6/helpers/getNumberType.js +38 -36
  144. package/lib/node_modules/libphonenumber-js/es6/helpers/getNumberType.js.map +1 -1
  145. package/lib/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.js +0 -1
  146. package/lib/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.js.map +1 -1
  147. package/lib/node_modules/libphonenumber-js/es6/helpers/isObject.js.map +1 -1
  148. package/lib/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js +14 -10
  149. package/lib/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js.map +1 -1
  150. package/lib/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js +4 -4
  151. package/lib/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js.map +1 -1
  152. package/lib/node_modules/libphonenumber-js/es6/helpers/parseDigits.js +22 -27
  153. package/lib/node_modules/libphonenumber-js/es6/helpers/parseDigits.js.map +1 -1
  154. package/lib/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js +6 -6
  155. package/lib/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js.map +1 -1
  156. package/lib/node_modules/libphonenumber-js/es6/isPossible.js +6 -7
  157. package/lib/node_modules/libphonenumber-js/es6/isPossible.js.map +1 -1
  158. package/lib/node_modules/libphonenumber-js/es6/isValid.js +6 -5
  159. package/lib/node_modules/libphonenumber-js/es6/isValid.js.map +1 -1
  160. package/lib/node_modules/libphonenumber-js/es6/isValidPhoneNumber.js +44 -26
  161. package/lib/node_modules/libphonenumber-js/es6/isValidPhoneNumber.js.map +1 -1
  162. package/lib/node_modules/libphonenumber-js/es6/metadata.js +120 -69
  163. package/lib/node_modules/libphonenumber-js/es6/metadata.js.map +1 -1
  164. package/lib/node_modules/libphonenumber-js/es6/normalizeArguments.js +87 -68
  165. package/lib/node_modules/libphonenumber-js/es6/normalizeArguments.js.map +1 -1
  166. package/lib/node_modules/libphonenumber-js/es6/parse.js +58 -40
  167. package/lib/node_modules/libphonenumber-js/es6/parse.js.map +1 -1
  168. package/lib/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js +32 -36
  169. package/lib/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js.map +1 -1
  170. package/lib/node_modules/libphonenumber-js/es6/parsePhoneNumber.js.map +1 -1
  171. package/lib/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.js +44 -26
  172. package/lib/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.js.map +1 -1
  173. package/lib/node_modules/libphonenumber-js/es6/parsePhoneNumber_.js +46 -28
  174. package/lib/node_modules/libphonenumber-js/es6/parsePhoneNumber_.js.map +1 -1
  175. package/lib/node_modules/libphonenumber-js/es6/tools/semver-compare.js.map +1 -1
  176. package/lib/node_modules/libphonenumber-js/metadata.min.json.js +19 -19
  177. package/lib/node_modules/libphonenumber-js/metadata.min.json.js.map +1 -1
  178. package/lib/node_modules/prop-types/index.js +1 -1
  179. package/lib/node_modules/react-day-picker/dist/esm/DayPicker.js +88 -64
  180. package/lib/node_modules/react-day-picker/dist/esm/DayPicker.js.map +1 -1
  181. package/lib/node_modules/react-day-picker/dist/esm/UI.js.map +1 -1
  182. package/lib/node_modules/react-day-picker/dist/esm/classes/CalendarDay.js.map +1 -1
  183. package/lib/node_modules/react-day-picker/dist/esm/classes/CalendarMonth.js.map +1 -1
  184. package/lib/node_modules/react-day-picker/dist/esm/classes/CalendarWeek.js.map +1 -1
  185. package/lib/node_modules/react-day-picker/dist/esm/classes/DateLib.js +71 -6
  186. package/lib/node_modules/react-day-picker/dist/esm/classes/DateLib.js.map +1 -1
  187. package/lib/node_modules/react-day-picker/dist/esm/components/Button.js.map +1 -1
  188. package/lib/node_modules/react-day-picker/dist/esm/components/CaptionLabel.js.map +1 -1
  189. package/lib/node_modules/react-day-picker/dist/esm/components/Chevron.js +18 -14
  190. package/lib/node_modules/react-day-picker/dist/esm/components/Chevron.js.map +1 -1
  191. package/lib/node_modules/react-day-picker/dist/esm/components/Day.js.map +1 -1
  192. package/lib/node_modules/react-day-picker/dist/esm/components/DayButton.js.map +1 -1
  193. package/lib/node_modules/react-day-picker/dist/esm/components/Dropdown.js.map +1 -1
  194. package/lib/node_modules/react-day-picker/dist/esm/components/DropdownNav.js.map +1 -1
  195. package/lib/node_modules/react-day-picker/dist/esm/components/Footer.js.map +1 -1
  196. package/lib/node_modules/react-day-picker/dist/esm/components/Month.js.map +1 -1
  197. package/lib/node_modules/react-day-picker/dist/esm/components/MonthCaption.js.map +1 -1
  198. package/lib/node_modules/react-day-picker/dist/esm/components/MonthGrid.js.map +1 -1
  199. package/lib/node_modules/react-day-picker/dist/esm/components/Months.js.map +1 -1
  200. package/lib/node_modules/react-day-picker/dist/esm/components/MonthsDropdown.js.map +1 -1
  201. package/lib/node_modules/react-day-picker/dist/esm/components/Nav.js.map +1 -1
  202. package/lib/node_modules/react-day-picker/dist/esm/components/NextMonthButton.js.map +1 -1
  203. package/lib/node_modules/react-day-picker/dist/esm/components/Option.js.map +1 -1
  204. package/lib/node_modules/react-day-picker/dist/esm/components/PreviousMonthButton.js.map +1 -1
  205. package/lib/node_modules/react-day-picker/dist/esm/components/Root.js.map +1 -1
  206. package/lib/node_modules/react-day-picker/dist/esm/components/Select.js.map +1 -1
  207. package/lib/node_modules/react-day-picker/dist/esm/components/Week.js.map +1 -1
  208. package/lib/node_modules/react-day-picker/dist/esm/components/WeekNumber.js.map +1 -1
  209. package/lib/node_modules/react-day-picker/dist/esm/components/WeekNumberHeader.js.map +1 -1
  210. package/lib/node_modules/react-day-picker/dist/esm/components/Weekday.js.map +1 -1
  211. package/lib/node_modules/react-day-picker/dist/esm/components/Weekdays.js.map +1 -1
  212. package/lib/node_modules/react-day-picker/dist/esm/components/Weeks.js.map +1 -1
  213. package/lib/node_modules/react-day-picker/dist/esm/components/YearsDropdown.js.map +1 -1
  214. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatCaption.js +3 -2
  215. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatCaption.js.map +1 -1
  216. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatDay.js.map +1 -1
  217. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatMonthDropdown.js.map +1 -1
  218. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumber.js.map +1 -1
  219. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumberHeader.js.map +1 -1
  220. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatWeekdayName.js.map +1 -1
  221. package/lib/node_modules/react-day-picker/dist/esm/formatters/formatYearDropdown.js.map +1 -1
  222. package/lib/node_modules/react-day-picker/dist/esm/formatters/index.js +1 -1
  223. package/lib/node_modules/react-day-picker/dist/esm/helpers/calculateFocusTarget.js.map +1 -1
  224. package/lib/node_modules/react-day-picker/dist/esm/helpers/createGetModifiers.js.map +1 -1
  225. package/lib/node_modules/react-day-picker/dist/esm/helpers/endOfBroadcastWeek.js.map +1 -1
  226. package/lib/node_modules/react-day-picker/dist/esm/helpers/getBroadcastWeeksInMonth.js.map +1 -1
  227. package/lib/node_modules/react-day-picker/dist/esm/helpers/getClassNamesForModifiers.js.map +1 -1
  228. package/lib/node_modules/react-day-picker/dist/esm/helpers/getComponents.js.map +1 -1
  229. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDataAttributes.js.map +1 -1
  230. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDates.js.map +1 -1
  231. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDays.js +4 -4
  232. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDays.js.map +1 -1
  233. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDefaultClassNames.js.map +1 -1
  234. package/lib/node_modules/react-day-picker/dist/esm/helpers/getDisplayMonths.js.map +1 -1
  235. package/lib/node_modules/react-day-picker/dist/esm/helpers/getFocusableDate.js.map +1 -1
  236. package/lib/node_modules/react-day-picker/dist/esm/helpers/getFormatters.js.map +1 -1
  237. package/lib/node_modules/react-day-picker/dist/esm/helpers/getInitialMonth.js.map +1 -1
  238. package/lib/node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js.map +1 -1
  239. package/lib/node_modules/react-day-picker/dist/esm/helpers/getMonths.js.map +1 -1
  240. package/lib/node_modules/react-day-picker/dist/esm/helpers/getNavMonth.js.map +1 -1
  241. package/lib/node_modules/react-day-picker/dist/esm/helpers/getNextFocus.js.map +1 -1
  242. package/lib/node_modules/react-day-picker/dist/esm/helpers/getNextMonth.js.map +1 -1
  243. package/lib/node_modules/react-day-picker/dist/esm/helpers/getPreviousMonth.js.map +1 -1
  244. package/lib/node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js.map +1 -1
  245. package/lib/node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js.map +1 -1
  246. package/lib/node_modules/react-day-picker/dist/esm/helpers/getWeeks.js +2 -2
  247. package/lib/node_modules/react-day-picker/dist/esm/helpers/getWeeks.js.map +1 -1
  248. package/lib/node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js +9 -11
  249. package/lib/node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js.map +1 -1
  250. package/lib/node_modules/react-day-picker/dist/esm/helpers/startOfBroadcastWeek.js.map +1 -1
  251. package/lib/node_modules/react-day-picker/dist/esm/helpers/useControlledValue.js.map +1 -1
  252. package/lib/node_modules/react-day-picker/dist/esm/labels/index.js +2 -2
  253. package/lib/node_modules/react-day-picker/dist/esm/labels/labelDayButton.js.map +1 -1
  254. package/lib/node_modules/react-day-picker/dist/esm/labels/labelGrid.js +3 -2
  255. package/lib/node_modules/react-day-picker/dist/esm/labels/labelGrid.js.map +1 -1
  256. package/lib/node_modules/react-day-picker/dist/esm/labels/labelGridcell.js.map +1 -1
  257. package/lib/node_modules/react-day-picker/dist/esm/labels/labelMonthDropdown.js +1 -1
  258. package/lib/node_modules/react-day-picker/dist/esm/labels/labelMonthDropdown.js.map +1 -1
  259. package/lib/node_modules/react-day-picker/dist/esm/labels/labelNav.js.map +1 -1
  260. package/lib/node_modules/react-day-picker/dist/esm/labels/labelNext.js +1 -1
  261. package/lib/node_modules/react-day-picker/dist/esm/labels/labelNext.js.map +1 -1
  262. package/lib/node_modules/react-day-picker/dist/esm/labels/labelPrevious.js +1 -1
  263. package/lib/node_modules/react-day-picker/dist/esm/labels/labelPrevious.js.map +1 -1
  264. package/lib/node_modules/react-day-picker/dist/esm/labels/labelWeekNumber.js +1 -1
  265. package/lib/node_modules/react-day-picker/dist/esm/labels/labelWeekNumber.js.map +1 -1
  266. package/lib/node_modules/react-day-picker/dist/esm/labels/labelWeekNumberHeader.js +1 -1
  267. package/lib/node_modules/react-day-picker/dist/esm/labels/labelWeekNumberHeader.js.map +1 -1
  268. package/lib/node_modules/react-day-picker/dist/esm/labels/labelWeekday.js.map +1 -1
  269. package/lib/node_modules/react-day-picker/dist/esm/labels/labelYearDropdown.js +1 -1
  270. package/lib/node_modules/react-day-picker/dist/esm/labels/labelYearDropdown.js.map +1 -1
  271. package/lib/node_modules/react-day-picker/dist/esm/selection/useMulti.js.map +1 -1
  272. package/lib/node_modules/react-day-picker/dist/esm/selection/useRange.js.map +1 -1
  273. package/lib/node_modules/react-day-picker/dist/esm/selection/useSingle.js.map +1 -1
  274. package/lib/node_modules/react-day-picker/dist/esm/useAnimation.js +1 -1
  275. package/lib/node_modules/react-day-picker/dist/esm/useAnimation.js.map +1 -1
  276. package/lib/node_modules/react-day-picker/dist/esm/useCalendar.js +1 -1
  277. package/lib/node_modules/react-day-picker/dist/esm/useCalendar.js.map +1 -1
  278. package/lib/node_modules/react-day-picker/dist/esm/useDayPicker.js.map +1 -1
  279. package/lib/node_modules/react-day-picker/dist/esm/useFocus.js +6 -0
  280. package/lib/node_modules/react-day-picker/dist/esm/useFocus.js.map +1 -1
  281. package/lib/node_modules/react-day-picker/dist/esm/useSelection.js.map +1 -1
  282. package/lib/node_modules/react-day-picker/dist/esm/utils/addToRange.js +6 -1
  283. package/lib/node_modules/react-day-picker/dist/esm/utils/addToRange.js.map +1 -1
  284. package/lib/node_modules/react-day-picker/dist/esm/utils/dateMatchModifiers.js.map +1 -1
  285. package/lib/node_modules/react-day-picker/dist/esm/utils/rangeContainsDayOfWeek.js.map +1 -1
  286. package/lib/node_modules/react-day-picker/dist/esm/utils/rangeContainsModifiers.js.map +1 -1
  287. package/lib/node_modules/react-day-picker/dist/esm/utils/rangeIncludesDate.js.map +1 -1
  288. package/lib/node_modules/react-day-picker/dist/esm/utils/rangeOverlaps.js.map +1 -1
  289. package/lib/node_modules/react-day-picker/dist/esm/utils/typeguards.js.map +1 -1
  290. package/lib/node_modules/react-day-picker/node_modules/date-fns/eachYearOfInterval.js +64 -0
  291. package/lib/node_modules/react-day-picker/node_modules/date-fns/eachYearOfInterval.js.map +1 -0
  292. package/lib/node_modules/react-hook-form/dist/index.esm.js +67 -44
  293. package/lib/node_modules/react-hook-form/dist/index.esm.js.map +1 -1
  294. package/lib/node_modules/react-virtuoso/dist/index.js +1246 -1200
  295. package/lib/node_modules/react-virtuoso/dist/index.js.map +1 -1
  296. package/lib/node_modules/ua-parser-js/src/ua-parser.js +85 -71
  297. package/lib/node_modules/ua-parser-js/src/ua-parser.js.map +1 -1
  298. package/lib/styles.css +1 -1
  299. package/lib/styles.css.map +1 -1
  300. package/lib/tsconfig.tsbuildinfo +1 -1
  301. package/lib/utils/getEncryptedData/getEncryptedData.d.ts +1 -1
  302. package/lib/utils/getEncryptedData/getEncryptedData.js +8 -17
  303. package/lib/utils/getEncryptedData/getEncryptedData.js.map +1 -1
  304. package/package.json +107 -106
@@ -1,15 +1,17 @@
1
1
  import { VALID_DIGITS } from '../../constants.js';
2
2
 
3
+ // The RFC 3966 format for extensions.
3
4
  var RFC3966_EXTN_PREFIX = ';ext=';
5
+
4
6
  /**
5
7
  * Helper method for constructing regular expressions for parsing. Creates
6
8
  * an expression that captures up to max_length digits.
7
9
  * @return {string} RegEx pattern to capture extension digits.
8
10
  */
9
-
10
11
  var getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {
11
12
  return "([".concat(VALID_DIGITS, "]{1,").concat(maxLength, "})");
12
13
  };
14
+
13
15
  /**
14
16
  * Helper initialiser method to create the regular-expression pattern to match
15
17
  * extensions.
@@ -17,79 +19,66 @@ var getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {
17
19
  * https://github.com/google/libphonenumber/blob/55b2646ec9393f4d3d6661b9c82ef9e258e8b829/javascript/i18n/phonenumbers/phonenumberutil.js#L759-L766
18
20
  * @return {string} RegEx pattern to capture extensions.
19
21
  */
20
-
21
22
  function createExtensionPattern(purpose) {
22
23
  // We cap the maximum length of an extension based on the ambiguity of the way
23
24
  // the extension is prefixed. As per ITU, the officially allowed length for
24
25
  // extensions is actually 40, but we don't support this since we haven't seen real
25
26
  // examples and this introduces many false interpretations as the extension labels
26
27
  // are not standardized.
27
-
28
28
  /** @type {string} */
29
29
  var extLimitAfterExplicitLabel = '20';
30
30
  /** @type {string} */
31
-
32
31
  var extLimitAfterLikelyLabel = '15';
33
32
  /** @type {string} */
34
-
35
33
  var extLimitAfterAmbiguousChar = '9';
36
34
  /** @type {string} */
37
-
38
35
  var extLimitWhenNotSure = '6';
39
- /** @type {string} */
40
-
41
- var possibleSeparatorsBetweenNumberAndExtLabel = "[ \xA0\\t,]*"; // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.
42
36
 
43
37
  /** @type {string} */
44
-
38
+ var possibleSeparatorsBetweenNumberAndExtLabel = "[ \xA0\\t,]*";
39
+ // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.
40
+ /** @type {string} */
45
41
  var possibleCharsAfterExtLabel = "[:\\.\uFF0E]?[ \xA0\\t,-]*";
46
42
  /** @type {string} */
43
+ var optionalExtnSuffix = "#?";
47
44
 
48
- var optionalExtnSuffix = "#?"; // Here the extension is called out in more explicit way, i.e mentioning it obvious
45
+ // Here the extension is called out in more explicit way, i.e mentioning it obvious
49
46
  // patterns like "ext.".
50
-
51
47
  /** @type {string} */
52
-
53
- var explicitExtLabels = "(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)"; // One-character symbols that can be used to indicate an extension, and less
48
+ var explicitExtLabels = "(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)";
49
+ // One-character symbols that can be used to indicate an extension, and less
54
50
  // commonly used or more ambiguous extension labels.
55
-
56
51
  /** @type {string} */
57
-
58
- var ambiguousExtLabels = "(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)"; // When extension is not separated clearly.
59
-
52
+ var ambiguousExtLabels = "(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)";
53
+ // When extension is not separated clearly.
60
54
  /** @type {string} */
61
-
62
- var ambiguousSeparator = "[- ]+"; // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching
55
+ var ambiguousSeparator = "[- ]+";
56
+ // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching
63
57
  // comma as extension label may have it.
64
-
65
58
  /** @type {string} */
66
-
67
- var possibleSeparatorsNumberExtLabelNoComma = "[ \xA0\\t]*"; // ",," is commonly used for auto dialling the extension when connected. First
59
+ var possibleSeparatorsNumberExtLabelNoComma = "[ \xA0\\t]*";
60
+ // ",," is commonly used for auto dialling the extension when connected. First
68
61
  // comma is matched through possibleSeparatorsBetweenNumberAndExtLabel, so we do
69
62
  // not repeat it here. Semi-colon works in Iphone and Android also to pop up a
70
63
  // button with the extension number following.
71
-
72
64
  /** @type {string} */
73
-
74
65
  var autoDiallingAndExtLabelsFound = "(?:,{2}|;)";
75
- /** @type {string} */
76
66
 
67
+ /** @type {string} */
77
68
  var rfcExtn = RFC3966_EXTN_PREFIX + getExtensionDigitsPattern(extLimitAfterExplicitLabel);
78
69
  /** @type {string} */
79
-
80
70
  var explicitExtn = possibleSeparatorsBetweenNumberAndExtLabel + explicitExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterExplicitLabel) + optionalExtnSuffix;
81
71
  /** @type {string} */
82
-
83
72
  var ambiguousExtn = possibleSeparatorsBetweenNumberAndExtLabel + ambiguousExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;
84
73
  /** @type {string} */
85
-
86
74
  var americanStyleExtnWithSuffix = ambiguousSeparator + getExtensionDigitsPattern(extLimitWhenNotSure) + "#";
87
- /** @type {string} */
88
75
 
76
+ /** @type {string} */
89
77
  var autoDiallingExtn = possibleSeparatorsNumberExtLabelNoComma + autoDiallingAndExtLabelsFound + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterLikelyLabel) + optionalExtnSuffix;
90
78
  /** @type {string} */
79
+ var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + "(?:,)+" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;
91
80
 
92
- var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + "(?:,)+" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix; // The first regular expression covers RFC 3966 format, where the extension is added
81
+ // The first regular expression covers RFC 3966 format, where the extension is added
93
82
  // using ";ext=". The second more generic where extension is mentioned with explicit
94
83
  // labels like "ext:". In both the above cases we allow more numbers in extension than
95
84
  // any other extension labels. The third one captures when single character extension
@@ -101,7 +90,6 @@ function createExtensionPattern(purpose) {
101
90
  // autodialling formats which are used when dialling and in this case we accept longer
102
91
  // extensions. The last one is more liberal on the number of commas that acts as
103
92
  // extension labels, so we have a strict cap on the number of digits in such extensions.
104
-
105
93
  return rfcExtn + "|" + explicitExtn + "|" + ambiguousExtn + "|" + americanStyleExtnWithSuffix + "|" + autoDiallingExtn + "|" + onlyCommasExtn;
106
94
  }
107
95
 
@@ -1 +1 @@
1
- {"version":3,"file":"createExtensionPattern.js","sources":["../../../../../../node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js"],"sourcesContent":["import { VALID_DIGITS } from '../../constants.js'; // The RFC 3966 format for extensions.\n\nvar RFC3966_EXTN_PREFIX = ';ext=';\n/**\r\n * Helper method for constructing regular expressions for parsing. Creates\r\n * an expression that captures up to max_length digits.\r\n * @return {string} RegEx pattern to capture extension digits.\r\n */\n\nvar getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {\n return \"([\".concat(VALID_DIGITS, \"]{1,\").concat(maxLength, \"})\");\n};\n/**\r\n * Helper initialiser method to create the regular-expression pattern to match\r\n * extensions.\r\n * Copy-pasted from Google's `libphonenumber`:\r\n * https://github.com/google/libphonenumber/blob/55b2646ec9393f4d3d6661b9c82ef9e258e8b829/javascript/i18n/phonenumbers/phonenumberutil.js#L759-L766\r\n * @return {string} RegEx pattern to capture extensions.\r\n */\n\n\nexport default function createExtensionPattern(purpose) {\n // We cap the maximum length of an extension based on the ambiguity of the way\n // the extension is prefixed. As per ITU, the officially allowed length for\n // extensions is actually 40, but we don't support this since we haven't seen real\n // examples and this introduces many false interpretations as the extension labels\n // are not standardized.\n\n /** @type {string} */\n var extLimitAfterExplicitLabel = '20';\n /** @type {string} */\n\n var extLimitAfterLikelyLabel = '15';\n /** @type {string} */\n\n var extLimitAfterAmbiguousChar = '9';\n /** @type {string} */\n\n var extLimitWhenNotSure = '6';\n /** @type {string} */\n\n var possibleSeparatorsBetweenNumberAndExtLabel = \"[ \\xA0\\\\t,]*\"; // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.\n\n /** @type {string} */\n\n var possibleCharsAfterExtLabel = \"[:\\\\.\\uFF0E]?[ \\xA0\\\\t,-]*\";\n /** @type {string} */\n\n var optionalExtnSuffix = \"#?\"; // Here the extension is called out in more explicit way, i.e mentioning it obvious\n // patterns like \"ext.\".\n\n /** @type {string} */\n\n var explicitExtLabels = \"(?:e?xt(?:ensi(?:o\\u0301?|\\xF3))?n?|\\uFF45?\\uFF58\\uFF54\\uFF4E?|\\u0434\\u043E\\u0431|anexo)\"; // One-character symbols that can be used to indicate an extension, and less\n // commonly used or more ambiguous extension labels.\n\n /** @type {string} */\n\n var ambiguousExtLabels = \"(?:[x\\uFF58#\\uFF03~\\uFF5E]|int|\\uFF49\\uFF4E\\uFF54)\"; // When extension is not separated clearly.\n\n /** @type {string} */\n\n var ambiguousSeparator = \"[- ]+\"; // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching\n // comma as extension label may have it.\n\n /** @type {string} */\n\n var possibleSeparatorsNumberExtLabelNoComma = \"[ \\xA0\\\\t]*\"; // \",,\" is commonly used for auto dialling the extension when connected. First\n // comma is matched through possibleSeparatorsBetweenNumberAndExtLabel, so we do\n // not repeat it here. Semi-colon works in Iphone and Android also to pop up a\n // button with the extension number following.\n\n /** @type {string} */\n\n var autoDiallingAndExtLabelsFound = \"(?:,{2}|;)\";\n /** @type {string} */\n\n var rfcExtn = RFC3966_EXTN_PREFIX + getExtensionDigitsPattern(extLimitAfterExplicitLabel);\n /** @type {string} */\n\n var explicitExtn = possibleSeparatorsBetweenNumberAndExtLabel + explicitExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterExplicitLabel) + optionalExtnSuffix;\n /** @type {string} */\n\n var ambiguousExtn = possibleSeparatorsBetweenNumberAndExtLabel + ambiguousExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n /** @type {string} */\n\n var americanStyleExtnWithSuffix = ambiguousSeparator + getExtensionDigitsPattern(extLimitWhenNotSure) + \"#\";\n /** @type {string} */\n\n var autoDiallingExtn = possibleSeparatorsNumberExtLabelNoComma + autoDiallingAndExtLabelsFound + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterLikelyLabel) + optionalExtnSuffix;\n /** @type {string} */\n\n var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + \"(?:,)+\" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix; // The first regular expression covers RFC 3966 format, where the extension is added\n // using \";ext=\". The second more generic where extension is mentioned with explicit\n // labels like \"ext:\". In both the above cases we allow more numbers in extension than\n // any other extension labels. The third one captures when single character extension\n // labels or less commonly used labels are used. In such cases we capture fewer\n // extension digits in order to reduce the chance of falsely interpreting two\n // numbers beside each other as a number + extension. The fourth one covers the\n // special case of American numbers where the extension is written with a hash\n // at the end, such as \"- 503#\". The fifth one is exclusively for extension\n // autodialling formats which are used when dialling and in this case we accept longer\n // extensions. The last one is more liberal on the number of commas that acts as\n // extension labels, so we have a strict cap on the number of digits in such extensions.\n\n return rfcExtn + \"|\" + explicitExtn + \"|\" + ambiguousExtn + \"|\" + americanStyleExtnWithSuffix + \"|\" + autoDiallingExtn + \"|\" + onlyCommasExtn;\n}\n//# sourceMappingURL=createExtensionPattern.js.map"],"names":["RFC3966_EXTN_PREFIX","getExtensionDigitsPattern","maxLength","concat","VALID_DIGITS","createExtensionPattern","purpose","extLimitAfterExplicitLabel","extLimitAfterLikelyLabel","extLimitAfterAmbiguousChar","extLimitWhenNotSure","possibleSeparatorsBetweenNumberAndExtLabel","possibleCharsAfterExtLabel","optionalExtnSuffix","explicitExtLabels","ambiguousExtLabels","ambiguousSeparator","possibleSeparatorsNumberExtLabelNoComma","autoDiallingAndExtLabelsFound","rfcExtn","explicitExtn","ambiguousExtn","americanStyleExtnWithSuffix","autoDiallingExtn","onlyCommasExtn"],"mappings":";;AAGA,IAAMA,mBAAmB,GAAG,OAA5B;AAEA;AACA;AACA;AACA;AACA;;AACA,IAAMC,yBAAyB,GAAG,SAA5BA,yBAA4BA,CAACC,SAAD,EAAA;AAAA,EAAA,OAAA,IAAA,CAAAC,MAAA,CAAoBC,YAApB,EAAA,MAAA,CAAA,CAAAD,MAAA,CAAuCD,SAAvC,EAAA,IAAA,CAAA;AAAA,CAAlC;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AACe,SAASG,sBAATA,CAAgCC,OAAhC,EAAyC;AACvD;AACA;AACA;AACA;AACA;;AACA;EACA,IAAIC,0BAA0B,GAAG,IAAjC;AACA;;EACA,IAAIC,wBAAwB,GAAG,IAA/B;AACA;;EACA,IAAIC,0BAA0B,GAAG,GAAjC;AACA;;EACA,IAAIC,mBAAmB,GAAG,GAA1B;AAEA;;AACA,EAAA,IAAIC,0CAA0C,GAAG,cAAjD,CAhBuD;;AAkBvD;;EACA,IAAIC,0BAA0B,GAAG,4BAAjC;AACA;;AACA,EAAA,IAAIC,kBAAkB,GAAG,IAAzB,CArBuD;AAwBvD;;AACA;;AACA,EAAA,IAAIC,iBAAiB,GACnB,0FADF,CA1BuD;AA6BvD;;AACA;;AACA,EAAA,IAAIC,kBAAkB,GAAG,oDAAzB,CA/BuD;;AAiCvD;;AACA,EAAA,IAAIC,kBAAkB,GAAG,OAAzB,CAlCuD;AAoCvD;;AACA;;AACA,EAAA,IAAIC,uCAAuC,GAAG,aAA9C,CAtCuD;AAwCvD;AACA;AACA;;AACA;;EACA,IAAIC,6BAA6B,GAAG,YAApC;AAEA;;AACA,EAAA,IAAIC,OAAO,GAAGnB,mBAAmB,GAC1BC,yBAAyB,CAACM,0BAAD,CADhC;AAEA;;AACA,EAAA,IAAIa,YAAY,GAAGT,0CAA0C,GAAGG,iBAA7C,GACZF,0BADY,GAEZX,yBAAyB,CAACM,0BAAD,CAFb,GAGZM,kBAHP;AAIA;;AACA,EAAA,IAAIQ,aAAa,GAAGV,0CAA0C,GAAGI,kBAA7C,GACbH,0BADa,GAElBX,yBAAyB,CAACQ,0BAAD,CAFP,GAGlBI,kBAHF;AAIA;;EACA,IAAIS,2BAA2B,GAAGN,kBAAkB,GAClDf,yBAAyB,CAACS,mBAAD,CADO,GACiB,GADnD;AAGA;;AACA,EAAA,IAAIa,gBAAgB,GAAGN,uCAAuC,GACvDC,6BADgB,GACgBN,0BADhB,GAEhBX,yBAAyB,CAACO,wBAAD,CAFT,GAGrBK,kBAHF;AAIA;;AACA,EAAA,IAAIW,cAAc,GAAGP,uCAAuC,GACtD,QADe,GACJL,0BADI,GAEfX,yBAAyB,CAACQ,0BAAD,CAFV,GAGfI,kBAHN,CArEuD;AA2EvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;EACA,OAAOM,OAAO,GAAG,GAAV,GACEC,YADF,GACiB,GADjB,GAEEC,aAFF,GAEkB,GAFlB,GAGEC,2BAHF,GAGgC,GAHhC,GAIEC,gBAJF,GAIqB,GAJrB,GAKEC,cALT;AAMA;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"createExtensionPattern.js","sources":["../../../../../../node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js"],"sourcesContent":["import { VALID_DIGITS } from '../../constants.js';\n\n// The RFC 3966 format for extensions.\nvar RFC3966_EXTN_PREFIX = ';ext=';\n\n/**\r\n * Helper method for constructing regular expressions for parsing. Creates\r\n * an expression that captures up to max_length digits.\r\n * @return {string} RegEx pattern to capture extension digits.\r\n */\nvar getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {\n return \"([\".concat(VALID_DIGITS, \"]{1,\").concat(maxLength, \"})\");\n};\n\n/**\r\n * Helper initialiser method to create the regular-expression pattern to match\r\n * extensions.\r\n * Copy-pasted from Google's `libphonenumber`:\r\n * https://github.com/google/libphonenumber/blob/55b2646ec9393f4d3d6661b9c82ef9e258e8b829/javascript/i18n/phonenumbers/phonenumberutil.js#L759-L766\r\n * @return {string} RegEx pattern to capture extensions.\r\n */\nexport default function createExtensionPattern(purpose) {\n // We cap the maximum length of an extension based on the ambiguity of the way\n // the extension is prefixed. As per ITU, the officially allowed length for\n // extensions is actually 40, but we don't support this since we haven't seen real\n // examples and this introduces many false interpretations as the extension labels\n // are not standardized.\n /** @type {string} */\n var extLimitAfterExplicitLabel = '20';\n /** @type {string} */\n var extLimitAfterLikelyLabel = '15';\n /** @type {string} */\n var extLimitAfterAmbiguousChar = '9';\n /** @type {string} */\n var extLimitWhenNotSure = '6';\n\n /** @type {string} */\n var possibleSeparatorsBetweenNumberAndExtLabel = \"[ \\xA0\\\\t,]*\";\n // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.\n /** @type {string} */\n var possibleCharsAfterExtLabel = \"[:\\\\.\\uFF0E]?[ \\xA0\\\\t,-]*\";\n /** @type {string} */\n var optionalExtnSuffix = \"#?\";\n\n // Here the extension is called out in more explicit way, i.e mentioning it obvious\n // patterns like \"ext.\".\n /** @type {string} */\n var explicitExtLabels = \"(?:e?xt(?:ensi(?:o\\u0301?|\\xF3))?n?|\\uFF45?\\uFF58\\uFF54\\uFF4E?|\\u0434\\u043E\\u0431|anexo)\";\n // One-character symbols that can be used to indicate an extension, and less\n // commonly used or more ambiguous extension labels.\n /** @type {string} */\n var ambiguousExtLabels = \"(?:[x\\uFF58#\\uFF03~\\uFF5E]|int|\\uFF49\\uFF4E\\uFF54)\";\n // When extension is not separated clearly.\n /** @type {string} */\n var ambiguousSeparator = \"[- ]+\";\n // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching\n // comma as extension label may have it.\n /** @type {string} */\n var possibleSeparatorsNumberExtLabelNoComma = \"[ \\xA0\\\\t]*\";\n // \",,\" is commonly used for auto dialling the extension when connected. First\n // comma is matched through possibleSeparatorsBetweenNumberAndExtLabel, so we do\n // not repeat it here. Semi-colon works in Iphone and Android also to pop up a\n // button with the extension number following.\n /** @type {string} */\n var autoDiallingAndExtLabelsFound = \"(?:,{2}|;)\";\n\n /** @type {string} */\n var rfcExtn = RFC3966_EXTN_PREFIX + getExtensionDigitsPattern(extLimitAfterExplicitLabel);\n /** @type {string} */\n var explicitExtn = possibleSeparatorsBetweenNumberAndExtLabel + explicitExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterExplicitLabel) + optionalExtnSuffix;\n /** @type {string} */\n var ambiguousExtn = possibleSeparatorsBetweenNumberAndExtLabel + ambiguousExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n /** @type {string} */\n var americanStyleExtnWithSuffix = ambiguousSeparator + getExtensionDigitsPattern(extLimitWhenNotSure) + \"#\";\n\n /** @type {string} */\n var autoDiallingExtn = possibleSeparatorsNumberExtLabelNoComma + autoDiallingAndExtLabelsFound + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterLikelyLabel) + optionalExtnSuffix;\n /** @type {string} */\n var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + \"(?:,)+\" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n\n // The first regular expression covers RFC 3966 format, where the extension is added\n // using \";ext=\". The second more generic where extension is mentioned with explicit\n // labels like \"ext:\". In both the above cases we allow more numbers in extension than\n // any other extension labels. The third one captures when single character extension\n // labels or less commonly used labels are used. In such cases we capture fewer\n // extension digits in order to reduce the chance of falsely interpreting two\n // numbers beside each other as a number + extension. The fourth one covers the\n // special case of American numbers where the extension is written with a hash\n // at the end, such as \"- 503#\". The fifth one is exclusively for extension\n // autodialling formats which are used when dialling and in this case we accept longer\n // extensions. The last one is more liberal on the number of commas that acts as\n // extension labels, so we have a strict cap on the number of digits in such extensions.\n return rfcExtn + \"|\" + explicitExtn + \"|\" + ambiguousExtn + \"|\" + americanStyleExtnWithSuffix + \"|\" + autoDiallingExtn + \"|\" + onlyCommasExtn;\n}\n//# sourceMappingURL=createExtensionPattern.js.map"],"names":["RFC3966_EXTN_PREFIX","getExtensionDigitsPattern","maxLength","concat","VALID_DIGITS","createExtensionPattern","purpose","extLimitAfterExplicitLabel","extLimitAfterLikelyLabel","extLimitAfterAmbiguousChar","extLimitWhenNotSure","possibleSeparatorsBetweenNumberAndExtLabel","possibleCharsAfterExtLabel","optionalExtnSuffix","explicitExtLabels","ambiguousExtLabels","ambiguousSeparator","possibleSeparatorsNumberExtLabelNoComma","autoDiallingAndExtLabelsFound","rfcExtn","explicitExtn","ambiguousExtn","americanStyleExtnWithSuffix","autoDiallingExtn","onlyCommasExtn"],"mappings":";;AAEA;AACA,IAAMA,mBAAmB,GAAG,OAAO;;AAEnC;AACA;AACA;AACA;AACA;AACA,IAAMC,yBAAyB,GAAG,SAA5BA,yBAAyBA,CAAIC,SAAS,EAAA;AAAA,EAAA,OAAA,IAAA,CAAAC,MAAA,CAAUC,YAAY,EAAA,MAAA,CAAA,CAAAD,MAAA,CAAOD,SAAS,EAAA,IAAA,CAAA;AAAA,CAAI;;AAEtF;AACA;AACA;AACA;AACA;AACA;AACA;AACe,SAASG,sBAAsBA,CAACC,OAAO,EAAE;AACvD;AACA;AACA;AACA;AACA;AACA;EACA,IAAIC,0BAA0B,GAAG,IAAI;AACrC;EACA,IAAIC,wBAAwB,GAAG,IAAI;AACnC;EACA,IAAIC,0BAA0B,GAAG,GAAG;AACpC;EACA,IAAIC,mBAAmB,GAAG,GAAG;;AAE7B;EACA,IAAIC,0CAA0C,GAAG,cAAgB;AACjE;AACA;EACA,IAAIC,0BAA0B,GAAG,4BAA8B;AAC/D;EACA,IAAIC,kBAAkB,GAAG,IAAI;;AAE7B;AACA;AACA;EACA,IAAIC,iBAAiB,GACnB,0FAA4F;AAC9F;AACA;AACA;EACA,IAAIC,kBAAkB,GAAG,oDAAoD;AAC7E;AACA;EACA,IAAIC,kBAAkB,GAAG,OAAO;AAChC;AACA;AACA;EACA,IAAIC,uCAAuC,GAAG,aAAe;AAC7D;AACA;AACA;AACA;AACA;EACA,IAAIC,6BAA6B,GAAG,YAAY;;AAEhD;AACA,EAAA,IAAIC,OAAO,GAAGnB,mBAAmB,GAC1BC,yBAAyB,CAACM,0BAA0B,CAAC;AAC5D;AACA,EAAA,IAAIa,YAAY,GAAGT,0CAA0C,GAAGG,iBAAiB,GAC1EF,0BAA0B,GAC1BX,yBAAyB,CAACM,0BAA0B,CAAC,GACrDM,kBAAkB;AACzB;AACA,EAAA,IAAIQ,aAAa,GAAGV,0CAA0C,GAAGI,kBAAkB,GAC5EH,0BAA0B,GAC/BX,yBAAyB,CAACQ,0BAA0B,CAAC,GACrDI,kBAAkB;AACpB;EACA,IAAIS,2BAA2B,GAAGN,kBAAkB,GAClDf,yBAAyB,CAACS,mBAAmB,CAAC,GAAG,GAAG;;AAEtD;AACA,EAAA,IAAIa,gBAAgB,GAAGN,uCAAuC,GACvDC,6BAA6B,GAAGN,0BAA0B,GAC1DX,yBAAyB,CAACO,wBAAwB,CAAC,GACxDK,kBAAkB;AACpB;AACA,EAAA,IAAIW,cAAc,GAAGP,uCAAuC,GACtD,QAAQ,GAAGL,0BAA0B,GACrCX,yBAAyB,CAACQ,0BAA0B,CAAC,GACrDI,kBAAkB;;AAExB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACA,OAAOM,OAAO,GAAG,GAAG,GACXC,YAAY,GAAG,GAAG,GAClBC,aAAa,GAAG,GAAG,GACnBC,2BAA2B,GAAG,GAAG,GACjCC,gBAAgB,GAAG,GAAG,GACtBC,cAAc;AACxB;;;;","x_google_ignoreList":[0]}
@@ -1,18 +1,19 @@
1
1
  import createExtensionPattern from './createExtensionPattern.js';
2
2
 
3
+ // Regexp of all known extension prefixes used by different regions followed by
3
4
  // 1 or more valid digits, for use when parsing.
5
+ var EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i');
4
6
 
5
- var EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i'); // Strips any extension (as in, the part of the number dialled after the call is
7
+ // Strips any extension (as in, the part of the number dialled after the call is
6
8
  // connected, usually indicated with extn, ext, x or similar) from the end of
7
9
  // the number, and returns it.
8
-
9
10
  function extractExtension(number) {
10
11
  var start = number.search(EXTN_PATTERN);
11
12
  if (start < 0) {
12
13
  return {};
13
- } // If we find a potential extension, and the number preceding this is a viable
14
+ }
15
+ // If we find a potential extension, and the number preceding this is a viable
14
16
  // number, we assume it is an extension.
15
-
16
17
  var numberWithoutExtension = number.slice(0, start);
17
18
  var matches = number.match(EXTN_PATTERN);
18
19
  var i = 1;
@@ -1 +1 @@
1
- {"version":3,"file":"extractExtension.js","sources":["../../../../../../node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js"],"sourcesContent":["import createExtensionPattern from './createExtensionPattern.js'; // Regexp of all known extension prefixes used by different regions followed by\n// 1 or more valid digits, for use when parsing.\n\nvar EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i'); // Strips any extension (as in, the part of the number dialled after the call is\n// connected, usually indicated with extn, ext, x or similar) from the end of\n// the number, and returns it.\n\nexport default function extractExtension(number) {\n var start = number.search(EXTN_PATTERN);\n\n if (start < 0) {\n return {};\n } // If we find a potential extension, and the number preceding this is a viable\n // number, we assume it is an extension.\n\n\n var numberWithoutExtension = number.slice(0, start);\n var matches = number.match(EXTN_PATTERN);\n var i = 1;\n\n while (i < matches.length) {\n if (matches[i]) {\n return {\n number: numberWithoutExtension,\n ext: matches[i]\n };\n }\n\n i++;\n }\n}\n//# sourceMappingURL=extractExtension.js.map"],"names":["EXTN_PATTERN","RegExp","createExtensionPattern","extractExtension","number","start","search","numberWithoutExtension","slice","matches","match","i","length","ext"],"mappings":";;AAGA;;AACA,IAAMA,YAAY,GAAG,IAAIC,MAAJ,CAAW,KAAA,GAAQC,sBAAsB,EAA9B,GAAmC,IAA9C,EAAoD,GAApD,CAArB;AAGA;AACA;;AACe,SAASC,gBAATA,CAA0BC,MAA1B,EAAkC;AAChD,EAAA,IAAMC,KAAK,GAAGD,MAAM,CAACE,MAAP,CAAcN,YAAd,CAAd;EACA,IAAIK,KAAK,GAAG,CAAZ,EAAe;AACd,IAAA,OAAO,EAAP;AACA,EAAA,CAJ+C;AAMhD;;EACA,IAAME,sBAAsB,GAAGH,MAAM,CAACI,KAAP,CAAa,CAAb,EAAgBH,KAAhB,CAA/B;AACA,EAAA,IAAMI,OAAO,GAAGL,MAAM,CAACM,KAAP,CAAaV,YAAb,CAAhB;EACA,IAAIW,CAAC,GAAG,CAAR;AACA,EAAA,OAAOA,CAAC,GAAGF,OAAO,CAACG,MAAnB,EAA2B;AAC1B,IAAA,IAAIH,OAAO,CAACE,CAAD,CAAX,EAAgB;MACf,OAAO;AACNP,QAAAA,MAAM,EAAEG,sBADF;QAENM,GAAG,EAAEJ,OAAO,CAACE,CAAD;OAFb;AAIA,IAAA;IACDA,CAAC,EAAA;AACD,EAAA;AACD;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"extractExtension.js","sources":["../../../../../../node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js"],"sourcesContent":["import createExtensionPattern from './createExtensionPattern.js';\n\n// Regexp of all known extension prefixes used by different regions followed by\n// 1 or more valid digits, for use when parsing.\nvar EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i');\n\n// Strips any extension (as in, the part of the number dialled after the call is\n// connected, usually indicated with extn, ext, x or similar) from the end of\n// the number, and returns it.\nexport default function extractExtension(number) {\n var start = number.search(EXTN_PATTERN);\n if (start < 0) {\n return {};\n }\n // If we find a potential extension, and the number preceding this is a viable\n // number, we assume it is an extension.\n var numberWithoutExtension = number.slice(0, start);\n var matches = number.match(EXTN_PATTERN);\n var i = 1;\n while (i < matches.length) {\n if (matches[i]) {\n return {\n number: numberWithoutExtension,\n ext: matches[i]\n };\n }\n i++;\n }\n}\n//# sourceMappingURL=extractExtension.js.map"],"names":["EXTN_PATTERN","RegExp","createExtensionPattern","extractExtension","number","start","search","numberWithoutExtension","slice","matches","match","i","length","ext"],"mappings":";;AAEA;AACA;AACA,IAAMA,YAAY,GAAG,IAAIC,MAAM,CAAC,KAAK,GAAGC,sBAAsB,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC;;AAE7E;AACA;AACA;AACe,SAASC,gBAAgBA,CAACC,MAAM,EAAE;AAChD,EAAA,IAAMC,KAAK,GAAGD,MAAM,CAACE,MAAM,CAACN,YAAY,CAAC;EACzC,IAAIK,KAAK,GAAG,CAAC,EAAE;AACd,IAAA,OAAO,EAAE;AACV,EAAA;AACA;AACA;EACA,IAAME,sBAAsB,GAAGH,MAAM,CAACI,KAAK,CAAC,CAAC,EAAEH,KAAK,CAAC;AACrD,EAAA,IAAMI,OAAO,GAAGL,MAAM,CAACM,KAAK,CAACV,YAAY,CAAC;EAC1C,IAAIW,CAAC,GAAG,CAAC;AACT,EAAA,OAAOA,CAAC,GAAGF,OAAO,CAACG,MAAM,EAAE;AAC1B,IAAA,IAAIH,OAAO,CAACE,CAAC,CAAC,EAAE;MACf,OAAO;AACNP,QAAAA,MAAM,EAAEG,sBAAsB;QAC9BM,GAAG,EAAEJ,OAAO,CAACE,CAAC;OACd;AACF,IAAA;AACAA,IAAAA,CAAC,EAAE;AACJ,EAAA;AACD;;;;","x_google_ignoreList":[0]}
@@ -10,37 +10,38 @@ import { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';
10
10
  * a national prefix, carrier code, and national
11
11
  * (significant) number.
12
12
  * @param {string} number — Phone number digits (possibly with a `+`).
13
- * @param {string} [country] — Default country.
14
- * @param {string} [callingCode] — Default calling code (some phone numbering plans are non-geographic).
13
+ * @param {string} [country] — Country.
14
+ * @param {string} [defaultCountry] — Default country.
15
+ * @param {string} [defaultCallingCode] — Default calling code (some phone numbering plans are non-geographic).
15
16
  * @param {object} metadata
16
17
  * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`
17
18
  * @example
18
19
  * // Returns `{ countryCallingCode: "1", number: "2133734253" }`.
19
- * extractCountryCallingCode('2133734253', 'US', null, metadata)
20
- * extractCountryCallingCode('2133734253', null, '1', metadata)
21
- * extractCountryCallingCode('+12133734253', null, null, metadata)
22
- * extractCountryCallingCode('+12133734253', 'RU', null, metadata)
20
+ * extractCountryCallingCode('2133734253', null, 'US', null, metadata)
21
+ * extractCountryCallingCode('2133734253', null, null, '1', metadata)
22
+ * extractCountryCallingCode('+12133734253', null, null, null, metadata)
23
+ * extractCountryCallingCode('+12133734253', null, 'RU', null, metadata)
23
24
  */
24
-
25
- function extractCountryCallingCode(number, country, callingCode, metadata) {
25
+ function extractCountryCallingCode(number, country, defaultCountry, defaultCallingCode, metadata) {
26
26
  if (!number) {
27
27
  return {};
28
28
  }
29
- var isNumberWithIddPrefix; // If this is not an international phone number,
29
+ var isNumberWithIddPrefix;
30
+
31
+ // If this is not an international phone number,
30
32
  // then either extract an "IDD" prefix, or extract a
31
33
  // country calling code from a number by autocorrecting it
32
34
  // by prepending a leading `+` in cases when it starts
33
35
  // with the country calling code.
34
36
  // https://wikitravel.org/en/International_dialling_prefix
35
37
  // https://github.com/catamphetamine/libphonenumber-js/issues/376
36
-
37
38
  if (number[0] !== '+') {
38
39
  // Convert an "out-of-country" dialing phone number
39
40
  // to a proper international phone number.
40
- var numberWithoutIDD = stripIddPrefix(number, country, callingCode, metadata); // If an IDD prefix was stripped then
41
+ var numberWithoutIDD = stripIddPrefix(number, country || defaultCountry, defaultCallingCode, metadata);
42
+ // If an IDD prefix was stripped then
41
43
  // convert the number to international one
42
44
  // for subsequent parsing.
43
-
44
45
  if (numberWithoutIDD && numberWithoutIDD !== number) {
45
46
  isNumberWithIddPrefix = true;
46
47
  number = '+' + numberWithoutIDD;
@@ -49,8 +50,8 @@ function extractCountryCallingCode(number, country, callingCode, metadata) {
49
50
  // for the default country. If so, we remove the country calling code,
50
51
  // and do some checks on the validity of the number before and after.
51
52
  // https://github.com/catamphetamine/libphonenumber-js/issues/376
52
- if (country || callingCode) {
53
- var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, callingCode, metadata),
53
+ if (country || defaultCountry || defaultCallingCode) {
54
+ var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata),
54
55
  countryCallingCode = _extractCountryCallin.countryCallingCode,
55
56
  shorterNumber = _extractCountryCallin.number;
56
57
  if (countryCallingCode) {
@@ -67,12 +68,17 @@ function extractCountryCallingCode(number, country, callingCode, metadata) {
67
68
  number: number
68
69
  };
69
70
  }
70
- } // Fast abortion: country codes do not begin with a '0'
71
+ }
71
72
 
73
+ // `number` can only be international at this point.
74
+
75
+ // Fast abortion: country codes do not begin with a '0'
72
76
  if (number[1] === '0') {
73
77
  return {};
74
78
  }
75
- metadata = new Metadata(metadata); // The thing with country phone codes
79
+ metadata = new Metadata(metadata);
80
+
81
+ // The thing with country phone codes
76
82
  // is that they are orthogonal to each other
77
83
  // i.e. there's no such country phone code A
78
84
  // for which country phone code B exists
@@ -81,7 +87,6 @@ function extractCountryCallingCode(number, country, callingCode, metadata) {
81
87
  // if a valid country code is found,
82
88
  // that means that it is the country code.
83
89
  //
84
-
85
90
  var i = 2;
86
91
  while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {
87
92
  var _countryCallingCode = number.slice(1, i);
@@ -96,7 +101,9 @@ function extractCountryCallingCode(number, country, callingCode, metadata) {
96
101
  i++;
97
102
  }
98
103
  return {};
99
- } // The possible values for the returned `countryCallingCodeSource` are:
104
+ }
105
+
106
+ // The possible values for the returned `countryCallingCodeSource` are:
100
107
  //
101
108
  // Copy-pasted from:
102
109
  // https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto
@@ -1 +1 @@
1
- {"version":3,"file":"extractCountryCallingCode.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js"],"sourcesContent":["import stripIddPrefix from './stripIddPrefix.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport Metadata from '../metadata.js';\nimport { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';\n/**\r\n * Converts a phone number digits (possibly with a `+`)\r\n * into a calling code and the rest phone number digits.\r\n * The \"rest phone number digits\" could include\r\n * a national prefix, carrier code, and national\r\n * (significant) number.\r\n * @param {string} number — Phone number digits (possibly with a `+`).\r\n * @param {string} [country] — Default country.\r\n * @param {string} [callingCode] — Default calling code (some phone numbering plans are non-geographic).\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`\r\n * @example\r\n * // Returns `{ countryCallingCode: \"1\", number: \"2133734253\" }`.\r\n * extractCountryCallingCode('2133734253', 'US', null, metadata)\r\n * extractCountryCallingCode('2133734253', null, '1', metadata)\r\n * extractCountryCallingCode('+12133734253', null, null, metadata)\r\n * extractCountryCallingCode('+12133734253', 'RU', null, metadata)\r\n */\n\nexport default function extractCountryCallingCode(number, country, callingCode, metadata) {\n if (!number) {\n return {};\n }\n\n var isNumberWithIddPrefix; // If this is not an international phone number,\n // then either extract an \"IDD\" prefix, or extract a\n // country calling code from a number by autocorrecting it\n // by prepending a leading `+` in cases when it starts\n // with the country calling code.\n // https://wikitravel.org/en/International_dialling_prefix\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n\n if (number[0] !== '+') {\n // Convert an \"out-of-country\" dialing phone number\n // to a proper international phone number.\n var numberWithoutIDD = stripIddPrefix(number, country, callingCode, metadata); // If an IDD prefix was stripped then\n // convert the number to international one\n // for subsequent parsing.\n\n if (numberWithoutIDD && numberWithoutIDD !== number) {\n isNumberWithIddPrefix = true;\n number = '+' + numberWithoutIDD;\n } else {\n // Check to see if the number starts with the country calling code\n // for the default country. If so, we remove the country calling code,\n // and do some checks on the validity of the number before and after.\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (country || callingCode) {\n var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, callingCode, metadata),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n shorterNumber = _extractCountryCallin.number;\n\n if (countryCallingCode) {\n return {\n countryCallingCodeSource: 'FROM_NUMBER_WITHOUT_PLUS_SIGN',\n countryCallingCode: countryCallingCode,\n number: shorterNumber\n };\n }\n }\n\n return {\n // No need to set it to `UNSPECIFIED`. It can be just `undefined`.\n // countryCallingCodeSource: 'UNSPECIFIED',\n number: number\n };\n }\n } // Fast abortion: country codes do not begin with a '0'\n\n\n if (number[1] === '0') {\n return {};\n }\n\n metadata = new Metadata(metadata); // The thing with country phone codes\n // is that they are orthogonal to each other\n // i.e. there's no such country phone code A\n // for which country phone code B exists\n // where B starts with A.\n // Therefore, while scanning digits,\n // if a valid country code is found,\n // that means that it is the country code.\n //\n\n var i = 2;\n\n while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {\n var _countryCallingCode = number.slice(1, i);\n\n if (metadata.hasCallingCode(_countryCallingCode)) {\n metadata.selectNumberingPlan(_countryCallingCode);\n return {\n countryCallingCodeSource: isNumberWithIddPrefix ? 'FROM_NUMBER_WITH_IDD' : 'FROM_NUMBER_WITH_PLUS_SIGN',\n countryCallingCode: _countryCallingCode,\n number: number.slice(i)\n };\n }\n\n i++;\n }\n\n return {};\n} // The possible values for the returned `countryCallingCodeSource` are:\n//\n// Copy-pasted from:\n// https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto\n//\n// // The source from which the country_code is derived. This is not set in the\n// // general parsing method, but in the method that parses and keeps raw_input.\n// // New fields could be added upon request.\n// enum CountryCodeSource {\n// // Default value returned if this is not set, because the phone number was\n// // created using parse, not parseAndKeepRawInput. hasCountryCodeSource will\n// // return false if this is the case.\n// UNSPECIFIED = 0;\n//\n// // The country_code is derived based on a phone number with a leading \"+\",\n// // e.g. the French number \"+33 1 42 68 53 00\".\n// FROM_NUMBER_WITH_PLUS_SIGN = 1;\n//\n// // The country_code is derived based on a phone number with a leading IDD,\n// // e.g. the French number \"011 33 1 42 68 53 00\", as it is dialled from US.\n// FROM_NUMBER_WITH_IDD = 5;\n//\n// // The country_code is derived based on a phone number without a leading\n// // \"+\", e.g. the French number \"33 1 42 68 53 00\" when defaultCountry is\n// // supplied as France.\n// FROM_NUMBER_WITHOUT_PLUS_SIGN = 10;\n//\n// // The country_code is derived NOT based on the phone number itself, but\n// // from the defaultCountry parameter provided in the parsing function by the\n// // clients. This happens mostly for numbers written in the national format\n// // (without country code). For example, this would be set when parsing the\n// // French number \"01 42 68 53 00\", when defaultCountry is supplied as\n// // France.\n// FROM_DEFAULT_COUNTRY = 20;\n// }\n//# sourceMappingURL=extractCountryCallingCode.js.map"],"names":["extractCountryCallingCode","number","country","callingCode","metadata","isNumberWithIddPrefix","numberWithoutIDD","stripIddPrefix","_extractCountryCallin","extractCountryCallingCodeFromInternationalNumberWithoutPlusSign","countryCallingCode","shorterNumber","countryCallingCodeSource","Metadata","i","MAX_LENGTH_COUNTRY_CODE","length","_countryCallingCode","slice","hasCallingCode","selectNumberingPlan"],"mappings":";;;;;AAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACe,SAASA,yBAATA,CACdC,MADc,EAEdC,OAFc,EAGdC,WAHc,EAIdC,QAJc,EAKb;EACD,IAAI,CAACH,MAAL,EAAa;AACZ,IAAA,OAAO,EAAP;AACA,EAAA;EAED,IAAII,qBAAJ,CALC;AAQD;AACA;AACA;AACA;AACA;AACA;;AACA,EAAA,IAAIJ,MAAM,CAAC,CAAD,CAAN,KAAc,GAAlB,EAAuB;AACtB;AACA;AACA,IAAA,IAAMK,gBAAgB,GAAGC,cAAc,CAACN,MAAD,EAASC,OAAT,EAAkBC,WAAlB,EAA+BC,QAA/B,CAAvC,CAHsB;AAKtB;AACA;;AACA,IAAA,IAAIE,gBAAgB,IAAIA,gBAAgB,KAAKL,MAA7C,EAAqD;AACpDI,MAAAA,qBAAqB,GAAG,IAAxB;MACAJ,MAAM,GAAG,MAAMK,gBAAf;AACA,IAAA,CAHD,MAGO;AACN;AACA;AACA;AACA;MACA,IAAIJ,OAAO,IAAIC,WAAf,EAA4B;QAC3B,IAAAK,qBAAA,GAGIC,+DAA+D,CAClER,MADkE,EAElEC,OAFkE,EAGlEC,WAHkE,EAIlEC,QAJkE,CAHnE;UACCM,kBADD,GAAAF,qBAAA,CACCE,kBADD;UAESC,aAFT,GAAAH,qBAAA,CAECP,MAFD;AASA,QAAA,IAAIS,kBAAJ,EAAwB;UACvB,OAAO;AACNE,YAAAA,wBAAwB,EAAE,+BADpB;AAENF,YAAAA,kBAAkB,EAAlBA,kBAFM;AAGNT,YAAAA,MAAM,EAAEU;WAHT;AAKA,QAAA;AACD,MAAA;MACD,OAAO;AACN;AACA;AACAV,QAAAA,MAAM,EAANA;OAHD;AAKA,IAAA;AACD,EAAA,CArDA;;AAwDD,EAAA,IAAIA,MAAM,CAAC,CAAD,CAAN,KAAc,GAAlB,EAAuB;AACtB,IAAA,OAAO,EAAP;AACA,EAAA;AAEDG,EAAAA,QAAQ,GAAG,IAAIS,QAAJ,CAAaT,QAAb,CAAX,CA5DC;AA+DD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;EACA,IAAIU,CAAC,GAAG,CAAR;EACA,OAAOA,CAAC,GAAG,CAAJ,IAASC,uBAAT,IAAoCD,CAAC,IAAIb,MAAM,CAACe,MAAvD,EAA+D;IAC9D,IAAMC,mBAAkB,GAAGhB,MAAM,CAACiB,KAAP,CAAa,CAAb,EAAgBJ,CAAhB,CAA3B;AACA,IAAA,IAAIV,QAAQ,CAACe,cAAT,CAAwBF,mBAAxB,CAAJ,EAAiD;MAChDb,QAAQ,CAACgB,mBAAT,CAA6BH,mBAA7B,CAAA;MACA,OAAO;AACNL,QAAAA,wBAAwB,EAAEP,qBAAqB,GAAG,sBAAH,GAA4B,4BADrE;AAENK,QAAAA,kBAAkB,EAAlBO,mBAFM;AAGNhB,QAAAA,MAAM,EAAEA,MAAM,CAACiB,KAAP,CAAaJ,CAAb;OAHT;AAKA,IAAA;IACDA,CAAC,EAAA;AACD,EAAA;AAED,EAAA,OAAO,EAAP;AACA;AAGD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"extractCountryCallingCode.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js"],"sourcesContent":["import stripIddPrefix from './stripIddPrefix.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport Metadata from '../metadata.js';\nimport { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';\n\n/**\r\n * Converts a phone number digits (possibly with a `+`)\r\n * into a calling code and the rest phone number digits.\r\n * The \"rest phone number digits\" could include\r\n * a national prefix, carrier code, and national\r\n * (significant) number.\r\n * @param {string} number — Phone number digits (possibly with a `+`).\r\n * @param {string} [country] — Country.\r\n * @param {string} [defaultCountry] — Default country.\r\n * @param {string} [defaultCallingCode] — Default calling code (some phone numbering plans are non-geographic).\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`\r\n * @example\r\n * // Returns `{ countryCallingCode: \"1\", number: \"2133734253\" }`.\r\n * extractCountryCallingCode('2133734253', null, 'US', null, metadata)\r\n * extractCountryCallingCode('2133734253', null, null, '1', metadata)\r\n * extractCountryCallingCode('+12133734253', null, null, null, metadata)\r\n * extractCountryCallingCode('+12133734253', null, 'RU', null, metadata)\r\n */\nexport default function extractCountryCallingCode(number, country, defaultCountry, defaultCallingCode, metadata) {\n if (!number) {\n return {};\n }\n var isNumberWithIddPrefix;\n\n // If this is not an international phone number,\n // then either extract an \"IDD\" prefix, or extract a\n // country calling code from a number by autocorrecting it\n // by prepending a leading `+` in cases when it starts\n // with the country calling code.\n // https://wikitravel.org/en/International_dialling_prefix\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (number[0] !== '+') {\n // Convert an \"out-of-country\" dialing phone number\n // to a proper international phone number.\n var numberWithoutIDD = stripIddPrefix(number, country || defaultCountry, defaultCallingCode, metadata);\n // If an IDD prefix was stripped then\n // convert the number to international one\n // for subsequent parsing.\n if (numberWithoutIDD && numberWithoutIDD !== number) {\n isNumberWithIddPrefix = true;\n number = '+' + numberWithoutIDD;\n } else {\n // Check to see if the number starts with the country calling code\n // for the default country. If so, we remove the country calling code,\n // and do some checks on the validity of the number before and after.\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (country || defaultCountry || defaultCallingCode) {\n var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n shorterNumber = _extractCountryCallin.number;\n if (countryCallingCode) {\n return {\n countryCallingCodeSource: 'FROM_NUMBER_WITHOUT_PLUS_SIGN',\n countryCallingCode: countryCallingCode,\n number: shorterNumber\n };\n }\n }\n return {\n // No need to set it to `UNSPECIFIED`. It can be just `undefined`.\n // countryCallingCodeSource: 'UNSPECIFIED',\n number: number\n };\n }\n }\n\n // `number` can only be international at this point.\n\n // Fast abortion: country codes do not begin with a '0'\n if (number[1] === '0') {\n return {};\n }\n metadata = new Metadata(metadata);\n\n // The thing with country phone codes\n // is that they are orthogonal to each other\n // i.e. there's no such country phone code A\n // for which country phone code B exists\n // where B starts with A.\n // Therefore, while scanning digits,\n // if a valid country code is found,\n // that means that it is the country code.\n //\n var i = 2;\n while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {\n var _countryCallingCode = number.slice(1, i);\n if (metadata.hasCallingCode(_countryCallingCode)) {\n metadata.selectNumberingPlan(_countryCallingCode);\n return {\n countryCallingCodeSource: isNumberWithIddPrefix ? 'FROM_NUMBER_WITH_IDD' : 'FROM_NUMBER_WITH_PLUS_SIGN',\n countryCallingCode: _countryCallingCode,\n number: number.slice(i)\n };\n }\n i++;\n }\n return {};\n}\n\n// The possible values for the returned `countryCallingCodeSource` are:\n//\n// Copy-pasted from:\n// https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto\n//\n// // The source from which the country_code is derived. This is not set in the\n// // general parsing method, but in the method that parses and keeps raw_input.\n// // New fields could be added upon request.\n// enum CountryCodeSource {\n// // Default value returned if this is not set, because the phone number was\n// // created using parse, not parseAndKeepRawInput. hasCountryCodeSource will\n// // return false if this is the case.\n// UNSPECIFIED = 0;\n//\n// // The country_code is derived based on a phone number with a leading \"+\",\n// // e.g. the French number \"+33 1 42 68 53 00\".\n// FROM_NUMBER_WITH_PLUS_SIGN = 1;\n//\n// // The country_code is derived based on a phone number with a leading IDD,\n// // e.g. the French number \"011 33 1 42 68 53 00\", as it is dialled from US.\n// FROM_NUMBER_WITH_IDD = 5;\n//\n// // The country_code is derived based on a phone number without a leading\n// // \"+\", e.g. the French number \"33 1 42 68 53 00\" when defaultCountry is\n// // supplied as France.\n// FROM_NUMBER_WITHOUT_PLUS_SIGN = 10;\n//\n// // The country_code is derived NOT based on the phone number itself, but\n// // from the defaultCountry parameter provided in the parsing function by the\n// // clients. This happens mostly for numbers written in the national format\n// // (without country code). For example, this would be set when parsing the\n// // French number \"01 42 68 53 00\", when defaultCountry is supplied as\n// // France.\n// FROM_DEFAULT_COUNTRY = 20;\n// }\n//# sourceMappingURL=extractCountryCallingCode.js.map"],"names":["extractCountryCallingCode","number","country","defaultCountry","defaultCallingCode","metadata","isNumberWithIddPrefix","numberWithoutIDD","stripIddPrefix","_extractCountryCallin","extractCountryCallingCodeFromInternationalNumberWithoutPlusSign","countryCallingCode","shorterNumber","countryCallingCodeSource","Metadata","i","MAX_LENGTH_COUNTRY_CODE","length","_countryCallingCode","slice","hasCallingCode","selectNumberingPlan"],"mappings":";;;;;AAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe,SAASA,yBAAyBA,CAChDC,MAAM,EACNC,OAAO,EACPC,cAAc,EACdC,kBAAkB,EAClBC,QAAQ,EACP;EACD,IAAI,CAACJ,MAAM,EAAE;AACZ,IAAA,OAAO,EAAE;AACV,EAAA;AAEA,EAAA,IAAIK,qBAAqB;;AAEzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAA,IAAIL,MAAM,CAAC,CAAC,CAAC,KAAK,GAAG,EAAE;AACtB;AACA;AACA,IAAA,IAAMM,gBAAgB,GAAGC,cAAc,CAACP,MAAM,EAAEC,OAAO,IAAIC,cAAc,EAAEC,kBAAkB,EAAEC,QAAQ,CAAC;AACxG;AACA;AACA;AACA,IAAA,IAAIE,gBAAgB,IAAIA,gBAAgB,KAAKN,MAAM,EAAE;AACpDK,MAAAA,qBAAqB,GAAG,IAAI;MAC5BL,MAAM,GAAG,GAAG,GAAGM,gBAAgB;AAChC,IAAA,CAAC,MAAM;AACN;AACA;AACA;AACA;AACA,MAAA,IAAIL,OAAO,IAAIC,cAAc,IAAIC,kBAAkB,EAAE;AACpD,QAAA,IAAAK,qBAAA,GAGIC,+DAA+D,CAClET,MAAM,EACNC,OAAO,EACPC,cAAc,EACdC,kBAAkB,EAClBC,QACD,CAAC;UARAM,kBAAkB,GAAAF,qBAAA,CAAlBE,kBAAkB;UACVC,aAAa,GAAAH,qBAAA,CAArBR,MAAM;AAQP,QAAA,IAAIU,kBAAkB,EAAE;UACvB,OAAO;AACNE,YAAAA,wBAAwB,EAAE,+BAA+B;AACzDF,YAAAA,kBAAkB,EAAlBA,kBAAkB;AAClBV,YAAAA,MAAM,EAAEW;WACR;AACF,QAAA;AACD,MAAA;MACA,OAAO;AACN;AACA;AACAX,QAAAA,MAAM,EAANA;OACA;AACF,IAAA;AACD,EAAA;;AAEA;;AAEA;AACA,EAAA,IAAIA,MAAM,CAAC,CAAC,CAAC,KAAK,GAAG,EAAE;AACtB,IAAA,OAAO,EAAE;AACV,EAAA;AAEAI,EAAAA,QAAQ,GAAG,IAAIS,QAAQ,CAACT,QAAQ,CAAC;;AAEjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACA,IAAIU,CAAC,GAAG,CAAC;EACT,OAAOA,CAAC,GAAG,CAAC,IAAIC,uBAAuB,IAAID,CAAC,IAAId,MAAM,CAACgB,MAAM,EAAE;IAC9D,IAAMC,mBAAkB,GAAGjB,MAAM,CAACkB,KAAK,CAAC,CAAC,EAAEJ,CAAC,CAAC;AAC7C,IAAA,IAAIV,QAAQ,CAACe,cAAc,CAACF,mBAAkB,CAAC,EAAE;AAChDb,MAAAA,QAAQ,CAACgB,mBAAmB,CAACH,mBAAkB,CAAC;MAChD,OAAO;AACNL,QAAAA,wBAAwB,EAAEP,qBAAqB,GAAG,sBAAsB,GAAG,4BAA4B;AACvGK,QAAAA,kBAAkB,EAAlBO,mBAAkB;AAClBjB,QAAAA,MAAM,EAAEA,MAAM,CAACkB,KAAK,CAACJ,CAAC;OACtB;AACF,IAAA;AACAA,IAAAA,CAAC,EAAE;AACJ,EAAA;AAEA,EAAA,OAAO,EAAE;AACV;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;","x_google_ignoreList":[0]}
@@ -7,22 +7,24 @@ import checkNumberLength from './checkNumberLength.js';
7
7
  * Sometimes some people incorrectly input international phone numbers
8
8
  * without the leading `+`. This function corrects such input.
9
9
  * @param {string} number — Phone number digits.
10
- * @param {string?} country
11
- * @param {string?} callingCode
10
+ * @param {string} [country] — Exact country of the phone number.
11
+ * @param {string} [defaultCountry]
12
+ * @param {string} [defaultCallingCode]
12
13
  * @param {object} metadata
13
14
  * @return {object} `{ countryCallingCode: string?, number: string }`.
14
15
  */
15
-
16
- function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, callingCode, metadata) {
17
- var countryCallingCode = country ? getCountryCallingCode(country, metadata) : callingCode;
16
+ function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata) {
17
+ var countryCallingCode = country || defaultCountry ? getCountryCallingCode(country || defaultCountry, metadata) : defaultCallingCode;
18
18
  if (number.indexOf(countryCallingCode) === 0) {
19
19
  metadata = new Metadata(metadata);
20
- metadata.selectNumberingPlan(country, callingCode);
20
+ metadata.selectNumberingPlan(country || defaultCountry, countryCallingCode);
21
21
  var possibleShorterNumber = number.slice(countryCallingCode.length);
22
- var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, metadata),
22
+ var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, country, metadata),
23
23
  possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;
24
- var _extractNationalNumbe2 = extractNationalNumber(number, metadata),
25
- nationalNumber = _extractNationalNumbe2.nationalNumber; // If the number was not valid before but is valid now,
24
+ var _extractNationalNumbe2 = extractNationalNumber(number, country, metadata),
25
+ nationalNumber = _extractNationalNumbe2.nationalNumber;
26
+
27
+ // If the number was not valid before but is valid now,
26
28
  // or if it was too long before, we consider the number
27
29
  // with the country calling code stripped to be a better result
28
30
  // and keep that instead.
@@ -30,8 +32,7 @@ function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number,
30
32
  // so if a number starts with `49`, it could be both a valid
31
33
  // national German number or an international number without
32
34
  // a leading `+`.
33
-
34
- if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, metadata) === 'TOO_LONG') {
35
+ if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, country, metadata) === 'TOO_LONG') {
35
36
  return {
36
37
  countryCallingCode: countryCallingCode,
37
38
  number: possibleShorterNumber
@@ -1 +1 @@
1
- {"version":3,"file":"extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js"],"sourcesContent":["import Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport extractNationalNumber from './extractNationalNumber.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryCallingCode from '../getCountryCallingCode.js';\n/**\r\n * Sometimes some people incorrectly input international phone numbers\r\n * without the leading `+`. This function corrects such input.\r\n * @param {string} number — Phone number digits.\r\n * @param {string?} country\r\n * @param {string?} callingCode\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCode: string?, number: string }`.\r\n */\n\nexport default function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, callingCode, metadata) {\n var countryCallingCode = country ? getCountryCallingCode(country, metadata) : callingCode;\n\n if (number.indexOf(countryCallingCode) === 0) {\n metadata = new Metadata(metadata);\n metadata.selectNumberingPlan(country, callingCode);\n var possibleShorterNumber = number.slice(countryCallingCode.length);\n\n var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, metadata),\n possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;\n\n var _extractNationalNumbe2 = extractNationalNumber(number, metadata),\n nationalNumber = _extractNationalNumbe2.nationalNumber; // If the number was not valid before but is valid now,\n // or if it was too long before, we consider the number\n // with the country calling code stripped to be a better result\n // and keep that instead.\n // For example, in Germany (+49), `49` is a valid area code,\n // so if a number starts with `49`, it could be both a valid\n // national German number or an international number without\n // a leading `+`.\n\n\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, metadata) === 'TOO_LONG') {\n return {\n countryCallingCode: countryCallingCode,\n number: possibleShorterNumber\n };\n }\n }\n\n return {\n number: number\n };\n}\n//# sourceMappingURL=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map"],"names":["extractCountryCallingCodeFromInternationalNumberWithoutPlusSign","number","country","callingCode","metadata","countryCallingCode","getCountryCallingCode","indexOf","Metadata","selectNumberingPlan","possibleShorterNumber","slice","length","_extractNationalNumbe","extractNationalNumber","possibleShorterNationalNumber","nationalNumber","_extractNationalNumbe2","matchesEntirely","nationalNumberPattern","checkNumberLength"],"mappings":";;;;;AAMA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACe,SAASA,+DAATA,CACdC,MADc,EAEdC,OAFc,EAGdC,WAHc,EAIdC,QAJc,EAKb;EACD,IAAMC,kBAAkB,GAAGH,OAAO,GAAGI,qBAAqB,CAACJ,OAAD,EAAUE,QAAV,CAAxB,GAA8CD,WAAhF;AACA,EAAA,IAAIF,MAAM,CAACM,OAAP,CAAeF,kBAAf,CAAA,KAAuC,CAA3C,EAA8C;AAC7CD,IAAAA,QAAQ,GAAG,IAAII,QAAJ,CAAaJ,QAAb,CAAX;AACAA,IAAAA,QAAQ,CAACK,mBAAT,CAA6BP,OAA7B,EAAsCC,WAAtC,CAAA;IACA,IAAMO,qBAAqB,GAAGT,MAAM,CAACU,KAAP,CAAaN,kBAAkB,CAACO,MAAhC,CAA9B;AACA,IAAA,IAAAC,qBAAA,GAEIC,qBAAqB,CACxBJ,qBADwB,EAExBN,QAFwB,CAFzB;MACiBW,6BADjB,GAAAF,qBAAA,CACCG,cADD;AAMA,IAAA,IAAAC,sBAAA,GAEIH,qBAAqB,CACxBb,MADwB,EAExBG,QAFwB,CAFzB;AACCY,MAAAA,cADD,GAAAC,sBAAA,CACCD,cADD,CAV6C;AAiB7C;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,IAAA,IAEE,CAACE,eAAe,CAACF,cAAD,EAAiBZ,QAAQ,CAACe,qBAAT,EAAjB,CAAhB,IAEAD,eAAe,CAACH,6BAAD,EAAgCX,QAAQ,CAACe,qBAAT,EAAhC,CAHhB,IAMAC,iBAAiB,CAACJ,cAAD,EAAiBZ,QAAjB,CAAjB,KAAgD,UAPjD,EAQE;MACD,OAAO;AACNC,QAAAA,kBAAkB,EAAlBA,kBADM;AAENJ,QAAAA,MAAM,EAAES;OAFT;AAIA,IAAA;AACD,EAAA;EACD,OAAO;AAAET,IAAAA,MAAM,EAANA;GAAT;AACA;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js"],"sourcesContent":["import Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport extractNationalNumber from './extractNationalNumber.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryCallingCode from '../getCountryCallingCode.js';\n\n/**\r\n * Sometimes some people incorrectly input international phone numbers\r\n * without the leading `+`. This function corrects such input.\r\n * @param {string} number — Phone number digits.\r\n * @param {string} [country] — Exact country of the phone number.\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCode: string?, number: string }`.\r\n */\nexport default function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata) {\n var countryCallingCode = country || defaultCountry ? getCountryCallingCode(country || defaultCountry, metadata) : defaultCallingCode;\n if (number.indexOf(countryCallingCode) === 0) {\n metadata = new Metadata(metadata);\n metadata.selectNumberingPlan(country || defaultCountry, countryCallingCode);\n var possibleShorterNumber = number.slice(countryCallingCode.length);\n var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, country, metadata),\n possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;\n var _extractNationalNumbe2 = extractNationalNumber(number, country, metadata),\n nationalNumber = _extractNationalNumbe2.nationalNumber;\n\n // If the number was not valid before but is valid now,\n // or if it was too long before, we consider the number\n // with the country calling code stripped to be a better result\n // and keep that instead.\n // For example, in Germany (+49), `49` is a valid area code,\n // so if a number starts with `49`, it could be both a valid\n // national German number or an international number without\n // a leading `+`.\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, country, metadata) === 'TOO_LONG') {\n return {\n countryCallingCode: countryCallingCode,\n number: possibleShorterNumber\n };\n }\n }\n return {\n number: number\n };\n}\n//# sourceMappingURL=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map"],"names":["extractCountryCallingCodeFromInternationalNumberWithoutPlusSign","number","country","defaultCountry","defaultCallingCode","metadata","countryCallingCode","getCountryCallingCode","indexOf","Metadata","selectNumberingPlan","possibleShorterNumber","slice","length","_extractNationalNumbe","extractNationalNumber","possibleShorterNationalNumber","nationalNumber","_extractNationalNumbe2","matchesEntirely","nationalNumberPattern","checkNumberLength"],"mappings":";;;;;AAMA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe,SAASA,+DAA+DA,CACtFC,MAAM,EACNC,OAAO,EACPC,cAAc,EACdC,kBAAkB,EAClBC,QAAQ,EACP;AACD,EAAA,IAAMC,kBAAkB,GAAGJ,OAAO,IAAIC,cAAc,GACjDI,qBAAqB,CAACL,OAAO,IAAIC,cAAc,EAAEE,QAAQ,CAAC,GAC1DD,kBAAkB;EAErB,IAAIH,MAAM,CAACO,OAAO,CAACF,kBAAkB,CAAC,KAAK,CAAC,EAAE;AAC7CD,IAAAA,QAAQ,GAAG,IAAII,QAAQ,CAACJ,QAAQ,CAAC;IACjCA,QAAQ,CAACK,mBAAmB,CAACR,OAAO,IAAIC,cAAc,EAAEG,kBAAkB,CAAC;IAE3E,IAAMK,qBAAqB,GAAGV,MAAM,CAACW,KAAK,CAACN,kBAAkB,CAACO,MAAM,CAAC;IAErE,IAAAC,qBAAA,GAEIC,qBAAqB,CACxBJ,qBAAqB,EACrBT,OAAO,EACPG,QACD,CAAC;MALgBW,6BAA6B,GAAAF,qBAAA,CAA7CG,cAAc;IAOf,IAAAC,sBAAA,GAEIH,qBAAqB,CACxBd,MAAM,EACNC,OAAO,EACPG,QACD,CAAC;MALAY,cAAc,GAAAC,sBAAA,CAAdD,cAAc;;AAOf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAA,IAEE,CAACE,eAAe,CAACF,cAAc,EAAEZ,QAAQ,CAACe,qBAAqB,EAAE,CAAC,IAClED,eAAe,CAACH,6BAA6B,EAAEX,QAAQ,CAACe,qBAAqB,EAAE,CAAC,IAGjFC,iBAAiB,CAACJ,cAAc,EAAEf,OAAO,EAAEG,QAAQ,CAAC,KAAK,UAAU,EAClE;MACD,OAAO;AACNC,QAAAA,kBAAkB,EAAlBA,kBAAkB;AAClBL,QAAAA,MAAM,EAAEU;OACR;AACF,IAAA;AACD,EAAA;EAEA,OAAO;AAAEV,IAAAA,MAAM,EAANA;GAAQ;AAClB;;;;","x_google_ignoreList":[0]}
@@ -6,7 +6,6 @@ import ParseError from '../ParseError.js';
6
6
  * @param {string} nationalNumber
7
7
  * @return {}
8
8
  */
9
-
10
9
  function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse, _ref) {
11
10
  var extractFormattedPhoneNumber = _ref.extractFormattedPhoneNumber;
12
11
  var phoneContext = extractPhoneContext(numberToParse);
@@ -19,23 +18,24 @@ function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse,
19
18
  // (this strips leading characters that could not be the start of a phone number)
20
19
  phoneNumberString = extractFormattedPhoneNumber(numberToParse) || '';
21
20
  } else {
22
- phoneNumberString = ''; // If the phone context contains a phone number prefix, we need to capture
23
- // it, whereas domains will be ignored.
21
+ phoneNumberString = '';
24
22
 
23
+ // If the phone context contains a phone number prefix, we need to capture
24
+ // it, whereas domains will be ignored.
25
25
  if (phoneContext.charAt(0) === PLUS_SIGN) {
26
26
  phoneNumberString += phoneContext;
27
- } // Now append everything between the "tel:" prefix and the phone-context.
27
+ }
28
+
29
+ // Now append everything between the "tel:" prefix and the phone-context.
28
30
  // This should include the national number, an optional extension or
29
31
  // isdn-subaddress component. Note we also handle the case when "tel:" is
30
32
  // missing, as we have seen in some of the phone number inputs.
31
33
  // In that case, we append everything from the beginning.
32
-
33
34
  var indexOfRfc3966Prefix = numberToParse.indexOf(RFC3966_PREFIX_);
34
- var indexOfNationalNumber; // RFC 3966 "tel:" prefix is preset at this stage because
35
+ var indexOfNationalNumber;
36
+ // RFC 3966 "tel:" prefix is preset at this stage because
35
37
  // `isPhoneContextValid()` requires it to be present.
36
-
37
38
  /* istanbul ignore else */
38
-
39
39
  if (indexOfRfc3966Prefix >= 0) {
40
40
  indexOfNationalNumber = indexOfRfc3966Prefix + RFC3966_PREFIX_.length;
41
41
  } else {
@@ -43,14 +43,16 @@ function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse,
43
43
  }
44
44
  var indexOfPhoneContext = numberToParse.indexOf(RFC3966_PHONE_CONTEXT_);
45
45
  phoneNumberString += numberToParse.substring(indexOfNationalNumber, indexOfPhoneContext);
46
- } // Delete the isdn-subaddress and everything after it if it is present.
46
+ }
47
+
48
+ // Delete the isdn-subaddress and everything after it if it is present.
47
49
  // Note extension won't appear at the same time with isdn-subaddress
48
50
  // according to paragraph 5.3 of the RFC3966 spec.
49
-
50
51
  var indexOfIsdn = phoneNumberString.indexOf(RFC3966_ISDN_SUBADDRESS_);
51
52
  if (indexOfIsdn > 0) {
52
53
  phoneNumberString = phoneNumberString.substring(0, indexOfIsdn);
53
- } // If both phone context and isdn-subaddress are absent but other
54
+ }
55
+ // If both phone context and isdn-subaddress are absent but other
54
56
  // parameters are present, the parameters are left in nationalNumber.
55
57
  // This is because we are concerned about deleting content from a potential
56
58
  // number string when there is no strong evidence that the number is
@@ -1 +1 @@
1
- {"version":3,"file":"extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js"],"sourcesContent":["import extractPhoneContext, { isPhoneContextValid, PLUS_SIGN, RFC3966_PREFIX_, RFC3966_PHONE_CONTEXT_, RFC3966_ISDN_SUBADDRESS_ } from './extractPhoneContext.js';\nimport ParseError from '../ParseError.js';\n/**\r\n * @param {string} numberToParse\r\n * @param {string} nationalNumber\r\n * @return {}\r\n */\n\nexport default function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse, _ref) {\n var extractFormattedPhoneNumber = _ref.extractFormattedPhoneNumber;\n var phoneContext = extractPhoneContext(numberToParse);\n\n if (!isPhoneContextValid(phoneContext)) {\n throw new ParseError('NOT_A_NUMBER');\n }\n\n var phoneNumberString;\n\n if (phoneContext === null) {\n // Extract a possible number from the string passed in.\n // (this strips leading characters that could not be the start of a phone number)\n phoneNumberString = extractFormattedPhoneNumber(numberToParse) || '';\n } else {\n phoneNumberString = ''; // If the phone context contains a phone number prefix, we need to capture\n // it, whereas domains will be ignored.\n\n if (phoneContext.charAt(0) === PLUS_SIGN) {\n phoneNumberString += phoneContext;\n } // Now append everything between the \"tel:\" prefix and the phone-context.\n // This should include the national number, an optional extension or\n // isdn-subaddress component. Note we also handle the case when \"tel:\" is\n // missing, as we have seen in some of the phone number inputs.\n // In that case, we append everything from the beginning.\n\n\n var indexOfRfc3966Prefix = numberToParse.indexOf(RFC3966_PREFIX_);\n var indexOfNationalNumber; // RFC 3966 \"tel:\" prefix is preset at this stage because\n // `isPhoneContextValid()` requires it to be present.\n\n /* istanbul ignore else */\n\n if (indexOfRfc3966Prefix >= 0) {\n indexOfNationalNumber = indexOfRfc3966Prefix + RFC3966_PREFIX_.length;\n } else {\n indexOfNationalNumber = 0;\n }\n\n var indexOfPhoneContext = numberToParse.indexOf(RFC3966_PHONE_CONTEXT_);\n phoneNumberString += numberToParse.substring(indexOfNationalNumber, indexOfPhoneContext);\n } // Delete the isdn-subaddress and everything after it if it is present.\n // Note extension won't appear at the same time with isdn-subaddress\n // according to paragraph 5.3 of the RFC3966 spec.\n\n\n var indexOfIsdn = phoneNumberString.indexOf(RFC3966_ISDN_SUBADDRESS_);\n\n if (indexOfIsdn > 0) {\n phoneNumberString = phoneNumberString.substring(0, indexOfIsdn);\n } // If both phone context and isdn-subaddress are absent but other\n // parameters are present, the parameters are left in nationalNumber.\n // This is because we are concerned about deleting content from a potential\n // number string when there is no strong evidence that the number is\n // actually written in RFC3966.\n\n\n if (phoneNumberString !== '') {\n return phoneNumberString;\n }\n}\n//# sourceMappingURL=extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js.map"],"names":["extractFormattedPhoneNumberFromPossibleRfc3966NumberUri","numberToParse","_ref","extractFormattedPhoneNumber","phoneContext","extractPhoneContext","isPhoneContextValid","ParseError","phoneNumberString","charAt","PLUS_SIGN","indexOfRfc3966Prefix","indexOf","RFC3966_PREFIX_","indexOfNationalNumber","length","indexOfPhoneContext","RFC3966_PHONE_CONTEXT_","substring","indexOfIsdn","RFC3966_ISDN_SUBADDRESS_"],"mappings":";;;AAUA;AACA;AACA;AACA;AACA;;AACe,SAASA,uDAATA,CAAiEC,aAAjE,EAAAC,IAAA,EAEZ;AAAA,EAAA,IADFC,2BACE,GAAAD,IAAA,CADFC,2BACE;AACF,EAAA,IAAMC,YAAY,GAAGC,mBAAmB,CAACJ,aAAD,CAAxC;AACA,EAAA,IAAI,CAACK,mBAAmB,CAACF,YAAD,CAAxB,EAAwC;AACvC,IAAA,MAAM,IAAIG,UAAJ,CAAe,cAAf,CAAN;AACA,EAAA;AAED,EAAA,IAAIC,iBAAJ;EAEA,IAAIJ,YAAY,KAAK,IAArB,EAA2B;AAC1B;AACA;AACAI,IAAAA,iBAAiB,GAAGL,2BAA2B,CAACF,aAAD,CAA3B,IAA8C,EAAlE;AACA,EAAA,CAJD,MAIO;IACNO,iBAAiB,GAAG,EAApB,CADM;AAIN;;AACA,IAAA,IAAIJ,YAAY,CAACK,MAAb,CAAoB,CAApB,CAAA,KAA2BC,SAA/B,EAA0C;AACzCF,MAAAA,iBAAiB,IAAIJ,YAArB;AACA,IAAA,CAPK;AAUN;AACA;AACA;AACA;;AACA,IAAA,IAAMO,oBAAoB,GAAGV,aAAa,CAACW,OAAd,CAAsBC,eAAtB,CAA7B;IACA,IAAIC,qBAAJ,CAfM;AAiBN;;AACA;;IACA,IAAIH,oBAAoB,IAAI,CAA5B,EAA+B;AAC9BG,MAAAA,qBAAqB,GAAGH,oBAAoB,GAAGE,eAAe,CAACE,MAA/D;AACA,IAAA,CAFD,MAEO;AACND,MAAAA,qBAAqB,GAAG,CAAxB;AACA,IAAA;AACD,IAAA,IAAME,mBAAmB,GAAGf,aAAa,CAACW,OAAd,CAAsBK,sBAAtB,CAA5B;IACAT,iBAAiB,IAAIP,aAAa,CAACiB,SAAd,CAAwBJ,qBAAxB,EAA+CE,mBAA/C,CAArB;AACA,EAAA,CAtCC;AAyCF;AACA;;AACA,EAAA,IAAMG,WAAW,GAAGX,iBAAiB,CAACI,OAAlB,CAA0BQ,wBAA1B,CAApB;EACA,IAAID,WAAW,GAAG,CAAlB,EAAqB;IACpBX,iBAAiB,GAAGA,iBAAiB,CAACU,SAAlB,CAA4B,CAA5B,EAA+BC,WAA/B,CAApB;AACA,EAAA,CA9CC;AAgDF;AACA;AACA;AACA;;EAEA,IAAIX,iBAAiB,KAAK,EAA1B,EAA8B;AAC7B,IAAA,OAAOA,iBAAP;AACA,EAAA;AACD;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js","sources":["../../../../../node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js"],"sourcesContent":["import extractPhoneContext, { isPhoneContextValid, PLUS_SIGN, RFC3966_PREFIX_, RFC3966_PHONE_CONTEXT_, RFC3966_ISDN_SUBADDRESS_ } from './extractPhoneContext.js';\nimport ParseError from '../ParseError.js';\n\n/**\r\n * @param {string} numberToParse\r\n * @param {string} nationalNumber\r\n * @return {}\r\n */\nexport default function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse, _ref) {\n var extractFormattedPhoneNumber = _ref.extractFormattedPhoneNumber;\n var phoneContext = extractPhoneContext(numberToParse);\n if (!isPhoneContextValid(phoneContext)) {\n throw new ParseError('NOT_A_NUMBER');\n }\n var phoneNumberString;\n if (phoneContext === null) {\n // Extract a possible number from the string passed in.\n // (this strips leading characters that could not be the start of a phone number)\n phoneNumberString = extractFormattedPhoneNumber(numberToParse) || '';\n } else {\n phoneNumberString = '';\n\n // If the phone context contains a phone number prefix, we need to capture\n // it, whereas domains will be ignored.\n if (phoneContext.charAt(0) === PLUS_SIGN) {\n phoneNumberString += phoneContext;\n }\n\n // Now append everything between the \"tel:\" prefix and the phone-context.\n // This should include the national number, an optional extension or\n // isdn-subaddress component. Note we also handle the case when \"tel:\" is\n // missing, as we have seen in some of the phone number inputs.\n // In that case, we append everything from the beginning.\n var indexOfRfc3966Prefix = numberToParse.indexOf(RFC3966_PREFIX_);\n var indexOfNationalNumber;\n // RFC 3966 \"tel:\" prefix is preset at this stage because\n // `isPhoneContextValid()` requires it to be present.\n /* istanbul ignore else */\n if (indexOfRfc3966Prefix >= 0) {\n indexOfNationalNumber = indexOfRfc3966Prefix + RFC3966_PREFIX_.length;\n } else {\n indexOfNationalNumber = 0;\n }\n var indexOfPhoneContext = numberToParse.indexOf(RFC3966_PHONE_CONTEXT_);\n phoneNumberString += numberToParse.substring(indexOfNationalNumber, indexOfPhoneContext);\n }\n\n // Delete the isdn-subaddress and everything after it if it is present.\n // Note extension won't appear at the same time with isdn-subaddress\n // according to paragraph 5.3 of the RFC3966 spec.\n var indexOfIsdn = phoneNumberString.indexOf(RFC3966_ISDN_SUBADDRESS_);\n if (indexOfIsdn > 0) {\n phoneNumberString = phoneNumberString.substring(0, indexOfIsdn);\n }\n // If both phone context and isdn-subaddress are absent but other\n // parameters are present, the parameters are left in nationalNumber.\n // This is because we are concerned about deleting content from a potential\n // number string when there is no strong evidence that the number is\n // actually written in RFC3966.\n\n if (phoneNumberString !== '') {\n return phoneNumberString;\n }\n}\n//# sourceMappingURL=extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js.map"],"names":["extractFormattedPhoneNumberFromPossibleRfc3966NumberUri","numberToParse","_ref","extractFormattedPhoneNumber","phoneContext","extractPhoneContext","isPhoneContextValid","ParseError","phoneNumberString","charAt","PLUS_SIGN","indexOfRfc3966Prefix","indexOf","RFC3966_PREFIX_","indexOfNationalNumber","length","indexOfPhoneContext","RFC3966_PHONE_CONTEXT_","substring","indexOfIsdn","RFC3966_ISDN_SUBADDRESS_"],"mappings":";;;AAUA;AACA;AACA;AACA;AACA;AACe,SAASA,uDAAuDA,CAACC,aAAa,EAAAC,IAAA,EAE1F;AAAA,EAAA,IADFC,2BAA2B,GAAAD,IAAA,CAA3BC,2BAA2B;AAE3B,EAAA,IAAMC,YAAY,GAAGC,mBAAmB,CAACJ,aAAa,CAAC;AACvD,EAAA,IAAI,CAACK,mBAAmB,CAACF,YAAY,CAAC,EAAE;AACvC,IAAA,MAAM,IAAIG,UAAU,CAAC,cAAc,CAAC;AACrC,EAAA;AAEA,EAAA,IAAIC,iBAAiB;EAErB,IAAIJ,YAAY,KAAK,IAAI,EAAE;AAC1B;AACA;AACAI,IAAAA,iBAAiB,GAAGL,2BAA2B,CAACF,aAAa,CAAC,IAAI,EAAE;AACrE,EAAA,CAAC,MAAM;AACNO,IAAAA,iBAAiB,GAAG,EAAE;;AAEtB;AACA;IACA,IAAIJ,YAAY,CAACK,MAAM,CAAC,CAAC,CAAC,KAAKC,SAAS,EAAE;AACzCF,MAAAA,iBAAiB,IAAIJ,YAAY;AAClC,IAAA;;AAEA;AACA;AACA;AACA;AACA;AACA,IAAA,IAAMO,oBAAoB,GAAGV,aAAa,CAACW,OAAO,CAACC,eAAe,CAAC;AACnE,IAAA,IAAIC,qBAAqB;AACzB;AACA;AACA;IACA,IAAIH,oBAAoB,IAAI,CAAC,EAAE;AAC9BG,MAAAA,qBAAqB,GAAGH,oBAAoB,GAAGE,eAAe,CAACE,MAAM;AACtE,IAAA,CAAC,MAAM;AACND,MAAAA,qBAAqB,GAAG,CAAC;AAC1B,IAAA;AACA,IAAA,IAAME,mBAAmB,GAAGf,aAAa,CAACW,OAAO,CAACK,sBAAsB,CAAC;IACzET,iBAAiB,IAAIP,aAAa,CAACiB,SAAS,CAACJ,qBAAqB,EAAEE,mBAAmB,CAAC;AACzF,EAAA;;AAEA;AACA;AACA;AACA,EAAA,IAAMG,WAAW,GAAGX,iBAAiB,CAACI,OAAO,CAACQ,wBAAwB,CAAC;EACvE,IAAID,WAAW,GAAG,CAAC,EAAE;IACpBX,iBAAiB,GAAGA,iBAAiB,CAACU,SAAS,CAAC,CAAC,EAAEC,WAAW,CAAC;AAChE,EAAA;AACA;AACA;AACA;AACA;AACA;;EAEA,IAAIX,iBAAiB,KAAK,EAAE,EAAE;AAC7B,IAAA,OAAOA,iBAAiB;AACzB,EAAA;AACD;;;;","x_google_ignoreList":[0]}