@singi-labs/sifa-sdk 0.11.32 → 0.12.1

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.
@@ -583,4 +583,4 @@ declare function hasAdultContent(item: {
583
583
  labels?: ActivityLabel[];
584
584
  }): boolean;
585
585
 
586
- export { type AdultContentLabel as A, type PublicationContributor as B, type CoSpeaker as C, type SkillRef as D, type ExternalAccount as E, type FeedItem as F, hasAdultContent as G, type LocationValue as L, type ProfileSkill as P, type SkillSuggestion as S, type TrustStat as T, type VerifiedAccount as V, type ActivityLabel as a, type ProfilePresentationDelivery as b, type PdsProviderInfo as c, type Profile as d, ADULT_CONTENT_LABELS as e, type ActiveApp as f, type Endorsement as g, type EndorsementData as h, type ExternalAccountKeytraceClaim as i, type LanguageProficiency as j, type PresentationLinkView as k, type ProfileCertification as l, type ProfileCourse as m, type ProfileEducation as n, type ProfileHonor as o, type ProfileIndustry as p, type ProfileInvolvement as q, type ProfileInvolvementLink as r, type ProfileLanguage as s, type ProfileLocation as t, type ProfileOverrideSource as u, type ProfilePosition as v, type ProfilePresentation as w, type ProfileProject as x, type ProfilePublication as y, type ProfileVolunteering as z };
586
+ export { type AdultContentLabel as A, type PublicationContributor as B, type CoSpeaker as C, type SkillRef as D, type ExternalAccount as E, type FeedItem as F, hasAdultContent as G, type LocationValue as L, type ProfileSkill as P, type SkillSuggestion as S, type TrustStat as T, type VerifiedAccount as V, type ActivityLabel as a, type ProfilePresentationDelivery as b, type PdsProviderInfo as c, type Profile as d, type ProfilePosition as e, type ProfileCertification as f, type ProfileEducation as g, type ProfileHonor as h, type ProfileLanguage as i, type ProfileProject as j, type ProfilePublication as k, type ProfileInvolvement as l, ADULT_CONTENT_LABELS as m, type ActiveApp as n, type Endorsement as o, type EndorsementData as p, type ExternalAccountKeytraceClaim as q, type LanguageProficiency as r, type PresentationLinkView as s, type ProfileCourse as t, type ProfileIndustry as u, type ProfileInvolvementLink as v, type ProfileLocation as w, type ProfileOverrideSource as x, type ProfilePresentation as y, type ProfileVolunteering as z };
@@ -583,4 +583,4 @@ declare function hasAdultContent(item: {
583
583
  labels?: ActivityLabel[];
584
584
  }): boolean;
585
585
 
