@singi-labs/sifa-sdk 0.19.85 → 0.19.87

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.d.cts CHANGED
@@ -1054,6 +1054,16 @@ declare function normalizeDoi(value: string): string;
1054
1054
  */
1055
1055
  declare function openAlexWorkUrl(id: string | undefined): string | undefined;
1056
1056
 
1057
+ /** Output variants served by the sifa-api blob proxy. */
1058
+ type BlobProxyVariant = 'thumb' | 'avatar';
1059
+ /**
1060
+ * URL of the sifa-api blob proxy (`GET /api/blob/:did/:cid?v=`) for a blob
1061
+ * owned by `did`. The proxy fetches the blob from the owner's PDS, resizes it
1062
+ * (`thumb`: 1000px JPEG, `avatar`: 256px WebP) and caches it. Use it for blobs
1063
+ * the Bluesky image CDN refuses, such as very large originals.
1064
+ */
1065
+ declare function blobProxyUrl(baseUrl: string, did: string, cid: string, variant: BlobProxyVariant): string;
1066
+
1057
1067
  /**
1058
1068
  * Endorsement comments carry an optional relationship-context prefix written by
1059
1069
  * the endorse dialog, e.g. `[worked_together: Acme] great colleague`. The prefix
@@ -1382,6 +1392,8 @@ declare function parseIntendedAudiences(input: string | undefined, delimiter?: s
1382
1392
  * only to produce readable text.
1383
1393
  */
1384
1394
  declare function stripHtmlToText(input: string | undefined): string;
1395
+ /** Friendly role values the import maps to a token (keyword matches aside). */
1396
+ declare const PRESENTATION_ROLE_VALUES: string[];
1385
1397
  /**
1386
1398
  * Map a friendly role value to its token. An existing token passes through.
1387
1399
  * Free-text or compound values (e.g. "Organizer & co-host/moderator") are
@@ -1391,6 +1403,8 @@ declare function stripHtmlToText(input: string | undefined): string;
1391
1403
  * behavior, so a fixed role dropdown never has to render arbitrary strings.
1392
1404
  */
1393
1405
  declare function normalizePresentationRole(value: string | undefined): string | undefined;
1406
+ /** Friendly mode values the import maps to a token. */
1407
+ declare const PRESENTATION_MODE_VALUES: string[];
1394
1408
  /** Map a friendly mode value to the community calendar token; drops an unknown value. */
1395
1409
  declare function normalizePresentationMode(value: string | undefined): string | undefined;
