@ca-plant-list/ca-plant-list 0.1.15 → 0.1.17
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.
- package/data/genera.json +4 -0
- package/lib/basepagerenderer.js +1 -1
- package/lib/taxon.js +10 -8
- package/package.json +1 -1
package/data/genera.json
CHANGED
package/lib/basepagerenderer.js
CHANGED
package/lib/taxon.js
CHANGED
@@ -17,9 +17,10 @@ class Taxon {
|
|
17
17
|
#rpiID;
|
18
18
|
#rankRPI;
|
19
19
|
#cesa;
|
20
|
+
#fesa;
|
20
21
|
#synonyms = [];
|
21
22
|
|
22
|
-
constructor( name, commonNames, status, jepsonID, calRecNum, iNatID, rpiID, rankRPI, cesa ) {
|
23
|
+
constructor( name, commonNames, status, jepsonID, calRecNum, iNatID, rpiID, rankRPI, cesa, fesa ) {
|
23
24
|
this.#name = name;
|
24
25
|
this.#genus = name.split( " " )[ 0 ];
|
25
26
|
this.#commonNames = commonNames ? commonNames.split( "," ).map( t => t.trim() ) : [];
|
@@ -29,7 +30,8 @@ class Taxon {
|
|
29
30
|
this.#iNatID = iNatID;
|
30
31
|
this.#rpiID = rpiID;
|
31
32
|
this.#rankRPI = rankRPI;
|
32
|
-
this.#cesa = cesa;
|
33
|
+
this.#cesa = cesa ? cesa : undefined;
|
34
|
+
this.#fesa = fesa ? fesa : undefined;
|
33
35
|
Genera.addTaxon( this );
|
34
36
|
}
|
35
37
|
|
@@ -68,12 +70,8 @@ class Taxon {
|
|
68
70
|
if ( !calfloraID ) {
|
69
71
|
return;
|
70
72
|
}
|
71
|
-
|
72
|
-
|
73
|
-
"Calflora",
|
74
|
-
{},
|
75
|
-
true
|
76
|
-
);
|
73
|
+
const link = HTML.getLink( "https://www.calflora.org/app/taxon?crn=" + calfloraID, "Calflora", {}, true );
|
74
|
+
return this.#cfSyn ? ( link + " (" + this.#cfSyn + ")" ) : link;
|
77
75
|
}
|
78
76
|
|
79
77
|
getCESA() {
|
@@ -88,6 +86,10 @@ class Taxon {
|
|
88
86
|
return Genera.getFamily( this.#genus );
|
89
87
|
}
|
90
88
|
|
89
|
+
getFESA() {
|
90
|
+
return this.#fesa;
|
91
|
+
}
|
92
|
+
|
91
93
|
getFileName( ext = "html" ) {
|
92
94
|
return this.getBaseFileName() + "." + ext;
|
93
95
|
}
|