From 1b4e275decf67d5a9807028b863429a91a11c330 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 17 Sep 2026 21:41:54 +0000 Subject: [PATCH 1/2] chore(main): release 2.4.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 191 ++++++++++++++++++++++++++++++++++ package-lock.json | 4 +- package.json | 2 +- 4 files changed, 195 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index d03fa520e..db7ad907a 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "2.3.0" + ".": "2.4.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 60aeea59b..2bc076f4c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,197 @@ The entries are generated by [release-please](https://github.com/googleapis/rele [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) history, and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [2.4.0](https://github.com/brazilian-utils/javascript/compare/2.3.0...2.4.0) (2026-09-17) + + +### Features + +* **area-code:** add getAreaCodeInfo and getAreaCodesByState ([748d9b8](https://github.com/brazilian-utils/javascript/commit/748d9b8b477cb1af6016970f66d2bca65cf6cdbc)) +* **area-code:** list every state a DDD serves (42, 47, 49 and 61 span two states) ([e17e55a](https://github.com/brazilian-utils/javascript/commit/e17e55a84cde49fe7915bb49b072847f2c91f9d9)) +* **banks:** add getBanks, getBankByCode and getBankByIspb; validate every Bacen bank account ([ac2e84d](https://github.com/brazilian-utils/javascript/commit/ac2e84d7deeea2c7e737afc46251f1786a80a957)) +* **banks:** keep the codes that left the Bacen list as legacy banks ([f7922c7](https://github.com/brazilian-utils/javascript/commit/f7922c711e4e5c502a846947f267f549d9b1d445)) +* **boleto:** support boleto de arrecadação and a referenceDate option ([6bde780](https://github.com/brazilian-utils/javascript/commit/6bde780845b5b0f067e83bc5a4e1e2e0fa0f41a0)) +* **business-days:** add isBusinessDay, addBusinessDays and differenceInBusinessDays ([2b78c29](https://github.com/brazilian-utils/javascript/commit/2b78c29c0d768f1daecac9e0e01e03b1507d98fb)) +* **business-days:** follow the date-fns signatures and add subBusinessDays ([688359f](https://github.com/brazilian-utils/javascript/commit/688359f200b7b4a7a2d68e668c1daf4d6b3424a2)) +* **capitalize:** keep company designations, roman numerals and state codes upper case by default ([b6cb522](https://github.com/brazilian-utils/javascript/commit/b6cb522fcc25d70b3bed9b6bc0df774390d87f1b)) +* **cbo:** add getCbo and isValidCbo ([a59ffbd](https://github.com/brazilian-utils/javascript/commit/a59ffbd701a86c8e3c8479e696938d76e3b7420e)) +* **cei-cno-caepf:** add isValidCei, formatCei, isValidCno, formatCno, isValidCaepf and formatCaepf ([fda26b0](https://github.com/brazilian-utils/javascript/commit/fda26b00d89cd3b9a7b1cecb123452ae969fd9aa)) +* **cep:** declare the unidade, estado and regiao fields of the ViaCEP response ([811cb10](https://github.com/brazilian-utils/javascript/commit/811cb10a07e69a38c4d11bb1a6ec45617584814b)) +* **certidao:** add formatCertidao, isValidCertidao and parseCertidao ([db5a602](https://github.com/brazilian-utils/javascript/commit/db5a602fe4040c073caa35bf932f71d6b7218836)) +* **cfop:** add getCfop and isValidCfop ([853202b](https://github.com/brazilian-utils/javascript/commit/853202b1d179d7fbc543cc7901e98559df4ecf86)) +* **cnae,ncm:** add the pad option to formatCnae and formatNcm ([09408b1](https://github.com/brazilian-utils/javascript/commit/09408b11c73ec914d194d2cc56c360bd699299a7)) +* **cnae:** add formatCnae, getCnae and isValidCnae ([2defadd](https://github.com/brazilian-utils/javascript/commit/2defaddb90532a2c9443280412a19a0da0aa18b4)) +* **cnpj:** accept a branch number in generateCnpj ([33e27be](https://github.com/brazilian-utils/javascript/commit/33e27be3e7ce35462d6c7cd70bab1308622f4746)) +* **cnpj:** add an obfuscate option to formatCnpj ([65c118c](https://github.com/brazilian-utils/javascript/commit/65c118c338dcae8798c6519344f02105023f648d)) +* **cns:** add isValidCns and formatCns ([d054ce6](https://github.com/brazilian-utils/javascript/commit/d054ce62e18713827483cdcee9604ba4373dd56c)) +* **cpf:** add an obfuscate option to formatCpf ([b6150ab](https://github.com/brazilian-utils/javascript/commit/b6150aba86e1277ffc7ae8c69cb52039bf21c6b6)) +* **credit-card:** add isValidCreditCard ([5c74b88](https://github.com/brazilian-utils/javascript/commit/5c74b8827ef7c3899fe02f984ccb3717f43a7161)) +* **cst:** add isValidCst and isValidCsosn ([536eec5](https://github.com/brazilian-utils/javascript/commit/536eec5bb1fcd52627338bc6942b0b18e5e33cfd)) +* **currency-to-words:** add convertCurrencyToWords ([e24e446](https://github.com/brazilian-utils/javascript/commit/e24e4461d1ca8503cd4f7ee63f967c7d575f8219)) +* **date-to-words:** add convertDateToWords ([b9b3a63](https://github.com/brazilian-utils/javascript/commit/b9b3a6397b663c2e9f1de880d30b7e42890a350e)) +* export public types from the package root ([6c67309](https://github.com/brazilian-utils/javascript/commit/6c673099299d61e53c9f03c72c6cd302bf5e7ea0)) +* **format:** mask the new formatters progressively like formatCpf and add pad to formatLegalNature ([e676688](https://github.com/brazilian-utils/javascript/commit/e676688b326b18165d160e94a45de3e6e8f1e344)) +* **iban:** add formatIban, isValidIban and parseIban ([31d3cb4](https://github.com/brazilian-utils/javascript/commit/31d3cb4ce408efa4923e76c78b1cb12466ca37e5)) +* **legal-nature:** add getLegalNature ([1abbd8c](https://github.com/brazilian-utils/javascript/commit/1abbd8c47be773ef8c05d7d49f0cba28ea8db17e)) +* **legal-nature:** expose the CONCLA category and add getLegalNaturesByCategory ([defbdf8](https://github.com/brazilian-utils/javascript/commit/defbdf83b8688f6a443b1f6e92d4769b039cbc8f)) +* **legal-nature:** mark the eight retired codes as legacy with their current code ([bb52cda](https://github.com/brazilian-utils/javascript/commit/bb52cda97ca79640856159144821ee26d324bc7d)) +* **municipality:** add getMunicipalities and getMunicipalityByCode (offline IBGE data) ([bed7b3f](https://github.com/brazilian-utils/javascript/commit/bed7b3f9cfababf6bc8e8c2b59dad5a91e2c0b14)) +* **municipality:** add overloaded return types to getMunicipality ([2687731](https://github.com/brazilian-utils/javascript/commit/2687731e2ced8803ebd3ae1d71f4420e526eee9f)) +* **ncm:** add formatNcm and isValidNcm ([80f50d1](https://github.com/brazilian-utils/javascript/commit/80f50d155993d7f3b30fa6fd22753a444a9c8eb3)) +* **nfe-key:** accept every 44-digit DF-e model, the SVC-SP emission and the XML id prefixes ([60fcb46](https://github.com/brazilian-utils/javascript/commit/60fcb46385072d915d50e824f6c3d9fec2943303)) +* **nfe-key:** accept the CT-e OS model 67 ([fe9e30f](https://github.com/brazilian-utils/javascript/commit/fe9e30fa25e197070779071dd6b8aa53500ccea0)) +* **nfe-key:** add formatNfeKey, isValidNfeKey and parseNfeKey ([d639a7a](https://github.com/brazilian-utils/javascript/commit/d639a7a5e4a38fc7be026058fc60ec45a0da66de)) +* **number-to-words:** add convertNumberToWords ([3a54ca0](https://github.com/brazilian-utils/javascript/commit/3a54ca0687e14619b6858f158d4f4c37e1f2992c)) +* **parse:** add the mask-stripping parse function of every new family ([c2dfcfa](https://github.com/brazilian-utils/javascript/commit/c2dfcfa09f92b1764765163083d9fe27f2768cb2)) +* **phone:** accept 7 and 8 as mobile first digits under version 2 ([af21b77](https://github.com/brazilian-utils/javascript/commit/af21b776f54ef94c727e867d809c4339e4d8b5a6)) +* **phone:** add isValidServicePhone and an accept/auto-mask upgrade to isValidPhone/formatPhone ([82df2d9](https://github.com/brazilian-utils/javascript/commit/82df2d9c7c8b07cdf83ee7b2f94aaf3e199e65e5)) +* **pix:** add generatePixPayload, isValidPixPayload, isValidPixKey, parsePixPayload and parsePixKey ([088861e](https://github.com/brazilian-utils/javascript/commit/088861e277cca1bf90627cf230258994f2dbd403)) +* **registro-profissional:** add isValidRegistroProfissional ([263c6ff](https://github.com/brazilian-utils/javascript/commit/263c6fffac90a86b49e9cf67d5d61684f9ad9c50)) +* **remove-accents:** add removeAccents ([18ff45e](https://github.com/brazilian-utils/javascript/commit/18ff45e19ba4c0a5c6ede092a41d3b9b3b4a80a4)) +* **renavam:** add generateRenavam ([e46aa21](https://github.com/brazilian-utils/javascript/commit/e46aa21d6910ba0179301d92a17fe6e30099d1a1)) +* **states:** add getStateByIbgeCode, getStateCodeByName, getStateNameByCode and getTimezoneByState ([cc3ce8a](https://github.com/brazilian-utils/javascript/commit/cc3ce8af6dbc0130763e1b09ac38ecd490417c2d)) +* **states:** tie the name, region and IBGE code of State to its code ([d8326f0](https://github.com/brazilian-utils/javascript/commit/d8326f0dc4b6ab7388f5aceffd4d630a88c9bc3f)) +* **types:** export the public types from the subpath entries ([6f2b2e8](https://github.com/brazilian-utils/javascript/commit/6f2b2e883559104b63f235992db2f3adc0533502)) +* **vin:** add isValidVin ([9d6c762](https://github.com/brazilian-utils/javascript/commit/9d6c76272608bb6aac5f51b6b5b3143a21041054)) +* **voter-id:** support 13-digit São Paulo/Minas Gerais voter ids ([9a3c4c4](https://github.com/brazilian-utils/javascript/commit/9a3c4c4b4bb53ca0b2903afb6f18dfba34355253)) + + +### Bug Fixes + +* account for FEBRABAN'"'"'s 22/02/2025 fator de vencimento cycle reset. ([6bde780](https://github.com/brazilian-utils/javascript/commit/6bde780845b5b0f067e83bc5a4e1e2e0fa0f41a0)) +* adjust build error and update deps ([40e0d85](https://github.com/brazilian-utils/javascript/commit/40e0d853088ef869fba5f268d3b9f000eb2b7ad9)) +* **api:** align the new utils with the library conventions ([58d561b](https://github.com/brazilian-utils/javascript/commit/58d561bcb925b8ea67ce5be883338702bbc63d0e)) +* **area-codes:** return regionName and regionCode from getAreaCodeInfo, as State does ([72856eb](https://github.com/brazilian-utils/javascript/commit/72856ebe9a4ec97cafdbf7574d1bec93fc489a69)) +* **bank-account:** accept only P for a Bradesco remainder of 1 and drop the extinct bank 746 ([e476a92](https://github.com/brazilian-utils/javascript/commit/e476a92d22d5624081acb652267095762f1c96b3)) +* **banks:** follow the Bacen STR participants CSV to its new address and repoint dead sources ([e5b8f9b](https://github.com/brazilian-utils/javascript/commit/e5b8f9b5a1f1a01ce1f4039e2e3ee28033e7f6ba)) +* **boleto:** keep the fator de vencimento inside the first cycle for an early reference date ([ee2f02b](https://github.com/brazilian-utils/javascript/commit/ee2f02b6e6a7508390c7a2a076f20f3d1249ad13)) +* **business-days:** return false from isBusinessDay for a non-string state code ([03e5c11](https://github.com/brazilian-utils/javascript/commit/03e5c11a8996676c489730eda317dc17d2b4cfa2)) +* **caepf:** reject a repeated base like CEI and CNO do ([f7eb3bb](https://github.com/brazilian-utils/javascript/commit/f7eb3bba910aeca253283c26429b4b4851dbfb87)) +* **capitalize:** keep the English possessive, single-letter designators and a pronoun me low ([7565d3d](https://github.com/brazilian-utils/javascript/commit/7565d3de2e571d1c986d0e0eaf26f90bf0eb0d8d)) +* **capitalize:** match user word lists case-insensitively and treat - and / as word boundaries ([2280040](https://github.com/brazilian-utils/javascript/commit/228004096756b405327d96f9de76c8c4de404633)) +* **capitalize:** read a designation written around a slash as the designation after ME ([4013eb3](https://github.com/brazilian-utils/javascript/commit/4013eb3fac95747af859e8c82739fa2abb519ffe)) +* **capitalize:** write ME as the pronoun after a hyphen and before a word that is not a designation ([27581f2](https://github.com/brazilian-utils/javascript/commit/27581f2bfc43e6d932ec8674432613d3982a7a51)) +* **cbo,cnae:** pad a numeric code before validating it ([fe32617](https://github.com/brazilian-utils/javascript/commit/fe32617242acb25a0b3cc0ba9fcb0aac421f9859)) +* **cep:** reject non-digit characters and drop the dead widenet provider ([ddaadd0](https://github.com/brazilian-utils/javascript/commit/ddaadd0ac74e22893769c0f369a13e7e8ea799d5)) +* **cep:** reject with the typed errors for a bad providers list, a missing UF and a BrasilAPI 404 ([02bd64f](https://github.com/brazilian-utils/javascript/commit/02bd64f4c63737629794f95615cab3ee2af71bcb)) +* **certidao:** reject unknown book types and take the matrícula as a string ([862a782](https://github.com/brazilian-utils/javascript/commit/862a7824bfa5492cc10a7291aa41fb6f5968e042)) +* **certidao:** require the registro civil service code 55 ([b8ded2e](https://github.com/brazilian-utils/javascript/commit/b8ded2e2d0f0830412cd5b878acf49729c1ed0b9)) +* **cfop:** drop the 23 group headings ending in 50 from the table ([27d6664](https://github.com/brazilian-utils/javascript/commit/27d6664e9cdc70d1277f452cbb7ed69164fb0859)) +* **cities:** return fresh copies and cache the combined list ([7ddcea0](https://github.com/brazilian-utils/javascript/commit/7ddcea0dd5927e7efbfdfe6292f3ed473cb17c58)) +* **cnpj:** fall back to the numeric format in generateCnpj for any version other than 2 ([ff2e3c9](https://github.com/brazilian-utils/javascript/commit/ff2e3c9a444a3f855630e3a3e52d58613444df24)) +* **cnpj:** select the alphanumeric rule only for version 2 ([3712fcd](https://github.com/brazilian-utils/javascript/commit/3712fcdfe571df714dd7203e49c5f74fb2bbcb74)) +* **cns,cei:** accept a run of separators like the other document formats ([fac0769](https://github.com/brazilian-utils/javascript/commit/fac0769735b385fef628dae8d84752763716d626)) +* **cns:** reject values that are not fifteen digits with optional separators ([b2795cd](https://github.com/brazilian-utils/javascript/commit/b2795cd0e37c32d6de11a9530d78da7ca69e1cb7)) +* **cpf:** use the Receita Federal região fiscal digit for MS and MT ([273a143](https://github.com/brazilian-utils/javascript/commit/273a1432e913939ce0e5f4c2c3f1e7e2b3c54f6c)) +* **credit-card:** accept only digits, spaces and hyphens and reject unsafe numbers ([203ea57](https://github.com/brazilian-utils/javascript/commit/203ea5725e2ce28f3768ab4473418e0c9a95af73)) +* **csosn:** read only the bare 3 digits, the code has no printed grouping ([214da0d](https://github.com/brazilian-utils/javascript/commit/214da0d9ea028caf5ef24d33513ebadc35259577)) +* **cst:** accept a separator only after the origin digit ([40bc6a8](https://github.com/brazilian-utils/javascript/commit/40bc6a8fd3dcfff5427406397d693cc0007d93c1)) +* **currency-to-words:** never round a sub-cent amount up to the next cent ([1fbcc08](https://github.com/brazilian-utils/javascript/commit/1fbcc089b3f6e9122abde5661d79c00aeaabdd86)) +* **currency:** coerce a non-string value without throwing and read the cents from the decimals ([c9f5a5e](https://github.com/brazilian-utils/javascript/commit/c9f5a5ec70402cb71c8f01f33fdec80eaba5bf9f)) +* **currency:** parse real decimal/thousands separators and never format non-finite values ([d205308](https://github.com/brazilian-utils/javascript/commit/d205308250d904a2417b0e977651d3f19b4a645a)) +* **email:** cap the final domain label at 63 letters ([aeef62c](https://github.com/brazilian-utils/javascript/commit/aeef62cf1d3da070122c264c4f5412aa8c814b08)) +* **email:** follow the WHATWG domain label grammar ([c415639](https://github.com/brazilian-utils/javascript/commit/c4156399982383d3e95153915fd3f130f041d81f)) +* **fetch:** reject a retries count that is not an integer ([2433f90](https://github.com/brazilian-utils/javascript/commit/2433f903aa7b0f6dc7e21ffda3d1b10eefa0d715)) +* generate alphanumeric CNPJs using the full A-Z alphabet ([cd6b5f4](https://github.com/brazilian-utils/javascript/commit/cd6b5f4a0fba8dd0cddcb487128474c079bb5a72)) +* generate alphanumeric CNPJs using the full A-Z alphabet ([dff411e](https://github.com/brazilian-utils/javascript/commit/dff411ebf250808ceb0fc72253eb54358bb49c8b)) +* generateCnpj generates alphanumeric CNPJs using the full A-Z alphabet. ([65c118c](https://github.com/brazilian-utils/javascript/commit/65c118c338dcae8798c6519344f02105023f648d)) +* generateCpf retries when the generated base would be a repeated-digit sequence. ([b6150ab](https://github.com/brazilian-utils/javascript/commit/b6150aba86e1277ffc7ae8c69cb52039bf21c6b6)) +* **generate:** never throw on a prototype key or an object without toString ([ca8d37d](https://github.com/brazilian-utils/javascript/commit/ca8d37d60fb1477c62bda4806b01c3e979d8910a)) +* **holidays:** add the GO and DF state entries, end PB 26/07 in 2015 and reject hostile state codes ([4645f54](https://github.com/brazilian-utils/javascript/commit/4645f5477060f52d19edee117b2e087e770e0c57)) +* **holidays:** audit every state holiday against its law ([e010b79](https://github.com/brazilian-utils/javascript/commit/e010b796cc0bf6e1ad0bcfceb20054e51936a1ef)) +* **holidays:** cite each state holiday's law and name the Consciência Negra entries ([d048c01](https://github.com/brazilian-utils/javascript/commit/d048c01ddaa09b224156a5ed76416800e2d937c0)) +* **holidays:** isHoliday returns a boolean and never throws ([f44d3a8](https://github.com/brazilian-utils/javascript/commit/f44d3a84ae7d933dbc3c6b74cd2c58f039ef2617)) +* **holidays:** move the Santa Catarina state holidays to Sunday per the 1999, 2004 and 2005 laws ([89cb3d5](https://github.com/brazilian-utils/javascript/commit/89cb3d5e23df2464675da88e8ab7ed52d7f6c52a)) +* **iban:** accept every account type letter of the SFN dictionary ([8b65923](https://github.com/brazilian-utils/javascript/commit/8b659237a9adea54be3316f1924d5bc8bbdce15c)) +* **iban:** accept only the printed IBAN characters before sanitizing ([dab1a9d](https://github.com/brazilian-utils/javascript/commit/dab1a9d620262b024160c0e001aab5919ce2a75a)) +* **iban:** reject 0 as the holder indicator and apply the printed character set to format and parse ([b688fd0](https://github.com/brazilian-utils/javascript/commit/b688fd0b427ffc32ef0a26ce18d2242d172efcb2)) +* **ie:** accept SP produtor rural and Tocantins 11-digit registrations ([464bb6e](https://github.com/brazilian-utils/javascript/commit/464bb6e33d30b39380017fd5f6c22d87609a9139)) +* isValidCpf accepts whitespace and the common separators between groups. ([b6150ab](https://github.com/brazilian-utils/javascript/commit/b6150aba86e1277ffc7ae8c69cb52039bf21c6b6)) +* **legal-nature:** replace the table with IBGE/CONCLA Natureza Jurídica 2021 ([501f8ac](https://github.com/brazilian-utils/javascript/commit/501f8ac1d1c8ed489c989d79bcbdede84faa2b8a)) +* **legal-nature:** strip the mask from a numeric code in getLegalNature ([ff7eda6](https://github.com/brazilian-utils/javascript/commit/ff7eda6024b57f15cc12986406573332cf38e0d2)) +* **license-plate:** fall back to the default format instead of using an unknown one verbatim ([85d7a2e](https://github.com/brazilian-utils/javascript/commit/85d7a2edf9d7768ddaa7856e05c9f4ba3d95725b)) +* **license-plate:** strip mask characters and add Mercosul conversion ([0d12b7d](https://github.com/brazilian-utils/javascript/commit/0d12b7d776d6297fb06fb4a33de01642a8f71484)) +* **lookups:** read a code the same way whether it comes as a string or a number ([5ef48fd](https://github.com/brazilian-utils/javascript/commit/5ef48fd19be264d756257984d0dd6ccdb776086a)) +* **lookups:** read includeLegacy for truthiness in getBanks and getLegalNatures ([4613b6d](https://github.com/brazilian-utils/javascript/commit/4613b6d40c609c18ce9bcfccaeffbd6c06630ccc)) +* **municipalities:** keep a state code that is not a string out of the own-property lookup ([aec89a6](https://github.com/brazilian-utils/javascript/commit/aec89a6978e3675357451ead152fc736846178d5)) +* **municipality:** resolve a numeric IBGE code in getMunicipality ([df51b0a](https://github.com/brazilian-utils/javascript/commit/df51b0a99e60ecd0f929157e377eead18d460b83)) +* **municipality:** return a fresh pair and overload the return type on the lookup direction ([033d6bd](https://github.com/brazilian-utils/javascript/commit/033d6bd727719e5339da1353abb10b25add2761a)) +* never throw on nullish input across the public API ([481fb92](https://github.com/brazilian-utils/javascript/commit/481fb92db1083506c16766fb985b17e80c2f4f39)) +* **nfe-key:** accept only the assigned tpEmis values ([e773022](https://github.com/brazilian-utils/javascript/commit/e773022566d27405187901496654b26a65a7511f)) +* **nfe-key:** return an empty string from formatNfeKey for a value that is not a key ([7d23f3a](https://github.com/brazilian-utils/javascript/commit/7d23f3a5314515641b96a9358e169489070e6ace)) +* **package:** resolve the subpath declarations under moduleResolution node ([1a27003](https://github.com/brazilian-utils/javascript/commit/1a270035165a8c95f55d93a65052035a08b3240c)) +* **passport:** accept lowercase and mask characters ([c5644ec](https://github.com/brazilian-utils/javascript/commit/c5644ecd16ca6c395cf4d82d28d29767a963c2b5)) +* **passport:** never throw on hostile objects and delegate formatPassport to parsePassport ([f6b1df2](https://github.com/brazilian-utils/javascript/commit/f6b1df25519eef9244756eb1277994ff13152bc7)) +* **phone:** group a 10-digit landline under nanp and auto, never throw on an unknown mask ([33ebc6e](https://github.com/brazilian-utils/javascript/commit/33ebc6eecf96dd0da1a804f03348f6fc3aa29935)) +* **phone:** read a bare 55 before a service number as the country code ([5c34f47](https://github.com/brazilian-utils/javascript/commit/5c34f470ce086514060ed9edd66ad52a5140bd4f)) +* **pis:** accept alphanumeric-style separators and avoid repeated-digit bases ([a8a78dc](https://github.com/brazilian-utils/javascript/commit/a8a78dcee52fd17543781d10e5b3d2f57da9ef94)) +* **pix:** keep the word boundary when a merchant name carries non-ASCII whitespace ([31bbcb8](https://github.com/brazilian-utils/javascript/commit/31bbcb8e86b79d18edd3181c7dd5b8fd832c9fe9)) +* **pix:** optional point of initiation, Pix Saque payloads and amounts that round-trip ([6334f2f](https://github.com/brazilian-utils/javascript/commit/6334f2f227d53cb03449b857210467bec6cc4102)) +* **pix:** read only mobile numbers as phone keys ([828b7dc](https://github.com/brazilian-utils/javascript/commit/828b7dca8e650d4a4ff29974bcd161302a05a87d)) +* **pix:** reject a dynamic payload that carries a Pix Saque facilitator ([c16f096](https://github.com/brazilian-utils/javascript/commit/c16f096241d0aa7e6c65899d8c9af88adfc3d0bc)) +* **pix:** validate the key syntax, the location encoding and the payload pairing ([e76f0c3](https://github.com/brazilian-utils/javascript/commit/e76f0c3fbc305b0e971053d9c26e8a28e076425e)) +* **processo-juridico:** check the órgão and tribunal codes against Resolução CNJ 65/2008 ([110bc12](https://github.com/brazilian-utils/javascript/commit/110bc1260d34b5c8f6bd6d161c305dbcd8786b84)) +* **processo-juridico:** use the CNJ Resolução 65/2008 dot-separated mask ([431e2b4](https://github.com/brazilian-utils/javascript/commit/431e2b4361d3d81664e15b11d416c98e7b7d97dd)) +* **registro-profissional:** follow the CFC and CFP registration layouts ([5915813](https://github.com/brazilian-utils/javascript/commit/5915813440572d0c3c04c8e1a195cf4ca797acfa)) +* **registro-profissional:** read T and S as transfer suffixes after the CRC check digit ([898186f](https://github.com/brazilian-utils/javascript/commit/898186f81f967ba3471d83cd03df0bc124803939)) +* reject negative, fractional and unsafe numbers in every code lookup ([9cb73d0](https://github.com/brazilian-utils/javascript/commit/9cb73d0a528332c481fb74dfc3a61565c3d17ed7)) +* reject stray characters in isValidCnh, isValidVoterId and isValidProcessoJuridico ([47a9db2](https://github.com/brazilian-utils/javascript/commit/47a9db2a2317e2bec7eba3ed9647f4d7eba45adb)) +* **renavam:** reject repeated digits and stray characters ([873065e](https://github.com/brazilian-utils/javascript/commit/873065e8187f4d235f6362842414ac7b8512ffd9)) +* resolve to null when code is not exactly 7 digits, without making a request. ([2687731](https://github.com/brazilian-utils/javascript/commit/2687731e2ced8803ebd3ae1d71f4420e526eee9f)) +* **scripts:** keep a retired bank code legacy when the dataset falls back to BrasilAPI ([8a2a38e](https://github.com/brazilian-utils/javascript/commit/8a2a38ef8b2c9d67c13bf81f60a619cb925d1dfd)) +* **service-phone:** drop 112 and 911 and add 141 per the Anatel Ato 43.151/2004 ([cfc5ed0](https://github.com/brazilian-utils/javascript/commit/cfc5ed028a3d3a47cbd8374dbf9a863af7e7d249)) +* **states:** sort by pt-BR locale and return fresh, mutation-safe copies ([e894d3c](https://github.com/brazilian-utils/javascript/commit/e894d3c8dbbc6d9d00c95ccbaf3662d922097834)) +* **tables:** validate the input of every code lookup the same way ([7cdd6c8](https://github.com/brazilian-utils/javascript/commit/7cdd6c8c721d00a32dd012b37c8d4ccebb4996fb)) +* **types:** keep the [@deprecated](https://github.com/deprecated) tag of the 2.3.0 aliases in the declarations ([8cb0a29](https://github.com/brazilian-utils/javascript/commit/8cb0a290df89bfc6050827a6e63bf14c40ce9681)) +* **types:** re-export the bank and state types from the eight subpaths that still lacked them ([4d44ec4](https://github.com/brazilian-utils/javascript/commit/4d44ec4f8db82f72439336efd6fb4704cb9a25e0)) +* **types:** re-export the option and state types from the calendar and area code subpaths ([edf4577](https://github.com/brazilian-utils/javascript/commit/edf457770d2e706bfe5d88ce0a37c91d6b8e425a)) +* **types:** roll up declaration entrypoint ([40f2f18](https://github.com/brazilian-utils/javascript/commit/40f2f18e03c4e0ffbd8f2c2416c08fb64301becc)) +* **types:** roll up declaration entrypoint ([9524bae](https://github.com/brazilian-utils/javascript/commit/9524bae7b5bf2eda6ee6ae7be7cc70aa8a936240)) +* **validators:** accept the CPF mask separators at the printed groups of the NF-e key, IBAN and card ([0e38f5e](https://github.com/brazilian-utils/javascript/commit/0e38f5e89a3f539fee8e4fe3b8cf3c3954cebef0)) +* **words:** write the groups the way the official texts do, without commas, and spell 14 quatorze ([6d47c14](https://github.com/brazilian-utils/javascript/commit/6d47c14d7083da83f4bccc726af8fd0210888927)) + + +### Performance + +* cache Intl.NumberFormat instances per (symbol, precision) pair. ([d205308](https://github.com/brazilian-utils/javascript/commit/d205308250d904a2417b0e977651d3f19b4a645a)) +* remove top-level allocations to restore tree-shaking ([f84dc93](https://github.com/brazilian-utils/javascript/commit/f84dc9366c59910d36c2885581b27ab5981b6a90)) + + +### Documentation + +* add llms.txt, community health files and refresh docs/changelog ([076d914](https://github.com/brazilian-utils/javascript/commit/076d9145764f8fb1209a1b9ac51c0f0c0cd92233)) +* align the README, migration guide, changelog header and release config with the toolchain ([6804088](https://github.com/brazilian-utils/javascript/commit/68040880e4f612c9d7bf14018f919f1ef3acd4a6)) +* badges, a "why" section, the brand logo on the docs cover and search ([7160341](https://github.com/brazilian-utils/javascript/commit/71603413e61427faa8f912940af3334138362632)) +* bring the v1 to v2 migration guide up to 2.4.0 ([edbc98e](https://github.com/brazilian-utils/javascript/commit/edbc98e07096f71906168d8476f4dd79365542b5)) +* **business-days:** name the includeOptional and stateCode options in the three walkers ([3600310](https://github.com/brazilian-utils/javascript/commit/3600310f61a730be9e7211dbbf4697a0e2d5ceb0)) +* **cep:** say a CEP that starts with 0 has to be a string when given as a number ([882cf95](https://github.com/brazilian-utils/javascript/commit/882cf9554ad01595a794eb734a47df256a18e50f)) +* cite the acts and ajustes behind the fiscal and calendar utilities ([1d3aeb0](https://github.com/brazilian-utils/javascript/commit/1d3aeb0da27ea95d9e3719170eb8958c4aa88193)) +* cite the annexes, decrees and manuals behind the identifiers and refresh the generated pages ([01b7d32](https://github.com/brazilian-utils/javascript/commit/01b7d325fd0ac40548ae64f28f258a8fe22b2fec)) +* cite the primary source behind every validator and lookup ([5247e22](https://github.com/brazilian-utils/javascript/commit/5247e22c6157a3f22347c4afb5587074501cbf6f)) +* describe every option used in the examples and correct the remaining citations ([e35bc22](https://github.com/brazilian-utils/javascript/commit/e35bc2221790b1b9b56db90e3949219d99d342af)) +* describe the acervo codes of art. 473, the arrecadação result and the legal-nature header ([e935499](https://github.com/brazilian-utils/javascript/commit/e93549970b95aaf7767e9ad328a51f7abb6adce8)) +* document every public type and export the types the API refers to ([79f36f7](https://github.com/brazilian-utils/javascript/commit/79f36f7cc45033c5b7ebd32024a6bde7ae0f0524)) +* final pass before the release ([6a33dea](https://github.com/brazilian-utils/javascript/commit/6a33dea44faaaa8f3faff13354d5142b1ca2232a)) +* final pass on the docs, README, package metadata and GitHub files ([8170689](https://github.com/brazilian-utils/javascript/commit/817068960f66b3030f8f66a71859f85628bdb7c9)) +* fix the examples and source citations the function-by-function review flagged ([b79cef0](https://github.com/brazilian-utils/javascript/commit/b79cef0c46cae164fd189a5ef637a5f2551f33a7)) +* group the utilities reference by family ([bffdcd2](https://github.com/brazilian-utils/javascript/commit/bffdcd227f6e32382bbc79206fd6b1c6e6c28897)) +* **municipalities:** deprecate getCities and getMunicipality in favour of the municipality family ([d313bcc](https://github.com/brazilian-utils/javascript/commit/d313bcc27a169453cabd41ccbbc2ea8bc71374bc)) +* put every cited URL on its own citation line and fill the thin sections ([68bc902](https://github.com/brazilian-utils/javascript/commit/68bc902db03fa0aad12544a801c04d2daba93140)) +* **readme:** state the Node.js 24 development requirement, apart from the library range ([bb91be4](https://github.com/brazilian-utils/javascript/commit/bb91be4f371fb7e4d1f6cc56a6b48b2c02e90d9f)) +* refine the utilities pages and use npm run for the package scripts ([d0dba0a](https://github.com/brazilian-utils/javascript/commit/d0dba0ac5de997175af599d59b9fa8edab692113)) +* **site:** move the docsify site to v5 ([5dd2a97](https://github.com/brazilian-utils/javascript/commit/5dd2a976ac6100f33814867efed3a041f3c5b6fe)) +* state the measured isValidCpf size and fix two comments in the words tables ([e879cb4](https://github.com/brazilian-utils/javascript/commit/e879cb4c4226131a10b0c02ad81216dcb91a353b)) +* state the supported Node.js range instead of 20+ in the feature list ([3ab1b44](https://github.com/brazilian-utils/javascript/commit/3ab1b44e1b260035c9b828caa692618a4b92598f)) +* track the public API surface with API Extractor ([ec56e4f](https://github.com/brazilian-utils/javascript/commit/ec56e4f49a91303d8faac250c3bc092134fa71d9)) +* **words:** cite the articles of Lei 14.822/2024 that carry each spelling ([5c8a9d4](https://github.com/brazilian-utils/javascript/commit/5c8a9d424149f882ddfa077e86f9cdb4e1e984bd)) + + +### Data + +* **data:** refresh CFOP from the consolidated annex, CBO from the official CSV and the CST table ([602800c](https://github.com/brazilian-utils/javascript/commit/602800c37e8c8ece251bb7761affe34f0cb8ff6c)) +* **data:** refresh the banks dataset from the current Bacen STR list ([e0f4e2d](https://github.com/brazilian-utils/javascript/commit/e0f4e2df19e2ae12a29c91dac5396c54bb47d679)) +* **data:** refresh the NCM table with the codes in force ([413b955](https://github.com/brazilian-utils/javascript/commit/413b955b4c0809eafdcb9c45a9634a02e8768200)) + ## [2.3.0](https://github.com/brazilian-utils/javascript/compare/2.2.0...2.3.0) (2026-04-08) ### Features diff --git a/package-lock.json b/package-lock.json index cda9f9ee2..17b5632a7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@brazilian-utils/brazilian-utils", - "version": "2.3.0", + "version": "2.4.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@brazilian-utils/brazilian-utils", - "version": "2.3.0", + "version": "2.4.0", "license": "MIT", "devDependencies": { "@arethetypeswrong/core": "0.18.5", diff --git a/package.json b/package.json index 011fb953f..f29fe68fb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@brazilian-utils/brazilian-utils", - "version": "2.3.0", + "version": "2.4.0", "description": "Zero-dependency, tree-shakeable TypeScript utilities for Brazilian data: validate, format, parse and generate CPF, CNPJ, CEP, boleto, Pix, phone, holidays and more.", "keywords": [ "boleto", From 8e5123116fcf20b5355c0cf41532f326a263fcc7 Mon Sep 17 00:00:00 2001 From: Hyan Mandian <5044101+hyanmandian@users.noreply.github.com> Date: Thu, 17 Sep 2026 18:42:32 -0300 Subject: [PATCH 2/2] chore(main): drop the changelog lines of the legacy bank codes removed before the release --- CHANGELOG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2bc076f4c..8ed054d17 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,6 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). * **area-code:** add getAreaCodeInfo and getAreaCodesByState ([748d9b8](https://github.com/brazilian-utils/javascript/commit/748d9b8b477cb1af6016970f66d2bca65cf6cdbc)) * **area-code:** list every state a DDD serves (42, 47, 49 and 61 span two states) ([e17e55a](https://github.com/brazilian-utils/javascript/commit/e17e55a84cde49fe7915bb49b072847f2c91f9d9)) * **banks:** add getBanks, getBankByCode and getBankByIspb; validate every Bacen bank account ([ac2e84d](https://github.com/brazilian-utils/javascript/commit/ac2e84d7deeea2c7e737afc46251f1786a80a957)) -* **banks:** keep the codes that left the Bacen list as legacy banks ([f7922c7](https://github.com/brazilian-utils/javascript/commit/f7922c711e4e5c502a846947f267f549d9b1d445)) * **boleto:** support boleto de arrecadação and a referenceDate option ([6bde780](https://github.com/brazilian-utils/javascript/commit/6bde780845b5b0f067e83bc5a4e1e2e0fa0f41a0)) * **business-days:** add isBusinessDay, addBusinessDays and differenceInBusinessDays ([2b78c29](https://github.com/brazilian-utils/javascript/commit/2b78c29c0d768f1daecac9e0e01e03b1507d98fb)) * **business-days:** follow the date-fns signatures and add subBusinessDays ([688359f](https://github.com/brazilian-utils/javascript/commit/688359f200b7b4a7a2d68e668c1daf4d6b3424a2)) @@ -143,7 +142,6 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). * reject stray characters in isValidCnh, isValidVoterId and isValidProcessoJuridico ([47a9db2](https://github.com/brazilian-utils/javascript/commit/47a9db2a2317e2bec7eba3ed9647f4d7eba45adb)) * **renavam:** reject repeated digits and stray characters ([873065e](https://github.com/brazilian-utils/javascript/commit/873065e8187f4d235f6362842414ac7b8512ffd9)) * resolve to null when code is not exactly 7 digits, without making a request. ([2687731](https://github.com/brazilian-utils/javascript/commit/2687731e2ced8803ebd3ae1d71f4420e526eee9f)) -* **scripts:** keep a retired bank code legacy when the dataset falls back to BrasilAPI ([8a2a38e](https://github.com/brazilian-utils/javascript/commit/8a2a38ef8b2c9d67c13bf81f60a619cb925d1dfd)) * **service-phone:** drop 112 and 911 and add 141 per the Anatel Ato 43.151/2004 ([cfc5ed0](https://github.com/brazilian-utils/javascript/commit/cfc5ed028a3d3a47cbd8374dbf9a863af7e7d249)) * **states:** sort by pt-BR locale and return fresh, mutation-safe copies ([e894d3c](https://github.com/brazilian-utils/javascript/commit/e894d3c8dbbc6d9d00c95ccbaf3662d922097834)) * **tables:** validate the input of every code lookup the same way ([7cdd6c8](https://github.com/brazilian-utils/javascript/commit/7cdd6c8c721d00a32dd012b37c8d4ccebb4996fb))