Skip to content

Commit

Permalink
3.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoRicupero authored and Marketto committed Oct 16, 2024
1 parent fc43700 commit 2edc747
Show file tree
Hide file tree
Showing 82 changed files with 216 additions and 212 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.MD
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## CHANGELOG

### 3.1.1 (2024-10-16)

- Fixed Validator Bug For CF Validation of People born in January

### 3.1.0 (2024-09-19)

- Replaced moment with dayjs
Expand Down
5 changes: 2 additions & 3 deletions dist/codice-fiscale-utils.bundle.min.js

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion dist/codice-fiscale-utils.bundle.min.js.map

This file was deleted.

8 changes: 5 additions & 3 deletions dist/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* @marketto/codice-fiscale-utils 3.1.0
* @marketto/codice-fiscale-utils 3.1.1
* Copyright (c) 2019-2024, Marco Ricupero <marco.ricupero@gmail.com>
* License: MIT
*/
Expand Down Expand Up @@ -1341,7 +1341,9 @@ class CFMismatchValidator {
personalInfo.lastName &&
personalInfo.firstName &&
(personalInfo.date ||
(personalInfo.day && personalInfo.month && personalInfo.year)) &&
(personalInfo.day &&
typeof personalInfo.month === "number" &&
personalInfo.year)) &&
personalInfo.gender &&
personalInfo.place &&
!(yield this.matchPersonalInfo(personalInfo)));
Expand Down Expand Up @@ -1426,7 +1428,7 @@ class CFMismatchValidator {
? {}
: { date: "MISSING_OR_INVALID_DATE" })), (this.parser.cfToBirthDay(this.codiceFiscale)
? {}
: { date: "MISSING_OR_INVALID_DAY" })), (this.parser.cfToBirthMonth(this.codiceFiscale)
: { date: "MISSING_OR_INVALID_DAY" })), (typeof this.parser.cfToBirthMonth(this.codiceFiscale) === "number"
? {}
: { date: "MISSING_OR_INVALID_MONTH" })), (this.parser.cfToBirthYear(this.codiceFiscale)
? {}
Expand Down
4 changes: 2 additions & 2 deletions dist/index.mjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.mjs.map

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions docs/classes/CFMismatchValidator.html

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions docs/classes/CheckDigitizer.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/classes/CodiceFiscaleUtils.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/classes/DateUtils.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/classes/Gender.html

Large diffs are not rendered by default.

48 changes: 24 additions & 24 deletions docs/classes/Parser.html

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions docs/classes/Pattern.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/classes/Validator-1.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/enums/BirthMonth.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/enums/CRC.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/enums/Omocodes.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/interfaces/IMismatchVerboseErrors.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/modules/DATE_MATCHER.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>DATE_MATCHER | @marketto/codice-fiscale-utils</title><meta name="description" content="Documentation for @marketto/codice-fiscale-utils"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@marketto/codice-fiscale-utils</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@marketto/codice-fiscale-utils</a></li><li><a href="DATE_MATCHER.html">DATE_MATCHER</a></li></ul><h1>Namespace DATE_MATCHER</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/Marketto/codice-fiscale-utils/blob/ebc19ecc8dad9e2802a5a7f40d56027039e3a19a/src/date-utils/date-matcher.const.ts#L1">src/date-utils/date-matcher.const.ts:1</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><h3 class="tsd-index-heading uppercase">Index</h3><section class="tsd-index-section"><h3 class="tsd-index-heading">Variables</h3><div class="tsd-index-list"><a href="../variables/DATE_MATCHER.DAY.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>DAY</span></a>
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>DATE_MATCHER | @marketto/codice-fiscale-utils</title><meta name="description" content="Documentation for @marketto/codice-fiscale-utils"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@marketto/codice-fiscale-utils</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@marketto/codice-fiscale-utils</a></li><li><a href="DATE_MATCHER.html">DATE_MATCHER</a></li></ul><h1>Namespace DATE_MATCHER</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/Marketto/codice-fiscale-utils/blob/2b81d1fe62804085d1a40a0ff1047d0480f8f00c/src/date-utils/date-matcher.const.ts#L1">src/date-utils/date-matcher.const.ts:1</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><h3 class="tsd-index-heading uppercase">Index</h3><section class="tsd-index-section"><h3 class="tsd-index-heading">Variables</h3><div class="tsd-index-list"><a href="../variables/DATE_MATCHER.DAY.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>DAY</span></a>
<a href="../variables/DATE_MATCHER.DAYS_30_MONTHS.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>DAYS_<wbr/>30_<wbr/>MONTHS</span></a>
<a href="../variables/DATE_MATCHER.DAYS_31_MONTHS.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>DAYS_<wbr/>31_<wbr/>MONTHS</span></a>
<a href="../variables/DATE_MATCHER.HOURS.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>HOURS</span></a>
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/VALIDATOR.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>VALIDATOR | @marketto/codice-fiscale-utils</title><meta name="description" content="Documentation for @marketto/codice-fiscale-utils"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@marketto/codice-fiscale-utils</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@marketto/codice-fiscale-utils</a></li><li><a href="VALIDATOR.html">VALIDATOR</a></li></ul><h1>Namespace VALIDATOR</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/Marketto/codice-fiscale-utils/blob/ebc19ecc8dad9e2802a5a7f40d56027039e3a19a/src/const/matcher.const.ts#L1">src/const/matcher.const.ts:1</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><h3 class="tsd-index-heading uppercase">Index</h3><section class="tsd-index-section"><h3 class="tsd-index-heading">Variables</h3><div class="tsd-index-list"><a href="../variables/VALIDATOR.BELFIORE_CODE_MATCHER.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>BELFIORE_<wbr/>CODE_<wbr/>MATCHER</span></a>
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>VALIDATOR | @marketto/codice-fiscale-utils</title><meta name="description" content="Documentation for @marketto/codice-fiscale-utils"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@marketto/codice-fiscale-utils</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@marketto/codice-fiscale-utils</a></li><li><a href="VALIDATOR.html">VALIDATOR</a></li></ul><h1>Namespace VALIDATOR</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/Marketto/codice-fiscale-utils/blob/2b81d1fe62804085d1a40a0ff1047d0480f8f00c/src/const/matcher.const.ts#L1">src/const/matcher.const.ts:1</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><h3 class="tsd-index-heading uppercase">Index</h3><section class="tsd-index-section"><h3 class="tsd-index-heading">Variables</h3><div class="tsd-index-list"><a href="../variables/VALIDATOR.BELFIORE_CODE_MATCHER.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>BELFIORE_<wbr/>CODE_<wbr/>MATCHER</span></a>
<a href="../variables/VALIDATOR.CF_FULL_NAME_MATCHER.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>CF_<wbr/>FULL_<wbr/>NAME_<wbr/>MATCHER</span></a>
<a href="../variables/VALIDATOR.CF_NAME_MATCHER.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>CF_<wbr/>NAME_<wbr/>MATCHER</span></a>
<a href="../variables/VALIDATOR.CF_SURNAME_MATCHER.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-32"></use></svg><span>CF_<wbr/>SURNAME_<wbr/>MATCHER</span></a>
Expand Down
Loading

0 comments on commit 2edc747

Please sign in to comment.