1396
1410
  interface ParsedPresentation {
@@ -1408,6 +1422,65 @@ interface ParsedDelivery {
1408
1422
  /** Map a row of the deliveries template to a delivery record (minus createdAt and presentationRef). */
1409
1423
  declare function presentationDeliveryCsvRowToRecord(row: CsvRow): ParsedDelivery;
1410
1424
 
1425
+ /**
1426
+ * Why a Talks & sessions CSV row was skipped (`error`) or imported with a
1427
+ * caveat (`warning`). Consumers map the code to translated copy.
1428
+ */
1429
+ type TalksImportIssueCode =
1430
+ /** error: a talk row has no title. */
1431
+ 'missingTitle'
1432
+ /** error: a URL column holds something that is not an http(s) URL. */
1433
+ | 'invalidUrl'
1434
+ /** error: the date is not YYYY, YYYY-MM or a real YYYY-MM-DD day. */
1435
+ | 'invalidDate'
1436
+ /** error: the session date is further ahead than the editor allows. */
1437
+ | 'dateTooFarAhead'
1438
+ /** error: a session has no title, no event name and no linked talk. */
1439
+ | 'missingTitleOrEvent'
1440
+ /** error: the session's presentation_key names a talk row that was skipped for an error. */
1441
+ | 'linkedTalkSkipped'
1442
+ /** error: the record fails the write schema for another reason (e.g. a value too long). */
1443
+ | 'invalidRecord'
1444
+ /** warning: presentation_key matches no talk in this upload; imported as a one-off session. */
1445
+ | 'unknownPresentationKey'
1446
+ /** warning: the role is not recognised; imported without a role. */
1447
+ | 'unknownRole'
1448
+ /** warning: the mode is not recognised; imported without a mode. */
1449
+ | 'unknownMode';
1450
+ interface TalksImportIssue {
1451
+ file: 'presentations' | 'deliveries';
1452
+ /**
1453
+ * Spreadsheet row number: the header is row 1, so the first data row is 2.
1454
+ * Off for files with multi-line quoted cells, which spreadsheets rarely emit.
1455
+ */
1456
+ row: number;
1457
+ /** CSV column the problem is in, when there is one. */
1458
+ column?: string;
1459
+ /** The offending cell value, when showing it helps. */
1460
+ value?: string;
1461
+ code: TalksImportIssueCode;
1462
+ severity: 'error' | 'warning';
1463
+ }
1464
+ interface TalksImportValidation {
1465
+ /** Talk rows without errors, ready to send to the import endpoint. */
1466
+ presentations: ParsedPresentation[];
1467
+ /** Session rows without errors, ready to send to the import endpoint. */
1468
+ deliveries: ParsedDelivery[];
1469
+ /** Every problem found, in file then row order. */
1470
+ issues: TalksImportIssue[];
1471
+ }
1472
+ /**
1473
+ * Map and check the two Talks & sessions templates row by row, so a preview can
1474
+ * say which rows will be skipped and why instead of the whole import failing.
1475
+ * Rows with an error are left out of the returned records; rows with only a
1476
+ * warning are kept. Applies the same 12-month session-date limit as the editor
1477
+ * (`DATE_LOOKAHEAD_MONTHS.talk`). Pure; `now` is injectable for tests.
1478
+ */
1479
+ declare function validateTalksImport(input: {
1480
+ presentationRows: CsvRow[];
1481
+ deliveryRows: CsvRow[];
1482
+ }, now?: Date): TalksImportValidation;
1483
+
1411
1484
  /**
1412
1485
  * URL patterns per app, mirroring the sifa-web registry.
1413
1486
  *
@@ -1887,6 +1960,12 @@ interface StreamMediaResolved extends StreamMediaBase {
1887
1960
  interface StreamMediaBlob extends StreamMediaBase {
1888
1961
  did: string;
1889
1962
  cid: string;
1963
+ /**
1964
+ * Blob byte size, when the record carries it. Lets a host route very large
1965
+ * blobs off the CDN. Record-supplied (Grain's cover size is copied from the
1966
+ * photo record by sifa-api), so treat it as a routing hint, not a guarantee.
1967
+ */
1968
+ size?: number;
1890
1969
  }
1891
1970
  type StreamMedia = StreamMediaResolved | StreamMediaBlob;
1892
1971
  /** An outbound link card (Bluesky external embed, bookmark subject, etc.). */
@@ -3138,4 +3217,4 @@ declare function roadmapIssueUrl(issue: number): string;
3138
3217
  */
3139
3218
  declare const SIFA_SDK_VERSION: string;
3140
3219
 
3141
- export { ACTIVITY_TIERS, ACTIVITY_VERBS, ACTIVITY_VISIBILITY_RULES, ALL_SECTIONS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, AccountFacetMode, type ActivityItem, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type ActivityVerbMap, AgentRef, type AgentRefFlat, type AppCategoryId, type AppUrlPatterns, type AppWithId, type ArtifactLinkKindOption, type BuildProfileHighlightsOptions, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPANY_PAGE_MIN_DESCRIPTION_LENGTH, COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS, COMPANY_PAGE_ROSTER_MIN_MEMBERS, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, COURSE_ROLE_LABELS, COURSE_ROLE_OPTIONS, COURSE_ROLE_TAKEN, COURSE_ROLE_TAUGHT, COURSE_ROLE_TEACHING_ASSISTANT, type CardHealth, type CardHealthStrategy, type CollapseContributorsOptions, type CollapsedContributors, type CompanyFirmographics, type CompanyHqFacts, type ContinentCode, type CourseRoleOption, type CsvRow, DATE_LOOKAHEAD_MONTHS, DIMENSIONS_MAX_SCORE, type DailyActivityCount, type DateLookaheadKind, type DimensionKey, type DimensionMap, type DisambiguationFields, type DisplayUrl, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EQF_LEVEL_LABELS, EQF_LEVEL_OPTIONS, type EmbedResult, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, type EqfLevel, type EqfLevelOption, type FormatDisplayUrlOptions, type GroupPublicationVersionsOptions, INDUSTRY_LABELS, INDUSTRY_OPTIONS, INVESTMENT_ROLE_LABELS, INVESTMENT_ROLE_OPTIONS, INVESTMENT_STAGE_LABELS, INVESTMENT_STAGE_OPTIONS, INVESTMENT_STATUS_LABELS, INVESTMENT_STATUS_OPTIONS, INVOLVEMENT_HEADING_ORDER, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvestmentOption, type InvolvementGroup, type InvolvementKindOption, type KnownAppId, type LexiconEntry, type LocationSegment, type LocationSegmentKind, type LocationSegmentsOptions, LocationValue, MIN_SKILLS, type MergedProfileSkill, ON_BEHALF_OF_EMPLOYMENT_TYPES, OPEN_TO_GROUP_LABELS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_LABELS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, OrgProfileRecord, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLICATION_TYPE_LABELS, PUBLICATION_TYPE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedEndorsementComment, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PersonalFacetContent, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryFlagCandidate, type PrimaryPositionCandidate, Profile, ProfileCertification, type ProfileCompletion, type ProfileDimensionInputs, ProfileEducation, type ProfileHighlightSection, type ProfileHighlightStatus, type ProfileHighlightTile, type ProfileHighlightsInput, ProfileHonor, ProfileInvolvement, ProfileLanguage, ProfilePosition, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileProject, ProfilePublication, ProfileSkill, type PublicationTypeOption, type PublicationVersionGroup, type Publisher, ROADMAP_ISSUES_REPO, ROADMAP_ITEM_META, RelatedIdentifier, type RgbColor, type RoadmapItemMeta, SEARCH_FILTER_DEFS, SECTION_GROUPS, SECTION_LABELS, SELF_APP_ID, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, STREAM_VERBS, type SearchFilterControl, type SearchFilterDef, type SearchFilterOptionSource, type SectionGroupId, type SectionId, type SkillCategory, type StreamAddress, type StreamAuthor, type StreamCardBody, type StreamCardContent, type StreamCardSubject, type StreamCardVM, type StreamExternalLink, type StreamGeo, type StreamMedia, type StreamMediaBase, type StreamMediaBlob, type StreamMediaResolved, type StreamRichSegment, type StreamSource, type StreamTheme, type StreamVerb, type TierMeta, type ToStreamCardVMOptions, type UrlPathPolicy, type VersionablePublication, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, actorShowsIdentity, buildMetaDescription, buildProfileHighlights, buildTalkSlug, categoryForApp, certDateExtractor, classifyEntityRef, collapseContributors, companyPageRichness, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countRecentActivity, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, excludeSelfApp, filterHidden, findIndustry, followingFeedFallbackApp, formatCompanyName, formatCredentialDateRange, formatDateRange, formatDisplayUrl, formatDistanceToNow, formatEventDate, formatIsoTitle, formatLocation, formatPositionDateRange, formatPresentationDuration, formatRelationship, formatRelativeTime, formatSingleDate, formatSpanDate, formatTimelineDate, getActivityTaxonomyVersion, getActivityTier, getActivityVerbsVersion, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getCourseRoleLabel, getDisplayLabel, getEducationLevelDisplay, getEmploymentTypeLabel, getEqfLevelLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabel, getIndustryLabelKey, getInvestmentRoleLabel, getInvestmentStageLabel, getInvestmentStatusLabel, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublicationTypeLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getVisibleSectionIds, getWorkplaceTypeLabel, groupInvolvementByHeading, groupPublicationVersions, groupSkillsByCategory, groupSkillsBySubCategory, groupSkillsForDisplay, hasPersonalProfileContent, hoistPrimary, isAppCategory, isBeyondLookahead, isCompanyPageIndexable, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isOnBehalfOfApplicable, isPseudoEmployer, isRegistrableDomainHandle, isRelationalActivity, isRoleLineRedundant, isSectionPopulated, isSelfAuthoredRich, isTeachingCourse, isUpcomingStart, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, locationSegments, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeDoi, normalizeLegalForm, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeSkillCategory, normalizeWorkplaceTypes, openAlexWorkUrl, openToTokenToValue, openToValueToToken, parseEndorsementComment, parseIntendedAudiences, parseLocationString, parsePresentationDuration, parseTalkRkey, pdsProviderFromApi, pickPrimaryFlagged, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, qualifiesAsOrg, readEqfLevel, relativeLuminance, renderAsLine, rendersCompanyProfile, rendersPersonalProfile, resolveAccountFacetMode, resolveAgentRef, resolveCardHealth, resolveCardUrl, resolveEmbed, rgbToString, roadmapIssueUrl, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, shouldRenderHighlights, singleDateExtractor, slugifyTitle, sortByActiveDateRange, sortByDateDesc, sortCertifications, sortEducation, sortHonors, sortLanguages, sortLanguagesByProficiency, sortPositions, sortProjects, sortPublications, splitCoursesByRole, streamAddressSchema, streamAuthorSchema, streamCardBodyContent, streamCardBodySchema, streamCardContent, streamCardSubjectSchema, streamCardSubjectText, streamCardVMSchema, streamExternalLinkSchema, streamGeoSchema, streamMediaSchema, streamRichSegmentSchema, streamSourceSchema, streamThemeSchema, streamVerbSchema, stripHtmlToText, suggestEqfLevelFromDegree, summarizePresentationDeliveries, toStreamCardVM, toStreamCardVMs, truncateGraphemes, verbForCollection, visibleItems, youtubeThumbnailUrl, youtubeVideoId };
3220
+ export { ACTIVITY_TIERS, ACTIVITY_VERBS, ACTIVITY_VISIBILITY_RULES, ALL_SECTIONS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, AccountFacetMode, type ActivityItem, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type ActivityVerbMap, AgentRef, type AgentRefFlat, type AppCategoryId, type AppUrlPatterns, type AppWithId, type ArtifactLinkKindOption, type BlobProxyVariant, type BuildProfileHighlightsOptions, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPANY_PAGE_MIN_DESCRIPTION_LENGTH, COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS, COMPANY_PAGE_ROSTER_MIN_MEMBERS, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, COURSE_ROLE_LABELS, COURSE_ROLE_OPTIONS, COURSE_ROLE_TAKEN, COURSE_ROLE_TAUGHT, COURSE_ROLE_TEACHING_ASSISTANT, type CardHealth, type CardHealthStrategy, type CollapseContributorsOptions, type CollapsedContributors, type CompanyFirmographics, type CompanyHqFacts, type ContinentCode, type CourseRoleOption, type CsvRow, DATE_LOOKAHEAD_MONTHS, DIMENSIONS_MAX_SCORE, type DailyActivityCount, type DateLookaheadKind, type DimensionKey, type DimensionMap, type DisambiguationFields, type DisplayUrl, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EQF_LEVEL_LABELS, EQF_LEVEL_OPTIONS, type EmbedResult, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, type EqfLevel, type EqfLevelOption, type FormatDisplayUrlOptions, type GroupPublicationVersionsOptions, INDUSTRY_LABELS, INDUSTRY_OPTIONS, INVESTMENT_ROLE_LABELS, INVESTMENT_ROLE_OPTIONS, INVESTMENT_STAGE_LABELS, INVESTMENT_STAGE_OPTIONS, INVESTMENT_STATUS_LABELS, INVESTMENT_STATUS_OPTIONS, INVOLVEMENT_HEADING_ORDER, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvestmentOption, type InvolvementGroup, type InvolvementKindOption, type KnownAppId, type LexiconEntry, type LocationSegment, type LocationSegmentKind, type LocationSegmentsOptions, LocationValue, MIN_SKILLS, type MergedProfileSkill, ON_BEHALF_OF_EMPLOYMENT_TYPES, OPEN_TO_GROUP_LABELS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_LABELS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, OrgProfileRecord, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_MODE_VALUES, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PRESENTATION_ROLE_VALUES, PUBLICATION_TYPE_LABELS, PUBLICATION_TYPE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedEndorsementComment, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PersonalFacetContent, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryFlagCandidate, type PrimaryPositionCandidate, Profile, ProfileCertification, type ProfileCompletion, type ProfileDimensionInputs, ProfileEducation, type ProfileHighlightSection, type ProfileHighlightStatus, type ProfileHighlightTile, type ProfileHighlightsInput, ProfileHonor, ProfileInvolvement, ProfileLanguage, ProfilePosition, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileProject, ProfilePublication, ProfileSkill, type PublicationTypeOption, type PublicationVersionGroup, type Publisher, ROADMAP_ISSUES_REPO, ROADMAP_ITEM_META, RelatedIdentifier, type RgbColor, type RoadmapItemMeta, SEARCH_FILTER_DEFS, SECTION_GROUPS, SECTION_LABELS, SELF_APP_ID, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, STREAM_VERBS, type SearchFilterControl, type SearchFilterDef, type SearchFilterOptionSource, type SectionGroupId, type SectionId, type SkillCategory, type StreamAddress, type StreamAuthor, type StreamCardBody, type StreamCardContent, type StreamCardSubject, type StreamCardVM, type StreamExternalLink, type StreamGeo, type StreamMedia, type StreamMediaBase, type StreamMediaBlob, type StreamMediaResolved, type StreamRichSegment, type StreamSource, type StreamTheme, type StreamVerb, type TalksImportIssue, type TalksImportIssueCode, type TalksImportValidation, type TierMeta, type ToStreamCardVMOptions, type UrlPathPolicy, type VersionablePublication, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, actorShowsIdentity, blobProxyUrl, buildMetaDescription, buildProfileHighlights, buildTalkSlug, categoryForApp, certDateExtractor, classifyEntityRef, collapseContributors, companyPageRichness, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countRecentActivity, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, excludeSelfApp, filterHidden, findIndustry, followingFeedFallbackApp, formatCompanyName, formatCredentialDateRange, formatDateRange, formatDisplayUrl, formatDistanceToNow, formatEventDate, formatIsoTitle, formatLocation, formatPositionDateRange, formatPresentationDuration, formatRelationship, formatRelativeTime, formatSingleDate, formatSpanDate, formatTimelineDate, getActivityTaxonomyVersion, getActivityTier, getActivityVerbsVersion, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getCourseRoleLabel, getDisplayLabel, getEducationLevelDisplay, getEmploymentTypeLabel, getEqfLevelLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabel, getIndustryLabelKey, getInvestmentRoleLabel, getInvestmentStageLabel, getInvestmentStatusLabel, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublicationTypeLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getVisibleSectionIds, getWorkplaceTypeLabel, groupInvolvementByHeading, groupPublicationVersions, groupSkillsByCategory, groupSkillsBySubCategory, groupSkillsForDisplay, hasPersonalProfileContent, hoistPrimary, isAppCategory, isBeyondLookahead, isCompanyPageIndexable, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isOnBehalfOfApplicable, isPseudoEmployer, isRegistrableDomainHandle, isRelationalActivity, isRoleLineRedundant, isSectionPopulated, isSelfAuthoredRich, isTeachingCourse, isUpcomingStart, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, locationSegments, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeDoi, normalizeLegalForm, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeSkillCategory, normalizeWorkplaceTypes, openAlexWorkUrl, openToTokenToValue, openToValueToToken, parseEndorsementComment, parseIntendedAudiences, parseLocationString, parsePresentationDuration, parseTalkRkey, pdsProviderFromApi, pickPrimaryFlagged, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, qualifiesAsOrg, readEqfLevel, relativeLuminance, renderAsLine, rendersCompanyProfile, rendersPersonalProfile, resolveAccountFacetMode, resolveAgentRef, resolveCardHealth, resolveCardUrl, resolveEmbed, rgbToString, roadmapIssueUrl, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, shouldRenderHighlights, singleDateExtractor, slugifyTitle, sortByActiveDateRange, sortByDateDesc, sortCertifications, sortEducation, sortHonors, sortLanguages, sortLanguagesByProficiency, sortPositions, sortProjects, sortPublications, splitCoursesByRole, streamAddressSchema, streamAuthorSchema, streamCardBodyContent, streamCardBodySchema, streamCardContent, streamCardSubjectSchema, streamCardSubjectText, streamCardVMSchema, streamExternalLinkSchema, streamGeoSchema, streamMediaSchema, streamRichSegmentSchema, streamSourceSchema, streamThemeSchema, streamVerbSchema, stripHtmlToText, suggestEqfLevelFromDegree, summarizePresentationDeliveries, toStreamCardVM, toStreamCardVMs, truncateGraphemes, validateTalksImport, verbForCollection, visibleItems, youtubeThumbnailUrl, youtubeVideoId };
package/dist/index.d.ts CHANGED
@@ -1054,6 +1054,16 @@ declare function normalizeDoi(value: string): string;
1054
1054
  */
1055
1055
  declare function openAlexWorkUrl(id: string | undefined): string | undefined;
1056
1056
 
1057
+ /** Output variants served by the sifa-api blob proxy. */
1058
+ type BlobProxyVariant = 'thumb' | 'avatar';
1059
+ /**
1060
+ * URL of the sifa-api blob proxy (`GET /api/blob/:did/:cid?v=`) for a blob
1061
+ * owned by `did`. The proxy fetches the blob from the owner's PDS, resizes it
1062
+ * (`thumb`: 1000px JPEG, `avatar`: 256px WebP) and caches it. Use it for blobs
1063
+ * the Bluesky image CDN refuses, such as very large originals.
1064
+ */
1065
+ declare function blobProxyUrl(baseUrl: string, did: string, cid: string, variant: BlobProxyVariant): string;
1066
+
1057
1067
  /**
1058
1068
  * Endorsement comments carry an optional relationship-context prefix written by
1059
1069
  * the endorse dialog, e.g. `[worked_together: Acme] great colleague`. The prefix
@@ -1382,6 +1392,8 @@ declare function parseIntendedAudiences(input: string | undefined, delimiter?: s
1382
1392
  * only to produce readable text.
1383
1393
  */
1384
1394
  declare function stripHtmlToText(input: string | undefined): string;
1395
+ /** Friendly role values the import maps to a token (keyword matches aside). */
1396
+ declare const PRESENTATION_ROLE_VALUES: string[];
1385
1397
  /**
1386
1398
  * Map a friendly role value to its token. An existing token passes through.
1387
1399
  * Free-text or compound values (e.g. "Organizer & co-host/moderator") are
@@ -1391,6 +1403,8 @@ declare function stripHtmlToText(input: string | undefined): string;
1391
1403
  * behavior, so a fixed role dropdown never has to render arbitrary strings.
1392
1404
  */
1393
1405
  declare function normalizePresentationRole(value: string | undefined): string | undefined;
1406
+ /** Friendly mode values the import maps to a token. */
1407
+ declare const PRESENTATION_MODE_VALUES: string[];
1394
1408
  /** Map a friendly mode value to the community calendar token; drops an unknown value. */
1395
1409
  declare function normalizePresentationMode(value: string | undefined): string | undefined;
1396
1410
  interface ParsedPresentation {
@@ -1408,6 +1422,65 @@ interface ParsedDelivery {
1408
1422
  /** Map a row of the deliveries template to a delivery record (minus createdAt and presentationRef). */
1409
1423
  declare function presentationDeliveryCsvRowToRecord(row: CsvRow): ParsedDelivery;
1410
1424
 
1425
+ /**
1426
+ * Why a Talks & sessions CSV row was skipped (`error`) or imported with a
1427
+ * caveat (`warning`). Consumers map the code to translated copy.
1428
+ */
1429
+ type TalksImportIssueCode =
1430
+ /** error: a talk row has no title. */
1431
+ 'missingTitle'
1432
+ /** error: a URL column holds something that is not an http(s) URL. */
1433
+ | 'invalidUrl'
1434
+ /** error: the date is not YYYY, YYYY-MM or a real YYYY-MM-DD day. */
1435
+ | 'invalidDate'
1436
+ /** error: the session date is further ahead than the editor allows. */
1437
+ | 'dateTooFarAhead'
1438
+ /** error: a session has no title, no event name and no linked talk. */
1439
+ | 'missingTitleOrEvent'
1440
+ /** error: the session's presentation_key names a talk row that was skipped for an error. */
1441
+ | 'linkedTalkSkipped'
1442
+ /** error: the record fails the write schema for another reason (e.g. a value too long). */
1443
+ | 'invalidRecord'
1444
+ /** warning: presentation_key matches no talk in this upload; imported as a one-off session. */
1445
+ | 'unknownPresentationKey'
1446
+ /** warning: the role is not recognised; imported without a role. */
1447
+ | 'unknownRole'
1448
+ /** warning: the mode is not recognised; imported without a mode. */
1449
+ | 'unknownMode';
1450
+ interface TalksImportIssue {
1451
+ file: 'presentations' | 'deliveries';
1452
+ /**
1453
+ * Spreadsheet row number: the header is row 1, so the first data row is 2.
1454
+ * Off for files with multi-line quoted cells, which spreadsheets rarely emit.
1455
+ */
1456
+ row: number;
1457
+ /** CSV column the problem is in, when there is one. */
1458
+ column?: string;
1459
+ /** The offending cell value, when showing it helps. */
1460
+ value?: string;
1461
+ code: TalksImportIssueCode;
1462
+ severity: 'error' | 'warning';
1463
+ }
1464
+ interface TalksImportValidation {
1465
+ /** Talk rows without errors, ready to send to the import endpoint. */
1466
+ presentations: ParsedPresentation[];
1467
+ /** Session rows without errors, ready to send to the import endpoint. */
1468
+ deliveries: ParsedDelivery[];
1469
+ /** Every problem found, in file then row order. */
1470
+ issues: TalksImportIssue[];
1471
+ }
1472
+ /**
1473
+ * Map and check the two Talks & sessions templates row by row, so a preview can
1474
+ * say which rows will be skipped and why instead of the whole import failing.
1475
+ * Rows with an error are left out of the returned records; rows with only a
1476
+ * warning are kept. Applies the same 12-month session-date limit as the editor
1477
+ * (`DATE_LOOKAHEAD_MONTHS.talk`). Pure; `now` is injectable for tests.
1478
+ */
1479
+ declare function validateTalksImport(input: {
1480
+ presentationRows: CsvRow[];
1481
+ deliveryRows: CsvRow[];
1482
+ }, now?: Date): TalksImportValidation;
1483
+
1411
1484
  /**
1412
1485
  * URL patterns per app, mirroring the sifa-web registry.
1413
1486
  *
@@ -1887,6 +1960,12 @@ interface StreamMediaResolved extends StreamMediaBase {
1887
1960
  interface StreamMediaBlob extends StreamMediaBase {
1888
1961
  did: string;
1889
1962
  cid: string;
1963
+ /**
1964
+ * Blob byte size, when the record carries it. Lets a host route very large
1965
+ * blobs off the CDN. Record-supplied (Grain's cover size is copied from the
1966
+ * photo record by sifa-api), so treat it as a routing hint, not a guarantee.
1967
+ */
1968
+ size?: number;
1890
1969
  }
1891
1970
  type StreamMedia = StreamMediaResolved | StreamMediaBlob;
1892
1971
  /** An outbound link card (Bluesky external embed, bookmark subject, etc.). */
@@ -3138,4 +3217,4 @@ declare function roadmapIssueUrl(issue: number): string;
3138
3217
  */
3139
3218
  declare const SIFA_SDK_VERSION: string;
3140
3219
 
3141
- export { ACTIVITY_TIERS, ACTIVITY_VERBS, ACTIVITY_VISIBILITY_RULES, ALL_SECTIONS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, AccountFacetMode, type ActivityItem, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type ActivityVerbMap, AgentRef, type AgentRefFlat, type AppCategoryId, type AppUrlPatterns, type AppWithId, type ArtifactLinkKindOption, type BuildProfileHighlightsOptions, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPANY_PAGE_MIN_DESCRIPTION_LENGTH, COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS, COMPANY_PAGE_ROSTER_MIN_MEMBERS, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, COURSE_ROLE_LABELS, COURSE_ROLE_OPTIONS, COURSE_ROLE_TAKEN, COURSE_ROLE_TAUGHT, COURSE_ROLE_TEACHING_ASSISTANT, type CardHealth, type CardHealthStrategy, type CollapseContributorsOptions, type CollapsedContributors, type CompanyFirmographics, type CompanyHqFacts, type ContinentCode, type CourseRoleOption, type CsvRow, DATE_LOOKAHEAD_MONTHS, DIMENSIONS_MAX_SCORE, type DailyActivityCount, type DateLookaheadKind, type DimensionKey, type DimensionMap, type DisambiguationFields, type DisplayUrl, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EQF_LEVEL_LABELS, EQF_LEVEL_OPTIONS, type EmbedResult, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, type EqfLevel, type EqfLevelOption, type FormatDisplayUrlOptions, type GroupPublicationVersionsOptions, INDUSTRY_LABELS, INDUSTRY_OPTIONS, INVESTMENT_ROLE_LABELS, INVESTMENT_ROLE_OPTIONS, INVESTMENT_STAGE_LABELS, INVESTMENT_STAGE_OPTIONS, INVESTMENT_STATUS_LABELS, INVESTMENT_STATUS_OPTIONS, INVOLVEMENT_HEADING_ORDER, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvestmentOption, type InvolvementGroup, type InvolvementKindOption, type KnownAppId, type LexiconEntry, type LocationSegment, type LocationSegmentKind, type LocationSegmentsOptions, LocationValue, MIN_SKILLS, type MergedProfileSkill, ON_BEHALF_OF_EMPLOYMENT_TYPES, OPEN_TO_GROUP_LABELS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_LABELS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, OrgProfileRecord, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PUBLICATION_TYPE_LABELS, PUBLICATION_TYPE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedEndorsementComment, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PersonalFacetContent, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryFlagCandidate, type PrimaryPositionCandidate, Profile, ProfileCertification, type ProfileCompletion, type ProfileDimensionInputs, ProfileEducation, type ProfileHighlightSection, type ProfileHighlightStatus, type ProfileHighlightTile, type ProfileHighlightsInput, ProfileHonor, ProfileInvolvement, ProfileLanguage, ProfilePosition, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileProject, ProfilePublication, ProfileSkill, type PublicationTypeOption, type PublicationVersionGroup, type Publisher, ROADMAP_ISSUES_REPO, ROADMAP_ITEM_META, RelatedIdentifier, type RgbColor, type RoadmapItemMeta, SEARCH_FILTER_DEFS, SECTION_GROUPS, SECTION_LABELS, SELF_APP_ID, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, STREAM_VERBS, type SearchFilterControl, type SearchFilterDef, type SearchFilterOptionSource, type SectionGroupId, type SectionId, type SkillCategory, type StreamAddress, type StreamAuthor, type StreamCardBody, type StreamCardContent, type StreamCardSubject, type StreamCardVM, type StreamExternalLink, type StreamGeo, type StreamMedia, type StreamMediaBase, type StreamMediaBlob, type StreamMediaResolved, type StreamRichSegment, type StreamSource, type StreamTheme, type StreamVerb, type TierMeta, type ToStreamCardVMOptions, type UrlPathPolicy, type VersionablePublication, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, actorShowsIdentity, buildMetaDescription, buildProfileHighlights, buildTalkSlug, categoryForApp, certDateExtractor, classifyEntityRef, collapseContributors, companyPageRichness, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countRecentActivity, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, excludeSelfApp, filterHidden, findIndustry, followingFeedFallbackApp, formatCompanyName, formatCredentialDateRange, formatDateRange, formatDisplayUrl, formatDistanceToNow, formatEventDate, formatIsoTitle, formatLocation, formatPositionDateRange, formatPresentationDuration, formatRelationship, formatRelativeTime, formatSingleDate, formatSpanDate, formatTimelineDate, getActivityTaxonomyVersion, getActivityTier, getActivityVerbsVersion, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getCourseRoleLabel, getDisplayLabel, getEducationLevelDisplay, getEmploymentTypeLabel, getEqfLevelLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabel, getIndustryLabelKey, getInvestmentRoleLabel, getInvestmentStageLabel, getInvestmentStatusLabel, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublicationTypeLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getVisibleSectionIds, getWorkplaceTypeLabel, groupInvolvementByHeading, groupPublicationVersions, groupSkillsByCategory, groupSkillsBySubCategory, groupSkillsForDisplay, hasPersonalProfileContent, hoistPrimary, isAppCategory, isBeyondLookahead, isCompanyPageIndexable, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isOnBehalfOfApplicable, isPseudoEmployer, isRegistrableDomainHandle, isRelationalActivity, isRoleLineRedundant, isSectionPopulated, isSelfAuthoredRich, isTeachingCourse, isUpcomingStart, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, locationSegments, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeDoi, normalizeLegalForm, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeSkillCategory, normalizeWorkplaceTypes, openAlexWorkUrl, openToTokenToValue, openToValueToToken, parseEndorsementComment, parseIntendedAudiences, parseLocationString, parsePresentationDuration, parseTalkRkey, pdsProviderFromApi, pickPrimaryFlagged, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, qualifiesAsOrg, readEqfLevel, relativeLuminance, renderAsLine, rendersCompanyProfile, rendersPersonalProfile, resolveAccountFacetMode, resolveAgentRef, resolveCardHealth, resolveCardUrl, resolveEmbed, rgbToString, roadmapIssueUrl, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, shouldRenderHighlights, singleDateExtractor, slugifyTitle, sortByActiveDateRange, sortByDateDesc, sortCertifications, sortEducation, sortHonors, sortLanguages, sortLanguagesByProficiency, sortPositions, sortProjects, sortPublications, splitCoursesByRole, streamAddressSchema, streamAuthorSchema, streamCardBodyContent, streamCardBodySchema, streamCardContent, streamCardSubjectSchema, streamCardSubjectText, streamCardVMSchema, streamExternalLinkSchema, streamGeoSchema, streamMediaSchema, streamRichSegmentSchema, streamSourceSchema, streamThemeSchema, streamVerbSchema, stripHtmlToText, suggestEqfLevelFromDegree, summarizePresentationDeliveries, toStreamCardVM, toStreamCardVMs, truncateGraphemes, verbForCollection, visibleItems, youtubeThumbnailUrl, youtubeVideoId };
3220
+ export { ACTIVITY_TIERS, ACTIVITY_VERBS, ACTIVITY_VISIBILITY_RULES, ALL_SECTIONS, APP_CATEGORIES, APP_CATEGORY_IDS, APP_CATEGORY_MAP, APP_URL_PATTERNS, ARTIFACT_LINK_KIND_LABELS, ARTIFACT_LINK_KIND_OPTIONS, AccountFacetMode, type ActivityItem, type ActivityItemForUrl, type ActivityTaxonomy, type ActivityTier, type ActivityVerbMap, AgentRef, type AgentRefFlat, type AppCategoryId, type AppUrlPatterns, type AppWithId, type ArtifactLinkKindOption, type BlobProxyVariant, type BuildProfileHighlightsOptions, CALENDAR_EVENT_MODE_LABELS, CALENDAR_EVENT_STATUS_LABELS, CATEGORY_LABELS, CATEGORY_ORDER, COLLECTION_TO_APP, COMPANY_OPTIONAL_EMPLOYMENT_TYPES, COMPANY_PAGE_MIN_DESCRIPTION_LENGTH, COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS, COMPANY_PAGE_ROSTER_MIN_MEMBERS, COMPLETENESS_MAX_SCORE, CONTINENTS, COUNTRIES, COURSE_ROLE_LABELS, COURSE_ROLE_OPTIONS, COURSE_ROLE_TAKEN, COURSE_ROLE_TAUGHT, COURSE_ROLE_TEACHING_ASSISTANT, type CardHealth, type CardHealthStrategy, type CollapseContributorsOptions, type CollapsedContributors, type CompanyFirmographics, type CompanyHqFacts, type ContinentCode, type CourseRoleOption, type CsvRow, DATE_LOOKAHEAD_MONTHS, DIMENSIONS_MAX_SCORE, type DailyActivityCount, type DateLookaheadKind, type DimensionKey, type DimensionMap, type DisambiguationFields, type DisplayUrl, EMPLOYMENT_TYPE_GROUPS, EMPLOYMENT_TYPE_LABELS, ENTITY_REF_ANCHORS, EQF_LEVEL_LABELS, EQF_LEVEL_OPTIONS, type EmbedResult, type EmploymentTypeGroup, type EmploymentTypeOption, type EntityRefAnchor, EntitySearchResult, type EqfLevel, type EqfLevelOption, type FormatDisplayUrlOptions, type GroupPublicationVersionsOptions, INDUSTRY_LABELS, INDUSTRY_OPTIONS, INVESTMENT_ROLE_LABELS, INVESTMENT_ROLE_OPTIONS, INVESTMENT_STAGE_LABELS, INVESTMENT_STAGE_OPTIONS, INVESTMENT_STATUS_LABELS, INVESTMENT_STATUS_OPTIONS, INVOLVEMENT_HEADING_ORDER, INVOLVEMENT_KIND_HEADINGS, INVOLVEMENT_KIND_LABELS, INVOLVEMENT_KIND_OPTIONS, type IndustryOption, type InvestmentOption, type InvolvementGroup, type InvolvementKindOption, type KnownAppId, type LexiconEntry, type LocationSegment, type LocationSegmentKind, type LocationSegmentsOptions, LocationValue, MIN_SKILLS, type MergedProfileSkill, ON_BEHALF_OF_EMPLOYMENT_TYPES, OPEN_TO_GROUP_LABELS, OPEN_TO_OPTIONS, OPEN_TO_TOKENS, OPEN_TO_TOKEN_LABELS, OPEN_TO_TOKEN_TO_VALUE, OPEN_TO_VALUE_TO_TOKEN, type OpenToGroup, type OpenToOption, OrgProfileRecord, PLATFORM_LABELS, PLATFORM_OPTIONS, PRESENTATION_LINK_TYPE_LABELS, PRESENTATION_LINK_TYPE_OPTIONS, PRESENTATION_MODE_VALUES, PRESENTATION_ROLE_LABELS, PRESENTATION_ROLE_OPTIONS, PRESENTATION_ROLE_VALUES, PUBLICATION_TYPE_LABELS, PUBLICATION_TYPE_OPTIONS, PUBLISHERS, type ParsedDelivery, type ParsedEndorsementComment, type ParsedPresentation, type PdsProvider, PdsProviderInfo, type PersonalFacetContent, type PlatformId, type PresentationDeliverySummary, PresentationDuration, type PresentationLinkTypeOption, type PresentationRoleOption, type PrimaryFlagCandidate, type PrimaryPositionCandidate, Profile, ProfileCertification, type ProfileCompletion, type ProfileDimensionInputs, ProfileEducation, type ProfileHighlightSection, type ProfileHighlightStatus, type ProfileHighlightTile, type ProfileHighlightsInput, ProfileHonor, ProfileInvolvement, ProfileLanguage, ProfilePosition, ProfilePresentationDelivery, ProfilePresentationDeliveryRecord, ProfilePresentationRecord, ProfileProject, ProfilePublication, ProfileSkill, type PublicationTypeOption, type PublicationVersionGroup, type Publisher, ROADMAP_ISSUES_REPO, ROADMAP_ITEM_META, RelatedIdentifier, type RgbColor, type RoadmapItemMeta, SEARCH_FILTER_DEFS, SECTION_GROUPS, SECTION_LABELS, SELF_APP_ID, SIFA_SDK_VERSION, SKILL_CATEGORIES, STANDARD_PUBLISHER_ID, STREAM_VERBS, type SearchFilterControl, type SearchFilterDef, type SearchFilterOptionSource, type SectionGroupId, type SectionId, type SkillCategory, type StreamAddress, type StreamAuthor, type StreamCardBody, type StreamCardContent, type StreamCardSubject, type StreamCardVM, type StreamExternalLink, type StreamGeo, type StreamMedia, type StreamMediaBase, type StreamMediaBlob, type StreamMediaResolved, type StreamRichSegment, type StreamSource, type StreamTheme, type StreamVerb, type TalksImportIssue, type TalksImportIssueCode, type TalksImportValidation, type TierMeta, type ToStreamCardVMOptions, type UrlPathPolicy, type VersionablePublication, WORKPLACE_TYPE_LABELS, WORKPLACE_TYPE_OPTIONS, type WorkplaceTypeOption, actorShowsIdentity, blobProxyUrl, buildMetaDescription, buildProfileHighlights, buildTalkSlug, categoryForApp, certDateExtractor, classifyEntityRef, collapseContributors, companyPageRichness, completenessPercent, completenessScore, contrastRatio, countFilledDimensions, countRecentActivity, countryCodeToFlag, dateRangeExtractor, dedupeSkills, detectPdsProvider, dimensionsFromInputs, durationFromMinutes, entityDisambiguationLabel, entityResultKey, excludeSelfApp, filterHidden, findIndustry, followingFeedFallbackApp, formatCompanyName, formatCredentialDateRange, formatDateRange, formatDisplayUrl, formatDistanceToNow, formatEventDate, formatIsoTitle, formatLocation, formatPositionDateRange, formatPresentationDuration, formatRelationship, formatRelativeTime, formatSingleDate, formatSpanDate, formatTimelineDate, getActivityTaxonomyVersion, getActivityTier, getActivityVerbsVersion, getAppCategoryIcon, getAppIdForCollection, getArtifactLinkKindLabel, getCalendarEventModeLabel, getCalendarEventStatusLabel, getContinent, getCourseRoleLabel, getDisplayLabel, getEducationLevelDisplay, getEmploymentTypeLabel, getEqfLevelLabel, getFaviconUrl, getFilledDimensionsMap, getHandleStem, getIndustryLabel, getIndustryLabelKey, getInvestmentRoleLabel, getInvestmentStageLabel, getInvestmentStatusLabel, getInvolvementKindHeading, getInvolvementKindLabel, getLexiconEntry, getOpenToLabelKey, getPdsDisplayName, getPlatformLabel, getPresentationLinkTypeLabel, getPresentationRoleLabel, getPublicationTypeLabel, getPublisherByHost, getPublisherById, getPublisherFromSiteUrl, getTierMeta, getVisibleSectionIds, getWorkplaceTypeLabel, groupInvolvementByHeading, groupPublicationVersions, groupSkillsByCategory, groupSkillsBySubCategory, groupSkillsForDisplay, hasPersonalProfileContent, hoistPrimary, isAppCategory, isBeyondLookahead, isCompanyPageIndexable, isCompanyRequired, isKnownAppId, isKnownPlatform, isLinked, isOnBehalfOfApplicable, isPseudoEmployer, isRegistrableDomainHandle, isRelationalActivity, isRoleLineRedundant, isSectionPopulated, isSelfAuthoredRich, isTeachingCourse, isUpcomingStart, isValidRgbColor, isVisibleActivityItem, lexiconDateExtractor, limitCombiningMarks, locationSegments, looksLikeDomain, meetsContrastAA, normalizeCompanyKey, normalizeDoi, normalizeLegalForm, normalizeOpenTo, normalizePlatformId, normalizePresentationMode, normalizePresentationRole, normalizeSkillCategory, normalizeWorkplaceTypes, openAlexWorkUrl, openToTokenToValue, openToValueToToken, parseEndorsementComment, parseIntendedAudiences, parseLocationString, parsePresentationDuration, parseTalkRkey, pdsProviderFromApi, pickPrimaryFlagged, pickPrimaryPosition, presentationCsvRowToRecord, presentationDeliveryCsvRowToRecord, profileToDimensionInputs, qualifiesAsOrg, readEqfLevel, relativeLuminance, renderAsLine, rendersCompanyProfile, rendersPersonalProfile, resolveAccountFacetMode, resolveAgentRef, resolveCardHealth, resolveCardUrl, resolveEmbed, rgbToString, roadmapIssueUrl, sanitizeDisplayText, sanitizeHandleInput, searchResultDisambiguation, shouldRenderHighlights, singleDateExtractor, slugifyTitle, sortByActiveDateRange, sortByDateDesc, sortCertifications, sortEducation, sortHonors, sortLanguages, sortLanguagesByProficiency, sortPositions, sortProjects, sortPublications, splitCoursesByRole, streamAddressSchema, streamAuthorSchema, streamCardBodyContent, streamCardBodySchema, streamCardContent, streamCardSubjectSchema, streamCardSubjectText, streamCardVMSchema, streamExternalLinkSchema, streamGeoSchema, streamMediaSchema, streamRichSegmentSchema, streamSourceSchema, streamThemeSchema, streamVerbSchema, stripHtmlToText, suggestEqfLevelFromDegree, summarizePresentationDeliveries, toStreamCardVM, toStreamCardVMs, truncateGraphemes, validateTalksImport, verbForCollection, visibleItems, youtubeThumbnailUrl, youtubeVideoId };
package/dist/index.js CHANGED
@@ -146,6 +146,7 @@ import {
146
146
  sanitizeDisplayText,
147
147
  normalizeDoi,
148
148
  openAlexWorkUrl,
149
+ blobProxyUrl,
149
150
  formatRelationship,
150
151
  parseEndorsementComment,
151
152
  sanitizeHandleInput,
@@ -166,7 +167,10 @@ import {
166
167
  normalizePresentationRole,
167
168
  normalizePresentationMode,
168
169
  presentationCsvRowToRecord,
169
- presentationDeliveryCsvRowToRecord
170
+ presentationDeliveryCsvRowToRecord,
171
+ PRESENTATION_ROLE_VALUES,
172
+ PRESENTATION_MODE_VALUES,
173
+ validateTalksImport
170
174
  } from "./import/index.js";
171
175
  import {
172
176
  ACTIVITY_VISIBILITY_RULES,
@@ -370,7 +374,7 @@ import {
370
374
  roadmapIssueUrl
371
375
  } from "./roadmap/index.js";
372
376
  import { SIFA_REPO_GROUPS, describeSifaRecord, repoGroupForCollection } from "./repo/index.js";
373
- var SIFA_SDK_VERSION = "0.19.85";
377
+ var SIFA_SDK_VERSION = "0.19.87";
374
378
  export {
375
379
  ACTIVITY_TIERS,
376
380
  ACTIVITY_VERBS,
@@ -458,8 +462,10 @@ export {
458
462
  PLATFORM_OPTIONS,
459
463
  PRESENTATION_LINK_TYPE_LABELS,
460
464
  PRESENTATION_LINK_TYPE_OPTIONS,
465
+ PRESENTATION_MODE_VALUES,
461
466
  PRESENTATION_ROLE_LABELS,
462
467
  PRESENTATION_ROLE_OPTIONS,
468
+ PRESENTATION_ROLE_VALUES,
463
469
  PROFILE_INVESTMENT_NSID,
464
470
  PROFILE_INVOLVEMENT_NSID,
465
471
  PROJECT_ROLES,
@@ -508,6 +514,7 @@ export {
508
514
  actorShowsIdentity,
509
515
  agentRefSchema,
510
516
  atUriSchema,
517
+ blobProxyUrl,
511
518
  buildMetaDescription,
512
519
  buildProfileHighlights,
513
520
  buildTalkSlug,
@@ -720,6 +727,7 @@ export {
720
727
  toStreamCardVMs,
721
728
  truncateGraphemes,
722
729
  uriSchema,
730
+ validateTalksImport,
723
731
  verbForCollection,
724
732
  visibleItems,
725
733
  youtubeThumbnailUrl,
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["/**\n * Sifa SDK -- public client library for the Sifa AppView on AT Protocol.\n *\n * Pre-1.0: the public API is unstable and may change in any minor release.\n *\n * @see https://github.com/singi-labs/sifa-sdk\n */\n\ndeclare const __SIFA_SDK_VERSION__: string;\n\nexport const SIFA_SDK_VERSION: string = __SIFA_SDK_VERSION__;\n\nexport type {\n ActiveApp,\n Endorsement,\n EndorsementData,\n ExternalAccount,\n ExternalAccountKeytraceClaim,\n FeedItem,\n LanguageProficiency,\n LocationValue,\n OrgAddressView,\n OrgFloorVerdict,\n OrgLinkView,\n OrgProfileView,\n RecognizedEntity,\n PdsProviderInfo,\n PresentationLinkView,\n Profile,\n ProfileCertification,\n ProfileCourse,\n ProfileEducation,\n ProfileHonor,\n ProfileIndustry,\n ProfileInvestment,\n ProfileInvestmentLink,\n ProfileInvolvement,\n ProfileInvolvementLink,\n ProfileLanguage,\n ProfileLocation,\n ProfileOverrideSource,\n ProfilePosition,\n PositionConfirmations,\n PositionViewerConfirmation,\n PositionOrgVerification,\n ProfilePresentation,\n CoSpeaker,\n ActorCard,\n AuthorSuggestion,\n ProjectMemberCard,\n ProjectRole,\n ProfilePresentationDelivery,\n ProfileProject,\n ProjectEventView,\n ProfilePublication,\n ProfileSkill,\n ProfileVolunteering,\n PublicationContributor,\n RelatedIdentifier,\n SkillRef,\n SkillSuggestion,\n TrustStat,\n VerifiedAccount,\n AccountFacetMode,\n} from './types/index.js';\n\n// Aggregated public profile view (`id.sifa.getProfileView` XRPC query).\nexport type {\n ProfileView,\n IndustryDomain,\n ProfileLocationView,\n PositionView,\n EducationView,\n SkillView,\n CertificationView,\n ProjectView,\n VolunteeringView,\n InvolvementView,\n InvolvementLinkView,\n PublicationView,\n ContributorView,\n CourseView,\n DurationView,\n CoSpeakerView,\n ProjectMemberView,\n PresentationDeliveryView,\n PresentationView,\n HonorView,\n LanguageView,\n ExternalAccountView,\n ActiveAppView,\n AtfundLinkView,\n} from './types/profile-view.js';\n\nexport { PROJECT_ROLES } from './types/index.js';\n\nexport {\n ACTIVITY_TIERS,\n APP_CATEGORIES,\n APP_CATEGORY_IDS,\n APP_CATEGORY_MAP,\n CATEGORY_LABELS,\n normalizeSkillCategory,\n CATEGORY_ORDER,\n CONTINENTS,\n COMPANY_OPTIONAL_EMPLOYMENT_TYPES,\n COUNTRIES,\n CALENDAR_EVENT_MODE_LABELS,\n CALENDAR_EVENT_STATUS_LABELS,\n PRESENTATION_LINK_TYPE_LABELS,\n PRESENTATION_LINK_TYPE_OPTIONS,\n PRESENTATION_ROLE_LABELS,\n PRESENTATION_ROLE_OPTIONS,\n PUBLICATION_TYPE_LABELS,\n PUBLICATION_TYPE_OPTIONS,\n EMPLOYMENT_TYPE_GROUPS,\n INVESTMENT_ROLE_OPTIONS,\n INVESTMENT_ROLE_LABELS,\n INVESTMENT_STAGE_OPTIONS,\n INVESTMENT_STAGE_LABELS,\n INVESTMENT_STATUS_OPTIONS,\n INVESTMENT_STATUS_LABELS,\n ON_BEHALF_OF_EMPLOYMENT_TYPES,\n EMPLOYMENT_TYPE_LABELS,\n INDUSTRY_OPTIONS,\n INDUSTRY_LABELS,\n getIndustryLabel,\n SEARCH_FILTER_DEFS,\n OPEN_TO_OPTIONS,\n OPEN_TO_TOKEN_LABELS,\n OPEN_TO_GROUP_LABELS,\n OPEN_TO_TOKENS,\n OPEN_TO_TOKEN_TO_VALUE,\n OPEN_TO_VALUE_TO_TOKEN,\n categoryForApp,\n findIndustry,\n getActivityTaxonomyVersion,\n getActivityTier,\n isRelationalActivity,\n getCalendarEventModeLabel,\n getCalendarEventStatusLabel,\n getPresentationLinkTypeLabel,\n getPresentationRoleLabel,\n getPublicationTypeLabel,\n getAppCategoryIcon,\n getEmploymentTypeLabel,\n isCompanyRequired,\n getInvestmentRoleLabel,\n getInvestmentStageLabel,\n getInvestmentStatusLabel,\n isOnBehalfOfApplicable,\n getIndustryLabelKey,\n getLexiconEntry,\n getOpenToLabelKey,\n normalizeOpenTo,\n openToTokenToValue,\n openToValueToToken,\n getTierMeta,\n getWorkplaceTypeLabel,\n normalizeWorkplaceTypes,\n isAppCategory,\n isKnownAppId,\n PLATFORM_LABELS,\n PLATFORM_OPTIONS,\n SKILL_CATEGORIES,\n WORKPLACE_TYPE_LABELS,\n WORKPLACE_TYPE_OPTIONS,\n dedupeSkills,\n getContinent,\n getFaviconUrl,\n getPlatformLabel,\n groupSkillsByCategory,\n groupSkillsBySubCategory,\n groupSkillsForDisplay,\n isKnownPlatform,\n normalizePlatformId,\n type ActivityTaxonomy,\n type ActivityTier,\n type AppCategoryId,\n type ContinentCode,\n type EmploymentTypeGroup,\n type EmploymentTypeOption,\n type InvestmentOption,\n type IndustryOption,\n type KnownAppId,\n type LexiconEntry,\n type MergedProfileSkill,\n type PresentationLinkTypeOption,\n type PresentationRoleOption,\n type PublicationTypeOption,\n INVOLVEMENT_KIND_OPTIONS,\n INVOLVEMENT_KIND_LABELS,\n INVOLVEMENT_KIND_HEADINGS,\n getInvolvementKindHeading,\n getInvolvementKindLabel,\n COURSE_ROLE_OPTIONS,\n COURSE_ROLE_LABELS,\n COURSE_ROLE_TAKEN,\n COURSE_ROLE_TAUGHT,\n COURSE_ROLE_TEACHING_ASSISTANT,\n getCourseRoleLabel,\n isTeachingCourse,\n splitCoursesByRole,\n type CourseRoleOption,\n EQF_LEVEL_LABELS,\n EQF_LEVEL_OPTIONS,\n getEducationLevelDisplay,\n getEqfLevelLabel,\n readEqfLevel,\n suggestEqfLevelFromDegree,\n type EqfLevel,\n type EqfLevelOption,\n ARTIFACT_LINK_KIND_OPTIONS,\n ARTIFACT_LINK_KIND_LABELS,\n getArtifactLinkKindLabel,\n VERIFICATION_PROVIDERS,\n getVerificationProvider,\n isKnownVerificationProvider,\n resolveVerifierProvider,\n primaryVerification,\n type AccountVerification,\n type VerificationProvider,\n type VerificationProviderId,\n type VerificationSource,\n type InvolvementKindOption,\n type ArtifactLinkKindOption,\n type OpenToGroup,\n type OpenToOption,\n type PlatformId,\n type SearchFilterControl,\n type SearchFilterDef,\n type SearchFilterOptionSource,\n type SkillCategory,\n type TierMeta,\n type WorkplaceTypeOption,\n} from './taxonomy/index.js';\n\nexport {\n certDateExtractor,\n contrastRatio,\n countryCodeToFlag,\n dateRangeExtractor,\n detectPdsProvider,\n formatCompanyName,\n formatCredentialDateRange,\n formatDateRange,\n formatPositionDateRange,\n formatDisplayUrl,\n formatDistanceToNow,\n formatIsoTitle,\n formatLocation,\n formatPresentationDuration,\n formatRelativeTime,\n formatTimelineDate,\n getDisplayLabel,\n getHandleStem,\n getPdsDisplayName,\n isValidRgbColor,\n lexiconDateExtractor,\n limitCombiningMarks,\n locationSegments,\n meetsContrastAA,\n normalizeCompanyKey,\n normalizeLegalForm,\n parseLocationString,\n parseTalkRkey,\n pdsProviderFromApi,\n relativeLuminance,\n resolveEmbed,\n youtubeVideoId,\n youtubeThumbnailUrl,\n rgbToString,\n sanitizeDisplayText,\n normalizeDoi,\n openAlexWorkUrl,\n formatRelationship,\n parseEndorsementComment,\n sanitizeHandleInput,\n singleDateExtractor,\n slugifyTitle,\n buildMetaDescription,\n buildTalkSlug,\n sortByDateDesc,\n summarizePresentationDeliveries,\n truncateGraphemes,\n collapseContributors,\n type CollapseContributorsOptions,\n type CollapsedContributors,\n type EmbedResult,\n type ParsedEndorsementComment,\n type PdsProvider,\n type PresentationDeliverySummary,\n type RgbColor,\n} from './format/index.js';\n\nexport {\n parsePresentationDuration,\n durationFromMinutes,\n parseIntendedAudiences,\n stripHtmlToText,\n normalizePresentationRole,\n normalizePresentationMode,\n presentationCsvRowToRecord,\n presentationDeliveryCsvRowToRecord,\n type CsvRow,\n type ParsedPresentation,\n type ParsedDelivery,\n} from './import/index.js';\n\nexport {\n ACTIVITY_VISIBILITY_RULES,\n ADULT_CONTENT_LABELS,\n APP_URL_PATTERNS,\n COLLECTION_TO_APP,\n getAppIdForCollection,\n hasAdultContent,\n isVisibleActivityItem,\n resolveCardHealth,\n resolveCardUrl,\n type ActivityItemForUrl,\n type ActivityLabel,\n type AdultContentLabel,\n type AppUrlPatterns,\n type CardHealth,\n type CardHealthStrategy,\n} from './cards/index.js';\n\nexport {\n PUBLISHERS,\n STANDARD_PUBLISHER_ID,\n getPublisherById,\n getPublisherByHost,\n getPublisherFromSiteUrl,\n type Publisher,\n} from './publishers/index.js';\n\n// Shared activity-stream view-model: the normalized, framework-free feed both\n// sifa-web (React cards) and page.sifa.id (string-HTML renderer) consume.\nexport {\n ACTIVITY_VERBS,\n STREAM_VERBS,\n getActivityVerbsVersion,\n streamVerbSchema,\n verbForCollection,\n streamAddressSchema,\n streamAuthorSchema,\n streamCardBodySchema,\n streamCardSubjectSchema,\n streamCardVMSchema,\n streamExternalLinkSchema,\n streamGeoSchema,\n streamMediaSchema,\n streamRichSegmentSchema,\n streamSourceSchema,\n streamThemeSchema,\n isSelfAuthoredRich,\n renderAsLine,\n streamCardBodyContent,\n streamCardContent,\n streamCardSubjectText,\n toStreamCardVM,\n toStreamCardVMs,\n type ActivityItem,\n type StreamCardContent,\n type ActivityVerbMap,\n type StreamAddress,\n type StreamAuthor,\n type StreamCardBody,\n type StreamCardSubject,\n type StreamCardVM,\n type StreamExternalLink,\n type StreamGeo,\n type StreamMedia,\n type StreamMediaBase,\n type StreamMediaBlob,\n type StreamMediaResolved,\n type StreamRichSegment,\n type StreamSource,\n type StreamTheme,\n type StreamVerb,\n type ToStreamCardVMOptions,\n} from './stream/index.js';\n\nexport {\n COMPLETENESS_MAX_SCORE,\n completenessPercent,\n completenessScore,\n DIMENSIONS_MAX_SCORE,\n MIN_SKILLS,\n countFilledDimensions,\n dimensionsFromInputs,\n getFilledDimensionsMap,\n pickPrimaryPosition,\n DATE_LOOKAHEAD_MONTHS,\n isBeyondLookahead,\n isUpcomingStart,\n type DateLookaheadKind,\n pickPrimaryFlagged,\n summarizeProfileView,\n profileToDimensionInputs,\n isPseudoEmployer,\n looksLikeDomain,\n entityDisambiguationLabel,\n searchResultDisambiguation,\n entityResultKey,\n classifyEntityRef,\n isLinked,\n ENTITY_REF_ANCHORS,\n qualifiesAsOrg,\n isRegistrableDomainHandle,\n hasPersonalProfileContent,\n rendersPersonalProfile,\n rendersCompanyProfile,\n resolveAccountFacetMode,\n isCompanyPageIndexable,\n companyPageRichness,\n COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS,\n COMPANY_PAGE_MIN_DESCRIPTION_LENGTH,\n COMPANY_PAGE_ROSTER_MIN_MEMBERS,\n countRecentActivity,\n followingFeedFallbackApp,\n SELF_APP_ID,\n excludeSelfApp,\n actorShowsIdentity,\n EMPTY_SITE_ACTIVITY_PRESET,\n SITE_PRESET_TAG_CATEGORY,\n SITE_PRESET_MAX_TAGS,\n SITE_PRESET_MAX_TAG_LENGTH,\n normalizeSitePresetTag,\n parseSitePresetTags,\n isSiteActivityPresetActive,\n recordTags,\n matchesSitePresetTags,\n matchesSiteActivityPreset,\n siteActivityPresetSchema,\n siteActivityPresetUpdateSchema,\n type SiteActivityPreset,\n type DailyActivityCount,\n type AppWithId,\n type DimensionKey,\n type DimensionMap,\n type PrimaryPositionCandidate,\n type PrimaryFlagCandidate,\n type ProfileSummary,\n type SummarizeProfileViewOptions,\n type ProfileCompletion,\n type ProfileDimensionInputs,\n type DisambiguationFields,\n type EntityRefAnchor,\n type CompanyFirmographics,\n type CompanyHqFacts,\n type PersonalFacetContent,\n resolveAgentRef,\n type AgentRefFlat,\n} from './logic/index.js';\n\n// Profile section model: which sections render, in what order, their nav\n// grouping, per-section sorts, and involvement grouping. Shared by the HTML\n// profile page, the Markdown/DOCX/print exports, and the personal-site renderer.\nexport {\n ALL_SECTIONS,\n INVOLVEMENT_HEADING_ORDER,\n SECTION_GROUPS,\n SECTION_LABELS,\n filterHidden,\n getVisibleSectionIds,\n groupInvolvementByHeading,\n groupPublicationVersions,\n type GroupPublicationVersionsOptions,\n type PublicationVersionGroup,\n type VersionablePublication,\n hoistPrimary,\n isRoleLineRedundant,\n isSectionPopulated,\n sortByActiveDateRange,\n sortCertifications,\n sortEducation,\n sortHonors,\n sortLanguages,\n sortLanguagesByProficiency,\n sortPositions,\n sortProjects,\n sortPublications,\n visibleItems,\n type InvolvementGroup,\n type SectionGroupId,\n type SectionId,\n} from './profile/index.js';\n\n// Profile \"Highlights\" block: selection + labeling of the one ongoing (or\n// most-recent) record per section. Shared by the sifa-web profile page and the\n// personal-site renderer so the two surfaces never diverge on what's featured.\nexport {\n buildProfileHighlights,\n shouldRenderHighlights,\n formatSpanDate,\n formatSingleDate,\n formatEventDate,\n type ProfileHighlightsInput,\n type ProfileHighlightSection,\n type ProfileHighlightStatus,\n type ProfileHighlightTile,\n type BuildProfileHighlightsOptions,\n} from './profile/index.js';\n\nexport {\n AtmosphereFeedItemSchema,\n BlobRefSchema,\n EndorsementConfirmationRecordSchema,\n EndorsementRecordSchema,\n OrgProfileRecordSchema,\n OrgEmploymentAttestationRecordSchema,\n EmploymentVerificationRecordSchema,\n EMPLOYMENT_STATUS_TOKENS,\n VERIFICATION_METHOD_TOKENS,\n resolveEmploymentVerification,\n EntitySearchResultSchema,\n EntitySearchResponseSchema,\n EntitySelectRequestSchema,\n EntitySelectResponseSchema,\n EntityImportSearchResponseSchema,\n EntityResolveDomainRequestSchema,\n EntityResolveDomainResponseSchema,\n EntityMintDomainResponseSchema,\n FEATURE_FLAGS,\n FeatureAllowlistEntrySchema,\n FeedActorSchema,\n FollowFeedItemSchema,\n FollowFeedPageSchema,\n FollowProfilePageSchema,\n FollowProfileSchema,\n GraphFollowRecordSchema,\n PresentationDurationSchema,\n PresentationLinkSchema,\n ProfileCertificationRecordSchema,\n ProfileCourseRecordSchema,\n ProfileEducationRecordSchema,\n ProfileExternalAccountRecordSchema,\n ProfileHonorRecordSchema,\n ProfileInvestmentRecordSchema,\n InvestmentAmountSchema,\n PROFILE_INVESTMENT_NSID,\n ProfileInvolvementRecordSchema,\n ArtifactLinkSchema,\n PROFILE_INVOLVEMENT_NSID,\n ProfileLanguageRecordSchema,\n ProfilePositionRecordSchema,\n ProfilePresentationDeliveryRecordSchema,\n ProfilePresentationRecordSchema,\n ProfileProjectRecordSchema,\n ProfilePublicationRecordSchema,\n RelatedIdentifierSchema,\n ProfileSelfRecordSchema,\n ProfileSkillRecordSchema,\n ProfileVolunteeringRecordSchema,\n PublicationAuthorSchema,\n SifaFeedItemSchema,\n atUriSchema,\n cidSchema,\n datetimeSchema,\n decodeFeedCursor,\n didSchema,\n encodeFeedCursor,\n externalRecordRefSchema,\n languageTagSchema,\n makeGraphFollowRecordSchema,\n maxGraphemes,\n partialDateSchema,\n selfLabelsSchema,\n skillRefSchema,\n strongRefSchema,\n uriSchema,\n type AtmosphereFeedItem,\n type BlobRef,\n type EndorsementConfirmationRecord,\n type EndorsementRecord,\n type OrgProfileRecord,\n type OrgEmploymentAttestationRecord,\n type EmploymentVerificationRecord,\n type EmploymentVerificationResolution,\n type ResolveEmploymentVerificationOptions,\n type EntitySearchResult,\n type EntitySearchResponse,\n type EntitySelectRequest,\n type EntitySelectResponse,\n type EntityImportSearchResponse,\n type EntityResolveDomainRequest,\n type EntityResolveDomainResponse,\n type EntityMintDomainResponse,\n type FeatureAllowlistEntry,\n type FeatureFlag,\n type FeedActor,\n type FeedCursor,\n type FollowFeedItem,\n type FollowFeedPage,\n type FollowProfileItem,\n type FollowProfilePage,\n type GraphFollowRecord,\n type SifaFeedItem,\n type ProfileCertificationRecord,\n type ProfileCourseRecord,\n type ProfileEducationRecord,\n type ProfileExternalAccountRecord,\n type ProfileHonorRecord,\n type ProfileInvolvementRecord,\n type ArtifactLink,\n type ProfileLanguageRecord,\n type PresentationDuration,\n type PresentationLink,\n type ProfilePositionRecord,\n type ProfilePresentationDeliveryRecord,\n type ProfilePresentationRecord,\n type ProfileProjectRecord,\n type ProfilePublicationRecord,\n type ProfileSelfRecord,\n type ProfileSkillRecord,\n type ProfileVolunteeringRecord,\n type PublicationAuthor,\n agentRefSchema,\n type AgentRef,\n} from './schemas/index.js';\n\nexport {\n ROADMAP_ITEM_META,\n ROADMAP_ISSUES_REPO,\n roadmapIssueUrl,\n type RoadmapItemMeta,\n} from './roadmap/index.js';\n\nexport type {\n LocationSegment,\n LocationSegmentKind,\n LocationSegmentsOptions,\n} from './format/index.js';\n\nexport type { DisplayUrl, FormatDisplayUrlOptions, UrlPathPolicy } from './format/index.js';\n\nexport { SIFA_REPO_GROUPS, describeSifaRecord, repoGroupForCollection } from './repo/index.js';\nexport type {\n RepoCollectionGroup,\n RepoDeleteOutcome,\n RepoDeleteRecordResult,\n RepoDeleteResult,\n RepoGroupDefinition,\n RepoGroupId,\n RepoInventory,\n RepoRecordLabel,\n RepoRecordSummary,\n} from './repo/index.js';\n"],"mappings":";AA8FA,SAAS,qBAAqB;AAE9B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAeA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAgBK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAQK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAOK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AAIP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAoBK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAiBA;AAAA,OAEK;AAKP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAIA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIK;AAKP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAMK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EA+CA;AAAA,OAEK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AAUP,SAAS,kBAAkB,oBAAoB,8BAA8B;AAnnBtE,IAAM,mBAA2B;","names":[]}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["/**\n * Sifa SDK -- public client library for the Sifa AppView on AT Protocol.\n *\n * Pre-1.0: the public API is unstable and may change in any minor release.\n *\n * @see https://github.com/singi-labs/sifa-sdk\n */\n\ndeclare const __SIFA_SDK_VERSION__: string;\n\nexport const SIFA_SDK_VERSION: string = __SIFA_SDK_VERSION__;\n\nexport type {\n ActiveApp,\n Endorsement,\n EndorsementData,\n ExternalAccount,\n ExternalAccountKeytraceClaim,\n FeedItem,\n LanguageProficiency,\n LocationValue,\n OrgAddressView,\n OrgFloorVerdict,\n OrgLinkView,\n OrgProfileView,\n RecognizedEntity,\n PdsProviderInfo,\n PresentationLinkView,\n Profile,\n ProfileCertification,\n ProfileCourse,\n ProfileEducation,\n ProfileHonor,\n ProfileIndustry,\n ProfileInvestment,\n ProfileInvestmentLink,\n ProfileInvolvement,\n ProfileInvolvementLink,\n ProfileLanguage,\n ProfileLocation,\n ProfileOverrideSource,\n ProfilePosition,\n PositionConfirmations,\n PositionViewerConfirmation,\n PositionOrgVerification,\n ProfilePresentation,\n CoSpeaker,\n ActorCard,\n AuthorSuggestion,\n ProjectMemberCard,\n ProjectRole,\n ProfilePresentationDelivery,\n ProfileProject,\n ProjectEventView,\n ProfilePublication,\n ProfileSkill,\n ProfileVolunteering,\n PublicationContributor,\n RelatedIdentifier,\n SkillRef,\n SkillSuggestion,\n TrustStat,\n VerifiedAccount,\n AccountFacetMode,\n} from './types/index.js';\n\n// Aggregated public profile view (`id.sifa.getProfileView` XRPC query).\nexport type {\n ProfileView,\n IndustryDomain,\n ProfileLocationView,\n PositionView,\n EducationView,\n SkillView,\n CertificationView,\n ProjectView,\n VolunteeringView,\n InvolvementView,\n InvolvementLinkView,\n PublicationView,\n ContributorView,\n CourseView,\n DurationView,\n CoSpeakerView,\n ProjectMemberView,\n PresentationDeliveryView,\n PresentationView,\n HonorView,\n LanguageView,\n ExternalAccountView,\n ActiveAppView,\n AtfundLinkView,\n} from './types/profile-view.js';\n\nexport { PROJECT_ROLES } from './types/index.js';\n\nexport {\n ACTIVITY_TIERS,\n APP_CATEGORIES,\n APP_CATEGORY_IDS,\n APP_CATEGORY_MAP,\n CATEGORY_LABELS,\n normalizeSkillCategory,\n CATEGORY_ORDER,\n CONTINENTS,\n COMPANY_OPTIONAL_EMPLOYMENT_TYPES,\n COUNTRIES,\n CALENDAR_EVENT_MODE_LABELS,\n CALENDAR_EVENT_STATUS_LABELS,\n PRESENTATION_LINK_TYPE_LABELS,\n PRESENTATION_LINK_TYPE_OPTIONS,\n PRESENTATION_ROLE_LABELS,\n PRESENTATION_ROLE_OPTIONS,\n PUBLICATION_TYPE_LABELS,\n PUBLICATION_TYPE_OPTIONS,\n EMPLOYMENT_TYPE_GROUPS,\n INVESTMENT_ROLE_OPTIONS,\n INVESTMENT_ROLE_LABELS,\n INVESTMENT_STAGE_OPTIONS,\n INVESTMENT_STAGE_LABELS,\n INVESTMENT_STATUS_OPTIONS,\n INVESTMENT_STATUS_LABELS,\n ON_BEHALF_OF_EMPLOYMENT_TYPES,\n EMPLOYMENT_TYPE_LABELS,\n INDUSTRY_OPTIONS,\n INDUSTRY_LABELS,\n getIndustryLabel,\n SEARCH_FILTER_DEFS,\n OPEN_TO_OPTIONS,\n OPEN_TO_TOKEN_LABELS,\n OPEN_TO_GROUP_LABELS,\n OPEN_TO_TOKENS,\n OPEN_TO_TOKEN_TO_VALUE,\n OPEN_TO_VALUE_TO_TOKEN,\n categoryForApp,\n findIndustry,\n getActivityTaxonomyVersion,\n getActivityTier,\n isRelationalActivity,\n getCalendarEventModeLabel,\n getCalendarEventStatusLabel,\n getPresentationLinkTypeLabel,\n getPresentationRoleLabel,\n getPublicationTypeLabel,\n getAppCategoryIcon,\n getEmploymentTypeLabel,\n isCompanyRequired,\n getInvestmentRoleLabel,\n getInvestmentStageLabel,\n getInvestmentStatusLabel,\n isOnBehalfOfApplicable,\n getIndustryLabelKey,\n getLexiconEntry,\n getOpenToLabelKey,\n normalizeOpenTo,\n openToTokenToValue,\n openToValueToToken,\n getTierMeta,\n getWorkplaceTypeLabel,\n normalizeWorkplaceTypes,\n isAppCategory,\n isKnownAppId,\n PLATFORM_LABELS,\n PLATFORM_OPTIONS,\n SKILL_CATEGORIES,\n WORKPLACE_TYPE_LABELS,\n WORKPLACE_TYPE_OPTIONS,\n dedupeSkills,\n getContinent,\n getFaviconUrl,\n getPlatformLabel,\n groupSkillsByCategory,\n groupSkillsBySubCategory,\n groupSkillsForDisplay,\n isKnownPlatform,\n normalizePlatformId,\n type ActivityTaxonomy,\n type ActivityTier,\n type AppCategoryId,\n type ContinentCode,\n type EmploymentTypeGroup,\n type EmploymentTypeOption,\n type InvestmentOption,\n type IndustryOption,\n type KnownAppId,\n type LexiconEntry,\n type MergedProfileSkill,\n type PresentationLinkTypeOption,\n type PresentationRoleOption,\n type PublicationTypeOption,\n INVOLVEMENT_KIND_OPTIONS,\n INVOLVEMENT_KIND_LABELS,\n INVOLVEMENT_KIND_HEADINGS,\n getInvolvementKindHeading,\n getInvolvementKindLabel,\n COURSE_ROLE_OPTIONS,\n COURSE_ROLE_LABELS,\n COURSE_ROLE_TAKEN,\n COURSE_ROLE_TAUGHT,\n COURSE_ROLE_TEACHING_ASSISTANT,\n getCourseRoleLabel,\n isTeachingCourse,\n splitCoursesByRole,\n type CourseRoleOption,\n EQF_LEVEL_LABELS,\n EQF_LEVEL_OPTIONS,\n getEducationLevelDisplay,\n getEqfLevelLabel,\n readEqfLevel,\n suggestEqfLevelFromDegree,\n type EqfLevel,\n type EqfLevelOption,\n ARTIFACT_LINK_KIND_OPTIONS,\n ARTIFACT_LINK_KIND_LABELS,\n getArtifactLinkKindLabel,\n VERIFICATION_PROVIDERS,\n getVerificationProvider,\n isKnownVerificationProvider,\n resolveVerifierProvider,\n primaryVerification,\n type AccountVerification,\n type VerificationProvider,\n type VerificationProviderId,\n type VerificationSource,\n type InvolvementKindOption,\n type ArtifactLinkKindOption,\n type OpenToGroup,\n type OpenToOption,\n type PlatformId,\n type SearchFilterControl,\n type SearchFilterDef,\n type SearchFilterOptionSource,\n type SkillCategory,\n type TierMeta,\n type WorkplaceTypeOption,\n} from './taxonomy/index.js';\n\nexport {\n certDateExtractor,\n contrastRatio,\n countryCodeToFlag,\n dateRangeExtractor,\n detectPdsProvider,\n formatCompanyName,\n formatCredentialDateRange,\n formatDateRange,\n formatPositionDateRange,\n formatDisplayUrl,\n formatDistanceToNow,\n formatIsoTitle,\n formatLocation,\n formatPresentationDuration,\n formatRelativeTime,\n formatTimelineDate,\n getDisplayLabel,\n getHandleStem,\n getPdsDisplayName,\n isValidRgbColor,\n lexiconDateExtractor,\n limitCombiningMarks,\n locationSegments,\n meetsContrastAA,\n normalizeCompanyKey,\n normalizeLegalForm,\n parseLocationString,\n parseTalkRkey,\n pdsProviderFromApi,\n relativeLuminance,\n resolveEmbed,\n youtubeVideoId,\n youtubeThumbnailUrl,\n rgbToString,\n sanitizeDisplayText,\n normalizeDoi,\n openAlexWorkUrl,\n blobProxyUrl,\n type BlobProxyVariant,\n formatRelationship,\n parseEndorsementComment,\n sanitizeHandleInput,\n singleDateExtractor,\n slugifyTitle,\n buildMetaDescription,\n buildTalkSlug,\n sortByDateDesc,\n summarizePresentationDeliveries,\n truncateGraphemes,\n collapseContributors,\n type CollapseContributorsOptions,\n type CollapsedContributors,\n type EmbedResult,\n type ParsedEndorsementComment,\n type PdsProvider,\n type PresentationDeliverySummary,\n type RgbColor,\n} from './format/index.js';\n\nexport {\n parsePresentationDuration,\n durationFromMinutes,\n parseIntendedAudiences,\n stripHtmlToText,\n normalizePresentationRole,\n normalizePresentationMode,\n presentationCsvRowToRecord,\n presentationDeliveryCsvRowToRecord,\n PRESENTATION_ROLE_VALUES,\n PRESENTATION_MODE_VALUES,\n type CsvRow,\n type ParsedPresentation,\n type ParsedDelivery,\n validateTalksImport,\n type TalksImportIssue,\n type TalksImportIssueCode,\n type TalksImportValidation,\n} from './import/index.js';\n\nexport {\n ACTIVITY_VISIBILITY_RULES,\n ADULT_CONTENT_LABELS,\n APP_URL_PATTERNS,\n COLLECTION_TO_APP,\n getAppIdForCollection,\n hasAdultContent,\n isVisibleActivityItem,\n resolveCardHealth,\n resolveCardUrl,\n type ActivityItemForUrl,\n type ActivityLabel,\n type AdultContentLabel,\n type AppUrlPatterns,\n type CardHealth,\n type CardHealthStrategy,\n} from './cards/index.js';\n\nexport {\n PUBLISHERS,\n STANDARD_PUBLISHER_ID,\n getPublisherById,\n getPublisherByHost,\n getPublisherFromSiteUrl,\n type Publisher,\n} from './publishers/index.js';\n\n// Shared activity-stream view-model: the normalized, framework-free feed both\n// sifa-web (React cards) and page.sifa.id (string-HTML renderer) consume.\nexport {\n ACTIVITY_VERBS,\n STREAM_VERBS,\n getActivityVerbsVersion,\n streamVerbSchema,\n verbForCollection,\n streamAddressSchema,\n streamAuthorSchema,\n streamCardBodySchema,\n streamCardSubjectSchema,\n streamCardVMSchema,\n streamExternalLinkSchema,\n streamGeoSchema,\n streamMediaSchema,\n streamRichSegmentSchema,\n streamSourceSchema,\n streamThemeSchema,\n isSelfAuthoredRich,\n renderAsLine,\n streamCardBodyContent,\n streamCardContent,\n streamCardSubjectText,\n toStreamCardVM,\n toStreamCardVMs,\n type ActivityItem,\n type StreamCardContent,\n type ActivityVerbMap,\n type StreamAddress,\n type StreamAuthor,\n type StreamCardBody,\n type StreamCardSubject,\n type StreamCardVM,\n type StreamExternalLink,\n type StreamGeo,\n type StreamMedia,\n type StreamMediaBase,\n type StreamMediaBlob,\n type StreamMediaResolved,\n type StreamRichSegment,\n type StreamSource,\n type StreamTheme,\n type StreamVerb,\n type ToStreamCardVMOptions,\n} from './stream/index.js';\n\nexport {\n COMPLETENESS_MAX_SCORE,\n completenessPercent,\n completenessScore,\n DIMENSIONS_MAX_SCORE,\n MIN_SKILLS,\n countFilledDimensions,\n dimensionsFromInputs,\n getFilledDimensionsMap,\n pickPrimaryPosition,\n DATE_LOOKAHEAD_MONTHS,\n isBeyondLookahead,\n isUpcomingStart,\n type DateLookaheadKind,\n pickPrimaryFlagged,\n summarizeProfileView,\n profileToDimensionInputs,\n isPseudoEmployer,\n looksLikeDomain,\n entityDisambiguationLabel,\n searchResultDisambiguation,\n entityResultKey,\n classifyEntityRef,\n isLinked,\n ENTITY_REF_ANCHORS,\n qualifiesAsOrg,\n isRegistrableDomainHandle,\n hasPersonalProfileContent,\n rendersPersonalProfile,\n rendersCompanyProfile,\n resolveAccountFacetMode,\n isCompanyPageIndexable,\n companyPageRichness,\n COMPANY_PAGE_MIN_FIRMOGRAPHIC_FIELDS,\n COMPANY_PAGE_MIN_DESCRIPTION_LENGTH,\n COMPANY_PAGE_ROSTER_MIN_MEMBERS,\n countRecentActivity,\n followingFeedFallbackApp,\n SELF_APP_ID,\n excludeSelfApp,\n actorShowsIdentity,\n EMPTY_SITE_ACTIVITY_PRESET,\n SITE_PRESET_TAG_CATEGORY,\n SITE_PRESET_MAX_TAGS,\n SITE_PRESET_MAX_TAG_LENGTH,\n normalizeSitePresetTag,\n parseSitePresetTags,\n isSiteActivityPresetActive,\n recordTags,\n matchesSitePresetTags,\n matchesSiteActivityPreset,\n siteActivityPresetSchema,\n siteActivityPresetUpdateSchema,\n type SiteActivityPreset,\n type DailyActivityCount,\n type AppWithId,\n type DimensionKey,\n type DimensionMap,\n type PrimaryPositionCandidate,\n type PrimaryFlagCandidate,\n type ProfileSummary,\n type SummarizeProfileViewOptions,\n type ProfileCompletion,\n type ProfileDimensionInputs,\n type DisambiguationFields,\n type EntityRefAnchor,\n type CompanyFirmographics,\n type CompanyHqFacts,\n type PersonalFacetContent,\n resolveAgentRef,\n type AgentRefFlat,\n} from './logic/index.js';\n\n// Profile section model: which sections render, in what order, their nav\n// grouping, per-section sorts, and involvement grouping. Shared by the HTML\n// profile page, the Markdown/DOCX/print exports, and the personal-site renderer.\nexport {\n ALL_SECTIONS,\n INVOLVEMENT_HEADING_ORDER,\n SECTION_GROUPS,\n SECTION_LABELS,\n filterHidden,\n getVisibleSectionIds,\n groupInvolvementByHeading,\n groupPublicationVersions,\n type GroupPublicationVersionsOptions,\n type PublicationVersionGroup,\n type VersionablePublication,\n hoistPrimary,\n isRoleLineRedundant,\n isSectionPopulated,\n sortByActiveDateRange,\n sortCertifications,\n sortEducation,\n sortHonors,\n sortLanguages,\n sortLanguagesByProficiency,\n sortPositions,\n sortProjects,\n sortPublications,\n visibleItems,\n type InvolvementGroup,\n type SectionGroupId,\n type SectionId,\n} from './profile/index.js';\n\n// Profile \"Highlights\" block: selection + labeling of the one ongoing (or\n// most-recent) record per section. Shared by the sifa-web profile page and the\n// personal-site renderer so the two surfaces never diverge on what's featured.\nexport {\n buildProfileHighlights,\n shouldRenderHighlights,\n formatSpanDate,\n formatSingleDate,\n formatEventDate,\n type ProfileHighlightsInput,\n type ProfileHighlightSection,\n type ProfileHighlightStatus,\n type ProfileHighlightTile,\n type BuildProfileHighlightsOptions,\n} from './profile/index.js';\n\nexport {\n AtmosphereFeedItemSchema,\n BlobRefSchema,\n EndorsementConfirmationRecordSchema,\n EndorsementRecordSchema,\n OrgProfileRecordSchema,\n OrgEmploymentAttestationRecordSchema,\n EmploymentVerificationRecordSchema,\n EMPLOYMENT_STATUS_TOKENS,\n VERIFICATION_METHOD_TOKENS,\n resolveEmploymentVerification,\n EntitySearchResultSchema,\n EntitySearchResponseSchema,\n EntitySelectRequestSchema,\n EntitySelectResponseSchema,\n EntityImportSearchResponseSchema,\n EntityResolveDomainRequestSchema,\n EntityResolveDomainResponseSchema,\n EntityMintDomainResponseSchema,\n FEATURE_FLAGS,\n FeatureAllowlistEntrySchema,\n FeedActorSchema,\n FollowFeedItemSchema,\n FollowFeedPageSchema,\n FollowProfilePageSchema,\n FollowProfileSchema,\n GraphFollowRecordSchema,\n PresentationDurationSchema,\n PresentationLinkSchema,\n ProfileCertificationRecordSchema,\n ProfileCourseRecordSchema,\n ProfileEducationRecordSchema,\n ProfileExternalAccountRecordSchema,\n ProfileHonorRecordSchema,\n ProfileInvestmentRecordSchema,\n InvestmentAmountSchema,\n PROFILE_INVESTMENT_NSID,\n ProfileInvolvementRecordSchema,\n ArtifactLinkSchema,\n PROFILE_INVOLVEMENT_NSID,\n ProfileLanguageRecordSchema,\n ProfilePositionRecordSchema,\n ProfilePresentationDeliveryRecordSchema,\n ProfilePresentationRecordSchema,\n ProfileProjectRecordSchema,\n ProfilePublicationRecordSchema,\n RelatedIdentifierSchema,\n ProfileSelfRecordSchema,\n ProfileSkillRecordSchema,\n ProfileVolunteeringRecordSchema,\n PublicationAuthorSchema,\n SifaFeedItemSchema,\n atUriSchema,\n cidSchema,\n datetimeSchema,\n decodeFeedCursor,\n didSchema,\n encodeFeedCursor,\n externalRecordRefSchema,\n languageTagSchema,\n makeGraphFollowRecordSchema,\n maxGraphemes,\n partialDateSchema,\n selfLabelsSchema,\n skillRefSchema,\n strongRefSchema,\n uriSchema,\n type AtmosphereFeedItem,\n type BlobRef,\n type EndorsementConfirmationRecord,\n type EndorsementRecord,\n type OrgProfileRecord,\n type OrgEmploymentAttestationRecord,\n type EmploymentVerificationRecord,\n type EmploymentVerificationResolution,\n type ResolveEmploymentVerificationOptions,\n type EntitySearchResult,\n type EntitySearchResponse,\n type EntitySelectRequest,\n type EntitySelectResponse,\n type EntityImportSearchResponse,\n type EntityResolveDomainRequest,\n type EntityResolveDomainResponse,\n type EntityMintDomainResponse,\n type FeatureAllowlistEntry,\n type FeatureFlag,\n type FeedActor,\n type FeedCursor,\n type FollowFeedItem,\n type FollowFeedPage,\n type FollowProfileItem,\n type FollowProfilePage,\n type GraphFollowRecord,\n type SifaFeedItem,\n type ProfileCertificationRecord,\n type ProfileCourseRecord,\n type ProfileEducationRecord,\n type ProfileExternalAccountRecord,\n type ProfileHonorRecord,\n type ProfileInvolvementRecord,\n type ArtifactLink,\n type ProfileLanguageRecord,\n type PresentationDuration,\n type PresentationLink,\n type ProfilePositionRecord,\n type ProfilePresentationDeliveryRecord,\n type ProfilePresentationRecord,\n type ProfileProjectRecord,\n type ProfilePublicationRecord,\n type ProfileSelfRecord,\n type ProfileSkillRecord,\n type ProfileVolunteeringRecord,\n type PublicationAuthor,\n agentRefSchema,\n type AgentRef,\n} from './schemas/index.js';\n\nexport {\n ROADMAP_ITEM_META,\n ROADMAP_ISSUES_REPO,\n roadmapIssueUrl,\n type RoadmapItemMeta,\n} from './roadmap/index.js';\n\nexport type {\n LocationSegment,\n LocationSegmentKind,\n LocationSegmentsOptions,\n} from './format/index.js';\n\nexport type { DisplayUrl, FormatDisplayUrlOptions, UrlPathPolicy } from './format/index.js';\n\nexport { SIFA_REPO_GROUPS, describeSifaRecord, repoGroupForCollection } from './repo/index.js';\nexport type {\n RepoCollectionGroup,\n RepoDeleteOutcome,\n RepoDeleteRecordResult,\n RepoDeleteResult,\n RepoGroupDefinition,\n RepoGroupId,\n RepoInventory,\n RepoRecordLabel,\n RepoRecordSummary,\n} from './repo/index.js';\n"],"mappings":";AA8FA,SAAS,qBAAqB;AAE9B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAeA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAgBK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA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KP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAIA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIK;AAKP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAMK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EA+CA;AAAA,OAEK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AAUP,SAAS,kBAAkB,oBAAoB,8BAA8B;AA3nBtE,IAAM,mBAA2B;","names":[]}
@@ -149,21 +149,21 @@ type EducationWriteInput = z.infer<typeof EducationWriteSchema>;
149
149
  /** Schema enforced by `POST /external-accounts` on sifa-api. */
150
150
  declare const ExternalAccountWriteSchema: z.ZodObject<{
151
151
  platform: z.ZodEnum<{
152
- rss: "rss";
153
- fediverse: "fediverse";
154
- twitter: "twitter";
155
- instagram: "instagram";
152
+ orcid: "orcid";
153
+ keyoxide: "keyoxide";
156
154
  github: "github";
157
155
  codeberg: "codeberg";
158
156
  gitlab: "gitlab";
159
157
  forgejo: "forgejo";
160
158
  gitea: "gitea";
161
- youtube: "youtube";
162
159
  linkedin: "linkedin";
160
+ youtube: "youtube";
161
+ twitter: "twitter";
162
+ instagram: "instagram";
163
163
  substack: "substack";
164
164
  website: "website";
165
- orcid: "orcid";
166
- keyoxide: "keyoxide";
165
+ rss: "rss";
166
+ fediverse: "fediverse";
167
167
  other: "other";
168
168
  }>;
169
169
  url: z.ZodPipe<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>, z.ZodString>;
@@ -149,21 +149,21 @@ type EducationWriteInput = z.infer<typeof EducationWriteSchema>;
149
149
  /** Schema enforced by `POST /external-accounts` on sifa-api. */
150
150
  declare const ExternalAccountWriteSchema: z.ZodObject<{
151
151
  platform: z.ZodEnum<{
152
- rss: "rss";
153
- fediverse: "fediverse";
154
- twitter: "twitter";
155
- instagram: "instagram";
152
+ orcid: "orcid";
153
+ keyoxide: "keyoxide";
156
154
  github: "github";
157
155
  codeberg: "codeberg";
158
156
  gitlab: "gitlab";
159
157
  forgejo: "forgejo";
160
158
  gitea: "gitea";
161
- youtube: "youtube";
162
159
  linkedin: "linkedin";
160
+ youtube: "youtube";
161
+ twitter: "twitter";
162
+ instagram: "instagram";
163
163
  substack: "substack";
164
164
  website: "website";
165
- orcid: "orcid";
166
- keyoxide: "keyoxide";
165
+ rss: "rss";
166
+ fediverse: "fediverse";
167
167
  other: "other";
168
168
  }>;
169
169
  url: z.ZodPipe<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>, z.ZodString>;
@@ -38,7 +38,8 @@ var streamMediaBlobSchema = z.object({
38
38
  cid: z.string(),
39
39
  alt: z.string(),
40
40
  aspectRatio: aspectRatioSchema.optional(),
41
- mimeType: z.string().optional()
41
+ mimeType: z.string().optional(),
42
+ size: z.number().int().nonnegative().optional()
42
43
  });
43
44
  var streamMediaSchema = z.union([
44
45
  streamMediaResolvedSchema,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/stream/stream-card-vm-schema.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport type {\n StreamAddress,\n StreamAuthor,\n StreamCardBody,\n StreamCardSubject,\n StreamCardVM,\n StreamExternalLink,\n StreamGeo,\n StreamMedia,\n StreamRichSegment,\n StreamSource,\n StreamTheme,\n} from './stream-card-vm.js';\nimport { streamVerbSchema } from './verb-schema.js';\n\n/** RGB channel: finite number in [0, 255] (mirrors `isValidRgbColor`). */\nconst rgbChannelSchema = z.number().min(0).max(255);\nconst rgbColorSchema = z.object({\n r: rgbChannelSchema,\n g: rgbChannelSchema,\n b: rgbChannelSchema,\n});\n\nconst aspectRatioSchema = z.object({\n width: z.number(),\n height: z.number(),\n});\n\nexport const streamSourceSchema: z.ZodType<StreamSource> = z.object({\n appId: z.string(),\n label: z.string(),\n color: z.string(),\n});\n\nexport const streamAuthorSchema: z.ZodType<StreamAuthor> = z.object({\n did: z.string().optional(),\n handle: z.string().optional(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n});\n\nexport const streamThemeSchema: z.ZodType<StreamTheme> = z.object({\n background: rgbColorSchema,\n foreground: rgbColorSchema,\n accent: rgbColorSchema,\n});\n\nconst streamMediaResolvedSchema = z.object({\n url: z.string(),\n alt: z.string(),\n aspectRatio: aspectRatioSchema.optional(),\n mimeType: z.string().optional(),\n});\n\nconst streamMediaBlobSchema = z.object({\n did: z.string(),\n cid: z.string(),\n alt: z.string(),\n aspectRatio: aspectRatioSchema.optional(),\n mimeType: z.string().optional(),\n});\n\nexport const streamMediaSchema: z.ZodType<StreamMedia> = z.union([\n streamMediaResolvedSchema,\n streamMediaBlobSchema,\n]);\n\nexport const streamExternalLinkSchema: z.ZodType<StreamExternalLink> = z.object({\n url: z.string(),\n title: z.string().optional(),\n thumb: z.string().optional(),\n});\n\nexport const streamGeoSchema: z.ZodType<StreamGeo> = z.object({\n latitude: z.number(),\n longitude: z.number(),\n});\n\nexport const streamAddressSchema: z.ZodType<StreamAddress> = z.object({\n name: z.string().optional(),\n street: z.string().optional(),\n locality: z.string().optional(),\n region: z.string().optional(),\n country: z.string().optional(),\n postalCode: z.string().optional(),\n});\n\nexport const streamRichSegmentSchema: z.ZodType<StreamRichSegment> = z.object({\n text: z.string(),\n link: z.string().optional(),\n mention: z.string().optional(),\n tag: z.string().optional(),\n});\n\nexport const streamCardBodySchema: z.ZodType<StreamCardBody> = z.discriminatedUnion('kind', [\n z.object({\n kind: z.literal('text'),\n text: z.string(),\n richSegments: z.array(streamRichSegmentSchema).optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('media'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('link'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('track'),\n text: z.string().optional(),\n trackTitle: z.string().optional(),\n artist: z.string().optional(),\n }),\n z.object({\n kind: z.literal('generic'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('github-pr'),\n repoOwner: z.string(),\n repoName: z.string(),\n prNumber: z.number(),\n title: z.string(),\n url: z.string().optional(),\n language: z.string().optional(),\n additions: z.number(),\n deletions: z.number(),\n mergedAt: z.string().optional(),\n }),\n z.object({\n kind: z.literal('book'),\n title: z.string(),\n authors: z.array(z.string()),\n stars: z.number().optional(),\n status: z.string().optional(),\n review: z.string().optional(),\n }),\n z.object({\n kind: z.literal('media-review'),\n reviewKind: z.enum(['review', 'post', 'note', 'other']),\n title: z.string().optional(),\n mediaType: z.string().optional(),\n rating: z.number().optional(),\n mainCredit: z.string().optional(),\n reviewText: z.string().optional(),\n isRevisit: z.boolean(),\n }),\n z.object({\n kind: z.literal('event-rsvp'),\n rsvpStatus: z.enum(['going', 'interested', 'notgoing', 'unknown']),\n eventName: z.string().optional(),\n startsAt: z.string().optional(),\n endsAt: z.string().optional(),\n mode: z.enum(['inperson', 'virtual', 'hybrid']).optional(),\n locationName: z.string().optional(),\n locationLocality: z.string().optional(),\n locationCountry: z.string().optional(),\n }),\n z.object({\n kind: z.literal('verification'),\n platform: z.string(),\n verified: z.boolean(),\n subjectLabel: z.string().optional(),\n handle: z.string().optional(),\n profileUrl: z.string().optional(),\n }),\n z.object({\n kind: z.literal('membership'),\n communityName: z.string().optional(),\n description: z.string().optional(),\n communityUri: z.string().optional(),\n }),\n z.object({\n kind: z.literal('location'),\n venueName: z.string().optional(),\n shout: z.string().optional(),\n address: streamAddressSchema.optional(),\n geo: streamGeoSchema.optional(),\n }),\n z.object({\n kind: z.literal('travel'),\n origin: z.string().optional(),\n destination: z.string().optional(),\n transportation: z.string().optional(),\n carrier: z.string().optional(),\n carrierCode: z.string().optional(),\n startDate: z.string().optional(),\n endDate: z.string().optional(),\n }),\n z.object({\n kind: z.literal('standard-site'),\n title: z.string().optional(),\n description: z.string().optional(),\n siteUrl: z.string().optional(),\n path: z.string().optional(),\n publisherName: z.string().optional(),\n icon: z.string().optional(),\n coverImageUrl: z.string().optional(),\n readingTime: z.number().optional(),\n publishedAt: z.string().optional(),\n }),\n]);\n\n/**\n * A stream item's repost / reply / quote target. The `post` variant nests a\n * full {@link streamCardVMSchema} (deferred via `z.lazy` for recursion).\n */\nexport const streamCardSubjectSchema: z.ZodType<StreamCardSubject> = z.discriminatedUnion('kind', [\n z.object({\n kind: z.literal('post'),\n post: z.lazy(() => streamCardVMSchema),\n }),\n z.object({\n kind: z.literal('person'),\n did: z.string(),\n handle: z.string().optional(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n }),\n z.object({\n kind: z.literal('record'),\n uri: z.string(),\n title: z.string().optional(),\n url: z.string().optional(),\n }),\n]);\n\n/** Hypercert credit roll + outbound links, hydrated by sifa-api. */\nconst hypercertDetailsSchema = z.object({\n contributors: z.array(\n z.object({\n displayName: z.string(),\n imageUrl: z.string().optional(),\n identifier: z.string().optional(),\n weight: z.number().optional(),\n }),\n ),\n contributorCount: z.number(),\n attachments: z.array(z.object({ title: z.string().optional(), url: z.string() })),\n});\n\n/** An account a Certified record points at. */\nconst certifiedActorSchema = z.object({\n did: z.string(),\n handle: z.string(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n});\n\n/** Certified badge + resolved accounts, hydrated by sifa-api. */\nconst certifiedDetailsSchema = z.object({\n badge: z\n .object({\n title: z.string(),\n description: z.string().optional(),\n icon: z.string().optional(),\n badgeType: z.string().optional(),\n })\n .optional(),\n recipient: certifiedActorSchema.optional(),\n issuer: certifiedActorSchema.optional(),\n group: certifiedActorSchema.optional(),\n role: z.string().optional(),\n});\n\n/** Zod schema for a {@link StreamCardVM}. Recursive through `subject.post`. */\nexport const streamCardVMSchema: z.ZodType<StreamCardVM> = z.lazy(() =>\n z.object({\n uri: z.string(),\n cid: z.string(),\n verb: streamVerbSchema,\n source: streamSourceSchema,\n author: streamAuthorSchema.optional(),\n tier: z.enum(['creation', 'action', 'filtered']),\n timestamp: z.string(),\n title: z.string(),\n sourceUrl: z.string().optional(),\n body: streamCardBodySchema.optional(),\n media: z.array(streamMediaSchema).optional(),\n externalLink: streamExternalLinkSchema.optional(),\n theme: streamThemeSchema.optional(),\n subject: z.lazy(() => streamCardSubjectSchema).optional(),\n hypercertDetails: hypercertDetailsSchema.optional(),\n certifiedDetails: certifiedDetailsSchema.optional(),\n }),\n);\n"],"mappings":";AAAA,SAAS,SAAS;AAelB,SAAS,wBAAwB;AAGjC,IAAM,mBAAmB,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,IAAI,GAAG;AAClD,IAAM,iBAAiB,EAAE,OAAO;AAAA,EAC9B,GAAG;AAAA,EACH,GAAG;AAAA,EAC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;AAAA,EACZ,WAAW,qBAAqB,SAAS;AAAA,EACzC,QAAQ,qBAAqB,SAAS;AAAA,EACtC,OAAO,qBAAqB,SAAS;AAAA,EACrC,MAAM,EAAE,OAAO,EAAE,SAAS;AAC5B,CAAC;AAGM,IAAM,qBAA8C,EAAE;AAAA,EAAK,MAChE,EAAE,OAAO;AAAA,IACP,KAAK,EAAE,OAAO;AAAA,IACd,KAAK,EAAE,OAAO;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,QAAQ,mBAAmB,SAAS;AAAA,IACpC,MAAM,EAAE,KAAK,CAAC,YAAY,UAAU,UAAU,CAAC;AAAA,IAC/C,WAAW,EAAE,OAAO;AAAA,IACpB,OAAO,EAAE,OAAO;AAAA,IAChB,WAAW,EAAE,OAAO,EAAE,SAAS;AAAA,IAC/B,MAAM,qBAAqB,SAAS;AAAA,IACpC,OAAO,EAAE,MAAM,iBAAiB,EAAE,SAAS;AAAA,IAC3C,cAAc,yBAAyB,SAAS;AAAA,IAChD,OAAO,kBAAkB,SAAS;AAAA,IAClC,SAAS,EAAE,KAAK,MAAM,uBAAuB,EAAE,SAAS;AAAA,IACxD,kBAAkB,uBAAuB,SAAS;AAAA,IAClD,kBAAkB,uBAAuB,SAAS;AAAA,EACpD,CAAC;AACH;","names":[]}
1
+ {"version":3,"sources":["../../src/stream/stream-card-vm-schema.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport type {\n StreamAddress,\n StreamAuthor,\n StreamCardBody,\n StreamCardSubject,\n StreamCardVM,\n StreamExternalLink,\n StreamGeo,\n StreamMedia,\n StreamRichSegment,\n StreamSource,\n StreamTheme,\n} from './stream-card-vm.js';\nimport { streamVerbSchema } from './verb-schema.js';\n\n/** RGB channel: finite number in [0, 255] (mirrors `isValidRgbColor`). */\nconst rgbChannelSchema = z.number().min(0).max(255);\nconst rgbColorSchema = z.object({\n r: rgbChannelSchema,\n g: rgbChannelSchema,\n b: rgbChannelSchema,\n});\n\nconst aspectRatioSchema = z.object({\n width: z.number(),\n height: z.number(),\n});\n\nexport const streamSourceSchema: z.ZodType<StreamSource> = z.object({\n appId: z.string(),\n label: z.string(),\n color: z.string(),\n});\n\nexport const streamAuthorSchema: z.ZodType<StreamAuthor> = z.object({\n did: z.string().optional(),\n handle: z.string().optional(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n});\n\nexport const streamThemeSchema: z.ZodType<StreamTheme> = z.object({\n background: rgbColorSchema,\n foreground: rgbColorSchema,\n accent: rgbColorSchema,\n});\n\nconst streamMediaResolvedSchema = z.object({\n url: z.string(),\n alt: z.string(),\n aspectRatio: aspectRatioSchema.optional(),\n mimeType: z.string().optional(),\n});\n\nconst streamMediaBlobSchema = z.object({\n did: z.string(),\n cid: z.string(),\n alt: z.string(),\n aspectRatio: aspectRatioSchema.optional(),\n mimeType: z.string().optional(),\n size: z.number().int().nonnegative().optional(),\n});\n\nexport const streamMediaSchema: z.ZodType<StreamMedia> = z.union([\n streamMediaResolvedSchema,\n streamMediaBlobSchema,\n]);\n\nexport const streamExternalLinkSchema: z.ZodType<StreamExternalLink> = z.object({\n url: z.string(),\n title: z.string().optional(),\n thumb: z.string().optional(),\n});\n\nexport const streamGeoSchema: z.ZodType<StreamGeo> = z.object({\n latitude: z.number(),\n longitude: z.number(),\n});\n\nexport const streamAddressSchema: z.ZodType<StreamAddress> = z.object({\n name: z.string().optional(),\n street: z.string().optional(),\n locality: z.string().optional(),\n region: z.string().optional(),\n country: z.string().optional(),\n postalCode: z.string().optional(),\n});\n\nexport const streamRichSegmentSchema: z.ZodType<StreamRichSegment> = z.object({\n text: z.string(),\n link: z.string().optional(),\n mention: z.string().optional(),\n tag: z.string().optional(),\n});\n\nexport const streamCardBodySchema: z.ZodType<StreamCardBody> = z.discriminatedUnion('kind', [\n z.object({\n kind: z.literal('text'),\n text: z.string(),\n richSegments: z.array(streamRichSegmentSchema).optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('media'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('link'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('track'),\n text: z.string().optional(),\n trackTitle: z.string().optional(),\n artist: z.string().optional(),\n }),\n z.object({\n kind: z.literal('generic'),\n text: z.string().optional(),\n tags: z.array(z.string()).optional(),\n }),\n z.object({\n kind: z.literal('github-pr'),\n repoOwner: z.string(),\n repoName: z.string(),\n prNumber: z.number(),\n title: z.string(),\n url: z.string().optional(),\n language: z.string().optional(),\n additions: z.number(),\n deletions: z.number(),\n mergedAt: z.string().optional(),\n }),\n z.object({\n kind: z.literal('book'),\n title: z.string(),\n authors: z.array(z.string()),\n stars: z.number().optional(),\n status: z.string().optional(),\n review: z.string().optional(),\n }),\n z.object({\n kind: z.literal('media-review'),\n reviewKind: z.enum(['review', 'post', 'note', 'other']),\n title: z.string().optional(),\n mediaType: z.string().optional(),\n rating: z.number().optional(),\n mainCredit: z.string().optional(),\n reviewText: z.string().optional(),\n isRevisit: z.boolean(),\n }),\n z.object({\n kind: z.literal('event-rsvp'),\n rsvpStatus: z.enum(['going', 'interested', 'notgoing', 'unknown']),\n eventName: z.string().optional(),\n startsAt: z.string().optional(),\n endsAt: z.string().optional(),\n mode: z.enum(['inperson', 'virtual', 'hybrid']).optional(),\n locationName: z.string().optional(),\n locationLocality: z.string().optional(),\n locationCountry: z.string().optional(),\n }),\n z.object({\n kind: z.literal('verification'),\n platform: z.string(),\n verified: z.boolean(),\n subjectLabel: z.string().optional(),\n handle: z.string().optional(),\n profileUrl: z.string().optional(),\n }),\n z.object({\n kind: z.literal('membership'),\n communityName: z.string().optional(),\n description: z.string().optional(),\n communityUri: z.string().optional(),\n }),\n z.object({\n kind: z.literal('location'),\n venueName: z.string().optional(),\n shout: z.string().optional(),\n address: streamAddressSchema.optional(),\n geo: streamGeoSchema.optional(),\n }),\n z.object({\n kind: z.literal('travel'),\n origin: z.string().optional(),\n destination: z.string().optional(),\n transportation: z.string().optional(),\n carrier: z.string().optional(),\n carrierCode: z.string().optional(),\n startDate: z.string().optional(),\n endDate: z.string().optional(),\n }),\n z.object({\n kind: z.literal('standard-site'),\n title: z.string().optional(),\n description: z.string().optional(),\n siteUrl: z.string().optional(),\n path: z.string().optional(),\n publisherName: z.string().optional(),\n icon: z.string().optional(),\n coverImageUrl: z.string().optional(),\n readingTime: z.number().optional(),\n publishedAt: z.string().optional(),\n }),\n]);\n\n/**\n * A stream item's repost / reply / quote target. The `post` variant nests a\n * full {@link streamCardVMSchema} (deferred via `z.lazy` for recursion).\n */\nexport const streamCardSubjectSchema: z.ZodType<StreamCardSubject> = z.discriminatedUnion('kind', [\n z.object({\n kind: z.literal('post'),\n post: z.lazy(() => streamCardVMSchema),\n }),\n z.object({\n kind: z.literal('person'),\n did: z.string(),\n handle: z.string().optional(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n }),\n z.object({\n kind: z.literal('record'),\n uri: z.string(),\n title: z.string().optional(),\n url: z.string().optional(),\n }),\n]);\n\n/** Hypercert credit roll + outbound links, hydrated by sifa-api. */\nconst hypercertDetailsSchema = z.object({\n contributors: z.array(\n z.object({\n displayName: z.string(),\n imageUrl: z.string().optional(),\n identifier: z.string().optional(),\n weight: z.number().optional(),\n }),\n ),\n contributorCount: z.number(),\n attachments: z.array(z.object({ title: z.string().optional(), url: z.string() })),\n});\n\n/** An account a Certified record points at. */\nconst certifiedActorSchema = z.object({\n did: z.string(),\n handle: z.string(),\n displayName: z.string().optional(),\n avatar: z.string().optional(),\n});\n\n/** Certified badge + resolved accounts, hydrated by sifa-api. */\nconst certifiedDetailsSchema = z.object({\n badge: z\n .object({\n title: z.string(),\n description: z.string().optional(),\n icon: z.string().optional(),\n badgeType: z.string().optional(),\n })\n .optional(),\n recipient: certifiedActorSchema.optional(),\n issuer: certifiedActorSchema.optional(),\n group: certifiedActorSchema.optional(),\n role: z.string().optional(),\n});\n\n/** Zod schema for a {@link StreamCardVM}. Recursive through `subject.post`. */\nexport const streamCardVMSchema: z.ZodType<StreamCardVM> = z.lazy(() =>\n z.object({\n uri: z.string(),\n cid: z.string(),\n verb: streamVerbSchema,\n source: streamSourceSchema,\n author: streamAuthorSchema.optional(),\n tier: z.enum(['creation', 'action', 'filtered']),\n timestamp: z.string(),\n title: z.string(),\n sourceUrl: z.string().optional(),\n body: streamCardBodySchema.optional(),\n media: z.array(streamMediaSchema).optional(),\n externalLink: streamExternalLinkSchema.optional(),\n theme: streamThemeSchema.optional(),\n subject: z.lazy(() => streamCardSubjectSchema).optional(),\n hypercertDetails: hypercertDetailsSchema.optional(),\n certifiedDetails: certifiedDetailsSchema.optional(),\n }),\n);\n"],"mappings":";AAAA,SAAS,SAAS;AAelB,SAAS,wBAAwB;AAGjC,IAAM,mBAAmB,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,IAAI,GAAG;AAClD,IAAM,iBAAiB,EAAE,OAAO;AAAA,EAC9B,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AACL,CAAC;AAED,IAAM,oBAAoB,EAAE,OAAO;AAAA,EACjC,OAAO,EAAE,OAAO;AAAA,EAChB,QAAQ,EAAE,OAAO;AACnB,CAAC;AAEM,IAAM,qBAA8C,EAAE,OAAO;AAAA,EAClE,OAAO,EAAE,OAAO;AAAA,EAChB,OAAO,EAAE,OAAO;AAAA,EAChB,OAAO,EAAE,OAAO;AAClB,CAAC;AAEM,IAAM,qBAA8C,EAAE,OAAO;AAAA,EAClE,KAAK,EAAE,OAAO,EAAE,SAAS;AAAA,EACzB,QAAQ,EAAE,OAAO,EAAE,SAAS;AAAA,EAC5B,aAAa,EAAE,OAAO,EAAE,SAAS;AAAA,EACjC,QAAQ,EAAE,OAAO,EAAE,SAAS;AAC9B,CAAC;AAEM,IAAM,oBAA4C,EAAE,OAAO;AAAA,EAChE,YAAY;AAAA,EACZ,YAAY;AAAA,EACZ,QAAQ;AACV,CAAC;AAED,IAAM,4BAA4B,EAAE,OAAO;AAAA,EAC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