586
- export { type AdultContentLabel as A, type PublicationContributor as B, type CoSpeaker as C, type SkillRef as D, type ExternalAccount as E, type FeedItem as F, hasAdultContent as G, type LocationValue as L, type ProfileSkill as P, type SkillSuggestion as S, type TrustStat as T, type VerifiedAccount as V, type ActivityLabel as a, type ProfilePresentationDelivery as b, type PdsProviderInfo as c, type Profile as d, ADULT_CONTENT_LABELS as e, type ActiveApp as f, type Endorsement as g, type EndorsementData as h, type ExternalAccountKeytraceClaim as i, type LanguageProficiency as j, type PresentationLinkView as k, type ProfileCertification as l, type ProfileCourse as m, type ProfileEducation as n, type ProfileHonor as o, type ProfileIndustry as p, type ProfileInvolvement as q, type ProfileInvolvementLink as r, type ProfileLanguage as s, type ProfileLocation as t, type ProfileOverrideSource as u, type ProfilePosition as v, type ProfilePresentation as w, type ProfileProject as x, type ProfilePublication as y, type ProfileVolunteering as z };
586
+ export { type AdultContentLabel as A, type PublicationContributor as B, type CoSpeaker as C, type SkillRef as D, type ExternalAccount as E, type FeedItem as F, hasAdultContent as G, type LocationValue as L, type ProfileSkill as P, type SkillSuggestion as S, type TrustStat as T, type VerifiedAccount as V, type ActivityLabel as a, type ProfilePresentationDelivery as b, type PdsProviderInfo as c, type Profile as d, type ProfilePosition as e, type ProfileCertification as f, type ProfileEducation as g, type ProfileHonor as h, type ProfileLanguage as i, type ProfileProject as j, type ProfilePublication as k, type ProfileInvolvement as l, ADULT_CONTENT_LABELS as m, type ActiveApp as n, type Endorsement as o, type EndorsementData as p, type ExternalAccountKeytraceClaim as q, type LanguageProficiency as r, type PresentationLinkView as s, type ProfileCourse as t, type ProfileIndustry as u, type ProfileInvolvementLink as v, type ProfileLocation as w, type ProfileOverrideSource as x, type ProfilePresentation as y, type ProfileVolunteering as z };
@@ -1,9 +1,9 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode } from 'react';
3
- import { S as SifaApiConfig, s as sifaQueryKeys, W as WriteResult, a5 as RefreshPdsResult, aj as UpdateProfileOverrideInput, ak as UpdateProfileSelfInput, al as UploadAvatarResult, j as CreateResult, U as ProfileLocationInput, k as ExternalAccountInput, i as CreateExternalAccountResult, am as VerifyExternalAccountResult, E as EndorsementInput, a4 as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, P as HideProfileItemInput, ag as StatsResponse, g as AppRegistryEntry, M as HiddenApp, w as FilterOptions, ab as SearchFilters, ac as SearchResponse, af as SkillSearchResult, l as FeaturedProfile, ae as SimilarProfile, v as FetchSuggestionsOptions, ai as SuggestionsResponse, G as FollowUserResult, o as FetchFollowListOptions, x as FollowListPage, H as FollowingResponse, q as FetchFollowingFeedOptions, p as FetchFollowProfilePageOptions, z as FollowProfilePageResponse, F as FeatureAllowlistResponse, m as FetchActivityFeedOptions, b as ActivityFeedResponse, e as ActivityTeaserResponse, L as HeatmapResponse, a as AccountCheckResult, a3 as ReactionStatus, a2 as ReactionResult, a1 as ReactionError, aa as RoadmapVotesResponse, C as CastRoadmapVoteResult, D as DeleteAccountResult } from './keys-B9_KrPw_.cjs';
3
+ import { S as SifaApiConfig, s as sifaQueryKeys, W as WriteResult, a5 as RefreshPdsResult, aj as UpdateProfileOverrideInput, ak as UpdateProfileSelfInput, al as UploadAvatarResult, j as CreateResult, U as ProfileLocationInput, k as ExternalAccountInput, i as CreateExternalAccountResult, am as VerifyExternalAccountResult, E as EndorsementInput, a4 as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, P as HideProfileItemInput, ag as StatsResponse, g as AppRegistryEntry, M as HiddenApp, w as FilterOptions, ab as SearchFilters, ac as SearchResponse, af as SkillSearchResult, l as FeaturedProfile, ae as SimilarProfile, v as FetchSuggestionsOptions, ai as SuggestionsResponse, G as FollowUserResult, o as FetchFollowListOptions, x as FollowListPage, H as FollowingResponse, q as FetchFollowingFeedOptions, p as FetchFollowProfilePageOptions, z as FollowProfilePageResponse, F as FeatureAllowlistResponse, m as FetchActivityFeedOptions, b as ActivityFeedResponse, e as ActivityTeaserResponse, L as HeatmapResponse, a as AccountCheckResult, a3 as ReactionStatus, a2 as ReactionResult, a1 as ReactionError, aa as RoadmapVotesResponse, C as CastRoadmapVoteResult, D as DeleteAccountResult } from './keys-Bn36IA8Q.cjs';
4
4
  import * as _tanstack_react_query from '@tanstack/react-query';
5
5
  import { UseQueryOptions, UseMutationOptions, UseInfiniteQueryOptions, InfiniteData } from '@tanstack/react-query';
6
- import { d as Profile, v as ProfilePosition, D as SkillRef, E as ExternalAccount, S as SkillSuggestion } from './adult-content-BO4nea-m.cjs';
6
+ import { d as Profile, e as ProfilePosition, D as SkillRef, E as ExternalAccount, S as SkillSuggestion } from './adult-content-DDGP8W1e.cjs';
7
7
  import { m as EntitySearchResponse, E as EntitySearchResult, g as EntityMintDomainResponse, k as EntityResolveDomainResponse, r as EntitySelectResponse, p as EntitySelectRequest, F as FollowFeedPage, c as FeatureFlag } from './feed-D2ZV8Eaj.cjs';
8
8
 
