@singi-labs/sifa-sdk 0.14.4 → 0.14.5
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/dist/index.cjs +59 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +50 -1
- package/dist/index.d.ts +50 -1
- package/dist/index.js +56 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2005,6 +2005,55 @@ function getPresentationRoleLabel(value) {
|
|
|
2005
2005
|
return PRESENTATION_ROLE_LABELS[value] ?? value;
|
|
2006
2006
|
}
|
|
2007
2007
|
|
|
2008
|
+
// src/taxonomy/publication-type.ts
|
|
2009
|
+
var PUBLICATION_TYPE_OPTIONS = [
|
|
2010
|
+
{ value: "journal-article", label: "Journal Article" },
|
|
2011
|
+
{ value: "conference-paper", label: "Conference Paper" },
|
|
2012
|
+
{ value: "conference-abstract", label: "Conference Abstract" },
|
|
2013
|
+
{ value: "conference-poster", label: "Conference Poster" },
|
|
2014
|
+
{ value: "book", label: "Book" },
|
|
2015
|
+
{ value: "book-chapter", label: "Book Chapter" },
|
|
2016
|
+
{ value: "book-review", label: "Book Review" },
|
|
2017
|
+
{ value: "edited-book", label: "Edited Book" },
|
|
2018
|
+
{ value: "dissertation", label: "Dissertation" },
|
|
2019
|
+
{ value: "preprint", label: "Preprint" },
|
|
2020
|
+
{ value: "dataset", label: "Dataset" },
|
|
2021
|
+
{ value: "report", label: "Report" },
|
|
2022
|
+
{ value: "review", label: "Review" },
|
|
2023
|
+
{ value: "patent", label: "Patent" },
|
|
2024
|
+
{ value: "software", label: "Software" },
|
|
2025
|
+
{ value: "working-paper", label: "Working Paper" },
|
|
2026
|
+
{ value: "artistic-performance", label: "Artistic Performance" },
|
|
2027
|
+
{ value: "lecture-speech", label: "Lecture/Speech" },
|
|
2028
|
+
{ value: "online-resource", label: "Online Resource" },
|
|
2029
|
+
{ value: "newspaper-article", label: "Newspaper Article" },
|
|
2030
|
+
{ value: "research-technique", label: "Research Technique" },
|
|
2031
|
+
{ value: "standards-and-policy", label: "Standards & Policy" },
|
|
2032
|
+
{ value: "technical-standard", label: "Technical Standard" },
|
|
2033
|
+
{ value: "registered-copyright", label: "Registered Copyright" },
|
|
2034
|
+
{ value: "translation", label: "Translation" },
|
|
2035
|
+
{ value: "dictionary-entry", label: "Dictionary Entry" },
|
|
2036
|
+
{ value: "encyclopedia-entry", label: "Encyclopedia Entry" },
|
|
2037
|
+
{ value: "supervised-student-publication", label: "Supervised Student Publication" },
|
|
2038
|
+
{ value: "annotation", label: "Annotation" },
|
|
2039
|
+
{ value: "test", label: "Test" },
|
|
2040
|
+
{ value: "spin-off-company", label: "Spin-off Company" },
|
|
2041
|
+
{ value: "disclosure", label: "Disclosure" },
|
|
2042
|
+
{ value: "license", label: "License" },
|
|
2043
|
+
{ value: "trademark", label: "Trademark" },
|
|
2044
|
+
{ value: "design", label: "Design" },
|
|
2045
|
+
// ORCID's catch-all. Labelled "Publication" rather than "Other" because it is
|
|
2046
|
+
// what shows on the card, and a badge reading "Other" tells a reader nothing.
|
|
2047
|
+
{ value: "other", label: "Publication" }
|
|
2048
|
+
];
|
|
2049
|
+
var PUBLICATION_TYPE_LABELS = Object.fromEntries(
|
|
2050
|
+
PUBLICATION_TYPE_OPTIONS.map((o) => [o.value, o.label])
|
|
2051
|
+
);
|
|
2052
|
+
function getPublicationTypeLabel(value) {
|
|
2053
|
+
if (!value) return void 0;
|
|
2054
|
+
return PUBLICATION_TYPE_LABELS[value] ?? "Publication";
|
|
2055
|
+
}
|
|
2056
|
+
|
|
2008
2057
|
// src/taxonomy/presentation-link-type.ts
|
|
2009
2058
|
var PRESENTATION_LINK_TYPE_OPTIONS = [
|
|
2010
2059
|
{ value: "id.sifa.defs#linkSlides", label: "Slides" },
|
|
@@ -2445,6 +2494,11 @@ function certDateExtractor(item) {
|
|
|
2445
2494
|
return { startDate: item.issueDate, endDate: item.expiryDate ?? item.issueDate };
|
|
2446
2495
|
}
|
|
2447
2496
|
|
|
2497
|
+
// src/format/doi.ts
|
|
2498
|
+
function normalizeDoi(value) {
|
|
2499
|
+
return value.trim().replace(/^https?:\/\/(dx\.)?doi\.org\//i, "").replace(/^doi:\s*/i, "");
|
|
2500
|
+
}
|
|
2501
|
+
|
|
2448
2502
|
// src/format/handle-utils.ts
|
|
2449
2503
|
function sanitizeHandleInput(raw) {
|
|
2450
2504
|
let identifier = raw.trim().replace(/^https?:\/\/bsky\.app\/profile\//i, "").replace(/^at:\/\//i, "").replace(/^@/, "").replace(/^https?:\/\//i, "");
|
|
@@ -5879,7 +5933,7 @@ function describeSifaRecord(collection, value) {
|
|
|
5879
5933
|
}
|
|
5880
5934
|
|
|
5881
5935
|
// src/index.ts
|
|
5882
|
-
var SIFA_SDK_VERSION = "0.14.
|
|
5936
|
+
var SIFA_SDK_VERSION = "0.14.5";
|
|
5883
5937
|
|
|
5884
5938
|
exports.ACTIVITY_TIERS = ACTIVITY_TIERS;
|
|
5885
5939
|
exports.ACTIVITY_VERBS = ACTIVITY_VERBS;
|
|
@@ -5956,6 +6010,8 @@ exports.PRESENTATION_ROLE_OPTIONS = PRESENTATION_ROLE_OPTIONS;
|
|
|
5956
6010
|
exports.PROFILE_INVESTMENT_NSID = PROFILE_INVESTMENT_NSID;
|
|
5957
6011
|
exports.PROFILE_INVOLVEMENT_NSID = PROFILE_INVOLVEMENT_NSID;
|
|
5958
6012
|
exports.PROJECT_ROLES = PROJECT_ROLES;
|
|
6013
|
+
exports.PUBLICATION_TYPE_LABELS = PUBLICATION_TYPE_LABELS;
|
|
6014
|
+
exports.PUBLICATION_TYPE_OPTIONS = PUBLICATION_TYPE_OPTIONS;
|
|
5959
6015
|
exports.PUBLISHERS = PUBLISHERS;
|
|
5960
6016
|
exports.PresentationDurationSchema = PresentationDurationSchema;
|
|
5961
6017
|
exports.PresentationLinkSchema = PresentationLinkSchema;
|
|
@@ -6051,6 +6107,7 @@ exports.getPdsDisplayName = getPdsDisplayName;
|
|
|
6051
6107
|
exports.getPlatformLabel = getPlatformLabel;
|
|
6052
6108
|
exports.getPresentationLinkTypeLabel = getPresentationLinkTypeLabel;
|
|
6053
6109
|
exports.getPresentationRoleLabel = getPresentationRoleLabel;
|
|
6110
|
+
exports.getPublicationTypeLabel = getPublicationTypeLabel;
|
|
6054
6111
|
exports.getPublisherByHost = getPublisherByHost;
|
|
6055
6112
|
exports.getPublisherById = getPublisherById;
|
|
6056
6113
|
exports.getPublisherFromSiteUrl = getPublisherFromSiteUrl;
|
|
@@ -6087,6 +6144,7 @@ exports.makeGraphFollowRecordSchema = makeGraphFollowRecordSchema;
|
|
|
6087
6144
|
exports.maxGraphemes = maxGraphemes;
|
|
6088
6145
|
exports.meetsContrastAA = meetsContrastAA;
|
|
6089
6146
|
exports.normalizeCompanyKey = normalizeCompanyKey;
|
|
6147
|
+
exports.normalizeDoi = normalizeDoi;
|
|
6090
6148
|
exports.normalizeLegalForm = normalizeLegalForm;
|
|
6091
6149
|
exports.normalizeOpenTo = normalizeOpenTo;
|
|
6092
6150
|
exports.normalizePlatformId = normalizePlatformId;
|