@singi-labs/sifa-sdk 0.11.23 → 0.11.25
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/{adult-content-DLMF0jAx.d.cts → adult-content-pvNBfDQL.d.cts} +32 -1
- package/dist/{adult-content-DLMF0jAx.d.ts → adult-content-pvNBfDQL.d.ts} +32 -1
- package/dist/{feed-DMWCGvKv.d.cts → feed-D2ZV8Eaj.d.cts} +74 -1
- package/dist/{feed-DMWCGvKv.d.ts → feed-D2ZV8Eaj.d.ts} +74 -1
- package/dist/index-BXi6sYhX.d.ts +611 -0
- package/dist/index-CCi2sg_u.d.ts +261 -0
- package/dist/index-CtH-frgT.d.cts +611 -0
- package/dist/index-OBJQIB9t.d.cts +261 -0
- package/dist/index.cjs +134 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +64 -7
- package/dist/index.d.ts +64 -7
- package/dist/index.js +120 -2
- package/dist/index.js.map +1 -1
- package/dist/{keys-OgHsKn9B.d.ts → keys-CxTXTPnI.d.ts} +2 -2
- package/dist/{keys-6Ck_vMeF.d.cts → keys-c5LIN2pO.d.cts} +2 -2
- package/dist/query/fetchers/index.cjs +11 -0
- package/dist/query/fetchers/index.cjs.map +1 -1
- package/dist/query/fetchers/index.d.cts +4 -247
- package/dist/query/fetchers/index.d.ts +4 -247
- package/dist/query/fetchers/index.js +11 -0
- package/dist/query/fetchers/index.js.map +1 -1
- package/dist/query/hooks/index.cjs +11 -0
- package/dist/query/hooks/index.cjs.map +1 -1
- package/dist/query/hooks/index.d.cts +6 -558
- package/dist/query/hooks/index.d.ts +6 -558
- package/dist/query/hooks/index.js +11 -0
- package/dist/query/hooks/index.js.map +1 -1
- package/dist/query/index.cjs +47 -0
- package/dist/query/index.cjs.map +1 -1
- package/dist/query/index.d.cts +6 -6
- package/dist/query/index.d.ts +6 -6
- package/dist/query/index.js +44 -1
- package/dist/query/index.js.map +1 -1
- package/dist/schemas/index.cjs +14 -0
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.cts +415 -3
- package/dist/schemas/index.d.ts +415 -3
- package/dist/schemas/index.js +12 -1
- package/dist/schemas/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/shared-CHCY7Lst.d.cts +0 -416
- package/dist/shared-CHCY7Lst.d.ts +0 -416
package/dist/index.d.cts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { P as ProfileSkill, b as ProfilePresentationDelivery, L as LocationValue, c as PdsProviderInfo, d as Profile } from './adult-content-
|
|
2
|
-
export { e as ADULT_CONTENT_LABELS, f as ActiveApp, a as ActivityLabel, A as AdultContentLabel, C as CoSpeaker, g as Endorsement, h as EndorsementData, E as ExternalAccount, i as ExternalAccountKeytraceClaim, F as FeedItem, j as LanguageProficiency, k as PresentationLinkView, l as ProfileCertification, m as ProfileCourse, n as ProfileEducation, o as ProfileHonor, p as ProfileIndustry, q as
|
|
3
|
-
import {
|
|
4
|
-
export {
|
|
5
|
-
import {
|
|
6
|
-
export { A as AtmosphereFeedItem,
|
|
1
|
+
import { P as ProfileSkill, b as ProfilePresentationDelivery, L as LocationValue, c as PdsProviderInfo, d as Profile } from './adult-content-pvNBfDQL.cjs';
|
|
2
|
+
export { e as ADULT_CONTENT_LABELS, f as ActiveApp, a as ActivityLabel, A as AdultContentLabel, C as CoSpeaker, g as Endorsement, h as EndorsementData, E as ExternalAccount, i as ExternalAccountKeytraceClaim, F as FeedItem, j as LanguageProficiency, k as PresentationLinkView, l as ProfileCertification, m as ProfileCourse, n as ProfileEducation, o as ProfileHonor, p as ProfileIndustry, q as ProfileInvolvement, r as ProfileInvolvementLink, s as ProfileLanguage, t as ProfileLocation, u as ProfileOverrideSource, v as ProfilePosition, w as ProfilePresentation, x as ProfileProject, y as ProfilePublication, z as ProfileVolunteering, B as PublicationContributor, D as SkillRef, S as SkillSuggestion, T as TrustStat, V as VerifiedAccount, G as hasAdultContent } from './adult-content-pvNBfDQL.cjs';
|
|
3
|
+
import { PresentationDuration, ProfilePresentationDeliveryRecord, ProfilePresentationRecord } from './schemas/index.cjs';
|
|
4
|
+
export { ArtifactLink, ArtifactLinkSchema, EndorsementConfirmationRecord, EndorsementConfirmationRecordSchema, EndorsementRecord, EndorsementRecordSchema, GraphFollowRecord, GraphFollowRecordSchema, PROFILE_INVOLVEMENT_NSID, PresentationDurationSchema, PresentationLink, PresentationLinkSchema, ProfileCertificationRecord, ProfileCertificationRecordSchema, ProfileCourseRecord, ProfileCourseRecordSchema, ProfileEducationRecord, ProfileEducationRecordSchema, ProfileExternalAccountRecord, ProfileExternalAccountRecordSchema, ProfileHonorRecord, ProfileHonorRecordSchema, ProfileInvolvementRecord, ProfileInvolvementRecordSchema, ProfileLanguageRecord, ProfileLanguageRecordSchema, ProfilePositionRecord, ProfilePositionRecordSchema, ProfilePresentationDeliveryRecordSchema, ProfilePresentationRecordSchema, ProfileProjectRecord, ProfileProjectRecordSchema, ProfilePublicationRecord, ProfilePublicationRecordSchema, ProfileSelfRecord, ProfileSelfRecordSchema, ProfileSkillRecord, ProfileSkillRecordSchema, ProfileVolunteeringRecord, ProfileVolunteeringRecordSchema, PublicationAuthor, PublicationAuthorSchema, atUriSchema, cidSchema, datetimeSchema, didSchema, externalRecordRefSchema, languageTagSchema, makeGraphFollowRecordSchema, maxGraphemes, selfLabelsSchema, strongRefSchema, uriSchema } from './schemas/index.cjs';
|
|
5
|
+
import { E as EntitySearchResult } from './feed-D2ZV8Eaj.cjs';
|
|
6
|
+
export { A as AtmosphereFeedItem, d as AtmosphereFeedItemSchema, e as EntityImportSearchResponse, f as EntityImportSearchResponseSchema, g as EntityMintDomainResponse, h as EntityMintDomainResponseSchema, i as EntityResolveDomainRequest, j as EntityResolveDomainRequestSchema, k as EntityResolveDomainResponse, l as EntityResolveDomainResponseSchema, m as EntitySearchResponse, n as EntitySearchResponseSchema, o as EntitySearchResultSchema, p as EntitySelectRequest, q as EntitySelectRequestSchema, r as EntitySelectResponse, s as EntitySelectResponseSchema, t as FEATURE_FLAGS, b as FeatureAllowlistEntry, u as FeatureAllowlistEntrySchema, c as FeatureFlag, v as FeedActor, w as FeedActorSchema, x as FeedCursor, y as FollowFeedItem, z as FollowFeedItemSchema, F as FollowFeedPage, B as FollowFeedPageSchema, a as FollowProfileItem, C as FollowProfilePage, D as FollowProfilePageSchema, G as FollowProfileSchema, S as SifaFeedItem, H as SifaFeedItemSchema, I as decodeFeedCursor, J as encodeFeedCursor } from './feed-D2ZV8Eaj.cjs';
|
|
7
7
|
import 'zod';
|
|
8
8
|
|
|
9
9
|
type ContinentCode = 'AF' | 'AN' | 'AS' | 'EU' | 'NA' | 'OC' | 'SA';
|
|
@@ -470,6 +470,43 @@ declare const CALENDAR_EVENT_STATUS_LABELS: Record<string, string>;
|
|
|
470
470
|
/** Resolve a label for a calendar-event status token. Falls back to the raw value. */
|
|
471
471
|
declare function getCalendarEventStatusLabel(value: string | undefined | null): string | undefined;
|
|
472
472
|
|
|
473
|
+
/**
|
|
474
|
+
* Involvement-kind taxonomy. Mirrors `id.sifa.defs#involvementKind.knownValues`
|
|
475
|
+
* from sifa-lexicons. `label` is the picker/select label; `heading` is the
|
|
476
|
+
* profile section heading a record of this kind renders under (charity records,
|
|
477
|
+
* including mapped legacy `volunteering`, render under "Volunteering").
|
|
478
|
+
*/
|
|
479
|
+
interface InvolvementKindOption {
|
|
480
|
+
value: string;
|
|
481
|
+
label: string;
|
|
482
|
+
heading: string;
|
|
483
|
+
}
|
|
484
|
+
declare const INVOLVEMENT_KIND_OPTIONS: InvolvementKindOption[];
|
|
485
|
+
declare const INVOLVEMENT_KIND_LABELS: Record<string, string>;
|
|
486
|
+
declare const INVOLVEMENT_KIND_HEADINGS: Record<string, string>;
|
|
487
|
+
/** Resolve the select label for an involvement-kind token. Falls back to the raw value. */
|
|
488
|
+
declare function getInvolvementKindLabel(value: string | undefined | null): string | undefined;
|
|
489
|
+
/**
|
|
490
|
+
* Resolve the display-section heading for an involvement-kind token. Unknown
|
|
491
|
+
* kinds (including a future token an older client hasn't learned) fall under
|
|
492
|
+
* "Other" so a record is never dropped from the profile.
|
|
493
|
+
*/
|
|
494
|
+
declare function getInvolvementKindHeading(value: string | undefined | null): string;
|
|
495
|
+
|
|
496
|
+
/**
|
|
497
|
+
* Artifact-link-kind taxonomy. Mirrors the bare-string `knownValues` of
|
|
498
|
+
* `id.sifa.defs#artifactLink.kind` from sifa-lexicons. Open set: any string is
|
|
499
|
+
* valid; these are the recognized kinds used to pick an icon and a default label.
|
|
500
|
+
*/
|
|
501
|
+
interface ArtifactLinkKindOption {
|
|
502
|
+
value: string;
|
|
503
|
+
label: string;
|
|
504
|
+
}
|
|
505
|
+
declare const ARTIFACT_LINK_KIND_OPTIONS: ArtifactLinkKindOption[];
|
|
506
|
+
declare const ARTIFACT_LINK_KIND_LABELS: Record<string, string>;
|
|
507
|
+
/** Resolve a label for an artifact-link-kind value. Falls back to the raw value. */
|
|
508
|
+
declare function getArtifactLinkKindLabel(value: string | undefined | null): string | undefined;
|
|
509
|
+
|
|
473
510
|
/**
|
|
474
511
|
* Best-effort title-case for a company display name.
|
|
475
512
|
*
|
|
@@ -1063,6 +1100,26 @@ declare function pickPrimaryPosition<T extends PrimaryPositionCandidate>(positio
|
|
|
1063
1100
|
/** True when the whole employer string is a self-employment / pseudo employer. */
|
|
1064
1101
|
declare function isPseudoEmployer(company: string): boolean;
|
|
1065
1102
|
|
|
1103
|
+
/**
|
|
1104
|
+
* Lightweight "does this typeahead query look like a domain?" predicate, used to
|
|
1105
|
+
* decide whether to fire the domain grow-on-demand path (resolve-domain) on a
|
|
1106
|
+
* local typeahead miss. It is a heuristic, NOT a validator: the API re-validates
|
|
1107
|
+
* against the public suffix list. It only needs to distinguish "randstad.com"
|
|
1108
|
+
* (a domain) from "Randstad" / "Acme Corp" (a name) so a plain company name
|
|
1109
|
+
* never triggers a domain lookup.
|
|
1110
|
+
*
|
|
1111
|
+
* Accepts an optional scheme and path (`https://www.stripe.com/pricing`), a
|
|
1112
|
+
* leading `www.`, and multi-label hosts; requires at least one dot and a >=2
|
|
1113
|
+
* alpha final label (TLD-shaped); rejects whitespace and `@` (emails).
|
|
1114
|
+
*
|
|
1115
|
+
* Runs on uncontrolled typeahead input, so it is deliberately ReDoS-safe: the
|
|
1116
|
+
* input length is bounded up front (a domain is <=253 chars), the host is
|
|
1117
|
+
* extracted with plain string ops (no scheme/path/trailing-dot regex), and each
|
|
1118
|
+
* label is validated by a single anchored, bounded pattern. There is no
|
|
1119
|
+
* ambiguous or nested quantifier anywhere, so matching is linear in the input.
|
|
1120
|
+
*/
|
|
1121
|
+
declare function looksLikeDomain(query: string): boolean;
|
|
1122
|
+
|
|
1066
1123
|
/**
|
|
1067
1124
|
* Disambiguation-display helpers for the org typeahead (#159, Flow 1A-2). Two
|
|
1068
1125
|
* same-name orgs must be told apart at a glance, so each row shows its domain,
|
|
@@ -1120,4 +1177,4 @@ declare function isLinked(entityRef: string | null | undefined): boolean;
|
|
|
1120
1177
|
*/
|
|
1121
1178
|
declare const SIFA_SDK_VERSION: string;
|
|
1122
1179
|
|
|
1123
|
-
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type AppCategoryId, type AppUrlPatterns, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, type CardHealth, type CardHealthStrategy, type ContinentCode, type CsvRow, DIMENSIONS_MAX_SCORE, type DimensionKey, type DimensionMap, type DisambiguationFields, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, INDUSTRY_OPTIONS, type IndustryOption, type KnownAppId, type LexiconEntry, LocationValue, MIN_SKILLS, type MergedProfileSkill, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryPositionCandidate, Profile, type ProfileCompletion, type ProfileDimensionInputs, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileSkill, type Publisher, type RgbColor, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, type SkillCategory, type TierMeta, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, categoryForApp, certDateExtractor, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, singleDateExtractor, sortByDateDesc, stripHtmlToText, summarizePresentationDeliveries, truncateGraphemes };
|
|
1180
|
+
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type AppCategoryId, type AppUrlPatterns, type ArtifactLinkKindOption, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, type CardHealth, type CardHealthStrategy, type ContinentCode, type CsvRow, DIMENSIONS_MAX_SCORE, type DimensionKey, type DimensionMap, type DisambiguationFields, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, INDUSTRY_OPTIONS, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvolvementKindOption, type KnownAppId, type LexiconEntry, LocationValue, MIN_SKILLS, type MergedProfileSkill, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryPositionCandidate, Profile, type ProfileCompletion, type ProfileDimensionInputs, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileSkill, type Publisher, type RgbColor, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, type SkillCategory, type TierMeta, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, categoryForApp, certDateExtractor, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, singleDateExtractor, sortByDateDesc, stripHtmlToText, summarizePresentationDeliveries, truncateGraphemes };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { P as ProfileSkill, b as ProfilePresentationDelivery, L as LocationValue, c as PdsProviderInfo, d as Profile } from './adult-content-
|
|
2
|
-
export { e as ADULT_CONTENT_LABELS, f as ActiveApp, a as ActivityLabel, A as AdultContentLabel, C as CoSpeaker, g as Endorsement, h as EndorsementData, E as ExternalAccount, i as ExternalAccountKeytraceClaim, F as FeedItem, j as LanguageProficiency, k as PresentationLinkView, l as ProfileCertification, m as ProfileCourse, n as ProfileEducation, o as ProfileHonor, p as ProfileIndustry, q as
|
|
3
|
-
import {
|
|
4
|
-
export {
|
|
5
|
-
import {
|
|
6
|
-
export { A as AtmosphereFeedItem,
|
|
1
|
+
import { P as ProfileSkill, b as ProfilePresentationDelivery, L as LocationValue, c as PdsProviderInfo, d as Profile } from './adult-content-pvNBfDQL.js';
|
|
2
|
+
export { e as ADULT_CONTENT_LABELS, f as ActiveApp, a as ActivityLabel, A as AdultContentLabel, C as CoSpeaker, g as Endorsement, h as EndorsementData, E as ExternalAccount, i as ExternalAccountKeytraceClaim, F as FeedItem, j as LanguageProficiency, k as PresentationLinkView, l as ProfileCertification, m as ProfileCourse, n as ProfileEducation, o as ProfileHonor, p as ProfileIndustry, q as ProfileInvolvement, r as ProfileInvolvementLink, s as ProfileLanguage, t as ProfileLocation, u as ProfileOverrideSource, v as ProfilePosition, w as ProfilePresentation, x as ProfileProject, y as ProfilePublication, z as ProfileVolunteering, B as PublicationContributor, D as SkillRef, S as SkillSuggestion, T as TrustStat, V as VerifiedAccount, G as hasAdultContent } from './adult-content-pvNBfDQL.js';
|
|
3
|
+
import { PresentationDuration, ProfilePresentationDeliveryRecord, ProfilePresentationRecord } from './schemas/index.js';
|
|
4
|
+
export { ArtifactLink, ArtifactLinkSchema, EndorsementConfirmationRecord, EndorsementConfirmationRecordSchema, EndorsementRecord, EndorsementRecordSchema, GraphFollowRecord, GraphFollowRecordSchema, PROFILE_INVOLVEMENT_NSID, PresentationDurationSchema, PresentationLink, PresentationLinkSchema, ProfileCertificationRecord, ProfileCertificationRecordSchema, ProfileCourseRecord, ProfileCourseRecordSchema, ProfileEducationRecord, ProfileEducationRecordSchema, ProfileExternalAccountRecord, ProfileExternalAccountRecordSchema, ProfileHonorRecord, ProfileHonorRecordSchema, ProfileInvolvementRecord, ProfileInvolvementRecordSchema, ProfileLanguageRecord, ProfileLanguageRecordSchema, ProfilePositionRecord, ProfilePositionRecordSchema, ProfilePresentationDeliveryRecordSchema, ProfilePresentationRecordSchema, ProfileProjectRecord, ProfileProjectRecordSchema, ProfilePublicationRecord, ProfilePublicationRecordSchema, ProfileSelfRecord, ProfileSelfRecordSchema, ProfileSkillRecord, ProfileSkillRecordSchema, ProfileVolunteeringRecord, ProfileVolunteeringRecordSchema, PublicationAuthor, PublicationAuthorSchema, atUriSchema, cidSchema, datetimeSchema, didSchema, externalRecordRefSchema, languageTagSchema, makeGraphFollowRecordSchema, maxGraphemes, selfLabelsSchema, strongRefSchema, uriSchema } from './schemas/index.js';
|
|
5
|
+
import { E as EntitySearchResult } from './feed-D2ZV8Eaj.js';
|
|
6
|
+
export { A as AtmosphereFeedItem, d as AtmosphereFeedItemSchema, e as EntityImportSearchResponse, f as EntityImportSearchResponseSchema, g as EntityMintDomainResponse, h as EntityMintDomainResponseSchema, i as EntityResolveDomainRequest, j as EntityResolveDomainRequestSchema, k as EntityResolveDomainResponse, l as EntityResolveDomainResponseSchema, m as EntitySearchResponse, n as EntitySearchResponseSchema, o as EntitySearchResultSchema, p as EntitySelectRequest, q as EntitySelectRequestSchema, r as EntitySelectResponse, s as EntitySelectResponseSchema, t as FEATURE_FLAGS, b as FeatureAllowlistEntry, u as FeatureAllowlistEntrySchema, c as FeatureFlag, v as FeedActor, w as FeedActorSchema, x as FeedCursor, y as FollowFeedItem, z as FollowFeedItemSchema, F as FollowFeedPage, B as FollowFeedPageSchema, a as FollowProfileItem, C as FollowProfilePage, D as FollowProfilePageSchema, G as FollowProfileSchema, S as SifaFeedItem, H as SifaFeedItemSchema, I as decodeFeedCursor, J as encodeFeedCursor } from './feed-D2ZV8Eaj.js';
|
|
7
7
|
import 'zod';
|
|
8
8
|
|
|
9
9
|
type ContinentCode = 'AF' | 'AN' | 'AS' | 'EU' | 'NA' | 'OC' | 'SA';
|
|
@@ -470,6 +470,43 @@ declare const CALENDAR_EVENT_STATUS_LABELS: Record<string, string>;
|
|
|
470
470
|
/** Resolve a label for a calendar-event status token. Falls back to the raw value. */
|
|
471
471
|
declare function getCalendarEventStatusLabel(value: string | undefined | null): string | undefined;
|
|
472
472
|
|
|
473
|
+
/**
|
|
474
|
+
* Involvement-kind taxonomy. Mirrors `id.sifa.defs#involvementKind.knownValues`
|
|
475
|
+
* from sifa-lexicons. `label` is the picker/select label; `heading` is the
|
|
476
|
+
* profile section heading a record of this kind renders under (charity records,
|
|
477
|
+
* including mapped legacy `volunteering`, render under "Volunteering").
|
|
478
|
+
*/
|
|
479
|
+
interface InvolvementKindOption {
|
|
480
|
+
value: string;
|
|
481
|
+
label: string;
|
|
482
|
+
heading: string;
|
|
483
|
+
}
|
|
484
|
+
declare const INVOLVEMENT_KIND_OPTIONS: InvolvementKindOption[];
|
|
485
|
+
declare const INVOLVEMENT_KIND_LABELS: Record<string, string>;
|
|
486
|
+
declare const INVOLVEMENT_KIND_HEADINGS: Record<string, string>;
|
|
487
|
+
/** Resolve the select label for an involvement-kind token. Falls back to the raw value. */
|
|
488
|
+
declare function getInvolvementKindLabel(value: string | undefined | null): string | undefined;
|
|
489
|
+
/**
|
|
490
|
+
* Resolve the display-section heading for an involvement-kind token. Unknown
|
|
491
|
+
* kinds (including a future token an older client hasn't learned) fall under
|
|
492
|
+
* "Other" so a record is never dropped from the profile.
|
|
493
|
+
*/
|
|
494
|
+
declare function getInvolvementKindHeading(value: string | undefined | null): string;
|
|
495
|
+
|
|
496
|
+
/**
|
|
497
|
+
* Artifact-link-kind taxonomy. Mirrors the bare-string `knownValues` of
|
|
498
|
+
* `id.sifa.defs#artifactLink.kind` from sifa-lexicons. Open set: any string is
|
|
499
|
+
* valid; these are the recognized kinds used to pick an icon and a default label.
|
|
500
|
+
*/
|
|
501
|
+
interface ArtifactLinkKindOption {
|
|
502
|
+
value: string;
|
|
503
|
+
label: string;
|
|
504
|
+
}
|
|
505
|
+
declare const ARTIFACT_LINK_KIND_OPTIONS: ArtifactLinkKindOption[];
|
|
506
|
+
declare const ARTIFACT_LINK_KIND_LABELS: Record<string, string>;
|
|
507
|
+
/** Resolve a label for an artifact-link-kind value. Falls back to the raw value. */
|
|
508
|
+
declare function getArtifactLinkKindLabel(value: string | undefined | null): string | undefined;
|
|
509
|
+
|
|
473
510
|
/**
|
|
474
511
|
* Best-effort title-case for a company display name.
|
|
475
512
|
*
|
|
@@ -1063,6 +1100,26 @@ declare function pickPrimaryPosition<T extends PrimaryPositionCandidate>(positio
|
|
|
1063
1100
|
/** True when the whole employer string is a self-employment / pseudo employer. */
|
|
1064
1101
|
declare function isPseudoEmployer(company: string): boolean;
|
|
1065
1102
|
|
|
1103
|
+
/**
|
|
1104
|
+
* Lightweight "does this typeahead query look like a domain?" predicate, used to
|
|
1105
|
+
* decide whether to fire the domain grow-on-demand path (resolve-domain) on a
|
|
1106
|
+
* local typeahead miss. It is a heuristic, NOT a validator: the API re-validates
|
|
1107
|
+
* against the public suffix list. It only needs to distinguish "randstad.com"
|
|
1108
|
+
* (a domain) from "Randstad" / "Acme Corp" (a name) so a plain company name
|
|
1109
|
+
* never triggers a domain lookup.
|
|
1110
|
+
*
|
|
1111
|
+
* Accepts an optional scheme and path (`https://www.stripe.com/pricing`), a
|
|
1112
|
+
* leading `www.`, and multi-label hosts; requires at least one dot and a >=2
|
|
1113
|
+
* alpha final label (TLD-shaped); rejects whitespace and `@` (emails).
|
|
1114
|
+
*
|
|
1115
|
+
* Runs on uncontrolled typeahead input, so it is deliberately ReDoS-safe: the
|
|
1116
|
+
* input length is bounded up front (a domain is <=253 chars), the host is
|
|
1117
|
+
* extracted with plain string ops (no scheme/path/trailing-dot regex), and each
|
|
1118
|
+
* label is validated by a single anchored, bounded pattern. There is no
|
|
1119
|
+
* ambiguous or nested quantifier anywhere, so matching is linear in the input.
|
|
1120
|
+
*/
|
|
1121
|
+
declare function looksLikeDomain(query: string): boolean;
|
|
1122
|
+
|
|
1066
1123
|
/**
|
|
1067
1124
|
* Disambiguation-display helpers for the org typeahead (#159, Flow 1A-2). Two
|
|
1068
1125
|
* same-name orgs must be told apart at a glance, so each row shows its domain,
|
|
@@ -1120,4 +1177,4 @@ declare function isLinked(entityRef: string | null | undefined): boolean;
|
|
|
1120
1177
|
*/
|
|
1121
1178
|
declare const SIFA_SDK_VERSION: string;
|
|
1122
1179
|
|
|
1123
|
-
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type AppCategoryId, type AppUrlPatterns, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, type CardHealth, type CardHealthStrategy, type ContinentCode, type CsvRow, DIMENSIONS_MAX_SCORE, type DimensionKey, type DimensionMap, type DisambiguationFields, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, INDUSTRY_OPTIONS, type IndustryOption, type KnownAppId, type LexiconEntry, LocationValue, MIN_SKILLS, type MergedProfileSkill, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryPositionCandidate, Profile, type ProfileCompletion, type ProfileDimensionInputs, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileSkill, type Publisher, type RgbColor, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, type SkillCategory, type TierMeta, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, categoryForApp, certDateExtractor, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, singleDateExtractor, sortByDateDesc, stripHtmlToText, summarizePresentationDeliveries, truncateGraphemes };
|
|
1180
|
+
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type AppCategoryId, type AppUrlPatterns, type ArtifactLinkKindOption, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, type CardHealth, type CardHealthStrategy, type ContinentCode, type CsvRow, DIMENSIONS_MAX_SCORE, type DimensionKey, type DimensionMap, type DisambiguationFields, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, INDUSTRY_OPTIONS, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvolvementKindOption, type KnownAppId, type LexiconEntry, LocationValue, MIN_SKILLS, type MergedProfileSkill, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryPositionCandidate, Profile, type ProfileCompletion, type ProfileDimensionInputs, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileSkill, type Publisher, type RgbColor, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, type SkillCategory, type TierMeta, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, categoryForApp, certDateExtractor, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, singleDateExtractor, sortByDateDesc, stripHtmlToText, summarizePresentationDeliveries, truncateGraphemes };
|
package/dist/index.js
CHANGED
|
@@ -1432,6 +1432,53 @@ function getCalendarEventStatusLabel(value) {
|
|
|
1432
1432
|
return CALENDAR_EVENT_STATUS_LABELS[value] ?? value;
|
|
1433
1433
|
}
|
|
1434
1434
|
|
|
1435
|
+
// src/taxonomy/involvement-kind.ts
|
|
1436
|
+
var INVOLVEMENT_KIND_OPTIONS = [
|
|
1437
|
+
{ value: "id.sifa.defs#involvementOpenSource", label: "Open source", heading: "Open Source" },
|
|
1438
|
+
{ value: "id.sifa.defs#involvementCommunity", label: "Community", heading: "Community" },
|
|
1439
|
+
{ value: "id.sifa.defs#involvementCharity", label: "Volunteering", heading: "Volunteering" },
|
|
1440
|
+
{ value: "id.sifa.defs#involvementCivic", label: "Civic", heading: "Civic" },
|
|
1441
|
+
{ value: "id.sifa.defs#involvementOther", label: "Other", heading: "Other" }
|
|
1442
|
+
];
|
|
1443
|
+
var INVOLVEMENT_KIND_LABELS = Object.fromEntries(
|
|
1444
|
+
INVOLVEMENT_KIND_OPTIONS.map((o) => [o.value, o.label])
|
|
1445
|
+
);
|
|
1446
|
+
var INVOLVEMENT_KIND_HEADINGS = Object.fromEntries(
|
|
1447
|
+
INVOLVEMENT_KIND_OPTIONS.map((o) => [o.value, o.heading])
|
|
1448
|
+
);
|
|
1449
|
+
function getInvolvementKindLabel(value) {
|
|
1450
|
+
if (!value) return void 0;
|
|
1451
|
+
return INVOLVEMENT_KIND_LABELS[value] ?? value;
|
|
1452
|
+
}
|
|
1453
|
+
function getInvolvementKindHeading(value) {
|
|
1454
|
+
if (!value) return "Other";
|
|
1455
|
+
return INVOLVEMENT_KIND_HEADINGS[value] ?? "Other";
|
|
1456
|
+
}
|
|
1457
|
+
|
|
1458
|
+
// src/taxonomy/artifact-link-kind.ts
|
|
1459
|
+
var ARTIFACT_LINK_KIND_OPTIONS = [
|
|
1460
|
+
{ value: "pull-request", label: "Pull request" },
|
|
1461
|
+
{ value: "issue", label: "Issue" },
|
|
1462
|
+
{ value: "commit", label: "Commit" },
|
|
1463
|
+
{ value: "review", label: "Review" },
|
|
1464
|
+
{ value: "release", label: "Release" },
|
|
1465
|
+
{ value: "talk", label: "Talk" },
|
|
1466
|
+
{ value: "video", label: "Video" },
|
|
1467
|
+
{ value: "slides", label: "Slides" },
|
|
1468
|
+
{ value: "article", label: "Article" },
|
|
1469
|
+
{ value: "thread", label: "Thread" },
|
|
1470
|
+
{ value: "dataset", label: "Dataset" },
|
|
1471
|
+
{ value: "edit", label: "Edit" },
|
|
1472
|
+
{ value: "other", label: "Link" }
|
|
1473
|
+
];
|
|
1474
|
+
var ARTIFACT_LINK_KIND_LABELS = Object.fromEntries(
|
|
1475
|
+
ARTIFACT_LINK_KIND_OPTIONS.map((o) => [o.value, o.label])
|
|
1476
|
+
);
|
|
1477
|
+
function getArtifactLinkKindLabel(value) {
|
|
1478
|
+
if (!value) return void 0;
|
|
1479
|
+
return ARTIFACT_LINK_KIND_LABELS[value] ?? value;
|
|
1480
|
+
}
|
|
1481
|
+
|
|
1435
1482
|
// src/format/company-name.ts
|
|
1436
1483
|
var SMALL_WORDS = /* @__PURE__ */ new Set([
|
|
1437
1484
|
"a",
|
|
@@ -2504,6 +2551,46 @@ function isPseudoEmployer(company) {
|
|
|
2504
2551
|
return PSEUDO_EMPLOYERS.has(normalized);
|
|
2505
2552
|
}
|
|
2506
2553
|
|
|
2554
|
+
// src/logic/domain-detect.ts
|
|
2555
|
+
var MAX_DOMAIN_LEN = 253;
|
|
2556
|
+
var LABEL = /^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$/;
|
|
2557
|
+
var TLD = /^[a-z]{2,63}$/;
|
|
2558
|
+
function stripTrailingDots(s) {
|
|
2559
|
+
let end = s.length;
|
|
2560
|
+
while (end > 0 && s.charCodeAt(end - 1) === 46) end -= 1;
|
|
2561
|
+
return s.slice(0, end);
|
|
2562
|
+
}
|
|
2563
|
+
function looksLikeDomain(query) {
|
|
2564
|
+
const q = query.trim().toLowerCase();
|
|
2565
|
+
if (!q || q.length > MAX_DOMAIN_LEN) return false;
|
|
2566
|
+
if (q.includes(" ") || q.includes(" ") || q.includes("@")) return false;
|
|
2567
|
+
let host = q;
|
|
2568
|
+
const schemeAt = host.indexOf("://");
|
|
2569
|
+
if (schemeAt !== -1) host = host.slice(schemeAt + 3);
|
|
2570
|
+
for (let i = 0; i < host.length; i += 1) {
|
|
2571
|
+
const ch = host[i];
|
|
2572
|
+
if (ch === "/" || ch === "?" || ch === "#") {
|
|
2573
|
+
host = host.slice(0, i);
|
|
2574
|
+
break;
|
|
2575
|
+
}
|
|
2576
|
+
}
|
|
2577
|
+
if (host.startsWith("www.")) host = host.slice(4);
|
|
2578
|
+
const colonAt = host.lastIndexOf(":");
|
|
2579
|
+
if (colonAt !== -1 && /^[0-9]{1,5}$/.test(host.slice(colonAt + 1))) {
|
|
2580
|
+
host = host.slice(0, colonAt);
|
|
2581
|
+
}
|
|
2582
|
+
host = stripTrailingDots(host);
|
|
2583
|
+
if (!host || host.length > MAX_DOMAIN_LEN) return false;
|
|
2584
|
+
const labels = host.split(".");
|
|
2585
|
+
if (labels.length < 2) return false;
|
|
2586
|
+
const tld = labels[labels.length - 1];
|
|
2587
|
+
if (tld === void 0 || !TLD.test(tld)) return false;
|
|
2588
|
+
for (let i = 0; i < labels.length - 1; i += 1) {
|
|
2589
|
+
if (!LABEL.test(labels[i])) return false;
|
|
2590
|
+
}
|
|
2591
|
+
return true;
|
|
2592
|
+
}
|
|
2593
|
+
|
|
2507
2594
|
// src/logic/entity-disambiguation.ts
|
|
2508
2595
|
function entityDisambiguationLabel(fields) {
|
|
2509
2596
|
const parts = [];
|
|
@@ -2627,6 +2714,17 @@ var EntitySelectResponseSchema = z.object({
|
|
|
2627
2714
|
var EntityImportSearchResponseSchema = z.object({
|
|
2628
2715
|
results: z.array(EntitySearchResultSchema)
|
|
2629
2716
|
});
|
|
2717
|
+
var EntityResolveDomainRequestSchema = z.object({
|
|
2718
|
+
domain: z.string().min(1).max(253)
|
|
2719
|
+
});
|
|
2720
|
+
var EntityResolveDomainResponseSchema = z.object({
|
|
2721
|
+
results: z.array(EntitySearchResultSchema),
|
|
2722
|
+
canMint: z.boolean()
|
|
2723
|
+
});
|
|
2724
|
+
var EntityMintDomainResponseSchema = z.object({
|
|
2725
|
+
result: EntitySearchResultSchema,
|
|
2726
|
+
pending: z.boolean()
|
|
2727
|
+
});
|
|
2630
2728
|
var EndorsementRecordSchema = z.object({
|
|
2631
2729
|
subject: didSchema,
|
|
2632
2730
|
skill: strongRefSchema,
|
|
@@ -2790,6 +2888,26 @@ var ProfileHonorRecordSchema = z.object({
|
|
|
2790
2888
|
awardedAt: datetimeSchema.optional(),
|
|
2791
2889
|
createdAt: datetimeSchema
|
|
2792
2890
|
});
|
|
2891
|
+
var PROFILE_INVOLVEMENT_NSID = "id.sifa.profile.involvement";
|
|
2892
|
+
var partialDateSchema = z.string().regex(/^\d{4}(-\d{2}(-\d{2}(T.+)?)?)?$/, "Expected YYYY, YYYY-MM, YYYY-MM-DD, or a datetime");
|
|
2893
|
+
var ArtifactLinkSchema = z.object({
|
|
2894
|
+
url: uriSchema,
|
|
2895
|
+
kind: z.string().optional(),
|
|
2896
|
+
label: z.string().refine(maxGraphemes(200)).max(2e3).optional()
|
|
2897
|
+
}).passthrough();
|
|
2898
|
+
var ProfileInvolvementRecordSchema = z.object({
|
|
2899
|
+
kind: z.string(),
|
|
2900
|
+
upstream: z.string().refine(maxGraphemes(256)).max(2560).optional(),
|
|
2901
|
+
upstreamDid: didSchema.optional(),
|
|
2902
|
+
upstreamUrl: uriSchema.optional(),
|
|
2903
|
+
role: z.string().refine(maxGraphemes(256)).max(2560).optional(),
|
|
2904
|
+
description: z.string().refine(maxGraphemes(5e3)).max(5e4).optional(),
|
|
2905
|
+
startedAt: partialDateSchema.optional(),
|
|
2906
|
+
endedAt: partialDateSchema.optional(),
|
|
2907
|
+
links: z.array(ArtifactLinkSchema).max(50).optional(),
|
|
2908
|
+
labels: selfLabelsSchema.optional(),
|
|
2909
|
+
createdAt: datetimeSchema
|
|
2910
|
+
}).passthrough();
|
|
2793
2911
|
var ProfileLanguageRecordSchema = z.object({
|
|
2794
2912
|
name: z.string().min(1).refine(maxGraphemes(64)).max(640),
|
|
2795
2913
|
proficiency: z.string().optional(),
|
|
@@ -2912,8 +3030,8 @@ var ProfileVolunteeringRecordSchema = z.object({
|
|
|
2912
3030
|
});
|
|
2913
3031
|
|
|
2914
3032
|
// src/index.ts
|
|
2915
|
-
var SIFA_SDK_VERSION = "0.11.
|
|
3033
|
+
var SIFA_SDK_VERSION = "0.11.25";
|
|
2916
3034
|
|
|
2917
|
-
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, ADULT_CONTENT_LABELS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, AtmosphereFeedItemSchema, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, DIMENSIONS_MAX_SCORE, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EndorsementConfirmationRecordSchema, EndorsementRecordSchema, EntityImportSearchResponseSchema, EntitySearchResponseSchema, EntitySearchResultSchema, EntitySelectRequestSchema, EntitySelectResponseSchema, FEATURE_FLAGS, FeatureAllowlistEntrySchema, FeedActorSchema, FollowFeedItemSchema, FollowFeedPageSchema, FollowProfilePageSchema, FollowProfileSchema, GraphFollowRecordSchema, INDUSTRY_OPTIONS, MIN_SKILLS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLISHERS, PresentationDurationSchema, PresentationLinkSchema, ProfileCertificationRecordSchema, ProfileCourseRecordSchema, ProfileEducationRecordSchema, ProfileExternalAccountRecordSchema, ProfileHonorRecordSchema, ProfileLanguageRecordSchema, ProfilePositionRecordSchema, ProfilePresentationDeliveryRecordSchema, ProfilePresentationRecordSchema, ProfileProjectRecordSchema, ProfilePublicationRecordSchema, ProfileSelfRecordSchema, ProfileSkillRecordSchema, ProfileVolunteeringRecordSchema, PublicationAuthorSchema, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, SifaFeedItemSchema, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, atUriSchema, categoryForApp, certDateExtractor, cidSchema, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, datetimeSchema, decodeFeedCursor, dedupeSkills, detectPdsProvider, didSchema, dimensionsFromInputs, durationFromMinutes, encodeFeedCursor, entityDisambiguationLabel, entityResultKey, externalRecordRefSchema, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, hasAdultContent, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, languageTagSchema, lexiconDateExtractor, limitCombiningMarks, makeGraphFollowRecordSchema, maxGraphemes, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, selfLabelsSchema, singleDateExtractor, sortByDateDesc, stripHtmlToText, strongRefSchema, summarizePresentationDeliveries, truncateGraphemes, uriSchema };
|
|
3035
|
+
export { ACTIVITY_TIERS, ACTIVITY_VISIBILITY_RULES, ADULT_CONTENT_LABELS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, ArtifactLinkSchema, AtmosphereFeedItemSchema, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, DIMENSIONS_MAX_SCORE, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EndorsementConfirmationRecordSchema, EndorsementRecordSchema, EntityImportSearchResponseSchema, EntityMintDomainResponseSchema, EntityResolveDomainRequestSchema, EntityResolveDomainResponseSchema, EntitySearchResponseSchema, EntitySearchResultSchema, EntitySelectRequestSchema, EntitySelectResponseSchema, FEATURE_FLAGS, FeatureAllowlistEntrySchema, FeedActorSchema, FollowFeedItemSchema, FollowFeedPageSchema, FollowProfilePageSchema, FollowProfileSchema, GraphFollowRecordSchema, INDUSTRY_OPTIONS, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, MIN_SKILLS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PROFILE_INVOLVEMENT_NSID, PUBLISHERS, PresentationDurationSchema, PresentationLinkSchema, ProfileCertificationRecordSchema, ProfileCourseRecordSchema, ProfileEducationRecordSchema, ProfileExternalAccountRecordSchema, ProfileHonorRecordSchema, ProfileInvolvementRecordSchema, ProfileLanguageRecordSchema, ProfilePositionRecordSchema, ProfilePresentationDeliveryRecordSchema, ProfilePresentationRecordSchema, ProfileProjectRecordSchema, ProfilePublicationRecordSchema, ProfileSelfRecordSchema, ProfileSkillRecordSchema, ProfileVolunteeringRecordSchema, PublicationAuthorSchema, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, SifaFeedItemSchema, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, atUriSchema, categoryForApp, certDateExtractor, cidSchema, classifyEntityRef, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countryCodeToFlag, dateRangeExtractor, datetimeSchema, decodeFeedCursor, dedupeSkills, detectPdsProvider, didSchema, dimensionsFromInputs, durationFromMinutes, encodeFeedCursor, entityDisambiguationLabel, entityResultKey, externalRecordRefSchema, findIndustry, formatCompanyName, formatDistanceToNow, formatLocation, formatPresentationDuration, formatRelativeTime, getActivityTaxonomyVersion, getActivityTier, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getDisplayLabel, getEmploymentTypeLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabelKey, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getWorkplaceTypeLabel, groupSkillsByCategory, hasAdultContent, isAppCategory, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isPseudoEmployer, isValidRgbColor, isVisibleActivityItem, languageTagSchema, lexiconDateExtractor, limitCombiningMarks, looksLikeDomain, makeGraphFollowRecordSchema, maxGraphemes, meetsContrastAA, normalizeCompanyKey, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeWorkplaceTypes, openToTokenToValue, openToValueToToken, parseIntendedAudiences, parseLocationString, parsePresentationDuration, pdsProviderFromApi, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, relativeLuminance, resolveCardHealth, resolveCardUrl, rgbToString, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, selfLabelsSchema, singleDateExtractor, sortByDateDesc, stripHtmlToText, strongRefSchema, summarizePresentationDeliveries, truncateGraphemes, uriSchema };
|
|
2918
3036
|
//# sourceMappingURL=index.js.map
|
|
2919
3037
|
//# sourceMappingURL=index.js.map
|