@ca-plant-list/ca-plant-list 0.4.17 → 0.4.19
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/exceptions.json +5 -3
- package/data/inattaxonphotos.csv +4 -0
- package/data/synonyms.csv +127 -122
- package/data/taxa.csv +22 -21
- package/data/text/Brassica-nigra.md +1 -0
- package/data/text/Brassica-rapa.md +1 -0
- package/data/text/Oxalis-oregana.footer.md +3 -0
- package/data/text/Oxalis-smalliana.footer.md +3 -0
- package/data/text/Polypodium-calirhiza.md +1 -0
- package/data/text/Polypodium-scouleri.md +1 -0
- package/data/text/Rumex-acetosella.md +1 -0
- package/lib/basepagerenderer.js +3 -3
- package/lib/csv.js +2 -1
- package/lib/ebook/images.js +5 -5
- package/lib/ebook/pages/page_list_species.js +1 -1
- package/lib/ebook/pages/taxonpage.js +2 -2
- package/lib/ebook/plantbook.js +1 -1
- package/lib/exceptions.js +3 -0
- package/lib/families.js +13 -13
- package/lib/genera.js +1 -1
- package/lib/htmltaxon.js +16 -7
- package/lib/index.d.ts +24 -0
- package/lib/pagerenderer.js +223 -220
- package/lib/photo.js +61 -31
- package/lib/taxa.js +2 -2
- package/lib/taxon.js +12 -3
- package/lib/tools/jepsoneflora.js +117 -152
- package/lib/tools/rpi.js +3 -4
- package/lib/tools/syncsv.js +41 -0
- package/lib/web/pagetaxon.js +4 -6
- package/package.json +6 -3
- package/scripts/cpl-tools.js +2 -11
- package/types/classes.d.ts +1 -28
- package/lib/inat_photo.js +0 -43
package/lib/inat_photo.js
DELETED
@@ -1,43 +0,0 @@
|
|
1
|
-
import { CC0, CC_BY, CC_BY_NC, COPYRIGHT, Photo } from "./photo.js";
|
2
|
-
|
3
|
-
class InatPhoto extends Photo {
|
4
|
-
/** @type {number} */
|
5
|
-
inatPhotoId;
|
6
|
-
/** @type {string} */
|
7
|
-
ext;
|
8
|
-
|
9
|
-
/**
|
10
|
-
* @param {number} id
|
11
|
-
* @param {string} ext
|
12
|
-
* @param {InatLicenseCode} licenseCode
|
13
|
-
* @param {string} attrName
|
14
|
-
*/
|
15
|
-
constructor(id, ext, licenseCode, attrName) {
|
16
|
-
/** @type {typeof COPYRIGHT | typeof CC_BY | typeof CC_BY_NC | typeof CC0} */
|
17
|
-
let rights = COPYRIGHT;
|
18
|
-
if (licenseCode === "cc0") rights = CC0;
|
19
|
-
else if (licenseCode === "cc-by") rights = CC_BY;
|
20
|
-
else if (licenseCode === "cc-by-nc") rights = CC_BY_NC;
|
21
|
-
super(null, attrName, rights);
|
22
|
-
this.inatPhotoId = id;
|
23
|
-
this.ext = ext;
|
24
|
-
}
|
25
|
-
|
26
|
-
getExt() {
|
27
|
-
return this.ext;
|
28
|
-
}
|
29
|
-
|
30
|
-
getId() {
|
31
|
-
return this.inatPhotoId;
|
32
|
-
}
|
33
|
-
|
34
|
-
getUrl() {
|
35
|
-
return `https://inaturalist-open-data.s3.amazonaws.com/photos/${this.inatPhotoId}/medium.${this.ext}`;
|
36
|
-
}
|
37
|
-
|
38
|
-
getSourceUrl() {
|
39
|
-
return `https://www.inaturalist.org/photos/${this.inatPhotoId}`;
|
40
|
-
}
|
41
|
-
}
|
42
|
-
|
43
|
-
export { InatPhoto };
|