@singi-labs/sifa-sdk 0.19.44 → 0.19.45

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.
Files changed (575) hide show
  1. package/dist/atproto/index.js +9 -3
  2. package/dist/atproto/index.js.map +1 -1
  3. package/dist/badge/index.js +5 -141
  4. package/dist/badge/index.js.map +1 -1
  5. package/dist/cards/adult-content.js +14 -0
  6. package/dist/cards/adult-content.js.map +1 -0
  7. package/dist/cards/app-url-patterns.js +369 -0
  8. package/dist/cards/app-url-patterns.js.map +1 -0
  9. package/dist/cards/index.js +24 -0
  10. package/dist/cards/index.js.map +1 -0
  11. package/dist/cards/resolve-card-url.js +198 -0
  12. package/dist/cards/resolve-card-url.js.map +1 -0
  13. package/dist/cards/visibility.js +45 -0
  14. package/dist/cards/visibility.js.map +1 -0
  15. package/dist/flags/index.js +4 -3
  16. package/dist/flags/index.js.map +1 -1
  17. package/dist/format/collapse-contributors.js +19 -0
  18. package/dist/format/collapse-contributors.js.map +1 -0
  19. package/dist/format/company-name.js +61 -0
  20. package/dist/format/company-name.js.map +1 -0
  21. package/dist/format/compare-text.js +9 -0
  22. package/dist/format/compare-text.js.map +1 -0
  23. package/dist/format/doi.js +8 -0
  24. package/dist/format/doi.js.map +1 -0
  25. package/dist/format/embed.js +131 -0
  26. package/dist/format/embed.js.map +1 -0
  27. package/dist/format/endorsement-context.js +35 -0
  28. package/dist/format/endorsement-context.js.map +1 -0
  29. package/dist/format/format-display-url.js +42 -0
  30. package/dist/format/format-display-url.js.map +1 -0
  31. package/dist/format/format-duration.js +13 -0
  32. package/dist/format/format-duration.js.map +1 -0
  33. package/dist/format/format-time.js +30 -0
  34. package/dist/format/format-time.js.map +1 -0
  35. package/dist/format/handle-utils.js +19 -0
  36. package/dist/format/handle-utils.js.map +1 -0
  37. package/dist/format/index.js +100 -0
  38. package/dist/format/index.js.map +1 -0
  39. package/dist/format/location-segments.js +29 -0
  40. package/dist/format/location-segments.js.map +1 -0
  41. package/dist/format/location-utils.js +42 -0
  42. package/dist/format/location-utils.js.map +1 -0
  43. package/dist/format/meta-description.js +35 -0
  44. package/dist/format/meta-description.js.map +1 -0
  45. package/dist/format/normalize-company-key.js +12 -0
  46. package/dist/format/normalize-company-key.js.map +1 -0
  47. package/dist/format/normalize-legal-form.js +71 -0
  48. package/dist/format/normalize-legal-form.js.map +1 -0
  49. package/dist/format/pds-utils.js +73 -0
  50. package/dist/format/pds-utils.js.map +1 -0
  51. package/dist/format/sort-by-date.js +39 -0
  52. package/dist/format/sort-by-date.js.map +1 -0
  53. package/dist/format/summarize-deliveries.js +37 -0
  54. package/dist/format/summarize-deliveries.js.map +1 -0
  55. package/dist/format/talk-slug.js +21 -0
  56. package/dist/format/talk-slug.js.map +1 -0
  57. package/dist/format/text-sanitize.js +29 -0
  58. package/dist/format/text-sanitize.js.map +1 -0
  59. package/dist/format/text-truncate.js +14 -0
  60. package/dist/format/text-truncate.js.map +1 -0
  61. package/dist/format/time-utils.js +19 -0
  62. package/dist/format/time-utils.js.map +1 -0
  63. package/dist/format/timeline.js +29 -0
  64. package/dist/format/timeline.js.map +1 -0
  65. package/dist/format/wcag-contrast.js +34 -0
  66. package/dist/format/wcag-contrast.js.map +1 -0
  67. package/dist/import/index.js +22 -0
  68. package/dist/import/index.js.map +1 -0
  69. package/dist/import/presentation-csv.js +116 -0
  70. package/dist/import/presentation-csv.js.map +1 -0
  71. package/dist/index.cjs +1 -1
  72. package/dist/index.js +675 -7086
  73. package/dist/index.js.map +1 -1
  74. package/dist/jev/index.js +18 -5
  75. package/dist/jev/index.js.map +1 -1
  76. package/dist/jsonld/index.js +30 -987
  77. package/dist/jsonld/index.js.map +1 -1
  78. package/dist/jsonld/profile.js +222 -0
  79. package/dist/jsonld/profile.js.map +1 -0
  80. package/dist/jsonld/terms.js +496 -0
  81. package/dist/jsonld/terms.js.map +1 -0
  82. package/dist/jsonld/url.js +17 -0
  83. package/dist/jsonld/url.js.map +1 -0
  84. package/dist/jsonld/works-graph.js +41 -0
  85. package/dist/jsonld/works-graph.js.map +1 -0
  86. package/dist/jsonld/works.js +178 -0
  87. package/dist/jsonld/works.js.map +1 -0
  88. package/dist/logic/actor-identity.js +8 -0
  89. package/dist/logic/actor-identity.js.map +1 -0
  90. package/dist/logic/agent-ref.js +24 -0
  91. package/dist/logic/agent-ref.js.map +1 -0
  92. package/dist/logic/company-page-indexable.js +23 -0
  93. package/dist/logic/company-page-indexable.js.map +1 -0
  94. package/dist/logic/date-lookahead.js +31 -0
  95. package/dist/logic/date-lookahead.js.map +1 -0
  96. package/dist/logic/domain-detect.js +43 -0
  97. package/dist/logic/domain-detect.js.map +1 -0
  98. package/dist/logic/entity-disambiguation.js +24 -0
  99. package/dist/logic/entity-disambiguation.js.map +1 -0
  100. package/dist/logic/entity-ref-anchor.js +33 -0
  101. package/dist/logic/entity-ref-anchor.js.map +1 -0
  102. package/dist/logic/index.js +91 -0
  103. package/dist/logic/index.js.map +1 -0
  104. package/dist/logic/org-floor.js +66 -0
  105. package/dist/logic/org-floor.js.map +1 -0
  106. package/dist/logic/primary-item.js +9 -0
  107. package/dist/logic/primary-item.js.map +1 -0
  108. package/dist/logic/primary-position.js +16 -0
  109. package/dist/logic/primary-position.js.map +1 -0
  110. package/dist/logic/profile-completeness.js +21 -0
  111. package/dist/logic/profile-completeness.js.map +1 -0
  112. package/dist/logic/profile-dimensions.js +50 -0
  113. package/dist/logic/profile-dimensions.js.map +1 -0
  114. package/dist/logic/profile-summary.js +23 -0
  115. package/dist/logic/profile-summary.js.map +1 -0
  116. package/dist/logic/pseudo-employer.js +34 -0
  117. package/dist/logic/pseudo-employer.js.map +1 -0
  118. package/dist/logic/recent-activity.js +10 -0
  119. package/dist/logic/recent-activity.js.map +1 -0
  120. package/dist/logic/self-app.js +10 -0
  121. package/dist/logic/self-app.js.map +1 -0
  122. package/dist/{org-BCrvebcf.d.ts → org-CxTEjjrm.d.ts} +1 -1
  123. package/dist/{org-settings-C73Sin5E.d.ts → org-settings-BShvhyFp.d.ts} +1 -1
  124. package/dist/profile/headline-role-dedupe.js +12 -0
  125. package/dist/profile/headline-role-dedupe.js.map +1 -0
  126. package/dist/profile/highlights.js +200 -0
  127. package/dist/profile/highlights.js.map +1 -0
  128. package/dist/profile/index.js +66 -0
  129. package/dist/profile/index.js.map +1 -0
  130. package/dist/profile/involvement-grouping.js +31 -0
  131. package/dist/profile/involvement-grouping.js.map +1 -0
  132. package/dist/profile/language-sort.js +24 -0
  133. package/dist/profile/language-sort.js.map +1 -0
  134. package/dist/profile/publication-versions.js +98 -0
  135. package/dist/profile/publication-versions.js.map +1 -0
  136. package/dist/profile/range-sort.js +14 -0
  137. package/dist/profile/range-sort.js.map +1 -0
  138. package/dist/profile/section-model.js +122 -0
  139. package/dist/profile/section-model.js.map +1 -0
  140. package/dist/profile/section-sorts.js +33 -0
  141. package/dist/profile/section-sorts.js.map +1 -0
  142. package/dist/publishers/index.js +16 -0
  143. package/dist/publishers/index.js.map +1 -0
  144. package/dist/publishers/registry.js +87 -0
  145. package/dist/publishers/registry.js.map +1 -0
  146. package/dist/publishing/index.js +46 -184
  147. package/dist/publishing/index.js.map +1 -1
  148. package/dist/publishing/linkblog.js +42 -0
  149. package/dist/publishing/linkblog.js.map +1 -0
  150. package/dist/publishing/registry.js +32 -0
  151. package/dist/publishing/registry.js.map +1 -0
  152. package/dist/publishing/schemas.js +74 -0
  153. package/dist/publishing/schemas.js.map +1 -0
  154. package/dist/publishing/types.js +32 -0
  155. package/dist/publishing/types.js.map +1 -0
  156. package/dist/query/client.js +119 -0
  157. package/dist/query/client.js.map +1 -0
  158. package/dist/query/config.js +23 -0
  159. package/dist/query/config.js.map +1 -0
  160. package/dist/query/fetchers/accounts.js +29 -0
  161. package/dist/query/fetchers/accounts.js.map +1 -0
  162. package/dist/query/fetchers/activity-items-hide.js +31 -0
  163. package/dist/query/fetchers/activity-items-hide.js.map +1 -0
  164. package/dist/query/fetchers/activity.js +61 -0
  165. package/dist/query/fetchers/activity.js.map +1 -0
  166. package/dist/query/fetchers/actor.js +30 -0
  167. package/dist/query/fetchers/actor.js.map +1 -0
  168. package/dist/query/fetchers/admin-feature-allowlists.js +41 -0
  169. package/dist/query/fetchers/admin-feature-allowlists.js.map +1 -0
  170. package/dist/query/fetchers/admin-review-queues.js +30 -0
  171. package/dist/query/fetchers/admin-review-queues.js.map +1 -0
  172. package/dist/query/fetchers/apps.js +31 -0
  173. package/dist/query/fetchers/apps.js.map +1 -0
  174. package/dist/query/fetchers/bsky-preferences.js +55 -0
  175. package/dist/query/fetchers/bsky-preferences.js.map +1 -0
  176. package/dist/query/fetchers/confirmations.js +55 -0
  177. package/dist/query/fetchers/confirmations.js.map +1 -0
  178. package/dist/query/fetchers/destructive.js +34 -0
  179. package/dist/query/fetchers/destructive.js.map +1 -0
  180. package/dist/query/fetchers/discovery.js +67 -0
  181. package/dist/query/fetchers/discovery.js.map +1 -0
  182. package/dist/query/fetchers/education.js +23 -0
  183. package/dist/query/fetchers/education.js.map +1 -0
  184. package/dist/query/fetchers/endorsement-inbox.js +36 -0
  185. package/dist/query/fetchers/endorsement-inbox.js.map +1 -0
  186. package/dist/query/fetchers/endorsement.js +23 -0
  187. package/dist/query/fetchers/endorsement.js.map +1 -0
  188. package/dist/query/fetchers/endorsements.js +20 -0
  189. package/dist/query/fetchers/endorsements.js.map +1 -0
  190. package/dist/query/fetchers/entities.js +65 -0
  191. package/dist/query/fetchers/entities.js.map +1 -0
  192. package/dist/query/fetchers/external-accounts.js +74 -0
  193. package/dist/query/fetchers/external-accounts.js.map +1 -0
  194. package/dist/query/fetchers/follow-extras.js +38 -0
  195. package/dist/query/fetchers/follow-extras.js.map +1 -0
  196. package/dist/query/fetchers/follow.js +105 -0
  197. package/dist/query/fetchers/follow.js.map +1 -0
  198. package/dist/query/fetchers/get-profile-view.js +21 -0
  199. package/dist/query/fetchers/get-profile-view.js.map +1 -0
  200. package/dist/query/fetchers/github-prs.js +45 -0
  201. package/dist/query/fetchers/github-prs.js.map +1 -0
  202. package/dist/query/fetchers/inbox.js +29 -0
  203. package/dist/query/fetchers/inbox.js.map +1 -0
  204. package/dist/query/fetchers/index.d.ts +2 -2
  205. package/dist/query/fetchers/index.js +360 -2045
  206. package/dist/query/fetchers/index.js.map +1 -1
  207. package/dist/query/fetchers/investments.js +18 -0
  208. package/dist/query/fetchers/investments.js.map +1 -0
  209. package/dist/query/fetchers/keytrace-claims.js +23 -0
  210. package/dist/query/fetchers/keytrace-claims.js.map +1 -0
  211. package/dist/query/fetchers/marque-domains.js +23 -0
  212. package/dist/query/fetchers/marque-domains.js.map +1 -0
  213. package/dist/query/fetchers/network-map.js +36 -0
  214. package/dist/query/fetchers/network-map.js.map +1 -0
  215. package/dist/query/fetchers/org.js +48 -0
  216. package/dist/query/fetchers/org.js.map +1 -0
  217. package/dist/query/fetchers/positions.js +77 -0
  218. package/dist/query/fetchers/positions.js.map +1 -0
  219. package/dist/query/fetchers/profile-completeness.js +45 -0
  220. package/dist/query/fetchers/profile-completeness.js.map +1 -0
  221. package/dist/query/fetchers/profile-items-hide.js +36 -0
  222. package/dist/query/fetchers/profile-items-hide.js.map +1 -0
  223. package/dist/query/fetchers/profile-locations.js +23 -0
  224. package/dist/query/fetchers/profile-locations.js.map +1 -0
  225. package/dist/query/fetchers/profile-mutations.js +82 -0
  226. package/dist/query/fetchers/profile-mutations.js.map +1 -0
  227. package/dist/query/fetchers/profile-summary.js +14 -0
  228. package/dist/query/fetchers/profile-summary.js.map +1 -0
  229. package/dist/query/fetchers/profile.js +31 -0
  230. package/dist/query/fetchers/profile.js.map +1 -0
  231. package/dist/query/fetchers/publications.js +66 -0
  232. package/dist/query/fetchers/publications.js.map +1 -0
  233. package/dist/query/fetchers/quoted-posts.js +40 -0
  234. package/dist/query/fetchers/quoted-posts.js.map +1 -0
  235. package/dist/query/fetchers/reactions.js +85 -0
  236. package/dist/query/fetchers/reactions.js.map +1 -0
  237. package/dist/query/fetchers/received-endorsements.js +20 -0
  238. package/dist/query/fetchers/received-endorsements.js.map +1 -0
  239. package/dist/query/fetchers/reciprocity.js +23 -0
  240. package/dist/query/fetchers/reciprocity.js.map +1 -0
  241. package/dist/query/fetchers/records.js +27 -0
  242. package/dist/query/fetchers/records.js.map +1 -0
  243. package/dist/query/fetchers/repo-inventory.js +23 -0
  244. package/dist/query/fetchers/repo-inventory.js.map +1 -0
  245. package/dist/query/fetchers/roadmap.js +73 -0
  246. package/dist/query/fetchers/roadmap.js.map +1 -0
  247. package/dist/query/fetchers/rpg.js +36 -0
  248. package/dist/query/fetchers/rpg.js.map +1 -0
  249. package/dist/query/fetchers/search.js +78 -0
  250. package/dist/query/fetchers/search.js.map +1 -0
  251. package/dist/query/fetchers/section-primary.js +23 -0
  252. package/dist/query/fetchers/section-primary.js.map +1 -0
  253. package/dist/query/fetchers/skills.js +30 -0
  254. package/dist/query/fetchers/skills.js.map +1 -0
  255. package/dist/query/fetchers/speakers.js +42 -0
  256. package/dist/query/fetchers/speakers.js.map +1 -0
  257. package/dist/query/fetchers/stats.js +16 -0
  258. package/dist/query/fetchers/stats.js.map +1 -0
  259. package/dist/query/fetchers/stream.js +30 -0
  260. package/dist/query/fetchers/stream.js.map +1 -0
  261. package/dist/query/fetchers/unlinked-positions.js +30 -0
  262. package/dist/query/fetchers/unlinked-positions.js.map +1 -0
  263. package/dist/query/hooks/index.d.ts +3 -3
  264. package/dist/query/hooks/index.js +283 -3555
  265. package/dist/query/hooks/index.js.map +1 -1
  266. package/dist/query/hooks/use-accounts.js +19 -0
  267. package/dist/query/hooks/use-accounts.js.map +1 -0
  268. package/dist/query/hooks/use-activity-items-hide.js +52 -0
  269. package/dist/query/hooks/use-activity-items-hide.js.map +1 -0
  270. package/dist/query/hooks/use-activity.js +44 -0
  271. package/dist/query/hooks/use-activity.js.map +1 -0
  272. package/dist/query/hooks/use-admin-review-queues.js +21 -0
  273. package/dist/query/hooks/use-admin-review-queues.js.map +1 -0
  274. package/dist/query/hooks/use-apps.js +31 -0
  275. package/dist/query/hooks/use-apps.js.map +1 -0
  276. package/dist/query/hooks/use-bsky-content-prefs.js +45 -0
  277. package/dist/query/hooks/use-bsky-content-prefs.js.map +1 -0
  278. package/dist/query/hooks/use-confirmations.js +121 -0
  279. package/dist/query/hooks/use-confirmations.js.map +1 -0
  280. package/dist/query/hooks/use-create-position.js +28 -0
  281. package/dist/query/hooks/use-create-position.js.map +1 -0
  282. package/dist/query/hooks/use-destructive.js +63 -0
  283. package/dist/query/hooks/use-destructive.js.map +1 -0
  284. package/dist/query/hooks/use-discovery.js +53 -0
  285. package/dist/query/hooks/use-discovery.js.map +1 -0
  286. package/dist/query/hooks/use-education-mutations.js +67 -0
  287. package/dist/query/hooks/use-education-mutations.js.map +1 -0
  288. package/dist/query/hooks/use-endorsement-inbox.js +80 -0
  289. package/dist/query/hooks/use-endorsement-inbox.js.map +1 -0
  290. package/dist/query/hooks/use-endorsement-mutations.js +33 -0
  291. package/dist/query/hooks/use-endorsement-mutations.js.map +1 -0
  292. package/dist/query/hooks/use-endorsement.js +20 -0
  293. package/dist/query/hooks/use-endorsement.js.map +1 -0
  294. package/dist/query/hooks/use-entity-search.js +73 -0
  295. package/dist/query/hooks/use-entity-search.js.map +1 -0
  296. package/dist/query/hooks/use-external-accounts.js +143 -0
  297. package/dist/query/hooks/use-external-accounts.js.map +1 -0
  298. package/dist/query/hooks/use-feature-allowlist.js +104 -0
  299. package/dist/query/hooks/use-feature-allowlist.js.map +1 -0
  300. package/dist/query/hooks/use-follow-extras.js +38 -0
  301. package/dist/query/hooks/use-follow-extras.js.map +1 -0
  302. package/dist/query/hooks/use-follow.js +113 -0
  303. package/dist/query/hooks/use-follow.js.map +1 -0
  304. package/dist/query/hooks/use-get-profile-view.js +20 -0
  305. package/dist/query/hooks/use-get-profile-view.js.map +1 -0
  306. package/dist/query/hooks/use-github-prs.js +21 -0
  307. package/dist/query/hooks/use-github-prs.js.map +1 -0
  308. package/dist/query/hooks/use-inbox.js +19 -0
  309. package/dist/query/hooks/use-inbox.js.map +1 -0
  310. package/dist/query/hooks/use-investment-mutations.js +65 -0
  311. package/dist/query/hooks/use-investment-mutations.js.map +1 -0
  312. package/dist/query/hooks/use-keytrace-claims.js +50 -0
  313. package/dist/query/hooks/use-keytrace-claims.js.map +1 -0
  314. package/dist/query/hooks/use-location-mutations.js +71 -0
  315. package/dist/query/hooks/use-location-mutations.js.map +1 -0
  316. package/dist/query/hooks/use-marque-domains.js +50 -0
  317. package/dist/query/hooks/use-marque-domains.js.map +1 -0
  318. package/dist/query/hooks/use-org-claim.js +29 -0
  319. package/dist/query/hooks/use-org-claim.js.map +1 -0
  320. package/dist/query/hooks/use-org-domains.js +28 -0
  321. package/dist/query/hooks/use-org-domains.js.map +1 -0
  322. package/dist/query/hooks/use-org-notification-emails.js +28 -0
  323. package/dist/query/hooks/use-org-notification-emails.js.map +1 -0
  324. package/dist/query/hooks/use-org-profile-settings.js +29 -0
  325. package/dist/query/hooks/use-org-profile-settings.js.map +1 -0
  326. package/dist/query/hooks/use-org-profile.js +21 -0
  327. package/dist/query/hooks/use-org-profile.js.map +1 -0
  328. package/dist/query/hooks/use-position-mutations.js +128 -0
  329. package/dist/query/hooks/use-position-mutations.js.map +1 -0
  330. package/dist/query/hooks/use-profile-completeness.js +21 -0
  331. package/dist/query/hooks/use-profile-completeness.js.map +1 -0
  332. package/dist/query/hooks/use-profile-items-hide.js +53 -0
  333. package/dist/query/hooks/use-profile-items-hide.js.map +1 -0
  334. package/dist/query/hooks/use-profile-mutations.js +143 -0
  335. package/dist/query/hooks/use-profile-mutations.js.map +1 -0
  336. package/dist/query/hooks/use-profile.js +30 -0
  337. package/dist/query/hooks/use-profile.js.map +1 -0
  338. package/dist/query/hooks/use-publication-mutations.js +90 -0
  339. package/dist/query/hooks/use-publication-mutations.js.map +1 -0
  340. package/dist/query/hooks/use-reaction-mutations.js +48 -0
  341. package/dist/query/hooks/use-reaction-mutations.js.map +1 -0
  342. package/dist/query/hooks/use-reactions.js +32 -0
  343. package/dist/query/hooks/use-reactions.js.map +1 -0
  344. package/dist/query/hooks/use-received-endorsements.js +23 -0
  345. package/dist/query/hooks/use-received-endorsements.js.map +1 -0
  346. package/dist/query/hooks/use-reciprocity.js +19 -0
  347. package/dist/query/hooks/use-reciprocity.js.map +1 -0
  348. package/dist/query/hooks/use-record-mutations.js +67 -0
  349. package/dist/query/hooks/use-record-mutations.js.map +1 -0
  350. package/dist/query/hooks/use-repo-inventory.js +43 -0
  351. package/dist/query/hooks/use-repo-inventory.js.map +1 -0
  352. package/dist/query/hooks/use-roadmap-mutations.js +51 -0
  353. package/dist/query/hooks/use-roadmap-mutations.js.map +1 -0
  354. package/dist/query/hooks/use-roadmap.js +31 -0
  355. package/dist/query/hooks/use-roadmap.js.map +1 -0
  356. package/dist/query/hooks/use-search.js +63 -0
  357. package/dist/query/hooks/use-search.js.map +1 -0
  358. package/dist/query/hooks/use-section-primary-mutations.js +53 -0
  359. package/dist/query/hooks/use-section-primary-mutations.js.map +1 -0
  360. package/dist/query/hooks/use-skill-mutations.js +91 -0
  361. package/dist/query/hooks/use-skill-mutations.js.map +1 -0
  362. package/dist/query/hooks/use-stats.js +19 -0
  363. package/dist/query/hooks/use-stats.js.map +1 -0
  364. package/dist/query/hooks/use-stream.js +20 -0
  365. package/dist/query/hooks/use-stream.js.map +1 -0
  366. package/dist/query/hooks/use-unlinked-positions.js +45 -0
  367. package/dist/query/hooks/use-unlinked-positions.js.map +1 -0
  368. package/dist/query/index.d.ts +4 -4
  369. package/dist/query/index.js +685 -3744
  370. package/dist/query/index.js.map +1 -1
  371. package/dist/query/keys.js +138 -0
  372. package/dist/query/keys.js.map +1 -0
  373. package/dist/repo/groups.js +81 -0
  374. package/dist/repo/groups.js.map +1 -0
  375. package/dist/repo/index.js +9 -0
  376. package/dist/repo/index.js.map +1 -0
  377. package/dist/repo/labels.js +121 -0
  378. package/dist/repo/labels.js.map +1 -0
  379. package/dist/repo/types.js +1 -0
  380. package/dist/repo/types.js.map +1 -0
  381. package/dist/resume/index.js +5 -179
  382. package/dist/resume/index.js.map +1 -1
  383. package/dist/resume/json-resume.js +153 -0
  384. package/dist/resume/json-resume.js.map +1 -0
  385. package/dist/roadmap/index.js +101 -0
  386. package/dist/roadmap/index.js.map +1 -0
  387. package/dist/rpg/catalog.js +101 -0
  388. package/dist/rpg/catalog.js.map +1 -0
  389. package/dist/rpg/index.js +13 -116
  390. package/dist/rpg/index.js.map +1 -1
  391. package/dist/rpg/unlocks.js +21 -0
  392. package/dist/rpg/unlocks.js.map +1 -0
  393. package/dist/schemas/blob-ref.js +12 -0
  394. package/dist/schemas/blob-ref.js.map +1 -0
  395. package/dist/schemas/confirmation.js +23 -0
  396. package/dist/schemas/confirmation.js.map +1 -0
  397. package/dist/schemas/endorsement-confirmation.js +18 -0
  398. package/dist/schemas/endorsement-confirmation.js.map +1 -0
  399. package/dist/schemas/endorsement.js +19 -0
  400. package/dist/schemas/endorsement.js.map +1 -0
  401. package/dist/schemas/entity.js +74 -0
  402. package/dist/schemas/entity.js.map +1 -0
  403. package/dist/schemas/feed.js +73 -0
  404. package/dist/schemas/feed.js.map +1 -0
  405. package/dist/schemas/follow-profile.js +32 -0
  406. package/dist/schemas/follow-profile.js.map +1 -0
  407. package/dist/schemas/graph-follow.js +19 -0
  408. package/dist/schemas/graph-follow.js.map +1 -0
  409. package/dist/schemas/index.js +164 -629
  410. package/dist/schemas/index.js.map +1 -1
  411. package/dist/schemas/org-employment-attestation.js +28 -0
  412. package/dist/schemas/org-employment-attestation.js.map +1 -0
  413. package/dist/schemas/org-profile.js +64 -0
  414. package/dist/schemas/org-profile.js.map +1 -0
  415. package/dist/schemas/profile-certification.js +28 -0
  416. package/dist/schemas/profile-certification.js.map +1 -0
  417. package/dist/schemas/profile-course.js +32 -0
  418. package/dist/schemas/profile-course.js.map +1 -0
  419. package/dist/schemas/profile-education.js +33 -0
  420. package/dist/schemas/profile-education.js.map +1 -0
  421. package/dist/schemas/profile-external-account.js +15 -0
  422. package/dist/schemas/profile-external-account.js.map +1 -0
  423. package/dist/schemas/profile-honor.js +18 -0
  424. package/dist/schemas/profile-honor.js.map +1 -0
  425. package/dist/schemas/profile-investment.js +48 -0
  426. package/dist/schemas/profile-investment.js.map +1 -0
  427. package/dist/schemas/profile-involvement.js +47 -0
  428. package/dist/schemas/profile-involvement.js.map +1 -0
  429. package/dist/schemas/profile-language.js +12 -0
  430. package/dist/schemas/profile-language.js.map +1 -0
  431. package/dist/schemas/profile-position.js +42 -0
  432. package/dist/schemas/profile-position.js.map +1 -0
  433. package/dist/schemas/profile-presentation-delivery.js +38 -0
  434. package/dist/schemas/profile-presentation-delivery.js.map +1 -0
  435. package/dist/schemas/profile-presentation.js +36 -0
  436. package/dist/schemas/profile-presentation.js.map +1 -0
  437. package/dist/schemas/profile-project.js +48 -0
  438. package/dist/schemas/profile-project.js.map +1 -0
  439. package/dist/schemas/profile-publication.js +30 -0
  440. package/dist/schemas/profile-publication.js.map +1 -0
  441. package/dist/schemas/profile-self.js +22 -0
  442. package/dist/schemas/profile-self.js.map +1 -0
  443. package/dist/schemas/profile-skill.js +13 -0
  444. package/dist/schemas/profile-skill.js.map +1 -0
  445. package/dist/schemas/profile-volunteering.js +20 -0
  446. package/dist/schemas/profile-volunteering.js.map +1 -0
  447. package/dist/schemas/shared.js +56 -0
  448. package/dist/schemas/shared.js.map +1 -0
  449. package/dist/schemas/write/certification.js +16 -0
  450. package/dist/schemas/write/certification.js.map +1 -0
  451. package/dist/schemas/write/course.js +36 -0
  452. package/dist/schemas/write/course.js.map +1 -0
  453. package/dist/schemas/write/education.js +18 -0
  454. package/dist/schemas/write/education.js.map +1 -0
  455. package/dist/schemas/write/external-account.js +13 -0
  456. package/dist/schemas/write/external-account.js.map +1 -0
  457. package/dist/schemas/write/honor.js +14 -0
  458. package/dist/schemas/write/honor.js.map +1 -0
  459. package/dist/schemas/write/index.d.ts +1 -1
  460. package/dist/schemas/write/index.js +89 -593
  461. package/dist/schemas/write/index.js.map +1 -1
  462. package/dist/schemas/write/investment.js +32 -0
  463. package/dist/schemas/write/investment.js.map +1 -0
  464. package/dist/schemas/write/involvement.js +34 -0
  465. package/dist/schemas/write/involvement.js.map +1 -0
  466. package/dist/schemas/write/language.js +10 -0
  467. package/dist/schemas/write/language.js.map +1 -0
  468. package/dist/schemas/write/org-claim.js +56 -0
  469. package/dist/schemas/write/org-claim.js.map +1 -0
  470. package/dist/schemas/write/org-employment-attestation.js +19 -0
  471. package/dist/schemas/write/org-employment-attestation.js.map +1 -0
  472. package/dist/schemas/write/org-profile.js +54 -0
  473. package/dist/schemas/write/org-profile.js.map +1 -0
  474. package/dist/schemas/write/org-settings.js +81 -0
  475. package/dist/schemas/write/org-settings.js.map +1 -0
  476. package/dist/schemas/write/position.js +24 -0
  477. package/dist/schemas/write/position.js.map +1 -0
  478. package/dist/schemas/write/presentation-delivery.js +34 -0
  479. package/dist/schemas/write/presentation-delivery.js.map +1 -0
  480. package/dist/schemas/write/presentation.js +23 -0
  481. package/dist/schemas/write/presentation.js.map +1 -0
  482. package/dist/schemas/write/profile-location.js +21 -0
  483. package/dist/schemas/write/profile-location.js.map +1 -0
  484. package/dist/schemas/write/profile-self.js +27 -0
  485. package/dist/schemas/write/profile-self.js.map +1 -0
  486. package/dist/schemas/write/project.js +27 -0
  487. package/dist/schemas/write/project.js.map +1 -0
  488. package/dist/schemas/write/publication.js +41 -0
  489. package/dist/schemas/write/publication.js.map +1 -0
  490. package/dist/schemas/write/shared.js +96 -0
  491. package/dist/schemas/write/shared.js.map +1 -0
  492. package/dist/schemas/write/skill.js +18 -0
  493. package/dist/schemas/write/skill.js.map +1 -0
  494. package/dist/schemas/write/volunteering.js +16 -0
  495. package/dist/schemas/write/volunteering.js.map +1 -0
  496. package/dist/stream/activity-item.js +1 -0
  497. package/dist/stream/activity-item.js.map +1 -0
  498. package/dist/stream/index.js +49 -0
  499. package/dist/stream/index.js.map +1 -0
  500. package/dist/stream/stream-card-vm-schema.js +265 -0
  501. package/dist/stream/stream-card-vm-schema.js.map +1 -0
  502. package/dist/stream/stream-card-vm.js +1 -0
  503. package/dist/stream/stream-card-vm.js.map +1 -0
  504. package/dist/stream/to-stream-card-vm.js +793 -0
  505. package/dist/stream/to-stream-card-vm.js.map +1 -0
  506. package/dist/stream/two-tier.js +30 -0
  507. package/dist/stream/two-tier.js.map +1 -0
  508. package/dist/stream/verbs.js +120 -0
  509. package/dist/stream/verbs.js.map +1 -0
  510. package/dist/taxonomy/activity-tiers.js +956 -0
  511. package/dist/taxonomy/activity-tiers.js.map +1 -0
  512. package/dist/taxonomy/app-categories.js +42 -0
  513. package/dist/taxonomy/app-categories.js.map +1 -0
  514. package/dist/taxonomy/app-category-map.js +166 -0
  515. package/dist/taxonomy/app-category-map.js.map +1 -0
  516. package/dist/taxonomy/artifact-link-kind.js +29 -0
  517. package/dist/taxonomy/artifact-link-kind.js.map +1 -0
  518. package/dist/taxonomy/calendar-event.js +28 -0
  519. package/dist/taxonomy/calendar-event.js.map +1 -0
  520. package/dist/taxonomy/continents.js +215 -0
  521. package/dist/taxonomy/continents.js.map +1 -0
  522. package/dist/taxonomy/countries.js +203 -0
  523. package/dist/taxonomy/countries.js.map +1 -0
  524. package/dist/taxonomy/course-role.js +37 -0
  525. package/dist/taxonomy/course-role.js.map +1 -0
  526. package/dist/taxonomy/employment-type.js +82 -0
  527. package/dist/taxonomy/employment-type.js.map +1 -0
  528. package/dist/taxonomy/eqf-level.js +59 -0
  529. package/dist/taxonomy/eqf-level.js.map +1 -0
  530. package/dist/taxonomy/index.js +263 -0
  531. package/dist/taxonomy/index.js.map +1 -0
  532. package/dist/taxonomy/industry-taxonomy.js +281 -0
  533. package/dist/taxonomy/industry-taxonomy.js.map +1 -0
  534. package/dist/taxonomy/investment.js +54 -0
  535. package/dist/taxonomy/investment.js.map +1 -0
  536. package/dist/taxonomy/involvement-kind.js +30 -0
  537. package/dist/taxonomy/involvement-kind.js.map +1 -0
  538. package/dist/taxonomy/open-to.js +128 -0
  539. package/dist/taxonomy/open-to.js.map +1 -0
  540. package/dist/taxonomy/platforms.js +56 -0
  541. package/dist/taxonomy/platforms.js.map +1 -0
  542. package/dist/taxonomy/presentation-link-type.js +22 -0
  543. package/dist/taxonomy/presentation-link-type.js.map +1 -0
  544. package/dist/taxonomy/presentation-role.js +21 -0
  545. package/dist/taxonomy/presentation-role.js.map +1 -0
  546. package/dist/taxonomy/publication-type.js +54 -0
  547. package/dist/taxonomy/publication-type.js.map +1 -0
  548. package/dist/taxonomy/relational.js +25 -0
  549. package/dist/taxonomy/relational.js.map +1 -0
  550. package/dist/taxonomy/search-filter-defs.js +66 -0
  551. package/dist/taxonomy/search-filter-defs.js.map +1 -0
  552. package/dist/taxonomy/skill-categories.js +28 -0
  553. package/dist/taxonomy/skill-categories.js.map +1 -0
  554. package/dist/taxonomy/skill-display-groups.js +12 -0
  555. package/dist/taxonomy/skill-display-groups.js.map +1 -0
  556. package/dist/taxonomy/skill-grouping.js +90 -0
  557. package/dist/taxonomy/skill-grouping.js.map +1 -0
  558. package/dist/taxonomy/verification-providers.js +69 -0
  559. package/dist/taxonomy/verification-providers.js.map +1 -0
  560. package/dist/taxonomy/workplace-type.js +38 -0
  561. package/dist/taxonomy/workplace-type.js.map +1 -0
  562. package/dist/tokens/colors.js +11 -0
  563. package/dist/tokens/colors.js.map +1 -0
  564. package/dist/tokens/icons.js +15 -0
  565. package/dist/tokens/icons.js.map +1 -0
  566. package/dist/tokens/index.js +10 -39
  567. package/dist/tokens/index.js.map +1 -1
  568. package/dist/tokens/typography.js +23 -0
  569. package/dist/tokens/typography.js.map +1 -0
  570. package/dist/types/index.js +10 -0
  571. package/dist/types/index.js.map +1 -0
  572. package/dist/types/profile-view.js +1 -0
  573. package/dist/types/profile-view.js.map +1 -0
  574. package/dist/{use-org-notification-emails-0hjt-dEw.d.ts → use-org-notification-emails-CWWi1D8t.d.ts} +2 -2
  575. package/package.json +4 -3
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/format/pds-utils.ts","../../src/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,GAAG,OAAA,CAAQ,UAAA,EAAY,QAAQ,CAAA;AAAA,IAC/B,IAAA,EAAM,EAAE,SAAA,EAAW,OAAA,EAAS,cAAA;AAAe,GAC7C;AACF","file":"index.js","sourcesContent":["import type { PdsProviderInfo } from '../types/index.js';\n\nexport interface PdsProvider {\n name: string;\n profileUrl: string;\n host?: string;\n}\n\nconst BSKY_PROFILE_BASE = 'https://bsky.app/profile/';\n\nconst PDS_PROVIDERS: { suffix: string; name: string }[] = [\n { suffix: '.bsky.social', name: 'bluesky' },\n { suffix: '.blacksky.app', name: 'blacksky' },\n { suffix: '.eurosky.social', name: 'eurosky' },\n { suffix: '.northsky.social', name: 'northsky' },\n];\n\nconst KNOWN_PROVIDER_NAMES = new Set(PDS_PROVIDERS.map((p) => p.name));\n\nconst ICON_ONLY_PROVIDERS = new Set(['selfhosted-social', 'selfhosted']);\n\nexport function pdsProviderFromApi(\n apiProvider: PdsProviderInfo | null | undefined,\n handle: string,\n): PdsProvider | null {\n if (!apiProvider) return null;\n if (ICON_ONLY_PROVIDERS.has(apiProvider.name)) {\n return { name: apiProvider.name, profileUrl: '', host: apiProvider.host };\n }\n if (!KNOWN_PROVIDER_NAMES.has(apiProvider.name)) return null;\n return {\n name: apiProvider.name,\n profileUrl: `${BSKY_PROFILE_BASE}${handle}`,\n host: apiProvider.host,\n };\n}\n\nexport function getHandleStem(handle: string): string {\n const lower = handle.toLowerCase();\n for (const provider of PDS_PROVIDERS) {\n if (lower.endsWith(provider.suffix) && lower.length > provider.suffix.length) {\n return handle.slice(0, -provider.suffix.length);\n }\n }\n return handle;\n}\n\nexport function getDisplayLabel(displayName: string | undefined, handle: string): string {\n if (displayName) return displayName;\n return getHandleStem(handle);\n}\n\n/**\n * Combine optional structured name fields (`id.sifa.profile.self.givenName`,\n * `familyName`) into a single string in Schema.org `Person` order — given\n * before family. Returns `undefined` when both are absent so callers can\n * fall back to `displayName`. Whitespace-only inputs are treated as absent.\n * Does not impose cultural ordering: users whose preferred presentation\n * differs (e.g. Eastern name order) should set `displayName` accordingly,\n * which this helper deliberately does not consult.\n */\nexport function formatStructuredName(\n givenName: string | undefined,\n familyName: string | undefined,\n): string | undefined {\n const given = givenName?.trim();\n const family = familyName?.trim();\n if (given && family) return `${given} ${family}`;\n return given || family || undefined;\n}\n\nconst PDS_DISPLAY_NAMES: Record<string, string> = {\n bluesky: 'Bluesky',\n blacksky: 'BlackSky',\n eurosky: 'EuroSky',\n northsky: 'NorthSky',\n 'selfhosted-social': 'Self-hosted',\n selfhosted: 'Self-hosted',\n};\n\nexport function getPdsDisplayName(providerName: string): string {\n return PDS_DISPLAY_NAMES[providerName] ?? providerName;\n}\n\nexport function detectPdsProvider(handle: string): PdsProvider | null {\n const lower = handle.toLowerCase();\n for (const provider of PDS_PROVIDERS) {\n if (lower.endsWith(provider.suffix)) {\n return {\n name: provider.name,\n profileUrl: `${BSKY_PROFILE_BASE}${handle}`,\n };\n }\n }\n return null;\n}\n","/**\n * Shared, single-source-of-truth model for which profile sections render, in\n * what order, their nav grouping, and which items a given viewer may see.\n *\n * Every Sifa profile surface builds on this: the HTML profile page, the\n * Markdown / DOCX / print exports, and the standalone personal-site renderer.\n * Adding a section to {@link ALL_SECTIONS} makes it appear everywhere (the\n * exports drive presence + order from here, and {@link SECTION_LABELS} is an\n * exhaustive `Record<SectionId, string>`, so a new id is a compile error until\n * it has a label).\n *\n * The per-section sorts live in `./section-sorts.js`, built on the same SDK\n * date extractors the HTML section components use, so the surfaces cannot\n * diverge on ordering.\n */\n\nimport type { Profile } from '../types/index.js';\n\n/**\n * Side-nav groups, in display order. Each labels a contiguous run of sections\n * in {@link ALL_SECTIONS}. `labelKey` resolves against the consumer's `sections`\n * i18n namespace.\n */\nexport const SECTION_GROUPS = [\n { id: 'overview', labelKey: 'groupOverview' },\n { id: 'experience', labelKey: 'groupExperience' },\n { id: 'qualifications', labelKey: 'groupQualifications' },\n { id: 'more', labelKey: 'groupMore' },\n] as const;\n\nexport type SectionGroupId = (typeof SECTION_GROUPS)[number]['id'];\n\n/**\n * Profile body sections in render + nav order (evidence-first): identity and\n * activity lead, then living work (career, projects, talks, publications, then\n * skills), then the formal record (credentials, education, courses), then the\n * rest. `ns` selects the consumer's i18n namespace for `labelKey`; `group`\n * ties the section to a {@link SECTION_GROUPS} header.\n */\nexport const ALL_SECTIONS = [\n { id: 'about', labelKey: 'about', ns: 'profile' as const, group: 'overview' as const },\n { id: 'career', labelKey: 'career', ns: 'sections' as const, group: 'experience' as const },\n { id: 'projects', labelKey: 'projects', ns: 'sections' as const, group: 'experience' as const },\n {\n id: 'presentations',\n labelKey: 'talksAndSessions',\n ns: 'sections' as const,\n group: 'experience' as const,\n },\n {\n id: 'publications',\n labelKey: 'publications',\n ns: 'sections' as const,\n group: 'experience' as const,\n },\n { id: 'skills', labelKey: 'skills', ns: 'sections' as const, group: 'experience' as const },\n {\n id: 'credentials',\n labelKey: 'credentials',\n ns: 'sections' as const,\n group: 'qualifications' as const,\n },\n {\n id: 'education',\n labelKey: 'education',\n ns: 'sections' as const,\n group: 'qualifications' as const,\n },\n { id: 'courses', labelKey: 'courses', ns: 'sections' as const, group: 'qualifications' as const },\n { id: 'awards', labelKey: 'awards', ns: 'sections' as const, group: 'more' as const },\n { id: 'involvement', labelKey: 'involvement', ns: 'sections' as const, group: 'more' as const },\n // Its own section rather than a group under involvement: that record is about\n // work contributed, this one about capital deployed.\n { id: 'investments', labelKey: 'investments', ns: 'sections' as const, group: 'more' as const },\n { id: 'languages', labelKey: 'languages', ns: 'sections' as const, group: 'more' as const },\n {\n id: 'other-profiles',\n labelKey: 'otherProfiles',\n ns: 'sections' as const,\n group: 'more' as const,\n },\n] as const;\n\n/** Every profile section id, in canonical render order. */\nexport type SectionId = (typeof ALL_SECTIONS)[number]['id'];\n\n/**\n * Whether a section has content a visitor can see (used to hide empty nav\n * entries and sections for visitors). Items the owner hid do not count: a\n * section whose only entries are hidden renders nothing for a visitor, so it\n * must not get a nav entry either.\n */\nexport function isSectionPopulated(profile: Profile, id: string): boolean {\n const hasVisible = <T extends { hidden?: boolean }>(items: T[] | undefined): boolean =>\n filterHidden(items).length > 0;\n switch (id) {\n case 'about':\n // Text fields, not hideable items. Without a headline the summary shows\n // in the identity card instead, so the About section stays out of it.\n return Boolean(profile.about && profile.headline);\n case 'career':\n return hasVisible(profile.positions);\n case 'education':\n return hasVisible(profile.education);\n case 'courses':\n return hasVisible(profile.courses);\n case 'skills':\n // Skills have no owner-hide flag (`ProfileSkill` carries no `hidden`).\n return Boolean(profile.skills?.length);\n case 'projects':\n return hasVisible(profile.projects);\n case 'credentials':\n return hasVisible(profile.certifications);\n case 'publications':\n return hasVisible(profile.publications);\n case 'presentations':\n return hasVisible(profile.presentations) || hasVisible(profile.presentationDeliveries);\n case 'involvement':\n return hasVisible(profile.involvement);\n case 'investments':\n return hasVisible(profile.investments);\n case 'awards':\n return hasVisible(profile.honors);\n case 'languages':\n return hasVisible(profile.languages);\n case 'other-profiles':\n return hasVisible(profile.externalAccounts);\n default:\n return false;\n }\n}\n\n/**\n * The section ids a given viewer should see, in {@link ALL_SECTIONS} order.\n * Owners see every section; visitors only see populated ones.\n */\nexport function getVisibleSectionIds(profile: Profile, isOwnProfile: boolean): SectionId[] {\n return ALL_SECTIONS.map((s) => s.id).filter(\n (id) => isOwnProfile || isSectionPopulated(profile, id),\n );\n}\n\n/** Drop items the owner has hidden from visitors. */\nexport function filterHidden<T extends { hidden?: boolean }>(items: T[] | undefined): T[] {\n return (items ?? []).filter((i) => !i.hidden);\n}\n\n/**\n * Items visible to a given viewer: owners see their own hidden items, visitors\n * do not. Shared by every export format (markdown, docx, print) and the public\n * `.md` route so the hidden rule lives in one place.\n */\nexport function visibleItems<T extends { hidden?: boolean }>(\n items: T[] | undefined,\n isOwnProfile: boolean,\n): T[] {\n return isOwnProfile ? (items ?? []) : filterHidden(items);\n}\n\n/**\n * English heading text for each section, keyed by {@link SectionId} (e.g.\n * `other-profiles` renders as \"Links\"). Exhaustive `Record<SectionId, string>`:\n * adding a section to {@link ALL_SECTIONS} without a label here is a compile\n * error, so a section can never silently render without (or with a stale)\n * heading. Consumers with i18n resolve their own localized labels via\n * `labelKey`; this is the canonical English fallback used by the exports.\n */\nexport const SECTION_LABELS: Record<SectionId, string> = {\n about: 'About',\n career: 'Career',\n skills: 'Skills',\n projects: 'Projects',\n presentations: 'Talks & sessions',\n publications: 'Publications',\n credentials: 'Credentials',\n education: 'Education',\n courses: 'Courses',\n awards: 'Awards',\n involvement: 'Involvement',\n investments: 'Investments',\n languages: 'Languages',\n 'other-profiles': 'Links',\n};\n","/** Shared URL helpers for the JSON-LD emitters. */\n\nexport const DEFAULT_BASE_URL = 'https://sifa.id';\n\n/**\n * Drop trailing slashes from a caller-supplied base URL.\n *\n * Written as a scan rather than `replace(/\\/+$/, '')` on purpose: the regex\n * form is a polynomial-backtracking hazard on input the library does not\n * control (CodeQL js/polynomial-redos). This runs in linear time.\n */\nexport function normaliseBaseUrl(baseUrl: string | undefined): string {\n const value = baseUrl ?? DEFAULT_BASE_URL;\n let end = value.length;\n while (end > 0 && value.charCodeAt(end - 1) === 0x2f) end -= 1;\n return value.slice(0, end);\n}\n\nexport function profileUrl(baseUrl: string, handle: string): string {\n return `${baseUrl}/p/${handle}`;\n}\n","/**\n * JSON Resume v1.0.0 emitter for a Sifa profile.\n *\n * https://jsonresume.org/schema/\n *\n * One pure function, no fetching, no DOM, no framework -- the same shape as the\n * JSON-LD emitter next door, and for the same reason: sifa.id, page.sifa.id and\n * any future consumer should emit one document from one implementation.\n *\n * Why this format earns its place: it is the lingua franca of CV tooling, so\n * emitting it hands a user every JSON Resume theme, and the Typst CV templates\n * on Typst Universe, without Sifa writing a renderer for any of them.\n *\n * Fields Sifa holds that JSON Resume has no slot for -- endorsements,\n * confirmations, involvement, investments, presentations, courses -- are\n * dropped rather than smuggled into a nearby field. The loss is documented for\n * the user at the point of download.\n */\n\nimport { formatStructuredName } from '../format/pds-utils.js';\nimport { filterHidden } from '../profile/section-model.js';\nimport type {\n ExternalAccount,\n LanguageProficiency,\n LocationValue,\n ProfileCertification,\n ProfileEducation,\n ProfileHonor,\n ProfileLanguage,\n ProfilePosition,\n ProfileProject,\n ProfilePublication,\n ProfileSkill,\n ProfileVolunteering,\n} from '../types/index.js';\nimport { normaliseBaseUrl, profileUrl } from '../jsonld/url.js';\n\nexport type Sanitizer = (input: string) => string;\n\nexport interface JsonResumeOptions {\n /** Canonical origin for the profile URL. Defaults to `https://sifa.id`. */\n readonly baseUrl?: string;\n /** Applied to every user-authored string. Defaults to identity. */\n readonly sanitize?: Sanitizer;\n /**\n * Absolute URL of the profile this resume describes. Defaults to\n * `${baseUrl}/p/${handle}`. A personal site served from a custom domain is\n * not at that path.\n */\n readonly canonicalUrl?: string;\n}\n\n/**\n * The subset of `Profile` this emitter reads. Deliberately structural rather\n * than the full `Profile`, so a caller holding a partially hydrated profile --\n * or a test -- does not have to invent forty unrelated fields.\n */\nexport interface JsonResumeProfileInput {\n readonly handle: string;\n readonly displayName?: string;\n readonly givenName?: string;\n readonly familyName?: string;\n readonly avatar?: string;\n readonly headline?: string;\n readonly about?: string;\n readonly website?: string;\n readonly location?: LocationValue | null;\n readonly positions?: ProfilePosition[];\n readonly education?: ProfileEducation[];\n readonly skills?: ProfileSkill[];\n readonly certifications?: ProfileCertification[];\n readonly projects?: ProfileProject[];\n readonly publications?: ProfilePublication[];\n readonly volunteering?: ProfileVolunteering[];\n readonly honors?: ProfileHonor[];\n readonly languages?: ProfileLanguage[];\n readonly externalAccounts?: ExternalAccount[];\n}\n\nexport interface JsonResumeLocation {\n readonly city?: string;\n readonly region?: string;\n readonly countryCode?: string;\n readonly postalCode?: string;\n}\n\nexport interface JsonResumeProfileLink {\n readonly network: string;\n readonly username?: string;\n readonly url?: string;\n}\n\nexport interface JsonResumeBasics {\n readonly name: string;\n readonly label?: string;\n readonly image?: string;\n readonly url?: string;\n readonly summary?: string;\n readonly location?: JsonResumeLocation;\n readonly profiles?: JsonResumeProfileLink[];\n}\n\nexport interface JsonResumeWork {\n readonly name?: string;\n readonly position: string;\n readonly summary?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeVolunteer {\n /**\n * Omitted when the record carries no organization name at all. Emitting an\n * empty string would render as a blank organization line in a CV template.\n */\n readonly organization?: string;\n readonly position?: string;\n readonly summary?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeEducation {\n /** Omitted when the record carries no institution name. See volunteer. */\n readonly institution?: string;\n readonly area?: string;\n readonly studyType?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeAward {\n readonly title: string;\n readonly date?: string;\n readonly awarder?: string;\n readonly summary?: string;\n}\n\nexport interface JsonResumeCertificate {\n readonly name: string;\n readonly date?: string;\n readonly issuer?: string;\n readonly url?: string;\n}\n\nexport interface JsonResumePublication {\n readonly name: string;\n readonly publisher?: string;\n readonly releaseDate?: string;\n readonly url?: string;\n readonly summary?: string;\n}\n\nexport interface JsonResumeSkill {\n readonly name: string;\n}\n\nexport interface JsonResumeLanguage {\n readonly language: string;\n readonly fluency?: string;\n}\n\nexport interface JsonResumeProject {\n readonly name: string;\n readonly description?: string;\n readonly url?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeMeta {\n readonly canonical: string;\n readonly version: string;\n readonly lastModified?: string;\n}\n\nexport interface JsonResume {\n readonly basics?: JsonResumeBasics;\n readonly work?: JsonResumeWork[];\n readonly volunteer?: JsonResumeVolunteer[];\n readonly education?: JsonResumeEducation[];\n readonly awards?: JsonResumeAward[];\n readonly certificates?: JsonResumeCertificate[];\n readonly publications?: JsonResumePublication[];\n readonly skills?: JsonResumeSkill[];\n readonly languages?: JsonResumeLanguage[];\n readonly projects?: JsonResumeProject[];\n readonly meta?: JsonResumeMeta;\n}\n\n/** Schema version this emitter targets, as JSON Resume writes it in `meta`. */\nconst SCHEMA_VERSION = 'v1.0.0';\n\n/**\n * A date JSON Resume will accept: `YYYY`, `YYYY-MM` or `YYYY-MM-DD`. Sifa\n * stores RFC 3339 for some fields, and a full timestamp pasted into a CV\n * template renders as `2020-03-04T00:00:00.000Z` on the page.\n */\nconst RESUME_DATE_RE = /^(\\d{4})(-\\d{2})?(-\\d{2})?/;\n\nexport function toResumeDate(value: string | undefined): string | undefined {\n const trimmed = value?.trim();\n if (!trimmed) return undefined;\n const match = RESUME_DATE_RE.exec(trimmed);\n return match ? match[0] : undefined;\n}\n\n/**\n * JSON Resume's `fluency` is free text, so these are display labels rather\n * than a mapped vocabulary. Kept in one place so export and a future import\n * agree on the spelling.\n */\nconst FLUENCY_LABELS: Record<LanguageProficiency, string> = {\n elementary: 'Elementary',\n limited_working: 'Limited working',\n professional_working: 'Professional working',\n full_professional: 'Full professional',\n native: 'Native or bilingual',\n};\n\nconst identity: Sanitizer = (input) => input;\n\n/** Drops keys whose value is undefined, so the document carries no empty slots. */\nfunction compact<T extends object>(value: T): T {\n return Object.fromEntries(Object.entries(value).filter(([, v]) => v !== undefined)) as T;\n}\n\n/** Omits the key entirely when the mapped list came out empty. */\nfunction section<K extends string, T>(key: K, items: T[]): Record<K, T[]> | undefined {\n return items.length > 0 ? ({ [key]: items } as Record<K, T[]>) : undefined;\n}\n\nfunction mapLocation(\n location: LocationValue | null | undefined,\n s: Sanitizer,\n): JsonResumeLocation | undefined {\n if (!location) return undefined;\n const mapped = compact({\n city: text(location.locality ?? location.city, s),\n region: text(location.region, s),\n countryCode: text(location.countryCode, s),\n postalCode: text(location.postalCode, s),\n });\n return Object.keys(mapped).length > 0 ? mapped : undefined;\n}\n\n/** Trimmed, sanitised, and undefined when there is nothing left. */\nfunction text(value: string | undefined, s: Sanitizer): string | undefined {\n const trimmed = value?.trim();\n return trimmed ? s(trimmed) : undefined;\n}\n\n/**\n * The name to print for a linked organization. `entityName` is the AppView's\n * resolved current name and wins when present, matching how the profile itself\n * renders these.\n */\nfunction orgName(\n entityName: string | undefined,\n stored: string | undefined,\n s: Sanitizer,\n): string | undefined {\n return text(entityName, s) ?? text(stored, s);\n}\n\n/**\n * Build a JSON Resume v1.0.0 document from a Sifa profile.\n *\n * Hidden records are dropped. Keys are omitted rather than emitted empty, so a\n * profile with no publications produces a document with no `publications` key\n * instead of one a reader has to interpret.\n */\nexport function profileToJsonResume(\n profile: JsonResumeProfileInput,\n options: JsonResumeOptions = {},\n): JsonResume {\n const s = options.sanitize ?? identity;\n const baseUrl = normaliseBaseUrl(options.baseUrl);\n const canonical = options.canonicalUrl ?? profileUrl(baseUrl, profile.handle);\n\n const name =\n formatStructuredName(profile.givenName, profile.familyName) ??\n text(profile.displayName, s) ??\n profile.handle;\n\n const profiles = filterHidden(profile.externalAccounts).map((account) =>\n compact<JsonResumeProfileLink>({\n network: s(account.platform),\n username: text(account.label, s),\n url: text(account.url, s),\n }),\n );\n\n const basics = compact<JsonResumeBasics>({\n name,\n label: text(profile.headline, s),\n image: text(profile.avatar, s),\n url: text(profile.website, s) ?? canonical,\n summary: text(profile.about, s),\n location: mapLocation(profile.location, s),\n ...section('profiles', profiles),\n });\n\n const work = filterHidden(profile.positions).map((position) =>\n compact<JsonResumeWork>({\n name: orgName(position.entityName, position.company, s),\n position: s(position.title),\n summary: text(position.description, s),\n startDate: toResumeDate(position.startedAt),\n endDate: toResumeDate(position.endedAt),\n }),\n );\n\n const volunteer = filterHidden(profile.volunteering).map((entry) =>\n compact<JsonResumeVolunteer>({\n organization: orgName(entry.entityName, entry.organization, s),\n position: text(entry.role, s),\n summary: text(entry.description, s),\n startDate: toResumeDate(entry.startDate),\n endDate: toResumeDate(entry.endDate),\n }),\n );\n\n const education = filterHidden(profile.education).map((entry) =>\n compact<JsonResumeEducation>({\n institution: orgName(entry.entityName, entry.institution, s),\n area: text(entry.fieldOfStudy, s),\n studyType: text(entry.degree, s),\n startDate: toResumeDate(entry.startedAt),\n endDate: toResumeDate(entry.endedAt),\n }),\n );\n\n const awards = filterHidden(profile.honors).map((honor) =>\n compact<JsonResumeAward>({\n title: s(honor.title),\n date: toResumeDate(honor.date),\n awarder: orgName(honor.entityName, honor.issuer, s),\n summary: text(honor.description, s),\n }),\n );\n\n const certificates = filterHidden(profile.certifications).map((cert) =>\n compact<JsonResumeCertificate>({\n name: s(cert.name),\n date: toResumeDate(cert.issueDate),\n // `issuingOrg` is the deprecated read-view alias for `authority`; records\n // indexed before the rename carry only the alias.\n issuer: orgName(cert.entityName, cert.authority ?? cert.issuingOrg, s),\n url: text(cert.credentialUrl, s),\n }),\n );\n\n const publications = filterHidden(profile.publications).map((publication) =>\n compact<JsonResumePublication>({\n name: s(publication.title),\n publisher: text(publication.publisher, s),\n releaseDate: toResumeDate(publication.date),\n url: text(publication.url, s),\n summary: text(publication.description, s),\n }),\n );\n\n // One entry per skill rather than JSON Resume's grouped shape: Sifa stores one\n // record per skill, and keeping the two symmetric is what makes a round-trip\n // through a third-party editor safe. Category and endorsement counts have no\n // JSON Resume slot and are dropped. Skill records carry no `hidden` flag, so\n // there is nothing to filter here.\n const skills = (profile.skills ?? []).map((skill) => ({ name: s(skill.name) }));\n\n const languages = filterHidden(profile.languages).map((language) =>\n compact<JsonResumeLanguage>({\n language: s(language.language),\n fluency: language.proficiency ? FLUENCY_LABELS[language.proficiency] : undefined,\n }),\n );\n\n const projects = filterHidden(profile.projects).map((project) =>\n compact<JsonResumeProject>({\n name: s(project.name),\n description: text(project.description, s),\n url: text(project.url, s),\n startDate: toResumeDate(project.startDate),\n endDate: toResumeDate(project.endDate),\n }),\n );\n\n return {\n basics,\n ...section('work', work),\n ...section('volunteer', volunteer),\n ...section('education', education),\n ...section('awards', awards),\n ...section('certificates', certificates),\n ...section('publications', publications),\n ...section('skills', skills),\n ...section('languages', languages),\n ...section('projects', projects),\n meta: { canonical, version: SCHEMA_VERSION },\n };\n}\n"]}
1
+ {"version":3,"sources":["../../src/resume/index.ts"],"sourcesContent":["export { profileToJsonResume, toResumeDate } from './json-resume.js';\nexport type {\n JsonResume,\n JsonResumeAward,\n JsonResumeBasics,\n JsonResumeCertificate,\n JsonResumeEducation,\n JsonResumeLanguage,\n JsonResumeLocation,\n JsonResumeMeta,\n JsonResumeOptions,\n JsonResumeProfileInput,\n JsonResumeProfileLink,\n JsonResumeProject,\n JsonResumePublication,\n JsonResumeSkill,\n JsonResumeVolunteer,\n JsonResumeWork,\n Sanitizer,\n} from './json-resume.js';\n"],"mappings":";AAAA,SAAS,qBAAqB,oBAAoB;","names":[]}
@@ -0,0 +1,153 @@
1
+ // src/resume/json-resume.ts
2
+ import { formatStructuredName } from "../format/pds-utils.js";
3
+ import { filterHidden } from "../profile/section-model.js";
4
+ import { normaliseBaseUrl, profileUrl } from "../jsonld/url.js";
5
+ var SCHEMA_VERSION = "v1.0.0";
6
+ var RESUME_DATE_RE = /^(\d{4})(-\d{2})?(-\d{2})?/;
7
+ function toResumeDate(value) {
8
+ const trimmed = value?.trim();
9
+ if (!trimmed) return void 0;
10
+ const match = RESUME_DATE_RE.exec(trimmed);
11
+ return match ? match[0] : void 0;
12
+ }
13
+ var FLUENCY_LABELS = {
14
+ elementary: "Elementary",
15
+ limited_working: "Limited working",
16
+ professional_working: "Professional working",
17
+ full_professional: "Full professional",
18
+ native: "Native or bilingual"
19
+ };
20
+ var identity = (input) => input;
21
+ function compact(value) {
22
+ return Object.fromEntries(Object.entries(value).filter(([, v]) => v !== void 0));
23
+ }
24
+ function section(key, items) {
25
+ return items.length > 0 ? { [key]: items } : void 0;
26
+ }
27
+ function mapLocation(location, s) {
28
+ if (!location) return void 0;
29
+ const mapped = compact({
30
+ city: text(location.locality ?? location.city, s),
31
+ region: text(location.region, s),
32
+ countryCode: text(location.countryCode, s),
33
+ postalCode: text(location.postalCode, s)
34
+ });
35
+ return Object.keys(mapped).length > 0 ? mapped : void 0;
36
+ }
37
+ function text(value, s) {
38
+ const trimmed = value?.trim();
39
+ return trimmed ? s(trimmed) : void 0;
40
+ }
41
+ function orgName(entityName, stored, s) {
42
+ return text(entityName, s) ?? text(stored, s);
43
+ }
44
+ function profileToJsonResume(profile, options = {}) {
45
+ const s = options.sanitize ?? identity;
46
+ const baseUrl = normaliseBaseUrl(options.baseUrl);
47
+ const canonical = options.canonicalUrl ?? profileUrl(baseUrl, profile.handle);
48
+ const name = formatStructuredName(profile.givenName, profile.familyName) ?? text(profile.displayName, s) ?? profile.handle;
49
+ const profiles = filterHidden(profile.externalAccounts).map(
50
+ (account) => compact({
51
+ network: s(account.platform),
52
+ username: text(account.label, s),
53
+ url: text(account.url, s)
54
+ })
55
+ );
56
+ const basics = compact({
57
+ name,
58
+ label: text(profile.headline, s),
59
+ image: text(profile.avatar, s),
60
+ url: text(profile.website, s) ?? canonical,
61
+ summary: text(profile.about, s),
62
+ location: mapLocation(profile.location, s),
63
+ ...section("profiles", profiles)
64
+ });
65
+ const work = filterHidden(profile.positions).map(
66
+ (position) => compact({
67
+ name: orgName(position.entityName, position.company, s),
68
+ position: s(position.title),
69
+ summary: text(position.description, s),
70
+ startDate: toResumeDate(position.startedAt),
71
+ endDate: toResumeDate(position.endedAt)
72
+ })
73
+ );
74
+ const volunteer = filterHidden(profile.volunteering).map(
75
+ (entry) => compact({
76
+ organization: orgName(entry.entityName, entry.organization, s),
77
+ position: text(entry.role, s),
78
+ summary: text(entry.description, s),
79
+ startDate: toResumeDate(entry.startDate),
80
+ endDate: toResumeDate(entry.endDate)
81
+ })
82
+ );
83
+ const education = filterHidden(profile.education).map(
84
+ (entry) => compact({
85
+ institution: orgName(entry.entityName, entry.institution, s),
86
+ area: text(entry.fieldOfStudy, s),
87
+ studyType: text(entry.degree, s),
88
+ startDate: toResumeDate(entry.startedAt),
89
+ endDate: toResumeDate(entry.endedAt)
90
+ })
91
+ );
92
+ const awards = filterHidden(profile.honors).map(
93
+ (honor) => compact({
94
+ title: s(honor.title),
95
+ date: toResumeDate(honor.date),
96
+ awarder: orgName(honor.entityName, honor.issuer, s),
97
+ summary: text(honor.description, s)
98
+ })
99
+ );
100
+ const certificates = filterHidden(profile.certifications).map(
101
+ (cert) => compact({
102
+ name: s(cert.name),
103
+ date: toResumeDate(cert.issueDate),
104
+ // `issuingOrg` is the deprecated read-view alias for `authority`; records
105
+ // indexed before the rename carry only the alias.
106
+ issuer: orgName(cert.entityName, cert.authority ?? cert.issuingOrg, s),
107
+ url: text(cert.credentialUrl, s)
108
+ })
109
+ );
110
+ const publications = filterHidden(profile.publications).map(
111
+ (publication) => compact({
112
+ name: s(publication.title),
113
+ publisher: text(publication.publisher, s),
114
+ releaseDate: toResumeDate(publication.date),
115
+ url: text(publication.url, s),
116
+ summary: text(publication.description, s)
117
+ })
118
+ );
119
+ const skills = (profile.skills ?? []).map((skill) => ({ name: s(skill.name) }));
120
+ const languages = filterHidden(profile.languages).map(
121
+ (language) => compact({
122
+ language: s(language.language),
123
+ fluency: language.proficiency ? FLUENCY_LABELS[language.proficiency] : void 0
124
+ })
125
+ );
126
+ const projects = filterHidden(profile.projects).map(
127
+ (project) => compact({
128
+ name: s(project.name),
129
+ description: text(project.description, s),
130
+ url: text(project.url, s),
131
+ startDate: toResumeDate(project.startDate),
132
+ endDate: toResumeDate(project.endDate)
133
+ })
134
+ );
135
+ return {
136
+ basics,
137
+ ...section("work", work),
138
+ ...section("volunteer", volunteer),
139
+ ...section("education", education),
140
+ ...section("awards", awards),
141
+ ...section("certificates", certificates),
142
+ ...section("publications", publications),
143
+ ...section("skills", skills),
144
+ ...section("languages", languages),
145
+ ...section("projects", projects),
146
+ meta: { canonical, version: SCHEMA_VERSION }
147
+ };
148
+ }
149
+ export {
150
+ profileToJsonResume,
151
+ toResumeDate
152
+ };
153
+ //# sourceMappingURL=json-resume.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/resume/json-resume.ts"],"sourcesContent":["/**\n * JSON Resume v1.0.0 emitter for a Sifa profile.\n *\n * https://jsonresume.org/schema/\n *\n * One pure function, no fetching, no DOM, no framework -- the same shape as the\n * JSON-LD emitter next door, and for the same reason: sifa.id, page.sifa.id and\n * any future consumer should emit one document from one implementation.\n *\n * Why this format earns its place: it is the lingua franca of CV tooling, so\n * emitting it hands a user every JSON Resume theme, and the Typst CV templates\n * on Typst Universe, without Sifa writing a renderer for any of them.\n *\n * Fields Sifa holds that JSON Resume has no slot for -- endorsements,\n * confirmations, involvement, investments, presentations, courses -- are\n * dropped rather than smuggled into a nearby field. The loss is documented for\n * the user at the point of download.\n */\n\nimport { formatStructuredName } from '../format/pds-utils.js';\nimport { filterHidden } from '../profile/section-model.js';\nimport type {\n ExternalAccount,\n LanguageProficiency,\n LocationValue,\n ProfileCertification,\n ProfileEducation,\n ProfileHonor,\n ProfileLanguage,\n ProfilePosition,\n ProfileProject,\n ProfilePublication,\n ProfileSkill,\n ProfileVolunteering,\n} from '../types/index.js';\nimport { normaliseBaseUrl, profileUrl } from '../jsonld/url.js';\n\nexport type Sanitizer = (input: string) => string;\n\nexport interface JsonResumeOptions {\n /** Canonical origin for the profile URL. Defaults to `https://sifa.id`. */\n readonly baseUrl?: string;\n /** Applied to every user-authored string. Defaults to identity. */\n readonly sanitize?: Sanitizer;\n /**\n * Absolute URL of the profile this resume describes. Defaults to\n * `${baseUrl}/p/${handle}`. A personal site served from a custom domain is\n * not at that path.\n */\n readonly canonicalUrl?: string;\n}\n\n/**\n * The subset of `Profile` this emitter reads. Deliberately structural rather\n * than the full `Profile`, so a caller holding a partially hydrated profile --\n * or a test -- does not have to invent forty unrelated fields.\n */\nexport interface JsonResumeProfileInput {\n readonly handle: string;\n readonly displayName?: string;\n readonly givenName?: string;\n readonly familyName?: string;\n readonly avatar?: string;\n readonly headline?: string;\n readonly about?: string;\n readonly website?: string;\n readonly location?: LocationValue | null;\n readonly positions?: ProfilePosition[];\n readonly education?: ProfileEducation[];\n readonly skills?: ProfileSkill[];\n readonly certifications?: ProfileCertification[];\n readonly projects?: ProfileProject[];\n readonly publications?: ProfilePublication[];\n readonly volunteering?: ProfileVolunteering[];\n readonly honors?: ProfileHonor[];\n readonly languages?: ProfileLanguage[];\n readonly externalAccounts?: ExternalAccount[];\n}\n\nexport interface JsonResumeLocation {\n readonly city?: string;\n readonly region?: string;\n readonly countryCode?: string;\n readonly postalCode?: string;\n}\n\nexport interface JsonResumeProfileLink {\n readonly network: string;\n readonly username?: string;\n readonly url?: string;\n}\n\nexport interface JsonResumeBasics {\n readonly name: string;\n readonly label?: string;\n readonly image?: string;\n readonly url?: string;\n readonly summary?: string;\n readonly location?: JsonResumeLocation;\n readonly profiles?: JsonResumeProfileLink[];\n}\n\nexport interface JsonResumeWork {\n readonly name?: string;\n readonly position: string;\n readonly summary?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeVolunteer {\n /**\n * Omitted when the record carries no organization name at all. Emitting an\n * empty string would render as a blank organization line in a CV template.\n */\n readonly organization?: string;\n readonly position?: string;\n readonly summary?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeEducation {\n /** Omitted when the record carries no institution name. See volunteer. */\n readonly institution?: string;\n readonly area?: string;\n readonly studyType?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeAward {\n readonly title: string;\n readonly date?: string;\n readonly awarder?: string;\n readonly summary?: string;\n}\n\nexport interface JsonResumeCertificate {\n readonly name: string;\n readonly date?: string;\n readonly issuer?: string;\n readonly url?: string;\n}\n\nexport interface JsonResumePublication {\n readonly name: string;\n readonly publisher?: string;\n readonly releaseDate?: string;\n readonly url?: string;\n readonly summary?: string;\n}\n\nexport interface JsonResumeSkill {\n readonly name: string;\n}\n\nexport interface JsonResumeLanguage {\n readonly language: string;\n readonly fluency?: string;\n}\n\nexport interface JsonResumeProject {\n readonly name: string;\n readonly description?: string;\n readonly url?: string;\n readonly startDate?: string;\n readonly endDate?: string;\n}\n\nexport interface JsonResumeMeta {\n readonly canonical: string;\n readonly version: string;\n readonly lastModified?: string;\n}\n\nexport interface JsonResume {\n readonly basics?: JsonResumeBasics;\n readonly work?: JsonResumeWork[];\n readonly volunteer?: JsonResumeVolunteer[];\n readonly education?: JsonResumeEducation[];\n readonly awards?: JsonResumeAward[];\n readonly certificates?: JsonResumeCertificate[];\n readonly publications?: JsonResumePublication[];\n readonly skills?: JsonResumeSkill[];\n readonly languages?: JsonResumeLanguage[];\n readonly projects?: JsonResumeProject[];\n readonly meta?: JsonResumeMeta;\n}\n\n/** Schema version this emitter targets, as JSON Resume writes it in `meta`. */\nconst SCHEMA_VERSION = 'v1.0.0';\n\n/**\n * A date JSON Resume will accept: `YYYY`, `YYYY-MM` or `YYYY-MM-DD`. Sifa\n * stores RFC 3339 for some fields, and a full timestamp pasted into a CV\n * template renders as `2020-03-04T00:00:00.000Z` on the page.\n */\nconst RESUME_DATE_RE = /^(\\d{4})(-\\d{2})?(-\\d{2})?/;\n\nexport function toResumeDate(value: string | undefined): string | undefined {\n const trimmed = value?.trim();\n if (!trimmed) return undefined;\n const match = RESUME_DATE_RE.exec(trimmed);\n return match ? match[0] : undefined;\n}\n\n/**\n * JSON Resume's `fluency` is free text, so these are display labels rather\n * than a mapped vocabulary. Kept in one place so export and a future import\n * agree on the spelling.\n */\nconst FLUENCY_LABELS: Record<LanguageProficiency, string> = {\n elementary: 'Elementary',\n limited_working: 'Limited working',\n professional_working: 'Professional working',\n full_professional: 'Full professional',\n native: 'Native or bilingual',\n};\n\nconst identity: Sanitizer = (input) => input;\n\n/** Drops keys whose value is undefined, so the document carries no empty slots. */\nfunction compact<T extends object>(value: T): T {\n return Object.fromEntries(Object.entries(value).filter(([, v]) => v !== undefined)) as T;\n}\n\n/** Omits the key entirely when the mapped list came out empty. */\nfunction section<K extends string, T>(key: K, items: T[]): Record<K, T[]> | undefined {\n return items.length > 0 ? ({ [key]: items } as Record<K, T[]>) : undefined;\n}\n\nfunction mapLocation(\n location: LocationValue | null | undefined,\n s: Sanitizer,\n): JsonResumeLocation | undefined {\n if (!location) return undefined;\n const mapped = compact({\n city: text(location.locality ?? location.city, s),\n region: text(location.region, s),\n countryCode: text(location.countryCode, s),\n postalCode: text(location.postalCode, s),\n });\n return Object.keys(mapped).length > 0 ? mapped : undefined;\n}\n\n/** Trimmed, sanitised, and undefined when there is nothing left. */\nfunction text(value: string | undefined, s: Sanitizer): string | undefined {\n const trimmed = value?.trim();\n return trimmed ? s(trimmed) : undefined;\n}\n\n/**\n * The name to print for a linked organization. `entityName` is the AppView's\n * resolved current name and wins when present, matching how the profile itself\n * renders these.\n */\nfunction orgName(\n entityName: string | undefined,\n stored: string | undefined,\n s: Sanitizer,\n): string | undefined {\n return text(entityName, s) ?? text(stored, s);\n}\n\n/**\n * Build a JSON Resume v1.0.0 document from a Sifa profile.\n *\n * Hidden records are dropped. Keys are omitted rather than emitted empty, so a\n * profile with no publications produces a document with no `publications` key\n * instead of one a reader has to interpret.\n */\nexport function profileToJsonResume(\n profile: JsonResumeProfileInput,\n options: JsonResumeOptions = {},\n): JsonResume {\n const s = options.sanitize ?? identity;\n const baseUrl = normaliseBaseUrl(options.baseUrl);\n const canonical = options.canonicalUrl ?? profileUrl(baseUrl, profile.handle);\n\n const name =\n formatStructuredName(profile.givenName, profile.familyName) ??\n text(profile.displayName, s) ??\n profile.handle;\n\n const profiles = filterHidden(profile.externalAccounts).map((account) =>\n compact<JsonResumeProfileLink>({\n network: s(account.platform),\n username: text(account.label, s),\n url: text(account.url, s),\n }),\n );\n\n const basics = compact<JsonResumeBasics>({\n name,\n label: text(profile.headline, s),\n image: text(profile.avatar, s),\n url: text(profile.website, s) ?? canonical,\n summary: text(profile.about, s),\n location: mapLocation(profile.location, s),\n ...section('profiles', profiles),\n });\n\n const work = filterHidden(profile.positions).map((position) =>\n compact<JsonResumeWork>({\n name: orgName(position.entityName, position.company, s),\n position: s(position.title),\n summary: text(position.description, s),\n startDate: toResumeDate(position.startedAt),\n endDate: toResumeDate(position.endedAt),\n }),\n );\n\n const volunteer = filterHidden(profile.volunteering).map((entry) =>\n compact<JsonResumeVolunteer>({\n organization: orgName(entry.entityName, entry.organization, s),\n position: text(entry.role, s),\n summary: text(entry.description, s),\n startDate: toResumeDate(entry.startDate),\n endDate: toResumeDate(entry.endDate),\n }),\n );\n\n const education = filterHidden(profile.education).map((entry) =>\n compact<JsonResumeEducation>({\n institution: orgName(entry.entityName, entry.institution, s),\n area: text(entry.fieldOfStudy, s),\n studyType: text(entry.degree, s),\n startDate: toResumeDate(entry.startedAt),\n endDate: toResumeDate(entry.endedAt),\n }),\n );\n\n const awards = filterHidden(profile.honors).map((honor) =>\n compact<JsonResumeAward>({\n title: s(honor.title),\n date: toResumeDate(honor.date),\n awarder: orgName(honor.entityName, honor.issuer, s),\n summary: text(honor.description, s),\n }),\n );\n\n const certificates = filterHidden(profile.certifications).map((cert) =>\n compact<JsonResumeCertificate>({\n name: s(cert.name),\n date: toResumeDate(cert.issueDate),\n // `issuingOrg` is the deprecated read-view alias for `authority`; records\n // indexed before the rename carry only the alias.\n issuer: orgName(cert.entityName, cert.authority ?? cert.issuingOrg, s),\n url: text(cert.credentialUrl, s),\n }),\n );\n\n const publications = filterHidden(profile.publications).map((publication) =>\n compact<JsonResumePublication>({\n name: s(publication.title),\n publisher: text(publication.publisher, s),\n releaseDate: toResumeDate(publication.date),\n url: text(publication.url, s),\n summary: text(publication.description, s),\n }),\n );\n\n // One entry per skill rather than JSON Resume's grouped shape: Sifa stores one\n // record per skill, and keeping the two symmetric is what makes a round-trip\n // through a third-party editor safe. Category and endorsement counts have no\n // JSON Resume slot and are dropped. Skill records carry no `hidden` flag, so\n // there is nothing to filter here.\n const skills = (profile.skills ?? []).map((skill) => ({ name: s(skill.name) }));\n\n const languages = filterHidden(profile.languages).map((language) =>\n compact<JsonResumeLanguage>({\n language: s(language.language),\n fluency: language.proficiency ? FLUENCY_LABELS[language.proficiency] : undefined,\n }),\n );\n\n const projects = filterHidden(profile.projects).map((project) =>\n compact<JsonResumeProject>({\n name: s(project.name),\n description: text(project.description, s),\n url: text(project.url, s),\n startDate: toResumeDate(project.startDate),\n endDate: toResumeDate(project.endDate),\n }),\n );\n\n return {\n basics,\n ...section('work', work),\n ...section('volunteer', volunteer),\n ...section('education', education),\n ...section('awards', awards),\n ...section('certificates', certificates),\n ...section('publications', publications),\n ...section('skills', skills),\n ...section('languages', languages),\n ...section('projects', projects),\n meta: { canonical, version: SCHEMA_VERSION },\n };\n}\n"],"mappings":";AAmBA,SAAS,4BAA4B;AACrC,SAAS,oBAAoB;AAe7B,SAAS,kBAAkB,kBAAkB;AA4J7C,IAAM,iBAAiB;AAOvB,IAAM,iBAAiB;AAEhB,SAAS,aAAa,OAA+C;AAC1E,QAAM,UAAU,OAAO,KAAK;AAC5B,MAAI,CAAC,QAAS,QAAO;AACrB,QAAM,QAAQ,eAAe,KAAK,OAAO;AACzC,SAAO,QAAQ,MAAM,CAAC,IAAI;AAC5B;AAOA,IAAM,iBAAsD;AAAA,EAC1D,YAAY;AAAA,EACZ,iBAAiB;AAAA,EACjB,sBAAsB;AAAA,EACtB,mBAAmB;AAAA,EACnB,QAAQ;AACV;AAEA,IAAM,WAAsB,CAAC,UAAU;AAGvC,SAAS,QAA0B,OAAa;AAC9C,SAAO,OAAO,YAAY,OAAO,QAAQ,KAAK,EAAE,OAAO,CAAC,CAAC,EAAE,CAAC,MAAM,MAAM,MAAS,CAAC;AACpF;AAGA,SAAS,QAA6B,KAAQ,OAAwC;AACpF,SAAO,MAAM,SAAS,IAAK,EAAE,CAAC,GAAG,GAAG,MAAM,IAAuB;AACnE;AAEA,SAAS,YACP,UACA,GACgC;AAChC,MAAI,CAAC,SAAU,QAAO;AACtB,QAAM,SAAS,QAAQ;AAAA,IACrB,MAAM,KAAK,SAAS,YAAY,SAAS,MAAM,CAAC;AAAA,IAChD,QAAQ,KAAK,SAAS,QAAQ,CAAC;AAAA,IAC/B,aAAa,KAAK,SAAS,aAAa,CAAC;AAAA,IACzC,YAAY,KAAK,SAAS,YAAY,CAAC;AAAA,EACzC,CAAC;AACD,SAAO,OAAO,KAAK,MAAM,EAAE,SAAS,IAAI,SAAS;AACnD;AAGA,SAAS,KAAK,OAA2B,GAAkC;AACzE,QAAM,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AG,QAAQ,UAAU,MAAM;AAAA,IAC3B,GAAG,QAAQ,aAAa,SAAS;AAAA,IACjC,GAAG,QAAQ,YAAY,QAAQ;AAAA,IAC/B,MAAM,EAAE,WAAW,SAAS,eAAe;AAAA,EAC7C;AACF;","names":[]}
@@ -0,0 +1,101 @@
1
+ // src/roadmap/index.ts
2
+ var ROADMAP_ISSUES_REPO = "singi-labs/sifa-workspace";
3
+ var ROADMAP_ITEM_META = {
4
+ endorsementsAttestations: {
5
+ description: "Let colleagues vouch for your skills and experience, recorded as attestations you carry with you.",
6
+ issues: [3, 166]
7
+ },
8
+ notifications: {
9
+ description: "Get told when someone endorses you, links a company, or acts on your profile.",
10
+ issues: [158]
11
+ },
12
+ verifiedConnections: {
13
+ description: "Confirm real working relationships, not just follows.",
14
+ issues: []
15
+ },
16
+ profileAnalytics: {
17
+ description: "See who views your profile and how people find you.",
18
+ issues: []
19
+ },
20
+ jobProfiles: {
21
+ description: "Structured work history that stays with your identity across the network.",
22
+ issues: [102]
23
+ },
24
+ eventRsvp: {
25
+ description: "Show the talks and events you're attending or speaking at.",
26
+ issues: [214]
27
+ },
28
+ companyPages: {
29
+ description: "Claimable organization pages that link the people who work there.",
30
+ issues: [73]
31
+ },
32
+ advancedSearch: {
33
+ description: "Search across categories, with filters and forgiving name matching.",
34
+ issues: [5]
35
+ },
36
+ multiAccountLinking: {
37
+ description: "Tie several atproto accounts to one professional identity.",
38
+ issues: [8]
39
+ },
40
+ mobileApps: {
41
+ description: "Native iOS and Android apps.",
42
+ issues: [114]
43
+ },
44
+ atmosphereStream: {
45
+ description: "One feed that gathers your activity from across the atproto network.",
46
+ issues: [7, 12]
47
+ },
48
+ localizationMultiLanguage: {
49
+ description: "The interface in your own language.",
50
+ issues: [218]
51
+ },
52
+ rssFediverseIngestion: {
53
+ description: "Fediverse posts are in your stream. RSS feeds are next.",
54
+ issues: [111, 153]
55
+ },
56
+ githubFeedIngestion: {
57
+ description: "GitHub activity is in your track record. GitLab and org-owned repositories are next.",
58
+ issues: [391, 392]
59
+ },
60
+ compensationInformation: {
61
+ description: "Add optional pay and compensation context to your roles.",
62
+ issues: [81]
63
+ },
64
+ embedCustomization: {
65
+ description: "Choose which fields show in your embeddable profile card.",
66
+ issues: [117]
67
+ },
68
+ academicLexicon: {
69
+ description: "Schema and features built for researchers and academics.",
70
+ issues: [119, 148]
71
+ },
72
+ journalismLexicon: {
73
+ description: "Schema and features built for journalists.",
74
+ issues: [121]
75
+ },
76
+ skillEvidenceGithub: {
77
+ description: "Back up skill claims with the languages in your GitHub repositories.",
78
+ issues: [107]
79
+ },
80
+ latexCvExport: {
81
+ description: "Export your profile as a LaTeX CV.",
82
+ issues: [113]
83
+ },
84
+ jsonResumeImportExport: {
85
+ description: "Move your profile in and out using the JSON Resume standard.",
86
+ issues: [151]
87
+ },
88
+ linkedClaimsResearch: {
89
+ description: "Exploring the LinkedClaims spec for portable, verifiable endorsements.",
90
+ issues: [155]
91
+ }
92
+ };
93
+ function roadmapIssueUrl(issue) {
94
+ return `https://github.com/${ROADMAP_ISSUES_REPO}/issues/${issue}`;
95
+ }
96
+ export {
97
+ ROADMAP_ISSUES_REPO,
98
+ ROADMAP_ITEM_META,
99
+ roadmapIssueUrl
100
+ };
101
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/roadmap/index.ts"],"sourcesContent":["/**\n * Canonical metadata for the votable Sifa roadmap items: a one-line description\n * and the sifa-workspace issue(s) tracking each item. Single source of truth\n * shared by the sifa-web /roadmap page (labels come from i18n; description and\n * issue links come from here) and the sifa-api operator script that writes the\n * matching userinput.app discussion bodies, so the two surfaces cannot drift.\n *\n * Keys match VOTABLE_KEYS in sifa-api and the roadmap item keys in sifa-web.\n * Descriptions are product voice.\n */\n\n/** Repository whose issues track roadmap items. */\nexport const ROADMAP_ISSUES_REPO = 'singi-labs/sifa-workspace';\n\nexport interface RoadmapItemMeta {\n /** One-line description of the item, in product voice. */\n description: string;\n /** sifa-workspace issue numbers tracking this item (may be empty). */\n issues: number[];\n}\n\nexport const ROADMAP_ITEM_META: Record<string, RoadmapItemMeta> = {\n endorsementsAttestations: {\n description:\n 'Let colleagues vouch for your skills and experience, recorded as attestations you carry with you.',\n issues: [3, 166],\n },\n notifications: {\n description: 'Get told when someone endorses you, links a company, or acts on your profile.',\n issues: [158],\n },\n verifiedConnections: {\n description: 'Confirm real working relationships, not just follows.',\n issues: [],\n },\n profileAnalytics: {\n description: 'See who views your profile and how people find you.',\n issues: [],\n },\n jobProfiles: {\n description: 'Structured work history that stays with your identity across the network.',\n issues: [102],\n },\n eventRsvp: {\n description: \"Show the talks and events you're attending or speaking at.\",\n issues: [214],\n },\n companyPages: {\n description: 'Claimable organization pages that link the people who work there.',\n issues: [73],\n },\n advancedSearch: {\n description: 'Search across categories, with filters and forgiving name matching.',\n issues: [5],\n },\n multiAccountLinking: {\n description: 'Tie several atproto accounts to one professional identity.',\n issues: [8],\n },\n mobileApps: {\n description: 'Native iOS and Android apps.',\n issues: [114],\n },\n atmosphereStream: {\n description: 'One feed that gathers your activity from across the atproto network.',\n issues: [7, 12],\n },\n localizationMultiLanguage: {\n description: 'The interface in your own language.',\n issues: [218],\n },\n rssFediverseIngestion: {\n description: 'Fediverse posts are in your stream. RSS feeds are next.',\n issues: [111, 153],\n },\n githubFeedIngestion: {\n description:\n 'GitHub activity is in your track record. GitLab and org-owned repositories are next.',\n issues: [391, 392],\n },\n compensationInformation: {\n description: 'Add optional pay and compensation context to your roles.',\n issues: [81],\n },\n embedCustomization: {\n description: 'Choose which fields show in your embeddable profile card.',\n issues: [117],\n },\n academicLexicon: {\n description: 'Schema and features built for researchers and academics.',\n issues: [119, 148],\n },\n journalismLexicon: {\n description: 'Schema and features built for journalists.',\n issues: [121],\n },\n skillEvidenceGithub: {\n description: 'Back up skill claims with the languages in your GitHub repositories.',\n issues: [107],\n },\n latexCvExport: {\n description: 'Export your profile as a LaTeX CV.',\n issues: [113],\n },\n jsonResumeImportExport: {\n description: 'Move your profile in and out using the JSON Resume standard.',\n issues: [151],\n },\n linkedClaimsResearch: {\n description: 'Exploring the LinkedClaims spec for portable, verifiable endorsements.',\n issues: [155],\n },\n};\n\n/** The GitHub issue URL for a sifa-workspace issue number. */\nexport function roadmapIssueUrl(issue: number): string {\n return `https://github.com/${ROADMAP_ISSUES_REPO}/issues/${issue}`;\n}\n"],"mappings":";AAYO,IAAM,sBAAsB;AAS5B,IAAM,oBAAqD;AAAA,EAChE,0BAA0B;AAAA,IACxB,aACE;AAAA,IACF,QAAQ,CAAC,GAAG,GAAG;AAAA,EACjB;AAAA,EACA,eAAe;AAAA,IACb,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,qBAAqB;AAAA,IACnB,aAAa;AAAA,IACb,QAAQ,CAAC;AAAA,EACX;AAAA,EACA,kBAAkB;AAAA,IAChB,aAAa;AAAA,IACb,QAAQ,CAAC;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,WAAW;AAAA,IACT,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,cAAc;AAAA,IACZ,aAAa;AAAA,IACb,QAAQ,CAAC,EAAE;AAAA,EACb;AAAA,EACA,gBAAgB;AAAA,IACd,aAAa;AAAA,IACb,QAAQ,CAAC,CAAC;AAAA,EACZ;AAAA,EACA,qBAAqB;AAAA,IACnB,aAAa;AAAA,IACb,QAAQ,CAAC,CAAC;AAAA,EACZ;AAAA,EACA,YAAY;AAAA,IACV,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,kBAAkB;AAAA,IAChB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG,EAAE;AAAA,EAChB;AAAA,EACA,2BAA2B;AAAA,IACzB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,uBAAuB;AAAA,IACrB,aAAa;AAAA,IACb,QAAQ,CAAC,KAAK,GAAG;AAAA,EACnB;AAAA,EACA,qBAAqB;AAAA,IACnB,aACE;AAAA,IACF,QAAQ,CAAC,KAAK,GAAG;AAAA,EACnB;AAAA,EACA,yBAAyB;AAAA,IACvB,aAAa;AAAA,IACb,QAAQ,CAAC,EAAE;AAAA,EACb;AAAA,EACA,oBAAoB;AAAA,IAClB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,iBAAiB;AAAA,IACf,aAAa;AAAA,IACb,QAAQ,CAAC,KAAK,GAAG;AAAA,EACnB;AAAA,EACA,mBAAmB;AAAA,IACjB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,qBAAqB;AAAA,IACnB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,eAAe;AAAA,IACb,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,wBAAwB;AAAA,IACtB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AAAA,EACA,sBAAsB;AAAA,IACpB,aAAa;AAAA,IACb,QAAQ,CAAC,GAAG;AAAA,EACd;AACF;AAGO,SAAS,gBAAgB,OAAuB;AACrD,SAAO,sBAAsB,mBAAmB,WAAW,KAAK;AAClE;","names":[]}
@@ -0,0 +1,101 @@
1
+ // src/rpg/catalog.ts
2
+ import { z } from "zod";
3
+ var RpgUnlockSchema = z.discriminatedUnion("kind", [
4
+ z.object({
5
+ kind: z.literal("hasRecord"),
6
+ collection: z.enum([
7
+ "id.sifa.profile.position",
8
+ "id.sifa.profile.volunteering",
9
+ "id.sifa.profile.presentation",
10
+ "id.sifa.profile.education"
11
+ ])
12
+ }),
13
+ z.object({ kind: z.literal("hasExternalAccount"), platforms: z.array(z.string()).min(1) }),
14
+ z.object({ kind: z.literal("usesApp"), appId: z.string().min(1) }),
15
+ z.object({ kind: z.literal("hasDoctorate") })
16
+ ]);
17
+ var RpgItemSchema = z.object({
18
+ /** Lowercase `[a-z0-9_]` only: the id is embedded in an AT Protocol record key. */
19
+ id: z.string().min(1).max(50).regex(/^[a-z0-9_]+$/),
20
+ title: z.string().max(100),
21
+ description: z.string().max(500),
22
+ kind: z.enum(["layer", "held"]),
23
+ category: z.string().max(30),
24
+ unlock: z.array(RpgUnlockSchema).min(1),
25
+ // ANY of these unlocks the item
26
+ enabled: z.boolean()
27
+ });
28
+ var RPG_ITEMS = [
29
+ {
30
+ id: "sifa_power_suit",
31
+ title: "Power Suit",
32
+ description: "",
33
+ kind: "layer",
34
+ category: "tops",
35
+ enabled: true,
36
+ unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.position" }]
37
+ },
38
+ {
39
+ id: "sifa_weekend_shirt",
40
+ title: "Weekend Shirt",
41
+ description: "",
42
+ kind: "layer",
43
+ category: "tops",
44
+ enabled: true,
45
+ unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.volunteering" }]
46
+ },
47
+ {
48
+ id: "sifa_speaker_mic",
49
+ title: "Speaker Mic",
50
+ description: "",
51
+ kind: "held",
52
+ category: "righthand",
53
+ enabled: true,
54
+ unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.presentation" }]
55
+ },
56
+ {
57
+ id: "sifa_school_books",
58
+ title: "School Books",
59
+ description: "",
60
+ kind: "held",
61
+ category: "lefthand",
62
+ enabled: true,
63
+ unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.education" }]
64
+ },
65
+ {
66
+ id: "sifa_doctoral_cap",
67
+ title: "Doctoral Cap",
68
+ description: "",
69
+ kind: "layer",
70
+ category: "headwear",
71
+ enabled: false,
72
+ unlock: [{ kind: "hasDoctorate" }]
73
+ },
74
+ {
75
+ id: "sifa_lab_coat",
76
+ title: "Lab Coat",
77
+ description: "",
78
+ kind: "layer",
79
+ category: "tops",
80
+ enabled: true,
81
+ unlock: [{ kind: "hasExternalAccount", platforms: ["orcid"] }]
82
+ },
83
+ {
84
+ id: "sifa_dev_hoodie",
85
+ title: "Dev Hoodie",
86
+ description: "",
87
+ kind: "layer",
88
+ category: "tops",
89
+ enabled: true,
90
+ unlock: [
91
+ { kind: "hasExternalAccount", platforms: ["github"] },
92
+ { kind: "usesApp", appId: "tangled" }
93
+ ]
94
+ }
95
+ ];
96
+ export {
97
+ RPG_ITEMS,
98
+ RpgItemSchema,
99
+ RpgUnlockSchema
100
+ };
101
+ //# sourceMappingURL=catalog.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/rpg/catalog.ts"],"sourcesContent":["import { z } from 'zod';\n\nexport const RpgUnlockSchema = z.discriminatedUnion('kind', [\n z.object({\n kind: z.literal('hasRecord'),\n collection: z.enum([\n 'id.sifa.profile.position',\n 'id.sifa.profile.volunteering',\n 'id.sifa.profile.presentation',\n 'id.sifa.profile.education',\n ]),\n }),\n z.object({ kind: z.literal('hasExternalAccount'), platforms: z.array(z.string()).min(1) }),\n z.object({ kind: z.literal('usesApp'), appId: z.string().min(1) }),\n z.object({ kind: z.literal('hasDoctorate') }),\n]);\n\nexport const RpgItemSchema = z.object({\n /** Lowercase `[a-z0-9_]` only: the id is embedded in an AT Protocol record key. */\n id: z\n .string()\n .min(1)\n .max(50)\n .regex(/^[a-z0-9_]+$/),\n title: z.string().max(100),\n description: z.string().max(500),\n kind: z.enum(['layer', 'held']),\n category: z.string().max(30),\n unlock: z.array(RpgUnlockSchema).min(1), // ANY of these unlocks the item\n enabled: z.boolean(),\n});\nexport type RpgItem = z.infer<typeof RpgItemSchema>;\nexport type RpgUnlock = z.infer<typeof RpgUnlockSchema>;\n\n/**\n * The Sifa item catalog for rpg.actor. PLACEHOLDER titles/categories until\n * rpg.actor transfers the real item cores.\n */\nexport const RPG_ITEMS: readonly RpgItem[] = [\n {\n id: 'sifa_power_suit',\n title: 'Power Suit',\n description: '',\n kind: 'layer',\n category: 'tops',\n enabled: true,\n unlock: [{ kind: 'hasRecord', collection: 'id.sifa.profile.position' }],\n },\n {\n id: 'sifa_weekend_shirt',\n title: 'Weekend Shirt',\n description: '',\n kind: 'layer',\n category: 'tops',\n enabled: true,\n unlock: [{ kind: 'hasRecord', collection: 'id.sifa.profile.volunteering' }],\n },\n {\n id: 'sifa_speaker_mic',\n title: 'Speaker Mic',\n description: '',\n kind: 'held',\n category: 'righthand',\n enabled: true,\n unlock: [{ kind: 'hasRecord', collection: 'id.sifa.profile.presentation' }],\n },\n {\n id: 'sifa_school_books',\n title: 'School Books',\n description: '',\n kind: 'held',\n category: 'lefthand',\n enabled: true,\n unlock: [{ kind: 'hasRecord', collection: 'id.sifa.profile.education' }],\n },\n {\n id: 'sifa_doctoral_cap',\n title: 'Doctoral Cap',\n description: '',\n kind: 'layer',\n category: 'headwear',\n enabled: false,\n unlock: [{ kind: 'hasDoctorate' }],\n },\n {\n id: 'sifa_lab_coat',\n title: 'Lab Coat',\n description: '',\n kind: 'layer',\n category: 'tops',\n enabled: true,\n unlock: [{ kind: 'hasExternalAccount', platforms: ['orcid'] }],\n },\n {\n id: 'sifa_dev_hoodie',\n title: 'Dev Hoodie',\n description: '',\n kind: 'layer',\n category: 'tops',\n enabled: true,\n unlock: [\n { kind: 'hasExternalAccount', platforms: ['github'] },\n { kind: 'usesApp', appId: 'tangled' },\n ],\n },\n];\n"],"mappings":";AAAA,SAAS,SAAS;AAEX,IAAM,kBAAkB,EAAE,mBAAmB,QAAQ;AAAA,EAC1D,EAAE,OAAO;AAAA,IACP,MAAM,EAAE,QAAQ,WAAW;AAAA,IAC3B,YAAY,EAAE,KAAK;AAAA,MACjB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF,CAAC;AAAA,EACH,CAAC;AAAA,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,oBAAoB,GAAG,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,CAAC;AAAA,EACzF,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,SAAS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A,IACN,UAAU;AAAA,IACV,SAAS;AAAA,IACT,QAAQ,CAAC,EAAE,MAAM,aAAa,YAAY,4BAA4B,CAAC;AAAA,EACzE;AAAA,EACA;AAAA,IACE,IAAI;AAAA,IACJ,OAAO;AAAA,IACP,aAAa;AAAA,IACb,MAAM;AAAA,IACN,UAAU;AAAA,IACV,SAAS;AAAA,IACT,QAAQ,CAAC,EAAE,MAAM,eAAe,CAAC;AAAA,EACnC;AAAA,EACA;AAAA,IACE,IAAI;AAAA,IACJ,OAAO;AAAA,IACP,aAAa;AAAA,IACb,MAAM;AAAA,IACN,UAAU;AAAA,IACV,SAAS;AAAA,IACT,QAAQ,CAAC,EAAE,MAAM,sBAAsB,WAAW,CAAC,OAAO,EAAE,CAAC;AAAA,EAC/D;AAAA,EACA;AAAA,IACE,IAAI;AAAA,IACJ,OAAO;AAAA,IACP,aAAa;AAAA,IACb,MAAM;AAAA,IACN,UAAU;AAAA,IACV,SAAS;AAAA,IACT,QAAQ;AAAA,MACN,EAAE,MAAM,sBAAsB,WAAW,CAAC,QAAQ,EAAE;AAAA,MACpD,EAAE,MAAM,WAAW,OAAO,UAAU;AAAA,IACtC;AAAA,EACF;AACF;","names":[]}
package/dist/rpg/index.js CHANGED
@@ -1,117 +1,14 @@
1
- import { z } from 'zod';
2
-
3
- // src/rpg/catalog.ts
4
- var RpgUnlockSchema = z.discriminatedUnion("kind", [
5
- z.object({
6
- kind: z.literal("hasRecord"),
7
- collection: z.enum([
8
- "id.sifa.profile.position",
9
- "id.sifa.profile.volunteering",
10
- "id.sifa.profile.presentation",
11
- "id.sifa.profile.education"
12
- ])
13
- }),
14
- z.object({ kind: z.literal("hasExternalAccount"), platforms: z.array(z.string()).min(1) }),
15
- z.object({ kind: z.literal("usesApp"), appId: z.string().min(1) }),
16
- z.object({ kind: z.literal("hasDoctorate") })
17
- ]);
18
- var RpgItemSchema = z.object({
19
- /** Lowercase `[a-z0-9_]` only: the id is embedded in an AT Protocol record key. */
20
- id: z.string().min(1).max(50).regex(/^[a-z0-9_]+$/),
21
- title: z.string().max(100),
22
- description: z.string().max(500),
23
- kind: z.enum(["layer", "held"]),
24
- category: z.string().max(30),
25
- unlock: z.array(RpgUnlockSchema).min(1),
26
- // ANY of these unlocks the item
27
- enabled: z.boolean()
28
- });
29
- var RPG_ITEMS = [
30
- {
31
- id: "sifa_power_suit",
32
- title: "Power Suit",
33
- description: "",
34
- kind: "layer",
35
- category: "tops",
36
- enabled: true,
37
- unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.position" }]
38
- },
39
- {
40
- id: "sifa_weekend_shirt",
41
- title: "Weekend Shirt",
42
- description: "",
43
- kind: "layer",
44
- category: "tops",
45
- enabled: true,
46
- unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.volunteering" }]
47
- },
48
- {
49
- id: "sifa_speaker_mic",
50
- title: "Speaker Mic",
51
- description: "",
52
- kind: "held",
53
- category: "righthand",
54
- enabled: true,
55
- unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.presentation" }]
56
- },
57
- {
58
- id: "sifa_school_books",
59
- title: "School Books",
60
- description: "",
61
- kind: "held",
62
- category: "lefthand",
63
- enabled: true,
64
- unlock: [{ kind: "hasRecord", collection: "id.sifa.profile.education" }]
65
- },
66
- {
67
- id: "sifa_doctoral_cap",
68
- title: "Doctoral Cap",
69
- description: "",
70
- kind: "layer",
71
- category: "headwear",
72
- enabled: false,
73
- unlock: [{ kind: "hasDoctorate" }]
74
- },
75
- {
76
- id: "sifa_lab_coat",
77
- title: "Lab Coat",
78
- description: "",
79
- kind: "layer",
80
- category: "tops",
81
- enabled: true,
82
- unlock: [{ kind: "hasExternalAccount", platforms: ["orcid"] }]
83
- },
84
- {
85
- id: "sifa_dev_hoodie",
86
- title: "Dev Hoodie",
87
- description: "",
88
- kind: "layer",
89
- category: "tops",
90
- enabled: true,
91
- unlock: [
92
- { kind: "hasExternalAccount", platforms: ["github"] },
93
- { kind: "usesApp", appId: "tangled" }
94
- ]
95
- }
96
- ];
97
-
98
- // src/rpg/unlocks.ts
99
- function matches(u, s) {
100
- switch (u.kind) {
101
- case "hasRecord":
102
- return s.collections.includes(u.collection);
103
- case "hasExternalAccount":
104
- return u.platforms.some((p) => s.externalPlatforms.includes(p));
105
- case "usesApp":
106
- return s.activeAppIds.includes(u.appId);
107
- case "hasDoctorate":
108
- return s.hasDoctorate;
109
- }
110
- }
111
- function evaluateRpgUnlocks(signals, items = RPG_ITEMS) {
112
- return items.filter((item) => item.enabled).map((item) => ({ item, earned: item.unlock.some((u) => matches(u, signals)) }));
113
- }
114
-
115
- export { RPG_ITEMS, RpgItemSchema, RpgUnlockSchema, evaluateRpgUnlocks };
116
- //# sourceMappingURL=index.js.map
1
+ // src/rpg/index.ts
2
+ import {
3
+ RPG_ITEMS,
4
+ RpgItemSchema,
5
+ RpgUnlockSchema
6
+ } from "./catalog.js";
7
+ import { evaluateRpgUnlocks } from "./unlocks.js";
8
+ export {
9
+ RPG_ITEMS,
10
+ RpgItemSchema,
11
+ RpgUnlockSchema,
12
+ evaluateRpgUnlocks
13
+ };
117
14
  //# sourceMappingURL=index.js.map