9
9
  interface SifaProviderProps {
@@ -1,5 +1,5 @@
1
- import { S as SifaApiConfig, A as ApiFetchOptions, j as CreateResult, W as WriteResult } from './keys-B9_KrPw_.cjs';
2
- import { d as Profile, v as ProfilePosition, D as SkillRef } from './adult-content-BO4nea-m.cjs';
1
+ import { S as SifaApiConfig, A as ApiFetchOptions, j as CreateResult, W as WriteResult } from './keys-Bn36IA8Q.cjs';
2
+ import { d as Profile, e as ProfilePosition, D as SkillRef } from './adult-content-DDGP8W1e.cjs';
3
3
  import { m as EntitySearchResponse, E as EntitySearchResult, g as EntityMintDomainResponse, k as EntityResolveDomainResponse, p as EntitySelectRequest, r as EntitySelectResponse } from './feed-D2ZV8Eaj.cjs';
4
4
 
5
5
  /**
@@ -1,5 +1,5 @@
1
- import { S as SifaApiConfig, A as ApiFetchOptions, j as CreateResult, W as WriteResult } from './keys-Cy0T900D.js';
2
- import { d as Profile, v as ProfilePosition, D as SkillRef } from './adult-content-BO4nea-m.js';
1
+ import { S as SifaApiConfig, A as ApiFetchOptions, j as CreateResult, W as WriteResult } from './keys-5oyp950_.js';
2
+ import { d as Profile, e as ProfilePosition, D as SkillRef } from './adult-content-DDGP8W1e.js';
3
3
  import { m as EntitySearchResponse, E as EntitySearchResult, g as EntityMintDomainResponse, k as EntityResolveDomainResponse, p as EntitySelectRequest, r as EntitySelectResponse } from './feed-D2ZV8Eaj.js';
4
4
 
5
5
  /**
@@ -1,9 +1,9 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode } from 'react';
3
- import { S as SifaApiConfig, s as sifaQueryKeys, W as WriteResult, a5 as RefreshPdsResult, aj as UpdateProfileOverrideInput, ak as UpdateProfileSelfInput, al as UploadAvatarResult, j as CreateResult, U as ProfileLocationInput, k as ExternalAccountInput, i as CreateExternalAccountResult, am as VerifyExternalAccountResult, E as EndorsementInput, a4 as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, P as HideProfileItemInput, ag as StatsResponse, g as AppRegistryEntry, M as HiddenApp, w as FilterOptions, ab as SearchFilters, ac as SearchResponse, af as SkillSearchResult, l as FeaturedProfile, ae as SimilarProfile, v as FetchSuggestionsOptions, ai as SuggestionsResponse, G as FollowUserResult, o as FetchFollowListOptions, x as FollowListPage, H as FollowingResponse, q as FetchFollowingFeedOptions, p as FetchFollowProfilePageOptions, z as FollowProfilePageResponse, F as FeatureAllowlistResponse, m as FetchActivityFeedOptions, b as ActivityFeedResponse, e as ActivityTeaserResponse, L as HeatmapResponse, a as AccountCheckResult, a3 as ReactionStatus, a2 as ReactionResult, a1 as ReactionError, aa as RoadmapVotesResponse, C as CastRoadmapVoteResult, D as DeleteAccountResult } from './keys-Cy0T900D.js';
3
+ import { S as SifaApiConfig, s as sifaQueryKeys, W as WriteResult, a5 as RefreshPdsResult, aj as UpdateProfileOverrideInput, ak as UpdateProfileSelfInput, al as UploadAvatarResult, j as CreateResult, U as ProfileLocationInput, k as ExternalAccountInput, i as CreateExternalAccountResult, am as VerifyExternalAccountResult, E as EndorsementInput, a4 as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, P as HideProfileItemInput, ag as StatsResponse, g as AppRegistryEntry, M as HiddenApp, w as FilterOptions, ab as SearchFilters, ac as SearchResponse, af as SkillSearchResult, l as FeaturedProfile, ae as SimilarProfile, v as FetchSuggestionsOptions, ai as SuggestionsResponse, G as FollowUserResult, o as FetchFollowListOptions, x as FollowListPage, H as FollowingResponse, q as FetchFollowingFeedOptions, p as FetchFollowProfilePageOptions, z as FollowProfilePageResponse, F as FeatureAllowlistResponse, m as FetchActivityFeedOptions, b as ActivityFeedResponse, e as ActivityTeaserResponse, L as HeatmapResponse, a as AccountCheckResult, a3 as ReactionStatus, a2 as ReactionResult, a1 as ReactionError, aa as RoadmapVotesResponse, C as CastRoadmapVoteResult, D as DeleteAccountResult } from './keys-5oyp950_.js';
4
4
  import * as _tanstack_react_query from '@tanstack/react-query';
5
5
  import { UseQueryOptions, UseMutationOptions, UseInfiniteQueryOptions, InfiniteData } from '@tanstack/react-query';
6
- import { d as Profile, v as ProfilePosition, D as SkillRef, E as ExternalAccount, S as SkillSuggestion } from './adult-content-BO4nea-m.js';
6
+ import { d as Profile, e as ProfilePosition, D as SkillRef, E as ExternalAccount, S as SkillSuggestion } from './adult-content-DDGP8W1e.js';
7
7
  import { m as EntitySearchResponse, E as EntitySearchResult, g as EntityMintDomainResponse, k as EntityResolveDomainResponse, r as EntitySelectResponse, p as EntitySelectRequest, F as FollowFeedPage, c as FeatureFlag } from './feed-D2ZV8Eaj.js';
8
8
 
9
9
  interface SifaProviderProps {
package/dist/index.cjs CHANGED
@@ -1481,6 +1481,68 @@ function getArtifactLinkKindLabel(value) {
1481
1481
  return ARTIFACT_LINK_KIND_LABELS[value] ?? value;
1482
1482
  }
1483
1483
 
1484
+ // src/taxonomy/verification-providers.ts
1485
+ var MU_VERIFIER_DIDS = [
1486
+ "did:plc:ooensn4mr5mhznzypvxelfa3",
1487
+ // eurosky.social -- coordinates the trusted-verifier program
1488
+ "did:plc:durcipmx2rwgzzagbiumobs5",
1489
+ // france-atmosphe.re
1490
+ "did:plc:zsf5p7rqilz2qvyd7ezmxrfj",
1491
+ // belgium-atmosphe.re
1492
+ "did:plc:hd564mpf6bekrwzyhvujs54b",
1493
+ // medsky.network
1494
+ "did:plc:u5zp7npt5kpueado77kuihyz",
1495
+ // npmx.dev
1496
+ "did:plc:6tndl5lqrzjrx7ahjom2gjbq",
1497
+ // stewardshiplab.org
1498
+ "did:plc:vnycpb2e4lh4tc7oyr3n2jvh",
1499
+ // newsmastfoundation.org
1500
+ "did:plc:dsiqe4pszk5ldbjk66fyryjv"
1501
+ // cpesr.fr
1502
+ ];
1503
+ var VERIFICATION_PROVIDERS = {
1504
+ bluesky: {
1505
+ id: "bluesky",
1506
+ label: "Bluesky",
1507
+ priority: 0,
1508
+ source: "bluesky-api",
1509
+ verifierDids: []
1510
+ },
1511
+ mu: {
1512
+ id: "mu",
1513
+ label: "mu (Eurosky)",
1514
+ priority: 1,
1515
+ source: "firehose",
1516
+ verifierDids: MU_VERIFIER_DIDS
1517
+ }
1518
+ };
1519
+ function isKnownVerificationProvider(id) {
1520
+ return Object.hasOwn(VERIFICATION_PROVIDERS, id);
1521
+ }
1522
+ function getVerificationProvider(id) {
1523
+ return isKnownVerificationProvider(id) ? VERIFICATION_PROVIDERS[id] : void 0;
1524
+ }
1525
+ function resolveVerifierProvider(issuerDid) {
1526
+ for (const provider of Object.values(VERIFICATION_PROVIDERS)) {
1527
+ if (provider.source !== "firehose") continue;
1528
+ if (provider.verifierDids.includes(issuerDid)) return provider.id;
1529
+ }
1530
+ return null;
1531
+ }
1532
+ function primaryVerification(verifications) {
1533
+ let best = null;
1534
+ let bestPriority = Number.POSITIVE_INFINITY;
1535
+ for (const verification of verifications) {
1536
+ const provider = getVerificationProvider(verification.provider);
1537
+ if (!provider) continue;
1538
+ if (provider.priority < bestPriority) {
1539
+ best = verification;
1540
+ bestPriority = provider.priority;
1541
+ }
1542
+ }
1543
+ return best;
1544
+ }
1545
+
1484
1546
  // src/format/company-name.ts
1485
1547
  var SMALL_WORDS = /* @__PURE__ */ new Set([
1486
1548
  "a",
@@ -1645,6 +1707,25 @@ function formatPresentationDuration(duration) {
1645
1707
  return `${minMinutes} min`;
1646
1708
  }
1647
1709
 
1710
+ // src/format/timeline.ts
1711
+ var MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
1712
+ function formatTimelineDate(dateStr) {
1713
+ if (dateStr.length === 4) return dateStr;
1714
+ const [year, month] = dateStr.split("-");
1715
+ if (!month) return year ?? dateStr;
1716
+ const idx = parseInt(month, 10) - 1;
1717
+ return `${MONTHS[idx]} ${year}`;
1718
+ }
1719
+ function formatDateRange(start, end, showPresent = true) {
1720
+ if (!start && !end) return "";
1721
+ if (!start) return end ? formatTimelineDate(end) : "";
1722
+ const formattedStart = formatTimelineDate(start);
1723
+ if (!end) return showPresent ? `${formattedStart} - Present` : formattedStart;
1724
+ const formattedEnd = formatTimelineDate(end);
1725
+ if (formattedStart === formattedEnd) return formattedStart;
1726
+ return `${formattedStart} - ${formattedEnd}`;
1727
+ }
1728
+
1648
1729
  // src/format/summarize-deliveries.ts
1649
1730
  var CANCELLED_STATUS = "community.lexicon.calendar.event#cancelled";
1650
1731
  var KEYNOTE_ROLE = "id.sifa.defs#keynote";
@@ -2706,6 +2787,184 @@ function classifyEntityRef(entityRef) {
2706
2787
  function isLinked(entityRef) {
2707
2788
  return classifyEntityRef(entityRef) !== "unlinked";
2708
2789
  }
2790
+
2791
+ // src/profile/section-model.ts
2792
+ var SECTION_GROUPS = [
2793
+ { id: "overview", labelKey: "groupOverview" },
2794
+ { id: "experience", labelKey: "groupExperience" },
2795
+ { id: "qualifications", labelKey: "groupQualifications" },
2796
+ { id: "more", labelKey: "groupMore" }
2797
+ ];
2798
+ var ALL_SECTIONS = [
2799
+ { id: "about", labelKey: "about", ns: "profile", group: "overview" },
2800
+ { id: "career", labelKey: "career", ns: "sections", group: "experience" },
2801
+ { id: "skills", labelKey: "skills", ns: "sections", group: "experience" },
2802
+ { id: "projects", labelKey: "projects", ns: "sections", group: "experience" },
2803
+ {
2804
+ id: "presentations",
2805
+ labelKey: "talksAndSessions",
2806
+ ns: "sections",
2807
+ group: "experience"
2808
+ },
2809
+ {
2810
+ id: "publications",
2811
+ labelKey: "publications",
2812
+ ns: "sections",
2813
+ group: "experience"
2814
+ },
2815
+ {
2816
+ id: "credentials",
2817
+ labelKey: "credentials",
2818
+ ns: "sections",
2819
+ group: "qualifications"
2820
+ },
2821
+ {
2822
+ id: "education",
2823
+ labelKey: "education",
2824
+ ns: "sections",
2825
+ group: "qualifications"
2826
+ },
2827
+ { id: "courses", labelKey: "courses", ns: "sections", group: "qualifications" },
2828
+ { id: "awards", labelKey: "awards", ns: "sections", group: "more" },
2829
+ { id: "involvement", labelKey: "involvement", ns: "sections", group: "more" },
2830
+ { id: "languages", labelKey: "languages", ns: "sections", group: "more" },
2831
+ {
2832
+ id: "other-profiles",
2833
+ labelKey: "otherProfiles",
2834
+ ns: "sections",
2835
+ group: "more"
2836
+ }
2837
+ ];
2838
+ function isSectionPopulated(profile, id) {
2839
+ switch (id) {
2840
+ case "about":
2841
+ return Boolean(profile.about && profile.headline);
2842
+ case "career":
2843
+ return Boolean(profile.positions?.length);
2844
+ case "education":
2845
+ return Boolean(profile.education?.length);
2846
+ case "courses":
2847
+ return Boolean(profile.courses?.length);
2848
+ case "skills":
2849
+ return Boolean(profile.skills?.length);
2850
+ case "projects":
2851
+ return Boolean(profile.projects?.length);
2852
+ case "credentials":
2853
+ return Boolean(profile.certifications?.length);
2854
+ case "publications":
2855
+ return Boolean(profile.publications?.length);
2856
+ case "presentations":
2857
+ return Boolean(profile.presentations?.length) || Boolean(profile.presentationDeliveries?.length);
2858
+ case "involvement":
2859
+ return Boolean(profile.involvement?.length);
2860
+ case "awards":
2861
+ return Boolean(profile.honors?.length);
2862
+ case "languages":
2863
+ return Boolean(profile.languages?.length);
2864
+ case "other-profiles":
2865
+ return Boolean(profile.externalAccounts?.length);
2866
+ default:
2867
+ return false;
2868
+ }
2869
+ }
2870
+ function getVisibleSectionIds(profile, isOwnProfile) {
2871
+ return ALL_SECTIONS.map((s) => s.id).filter(
2872
+ (id) => isOwnProfile || isSectionPopulated(profile, id)
2873
+ );
2874
+ }
2875
+ function filterHidden(items) {
2876
+ return (items ?? []).filter((i) => !i.hidden);
2877
+ }
2878
+ function visibleItems(items, isOwnProfile) {
2879
+ return isOwnProfile ? items ?? [] : filterHidden(items);
2880
+ }
2881
+ var SECTION_LABELS = {
2882
+ about: "About",
2883
+ career: "Career",
2884
+ skills: "Skills",
2885
+ projects: "Projects",
2886
+ presentations: "Talks & sessions",
2887
+ publications: "Publications",
2888
+ credentials: "Credentials",
2889
+ education: "Education",
2890
+ courses: "Courses",
2891
+ awards: "Awards",
2892
+ involvement: "Involvement",
2893
+ languages: "Languages",
2894
+ "other-profiles": "Links"
2895
+ };
2896
+
2897
+ // src/profile/range-sort.ts
2898
+ var hasValue = (date) => !!date;
2899
+ function sortByActiveDateRange(items) {
2900
+ return sortByDateDesc(items, (p) => ({
2901
+ startDate: p.startDate,
2902
+ endDate: p.endDate,
2903
+ current: !hasValue(p.endDate) && hasValue(p.startDate)
2904
+ }));
2905
+ }
2906
+
2907
+ // src/profile/language-sort.ts
2908
+ var PROFICIENCY_RANK = {
2909
+ native: 5,
2910
+ full_professional: 4,
2911
+ professional_working: 3,
2912
+ limited_working: 2,
2913
+ elementary: 1
2914
+ };
2915
+ function rank(proficiency) {
2916
+ if (!proficiency) return 0;
2917
+ return PROFICIENCY_RANK[proficiency] ?? 0;
2918
+ }
2919
+ function sortLanguagesByProficiency(items) {
2920
+ return [...items].sort((a, b) => {
2921
+ const diff = rank(b.proficiency) - rank(a.proficiency);
2922
+ if (diff !== 0) return diff;
2923
+ return (a.language ?? "").localeCompare(b.language ?? "");
2924
+ });
2925
+ }
2926
+
2927
+ // src/profile/section-sorts.ts
2928
+ function hoistPrimary(positions) {
2929
+ const idx = positions.findIndex((p) => p.primary && !p.endedAt);
2930
+ if (idx <= 0) return positions;
2931
+ const primary = positions[idx];
2932
+ return [primary, ...positions.slice(0, idx), ...positions.slice(idx + 1)];
2933
+ }
2934
+ var sortPositions = (items) => hoistPrimary(sortByDateDesc(items, lexiconDateExtractor));
2935
+ var sortEducation = (items) => sortByDateDesc(items, lexiconDateExtractor);
2936
+ var sortProjects = (items) => sortByActiveDateRange(items);
2937
+ var sortPublications = (items) => sortByDateDesc(items, singleDateExtractor);
2938
+ var sortCertifications = (items) => sortByDateDesc(items, certDateExtractor);
2939
+ var sortHonors = (items) => sortByDateDesc(items, singleDateExtractor);
2940
+ var sortLanguages = (items) => sortLanguagesByProficiency(items);
2941
+
2942
+ // src/profile/involvement-grouping.ts
2943
+ var INVOLVEMENT_HEADING_ORDER = [
2944
+ "Open Source",
2945
+ "Community",
2946
+ "Volunteering",
2947
+ "Civic",
2948
+ "Other"
2949
+ ];
2950
+ function groupInvolvementByHeading(items) {
2951
+ const byHeading = /* @__PURE__ */ new Map();
2952
+ for (const item of items) {
2953
+ const heading = getInvolvementKindHeading(item.kind);
2954
+ const bucket = byHeading.get(heading) ?? [];
2955
+ bucket.push(item);
2956
+ byHeading.set(heading, bucket);
2957
+ }
2958
+ const recency = (i) => i.endedAt ?? i.startedAt ?? "";
2959
+ const groups = [];
2960
+ for (const heading of INVOLVEMENT_HEADING_ORDER) {
2961
+ const bucket = byHeading.get(heading);
2962
+ if (!bucket?.length) continue;
2963
+ const sorted = [...bucket].sort((a, b) => recency(b).localeCompare(recency(a)));
2964
+ groups.push({ heading, items: sorted });
2965
+ }
2966
+ return groups;
2967
+ }
2709
2968
  function maxGraphemes(max) {
2710
2969
  return (value) => {
2711
2970
  const segmenter = new Intl.Segmenter(void 0, { granularity: "grapheme" });
@@ -3107,11 +3366,12 @@ var ProfileVolunteeringRecordSchema = zod.z.object({
3107
3366
  });
3108
3367
 
3109
3368
  // src/index.ts
3110
- var SIFA_SDK_VERSION = "0.11.32";
3369
+ var SIFA_SDK_VERSION = "0.12.1";
3111
3370
 
3112
3371
  exports.ACTIVITY_TIERS = ACTIVITY_TIERS;
3113
3372
  exports.ACTIVITY_VISIBILITY_RULES = ACTIVITY_VISIBILITY_RULES;
3114
3373
  exports.ADULT_CONTENT_LABELS = ADULT_CONTENT_LABELS;
3374
+ exports.ALL_SECTIONS = ALL_SECTIONS;
3115
3375
  exports.APP_CATEGORIES = APP_CATEGORIES;
3116
3376
  exports.APP_CATEGORY_IDS = APP_CATEGORY_IDS;
3117
3377
  exports.APP_CATEGORY_MAP = APP_CATEGORY_MAP;
@@ -3152,6 +3412,7 @@ exports.FollowProfilePageSchema = FollowProfilePageSchema;
3152
3412
  exports.FollowProfileSchema = FollowProfileSchema;
3153
3413
  exports.GraphFollowRecordSchema = GraphFollowRecordSchema;
3154
3414
  exports.INDUSTRY_OPTIONS = INDUSTRY_OPTIONS;
3415
+ exports.INVOLVEMENT_HEADING_ORDER = INVOLVEMENT_HEADING_ORDER;
3155
3416
  exports.INVOLVEMENT_KIND_HEADINGS = INVOLVEMENT_KIND_HEADINGS;
3156
3417
  exports.INVOLVEMENT_KIND_LABELS = INVOLVEMENT_KIND_LABELS;
3157
3418
  exports.INVOLVEMENT_KIND_OPTIONS = INVOLVEMENT_KIND_OPTIONS;
@@ -3186,10 +3447,13 @@ exports.ProfileSelfRecordSchema = ProfileSelfRecordSchema;
3186
3447
  exports.ProfileSkillRecordSchema = ProfileSkillRecordSchema;
3187
3448
  exports.ProfileVolunteeringRecordSchema = ProfileVolunteeringRecordSchema;
3188
3449
  exports.PublicationAuthorSchema = PublicationAuthorSchema;
3450
+ exports.SECTION_GROUPS = SECTION_GROUPS;
3451
+ exports.SECTION_LABELS = SECTION_LABELS;
3189
3452
  exports.SIFA_SDK_VERSION = SIFA_SDK_VERSION;
3190
3453
  exports.SKILL_CATEGORIES = SKILL_CATEGORIES;
3191
3454
  exports.STANDARD_PUBLISHER_ID = STANDARD_PUBLISHER_ID;
3192
3455
  exports.SifaFeedItemSchema = SifaFeedItemSchema;
3456
+ exports.VERIFICATION_PROVIDERS = VERIFICATION_PROVIDERS;
3193
3457
  exports.WORKPLACE_TYPE_LABELS = WORKPLACE_TYPE_LABELS;
3194
3458
  exports.WORKPLACE_TYPE_OPTIONS = WORKPLACE_TYPE_OPTIONS;
3195
3459
  exports.atUriSchema = atUriSchema;
@@ -3214,12 +3478,15 @@ exports.encodeFeedCursor = encodeFeedCursor;
3214
3478
  exports.entityDisambiguationLabel = entityDisambiguationLabel;
3215
3479
  exports.entityResultKey = entityResultKey;
3216
3480
  exports.externalRecordRefSchema = externalRecordRefSchema;
3481
+ exports.filterHidden = filterHidden;
3217
3482
  exports.findIndustry = findIndustry;
3218
3483
  exports.formatCompanyName = formatCompanyName;
3484
+ exports.formatDateRange = formatDateRange;
3219
3485
  exports.formatDistanceToNow = formatDistanceToNow;
3220
3486
  exports.formatLocation = formatLocation;
3221
3487
  exports.formatPresentationDuration = formatPresentationDuration;
3222
3488
  exports.formatRelativeTime = formatRelativeTime;
3489
+ exports.formatTimelineDate = formatTimelineDate;
3223
3490
  exports.getActivityTaxonomyVersion = getActivityTaxonomyVersion;
3224
3491
  exports.getActivityTier = getActivityTier;
3225
3492
  exports.getAppCategoryIcon = getAppCategoryIcon;
@@ -3246,15 +3513,21 @@ exports.getPublisherByHost = getPublisherByHost;
3246
3513
  exports.getPublisherById = getPublisherById;
3247
3514
  exports.getPublisherFromSiteUrl = getPublisherFromSiteUrl;
3248
3515
  exports.getTierMeta = getTierMeta;
3516
+ exports.getVerificationProvider = getVerificationProvider;
3517
+ exports.getVisibleSectionIds = getVisibleSectionIds;
3249
3518
  exports.getWorkplaceTypeLabel = getWorkplaceTypeLabel;
3519
+ exports.groupInvolvementByHeading = groupInvolvementByHeading;
3250
3520
  exports.groupSkillsByCategory = groupSkillsByCategory;
3251
3521
  exports.hasAdultContent = hasAdultContent;
3522
+ exports.hoistPrimary = hoistPrimary;
3252
3523
  exports.isAppCategory = isAppCategory;
3253
3524
  exports.isCompanyRequired = isCompanyRequired;
3254
3525
  exports.isKnownAppId = isKnownAppId;
3255
3526
  exports.isKnownPlatform = isKnownPlatform;
3527
+ exports.isKnownVerificationProvider = isKnownVerificationProvider;
3256
3528
  exports.isLinked = isLinked;
3257
3529
  exports.isPseudoEmployer = isPseudoEmployer;
3530
+ exports.isSectionPopulated = isSectionPopulated;
3258
3531
  exports.isValidRgbColor = isValidRgbColor;
3259
3532
  exports.isVisibleActivityItem = isVisibleActivityItem;
3260
3533
  exports.languageTagSchema = languageTagSchema;
@@ -3281,21 +3554,33 @@ exports.pdsProviderFromApi = pdsProviderFromApi;
3281
3554
  exports.pickPrimaryPosition = pickPrimaryPosition;
3282
3555
  exports.presentationCsvRowToRecord = presentationCsvRowToRecord;
3283
3556
  exports.presentationDeliveryCsvRowToRecord = presentationDeliveryCsvRowToRecord;
3557
+ exports.primaryVerification = primaryVerification;
3284
3558
  exports.profileToDimensionInputs = profileToDimensionInputs;
3285
3559
  exports.relativeLuminance = relativeLuminance;
3286
3560
  exports.resolveCardHealth = resolveCardHealth;
3287
3561
  exports.resolveCardUrl = resolveCardUrl;
3562
+ exports.resolveVerifierProvider = resolveVerifierProvider;
3288
3563
  exports.rgbToString = rgbToString;
3289
3564
  exports.sanitizeDisplayText = sanitizeDisplayText;
3290
3565
  exports.sanitizeHandleInput = sanitizeHandleInput;
3291
3566
  exports.searchResultDisambiguation = searchResultDisambiguation;
3292
3567
  exports.selfLabelsSchema = selfLabelsSchema;
3293
3568
  exports.singleDateExtractor = singleDateExtractor;
3569
+ exports.sortByActiveDateRange = sortByActiveDateRange;
3294
3570
  exports.sortByDateDesc = sortByDateDesc;
3571
+ exports.sortCertifications = sortCertifications;
3572
+ exports.sortEducation = sortEducation;
3573
+ exports.sortHonors = sortHonors;
3574
+ exports.sortLanguages = sortLanguages;
3575
+ exports.sortLanguagesByProficiency = sortLanguagesByProficiency;
3576
+ exports.sortPositions = sortPositions;
3577
+ exports.sortProjects = sortProjects;
3578
+ exports.sortPublications = sortPublications;
3295
3579
  exports.stripHtmlToText = stripHtmlToText;
3296
3580
  exports.strongRefSchema = strongRefSchema;
3297
3581
  exports.summarizePresentationDeliveries = summarizePresentationDeliveries;
3298
3582
  exports.truncateGraphemes = truncateGraphemes;
3299
3583
  exports.uriSchema = uriSchema;
3584
+ exports.visibleItems = visibleItems;
3300
3585
  //# sourceMappingURL=index.cjs.map
3301
3586
  //# sourceMappingURL=index.cjs.map