six-degrees 0.5.0 → 0.6.0

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 (366) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/build-manifest.json +3 -3
  3. package/.next/standalone/.next/prerender-manifest.json +14 -14
  4. package/.next/standalone/.next/server/app/_global-error.html +1 -1
  5. package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
  6. package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  7. package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  8. package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  9. package/.next/standalone/.next/server/app/_not-found/page.js +1 -1
  10. package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
  11. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  12. package/.next/standalone/.next/server/app/_not-found.html +1 -1
  13. package/.next/standalone/.next/server/app/_not-found.rsc +20 -19
  14. package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +20 -19
  15. package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +16 -15
  16. package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  17. package/.next/standalone/.next/server/app/api/admin-delete/route.js.nft.json +1 -1
  18. package/.next/standalone/.next/server/app/api/admin-update/route.js.nft.json +1 -1
  19. package/.next/standalone/.next/server/app/api/bridges/route.js.nft.json +1 -1
  20. package/.next/standalone/.next/server/app/api/bulk-import/route.js.nft.json +1 -1
  21. package/.next/standalone/.next/server/app/api/company-scores/legacy/route.js.nft.json +1 -1
  22. package/.next/standalone/.next/server/app/api/company-scores/route.js.nft.json +1 -1
  23. package/.next/standalone/.next/server/app/api/connections/route.js.nft.json +1 -1
  24. package/.next/standalone/.next/server/app/api/data/export/route.js.nft.json +1 -1
  25. package/.next/standalone/.next/server/app/api/data/import/route.js.nft.json +1 -1
  26. package/.next/standalone/.next/server/app/api/data/restart/route.js.nft.json +1 -1
  27. package/.next/standalone/.next/server/app/api/data/reveal/route.js.nft.json +1 -1
  28. package/.next/standalone/.next/server/app/api/data/route.js.nft.json +1 -1
  29. package/.next/standalone/.next/server/app/api/delete-cluster/route.js.nft.json +1 -1
  30. package/.next/standalone/.next/server/app/api/ingest/route.js.nft.json +1 -1
  31. package/.next/standalone/.next/server/app/api/network/route.js.nft.json +1 -1
  32. package/.next/standalone/.next/server/app/api/notifications/route.js.nft.json +1 -1
  33. package/.next/standalone/.next/server/app/api/outreach/route.js.nft.json +1 -1
  34. package/.next/standalone/.next/server/app/api/queue/route.js.nft.json +1 -1
  35. package/.next/standalone/.next/server/app/api/scraper/route.js.nft.json +1 -1
  36. package/.next/standalone/.next/server/app/api/settings/route.js.nft.json +1 -1
  37. package/.next/standalone/.next/server/app/api/settings/sector-preview/route.js.nft.json +1 -1
  38. package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route.js.nft.json +1 -1
  39. package/.next/standalone/.next/server/app/api/setup-profile/route.js.nft.json +1 -1
  40. package/.next/standalone/.next/server/app/api/social/crm/route.js.nft.json +1 -1
  41. package/.next/standalone/.next/server/app/api/social/messages/route.js.nft.json +1 -1
  42. package/.next/standalone/.next/server/app/api/social/route.js.nft.json +1 -1
  43. package/.next/standalone/.next/server/app/api/unlock/route.js.nft.json +1 -1
  44. package/.next/standalone/.next/server/app/api/update/route.js +1 -1
  45. package/.next/standalone/.next/server/app/api/update/route.js.nft.json +1 -1
  46. package/.next/standalone/.next/server/app/api/update-images/route.js.nft.json +1 -1
  47. package/.next/standalone/.next/server/app/api/users/route.js.nft.json +1 -1
  48. package/.next/standalone/.next/server/app/avatars/[file]/route.js.nft.json +1 -1
  49. package/.next/standalone/.next/server/app/import/page.js +1 -1
  50. package/.next/standalone/.next/server/app/import/page.js.nft.json +1 -1
  51. package/.next/standalone/.next/server/app/import/page_client-reference-manifest.js +1 -1
  52. package/.next/standalone/.next/server/app/import.html +1 -1
  53. package/.next/standalone/.next/server/app/import.rsc +24 -23
  54. package/.next/standalone/.next/server/app/import.segments/_full.segment.rsc +24 -23
  55. package/.next/standalone/.next/server/app/import.segments/_tree.segment.rsc +2 -2
  56. package/.next/standalone/.next/server/app/import.segments/import/__PAGE__.segment.rsc +18 -17
  57. package/.next/standalone/.next/server/app/index.html +1 -1
  58. package/.next/standalone/.next/server/app/index.rsc +22 -21
  59. package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +18 -17
  60. package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +22 -21
  61. package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +2 -2
  62. package/.next/standalone/.next/server/app/launch/page.js +1 -1
  63. package/.next/standalone/.next/server/app/launch/page.js.nft.json +1 -1
  64. package/.next/standalone/.next/server/app/launch/page_client-reference-manifest.js +1 -1
  65. package/.next/standalone/.next/server/app/launch.html +2 -2
  66. package/.next/standalone/.next/server/app/launch.rsc +24 -23
  67. package/.next/standalone/.next/server/app/launch.segments/_full.segment.rsc +24 -23
  68. package/.next/standalone/.next/server/app/launch.segments/_tree.segment.rsc +2 -2
  69. package/.next/standalone/.next/server/app/launch.segments/launch/__PAGE__.segment.rsc +18 -17
  70. package/.next/standalone/.next/server/app/page.js +1 -1
  71. package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
  72. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  73. package/.next/standalone/.next/server/app/paths/page.js +1 -1
  74. package/.next/standalone/.next/server/app/paths/page.js.nft.json +1 -1
  75. package/.next/standalone/.next/server/app/paths/page_client-reference-manifest.js +1 -1
  76. package/.next/standalone/.next/server/app/paths.html +1 -1
  77. package/.next/standalone/.next/server/app/paths.rsc +24 -23
  78. package/.next/standalone/.next/server/app/paths.segments/_full.segment.rsc +24 -23
  79. package/.next/standalone/.next/server/app/paths.segments/_tree.segment.rsc +2 -2
  80. package/.next/standalone/.next/server/app/paths.segments/paths/__PAGE__.segment.rsc +18 -17
  81. package/.next/standalone/.next/server/app/profile/page.js +1 -1
  82. package/.next/standalone/.next/server/app/profile/page.js.nft.json +1 -1
  83. package/.next/standalone/.next/server/app/profile/page_client-reference-manifest.js +1 -1
  84. package/.next/standalone/.next/server/app/profile.html +1 -1
  85. package/.next/standalone/.next/server/app/profile.rsc +24 -23
  86. package/.next/standalone/.next/server/app/profile.segments/_full.segment.rsc +24 -23
  87. package/.next/standalone/.next/server/app/profile.segments/_tree.segment.rsc +2 -2
  88. package/.next/standalone/.next/server/app/profile.segments/profile/__PAGE__.segment.rsc +18 -17
  89. package/.next/standalone/.next/server/app/queue/page.js +1 -1
  90. package/.next/standalone/.next/server/app/queue/page.js.nft.json +1 -1
  91. package/.next/standalone/.next/server/app/queue/page_client-reference-manifest.js +1 -1
  92. package/.next/standalone/.next/server/app/queue.html +1 -1
  93. package/.next/standalone/.next/server/app/queue.rsc +24 -23
  94. package/.next/standalone/.next/server/app/queue.segments/_full.segment.rsc +24 -23
  95. package/.next/standalone/.next/server/app/queue.segments/_tree.segment.rsc +2 -2
  96. package/.next/standalone/.next/server/app/queue.segments/queue/__PAGE__.segment.rsc +18 -17
  97. package/.next/standalone/.next/server/app/scores/page.js +1 -1
  98. package/.next/standalone/.next/server/app/scores/page.js.nft.json +1 -1
  99. package/.next/standalone/.next/server/app/scores/page_client-reference-manifest.js +1 -1
  100. package/.next/standalone/.next/server/app/scores.html +1 -1
  101. package/.next/standalone/.next/server/app/scores.rsc +24 -23
  102. package/.next/standalone/.next/server/app/scores.segments/_full.segment.rsc +24 -23
  103. package/.next/standalone/.next/server/app/scores.segments/_tree.segment.rsc +2 -2
  104. package/.next/standalone/.next/server/app/scores.segments/scores/__PAGE__.segment.rsc +18 -17
  105. package/.next/standalone/.next/server/app/settings/page.js +1 -1
  106. package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -1
  107. package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  108. package/.next/standalone/.next/server/app/settings.html +1 -1
  109. package/.next/standalone/.next/server/app/settings.rsc +24 -23
  110. package/.next/standalone/.next/server/app/settings.segments/_full.segment.rsc +24 -23
  111. package/.next/standalone/.next/server/app/settings.segments/_tree.segment.rsc +2 -2
  112. package/.next/standalone/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +18 -17
  113. package/.next/standalone/.next/server/app/setup/page.js +1 -1
  114. package/.next/standalone/.next/server/app/setup/page.js.nft.json +1 -1
  115. package/.next/standalone/.next/server/app/setup/page_client-reference-manifest.js +1 -1
  116. package/.next/standalone/.next/server/app/setup.html +1 -1
  117. package/.next/standalone/.next/server/app/setup.rsc +24 -23
  118. package/.next/standalone/.next/server/app/setup.segments/_full.segment.rsc +24 -23
  119. package/.next/standalone/.next/server/app/setup.segments/_tree.segment.rsc +2 -2
  120. package/.next/standalone/.next/server/app/setup.segments/setup/__PAGE__.segment.rsc +18 -17
  121. package/.next/standalone/.next/server/app/social/page.js +1 -1
  122. package/.next/standalone/.next/server/app/social/page.js.nft.json +1 -1
  123. package/.next/standalone/.next/server/app/social/page_client-reference-manifest.js +1 -1
  124. package/.next/standalone/.next/server/app/social.html +1 -1
  125. package/.next/standalone/.next/server/app/social.rsc +24 -23
  126. package/.next/standalone/.next/server/app/social.segments/_full.segment.rsc +24 -23
  127. package/.next/standalone/.next/server/app/social.segments/_tree.segment.rsc +2 -2
  128. package/.next/standalone/.next/server/app/social.segments/social/__PAGE__.segment.rsc +18 -17
  129. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0-rnla2._.js +1 -1
  130. package/.next/standalone/.next/server/chunks/[root-of-the-server]__00la_y0._.js +1 -1
  131. package/.next/standalone/.next/server/chunks/[root-of-the-server]__05_3-22._.js +1 -1
  132. package/.next/standalone/.next/server/chunks/[root-of-the-server]__07t47cm._.js +1 -1
  133. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0cj5jqc._.js +1 -1
  134. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0e0fei3._.js +1 -1
  135. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ljnyho._.js +1 -1
  136. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0o5-tcg._.js +1 -1
  137. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0qrnous._.js +1 -1
  138. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0t3v1a1._.js +1 -1
  139. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0um1uey._.js +1 -1
  140. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0wmexuc._.js +1 -1
  141. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0xu34sz._.js +1 -1
  142. package/.next/standalone/.next/server/chunks/[root-of-the-server]__133knx1._.js +1 -1
  143. package/.next/standalone/.next/server/chunks/[root-of-the-server]__13dx4sd._.js +1 -1
  144. package/.next/standalone/.next/server/chunks/[root-of-the-server]__14ou7j5._.js +1 -1
  145. package/.next/standalone/.next/server/chunks/[root-of-the-server]__15-17hl._.js +1 -1
  146. package/.next/standalone/.next/server/chunks/[root-of-the-server]__15wc9e-._.js +1 -1
  147. package/.next/standalone/.next/server/chunks/[root-of-the-server]__16iu0hv._.js +1 -1
  148. package/.next/standalone/.next/server/chunks/[root-of-the-server]__18bcnu4._.js +3 -0
  149. package/.next/standalone/.next/server/chunks/[root-of-the-server]__19b7mig._.js +1 -1
  150. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1bbcwub._.js +2 -2
  151. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1eris29._.js +1 -1
  152. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1gjo_cq._.js +1 -1
  153. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1kbl21f._.js +1 -1
  154. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qcm08_._.js +1 -1
  155. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1rphsdk._.js +1 -1
  156. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1tir0vc._.js +2 -2
  157. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1w25q0m._.js +1 -1
  158. package/.next/standalone/.next/server/chunks/[root-of-the-server]__20rwfdw._.js +2 -2
  159. package/.next/standalone/.next/server/chunks/_1_fynia._.js +7 -7
  160. package/.next/standalone/.next/server/chunks/_1itd1o_._.js +2 -2
  161. package/.next/standalone/.next/server/chunks/lib_0851sk0._.js +5 -5
  162. package/.next/standalone/.next/server/chunks/lib_1q7p2ro._.js +5 -5
  163. package/.next/standalone/.next/server/chunks/lib_1r6l86l._.js +5 -5
  164. package/.next/standalone/.next/server/chunks/lib_db-client_15le7cw.js +9 -9
  165. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__08oxiqh._.js +3 -0
  166. package/.next/standalone/.next/server/chunks/ssr/_03l7vge._.js +1 -1
  167. package/.next/standalone/.next/server/chunks/ssr/_08g31gm._.js +3 -0
  168. package/.next/standalone/.next/server/chunks/ssr/_0gk_ofx._.js +3 -0
  169. package/.next/standalone/.next/server/chunks/ssr/_0nwsf93._.js +3 -0
  170. package/.next/standalone/.next/server/chunks/ssr/_0vho1lb._.js +3 -0
  171. package/.next/standalone/.next/server/chunks/ssr/{_0jdkqgi._.js → _1-658fq._.js} +2 -2
  172. package/.next/standalone/.next/server/chunks/ssr/_1bc46kz._.js +3 -0
  173. package/.next/standalone/.next/server/chunks/ssr/_1f_n00p._.js +3 -0
  174. package/.next/standalone/.next/server/chunks/ssr/_1fm1ih_._.js +9 -0
  175. package/.next/standalone/.next/server/chunks/ssr/_1k2nmbw._.js +9 -0
  176. package/.next/standalone/.next/server/chunks/ssr/_2105jz8._.js +3 -0
  177. package/.next/standalone/.next/server/chunks/ssr/app_141w189._.js +1 -1
  178. package/.next/standalone/.next/server/chunks/ssr/app_components_0t908t-._.js +3 -0
  179. package/.next/standalone/.next/server/chunks/ssr/app_components_0uuff77._.js +13 -0
  180. package/.next/standalone/.next/server/chunks/ssr/app_components_1j3q-h5._.js +13 -0
  181. package/.next/standalone/.next/server/chunks/ssr/{_0gtv9jb._.js → app_components_CompanyScores_1g0mytz.js} +2 -2
  182. package/.next/standalone/.next/server/chunks/ssr/app_components_settings_SectorPicker_1c-29qw.js +1 -1
  183. package/.next/standalone/.next/server/chunks/ssr/app_import_page_1fmu6_l.js +1 -1
  184. package/.next/standalone/.next/server/chunks/ssr/app_page_1fazqbf.js +14 -12
  185. package/.next/standalone/.next/server/chunks/ssr/app_paths_page_1ol90m7.js +2 -2
  186. package/.next/standalone/.next/server/chunks/ssr/app_profile_page_0u3-l5y.js +1 -1
  187. package/.next/standalone/.next/server/chunks/ssr/app_queue_page_0c6znd6.js +6 -6
  188. package/.next/standalone/.next/server/chunks/ssr/app_settings_page_1f8mjj_.js +1 -1
  189. package/.next/standalone/.next/server/chunks/ssr/app_setup_page_1-282zx.js +4 -4
  190. package/.next/standalone/.next/server/chunks/ssr/app_social_page_0h7zxda.js +1 -1
  191. package/.next/standalone/.next/server/chunks/ssr/{lib_0i8v-s3._.js → lib_1c4ieuw._.js} +2 -2
  192. package/.next/standalone/.next/server/chunks/ssr/lib_galaxy-lab_108_lu-.js +1 -1
  193. package/.next/standalone/.next/server/middleware-build-manifest.js +3 -3
  194. package/.next/standalone/.next/server/middleware-manifest.json +5 -5
  195. package/.next/standalone/.next/server/pages/404.html +1 -1
  196. package/.next/standalone/.next/server/pages/500.html +1 -1
  197. package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
  198. package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
  199. package/.next/standalone/.next/static/chunks/02pq76u7y4v9-.js +22 -0
  200. package/.next/standalone/.next/static/chunks/0cmq0exd4d0h9.js +1 -0
  201. package/.next/{static/chunks/2wgz9ietkqqe6.js → standalone/.next/static/chunks/0i02yxppzds1o.js} +1 -1
  202. package/.next/standalone/.next/static/chunks/0m_p4k-q2qh--.js +1 -0
  203. package/.next/standalone/.next/static/chunks/0oyslj62jkubd.js +1 -0
  204. package/.next/standalone/.next/static/chunks/{1x_ysly42-teq.css → 0vo-l8hxneba6.css} +1 -1
  205. package/.next/{static/chunks/3sowbvbaj1s6n.js → standalone/.next/static/chunks/0ws7zy0w57ufi.js} +1 -1
  206. package/.next/standalone/.next/static/chunks/0yh8z2tbrc5i_.js +1 -0
  207. package/.next/standalone/.next/static/chunks/172e10mi-tpo_.js +34 -0
  208. package/.next/standalone/.next/static/chunks/1ei5vbe2uw6fl.js +1 -0
  209. package/.next/standalone/.next/static/chunks/1f7_pl_wq7lh3.js +11 -0
  210. package/.next/standalone/.next/static/chunks/1jzbe7zdx9vbj.js +2 -0
  211. package/.next/standalone/.next/static/chunks/1m3017gp790pw.js +45 -0
  212. package/.next/standalone/.next/static/chunks/1t20e8u0st7ep.js +1 -0
  213. package/.next/standalone/.next/static/chunks/2-ch9rm27eril.js +11 -0
  214. package/.next/standalone/.next/static/chunks/2ldv-v3s9yaif.js +1 -0
  215. package/.next/standalone/.next/static/chunks/3bp284gjf7dyq.js +1 -0
  216. package/.next/standalone/.next/static/chunks/3k1f6clbn3gj3.js +7 -0
  217. package/.next/standalone/.next/static/chunks/3l4t8je6iguzc.js +1 -0
  218. package/.next/standalone/.next/static/chunks/{0muwt9bykzr-1.js → 3tplzuc9jk-tl.js} +1 -1
  219. package/.next/standalone/.next/static/chunks/42m0bqr8pbovz.js +11 -0
  220. package/.next/standalone/CHANGELOG.md +61 -0
  221. package/.next/standalone/README.md +22 -8
  222. package/.next/standalone/app/api/scraper/route.js +40 -3
  223. package/.next/standalone/app/api/update/route.js +12 -6
  224. package/.next/standalone/app/components/AppHeader.js +257 -0
  225. package/.next/standalone/app/components/Avatar.js +2 -1
  226. package/.next/standalone/app/components/ChainView.js +12 -12
  227. package/.next/standalone/app/components/FilterPanel.js +20 -12
  228. package/.next/standalone/app/components/ForceGraph.js +163 -25
  229. package/.next/standalone/app/components/GalaxyLab.js +43 -12
  230. package/.next/standalone/app/components/GridView.js +4 -4
  231. package/.next/standalone/app/components/LinkedInLimits.js +2 -1
  232. package/.next/standalone/app/components/ListView.js +3 -3
  233. package/.next/standalone/app/components/NoteDetail.js +2 -1
  234. package/.next/standalone/app/components/OnboardingGate.js +2 -2
  235. package/.next/standalone/app/components/OutlinkQuest.js +2 -1
  236. package/.next/standalone/app/components/PathsAnalyzer.js +3 -2
  237. package/.next/standalone/app/components/PeopleMap.js +2 -1
  238. package/.next/standalone/app/components/RingsView.js +3 -3
  239. package/.next/standalone/app/components/ScanTrail.js +85 -0
  240. package/.next/standalone/app/components/SeparationView.js +100 -77
  241. package/.next/standalone/app/components/Sidebar.js +4 -4
  242. package/.next/standalone/app/components/TheirCircle.js +2 -1
  243. package/.next/standalone/app/components/ThemeLoader.js +9 -0
  244. package/.next/standalone/app/components/UpdatePanel.js +20 -2
  245. package/.next/standalone/app/components/settings/AppearanceSection.js +226 -0
  246. package/.next/standalone/app/components/settings/NetworkHealthSection.js +2 -1
  247. package/.next/standalone/app/components/ui.js +2 -1
  248. package/.next/standalone/app/globals.css +70 -2
  249. package/.next/standalone/app/import/page.js +3 -3
  250. package/.next/standalone/app/layout.js +11 -2
  251. package/.next/standalone/app/page.js +69 -215
  252. package/.next/standalone/app/paths/page.js +8 -21
  253. package/.next/standalone/app/profile/page.js +11 -10
  254. package/.next/standalone/app/queue/page.js +8 -21
  255. package/.next/standalone/app/scores/page.js +1 -1
  256. package/.next/standalone/app/settings/page.js +7 -3
  257. package/.next/standalone/app/setup/page.js +83 -88
  258. package/.next/standalone/app/social/Crm.js +2 -1
  259. package/.next/standalone/app/social/SocialHub.js +2 -2
  260. package/.next/standalone/app/social/page.js +1 -1
  261. package/.next/standalone/lib/data-import.js +1 -0
  262. package/.next/standalone/lib/galaxy-export.js +2 -1
  263. package/.next/standalone/lib/galaxy-lab.js +24 -8
  264. package/.next/standalone/lib/level.js +51 -0
  265. package/.next/standalone/lib/release.js +13 -7
  266. package/.next/standalone/lib/scanner-python.js +38 -8
  267. package/.next/standalone/lib/scraper-client.js +2 -1
  268. package/.next/standalone/lib/separation.js +4 -2
  269. package/.next/standalone/lib/theme-store.js +61 -0
  270. package/.next/standalone/lib/themes.js +186 -0
  271. package/.next/standalone/lib/tiers.js +2 -8
  272. package/.next/standalone/package-lock.json +2 -2
  273. package/.next/standalone/package.json +4 -4
  274. package/.next/standalone/scripts/build-desktop.mjs +325 -0
  275. package/.next/standalone/scripts/build-site.mjs +85 -15
  276. package/.next/standalone/scripts/gen-test-network.mjs +93 -0
  277. package/.next/standalone/scripts/next.mjs +20 -0
  278. package/.next/standalone/scripts/readme_buttons.py +3 -0
  279. package/.next/standalone/scripts/requirements.txt +18 -1
  280. package/.next/standalone/scripts/site-news.mjs +54 -9
  281. package/.next/standalone/scripts/smoke-desktop.mjs +177 -0
  282. package/.next/standalone/scripts/windows/six-degrees.iss +100 -0
  283. package/.next/static/chunks/02pq76u7y4v9-.js +22 -0
  284. package/.next/static/chunks/0cmq0exd4d0h9.js +1 -0
  285. package/.next/{standalone/.next/static/chunks/2wgz9ietkqqe6.js → static/chunks/0i02yxppzds1o.js} +1 -1
  286. package/.next/static/chunks/0m_p4k-q2qh--.js +1 -0
  287. package/.next/static/chunks/0oyslj62jkubd.js +1 -0
  288. package/.next/static/chunks/{1x_ysly42-teq.css → 0vo-l8hxneba6.css} +1 -1
  289. package/.next/{standalone/.next/static/chunks/3sowbvbaj1s6n.js → static/chunks/0ws7zy0w57ufi.js} +1 -1
  290. package/.next/static/chunks/0yh8z2tbrc5i_.js +1 -0
  291. package/.next/static/chunks/172e10mi-tpo_.js +34 -0
  292. package/.next/static/chunks/1ei5vbe2uw6fl.js +1 -0
  293. package/.next/static/chunks/1f7_pl_wq7lh3.js +11 -0
  294. package/.next/static/chunks/1jzbe7zdx9vbj.js +2 -0
  295. package/.next/static/chunks/1m3017gp790pw.js +45 -0
  296. package/.next/static/chunks/1t20e8u0st7ep.js +1 -0
  297. package/.next/static/chunks/2-ch9rm27eril.js +11 -0
  298. package/.next/static/chunks/2ldv-v3s9yaif.js +1 -0
  299. package/.next/static/chunks/3bp284gjf7dyq.js +1 -0
  300. package/.next/static/chunks/3k1f6clbn3gj3.js +7 -0
  301. package/.next/static/chunks/3l4t8je6iguzc.js +1 -0
  302. package/.next/static/chunks/{0muwt9bykzr-1.js → 3tplzuc9jk-tl.js} +1 -1
  303. package/.next/static/chunks/42m0bqr8pbovz.js +11 -0
  304. package/CHANGELOG.md +61 -0
  305. package/README.md +22 -8
  306. package/lib/data-import.js +1 -0
  307. package/lib/galaxy-export.js +2 -1
  308. package/lib/galaxy-lab.js +24 -8
  309. package/lib/level.js +51 -0
  310. package/lib/release.js +13 -7
  311. package/lib/scanner-python.js +38 -8
  312. package/lib/scraper-client.js +2 -1
  313. package/lib/separation.js +4 -2
  314. package/lib/theme-store.js +61 -0
  315. package/lib/themes.js +186 -0
  316. package/lib/tiers.js +2 -8
  317. package/package.json +4 -4
  318. package/scripts/requirements.txt +18 -1
  319. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ljcioj._.js +0 -3
  320. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__16hs8kw._.js +0 -3
  321. package/.next/standalone/.next/server/chunks/ssr/_01kacen._.js +0 -3
  322. package/.next/standalone/.next/server/chunks/ssr/_0xi-fbs._.js +0 -3
  323. package/.next/standalone/.next/server/chunks/ssr/_0xmwmfv._.js +0 -3
  324. package/.next/standalone/.next/server/chunks/ssr/_1-b9hj7._.js +0 -9
  325. package/.next/standalone/.next/server/chunks/ssr/_112ewem._.js +0 -3
  326. package/.next/standalone/.next/server/chunks/ssr/_16ab63q._.js +0 -3
  327. package/.next/standalone/.next/server/chunks/ssr/_1fxm0-s._.js +0 -3
  328. package/.next/standalone/.next/server/chunks/ssr/_1ra1d3r._.js +0 -9
  329. package/.next/standalone/.next/server/chunks/ssr/app_components_ui_0pdmz2z.js +0 -3
  330. package/.next/standalone/.next/server/chunks/ssr/lib_13rapwj._.js +0 -3
  331. package/.next/standalone/.next/static/chunks/03bziijw5srol.js +0 -1
  332. package/.next/standalone/.next/static/chunks/0bgq8wmopl_ig.js +0 -7
  333. package/.next/standalone/.next/static/chunks/0ezus6p2eb-vg.js +0 -1
  334. package/.next/standalone/.next/static/chunks/0g_fy2034bp0x.js +0 -34
  335. package/.next/standalone/.next/static/chunks/0q5dru4q6gxl5.js +0 -22
  336. package/.next/standalone/.next/static/chunks/0w-byiwb2zax8.js +0 -2
  337. package/.next/standalone/.next/static/chunks/1g7jcovdejc9-.js +0 -1
  338. package/.next/standalone/.next/static/chunks/1i51yylxdzht1.js +0 -1
  339. package/.next/standalone/.next/static/chunks/1zf8swaasjf1e.js +0 -43
  340. package/.next/standalone/.next/static/chunks/2dwtoszeq91us.js +0 -1
  341. package/.next/standalone/.next/static/chunks/2rqtpccruavf2.js +0 -1
  342. package/.next/standalone/.next/static/chunks/30x3oq_st7a5r.js +0 -1
  343. package/.next/standalone/.next/static/chunks/355ryio1b7sm1.js +0 -1
  344. package/.next/standalone/.next/static/chunks/3ap5hgma7n0o7.js +0 -1
  345. package/.next/standalone/.next/static/chunks/3fci6qi39-1n5.js +0 -1
  346. package/.next/static/chunks/03bziijw5srol.js +0 -1
  347. package/.next/static/chunks/0bgq8wmopl_ig.js +0 -7
  348. package/.next/static/chunks/0ezus6p2eb-vg.js +0 -1
  349. package/.next/static/chunks/0g_fy2034bp0x.js +0 -34
  350. package/.next/static/chunks/0q5dru4q6gxl5.js +0 -22
  351. package/.next/static/chunks/0w-byiwb2zax8.js +0 -2
  352. package/.next/static/chunks/1g7jcovdejc9-.js +0 -1
  353. package/.next/static/chunks/1i51yylxdzht1.js +0 -1
  354. package/.next/static/chunks/1zf8swaasjf1e.js +0 -43
  355. package/.next/static/chunks/2dwtoszeq91us.js +0 -1
  356. package/.next/static/chunks/2rqtpccruavf2.js +0 -1
  357. package/.next/static/chunks/30x3oq_st7a5r.js +0 -1
  358. package/.next/static/chunks/355ryio1b7sm1.js +0 -1
  359. package/.next/static/chunks/3ap5hgma7n0o7.js +0 -1
  360. package/.next/static/chunks/3fci6qi39-1n5.js +0 -1
  361. /package/.next/standalone/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_buildManifest.js +0 -0
  362. /package/.next/standalone/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_clientMiddlewareManifest.js +0 -0
  363. /package/.next/standalone/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_ssgManifest.js +0 -0
  364. /package/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_buildManifest.js +0 -0
  365. /package/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_clientMiddlewareManifest.js +0 -0
  366. /package/.next/static/{I-cj79yE2IZ8taX2dZGp3 → dQUvvVSXqbkEFC3-CNcwT}/_ssgManifest.js +0 -0
@@ -1,22 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,68863,e=>{"use strict";var n=e.i(43476),t=e.i(71645),i=e.i(18566),o=e.i(2776),s=e.i(22016),a=e.i(40996);let r={install:"Install",setup:"Set up the scanner"};var l=e.i(64745),d=e.i(48235),c=e.i(51798);let h=`
2
- @keyframes radarSweep { to { transform: rotate(360deg); } }
3
- @keyframes radarPing { 0% { opacity: .9; r: 3; } 100% { opacity: 0; r: 11; } }
4
- .radar-sweep { transform-origin: 118px 118px; animation: radarSweep 2.6s linear infinite; }
5
- .radar-ping { animation: radarPing 2.6s ease-out infinite; }
6
- .radar-go { transition: transform .15s ease, box-shadow .2s ease; }
7
- .radar-go:not(:disabled):hover { transform: scale(1.04); box-shadow: 0 0 34px rgba(0,255,136,.45); }
8
- .radar-go:not(:disabled):active { transform: scale(.97); }
9
- @media (prefers-reduced-motion: reduce) { .radar-sweep, .radar-ping { animation: none; } }
10
- `,p=[[.62,.7],[.38,2.1],[.8,3.3],[.5,4.4],[.72,5.6]];function g(e,n,t){let i=n=>`${(118+e*Math.cos(n)).toFixed(2)} ${(118+e*Math.sin(n)).toFixed(2)}`,o=+(t-n>Math.PI);return`M${i(n)} A${e} ${e} 0 ${o} 1 ${i(t)}`}function u({li:e,running:t,scanning:i,disabled:o,label:s,sublabel:a,onScan:r,onPace:l}){let d=e?.limits?.pace||"fast",f=e?.limits?.daily||0,x=e?.unreadable?f:e?.searchesToday||0,y=f?Math.max(0,f-x):null,b=f?Math.min(1,x/f):0,m=b>=.9?"#ff6b6b":b>=.6?"#FFD700":"#00ff88",j=-Math.PI/2,w=108;return(0,n.jsxs)("div",{style:{display:"flex",gap:22,alignItems:"center",flexWrap:"wrap",padding:"14px 16px",borderRadius:14,border:"1px solid rgba(0,255,136,0.18)",background:"radial-gradient(circle at 20% 50%, rgba(0,255,136,0.06), rgba(255,255,255,0.02) 60%)"},children:[(0,n.jsx)("style",{children:h}),(0,n.jsxs)("div",{style:{position:"relative",width:236,height:236,flexShrink:0},children:[(0,n.jsxs)("svg",{width:236,height:236,"aria-hidden":"true",style:{position:"absolute",inset:0},children:[(0,n.jsxs)("defs",{children:[(0,n.jsxs)("radialGradient",{id:"radarBg",children:[(0,n.jsx)("stop",{offset:"0",stopColor:"#0f2a22"}),(0,n.jsx)("stop",{offset:"1",stopColor:"#0a0a1a"})]}),(0,n.jsxs)("linearGradient",{id:"radarBeam",x1:"0",y1:"0",x2:"1",y2:"0",children:[(0,n.jsx)("stop",{offset:"0",stopColor:"#00ff88",stopOpacity:"0"}),(0,n.jsx)("stop",{offset:"1",stopColor:"#00ff88",stopOpacity:"0.45"})]})]}),(0,n.jsx)("circle",{cx:118,cy:118,r:w,fill:"url(#radarBg)",stroke:"rgba(0,255,136,0.25)"}),[.33,.66].map(e=>(0,n.jsx)("circle",{cx:118,cy:118,r:w*e,fill:"none",stroke:"rgba(0,255,136,0.14)",strokeDasharray:"2 5"},e)),(0,n.jsx)("line",{x1:118-w,y1:118,x2:118+w,y2:118,stroke:"rgba(0,255,136,0.1)"}),(0,n.jsx)("line",{x1:118,y1:118-w,x2:118,y2:118+w,stroke:"rgba(0,255,136,0.1)"}),(0,n.jsxs)("g",{className:t?"radar-sweep":void 0,opacity:t?1:.35,children:[(0,n.jsx)("path",{d:`M118 118 L${118+w} 118 A${w} ${w} 0 0 0 ${118+.8525245220595057*w} ${118+-.5226872289306592*w} Z`,fill:"url(#radarBeam)"}),(0,n.jsx)("line",{x1:118,y1:118,x2:118+w,y2:118,stroke:"#00ff88",strokeOpacity:.8,strokeWidth:1.5})]}),p.map(([e,i],o)=>(0,n.jsxs)("g",{children:[(0,n.jsx)("circle",{cx:118+w*e*Math.cos(i),cy:118+w*e*Math.sin(i),r:2.4,fill:"#00ff88",opacity:t?.9:.35}),t&&(0,n.jsx)("circle",{className:"radar-ping",style:{animationDelay:`${i/(2*Math.PI)*2.6}s`},cx:118+w*e*Math.cos(i),cy:118+w*e*Math.sin(i),r:3,fill:"none",stroke:"#00ff88"})]},o)),(0,n.jsx)("path",{d:g(w+5,j,j+2*Math.PI-.001),fill:"none",stroke:"rgba(255,255,255,0.08)",strokeWidth:5}),b>0&&(0,n.jsx)("path",{d:g(w+5,j,j+2*Math.PI*b-.001),fill:"none",stroke:m,strokeWidth:5,strokeLinecap:"round"})]}),(0,n.jsxs)("button",{type:"button",className:"radar-go",onClick:r,disabled:o,style:{position:"absolute",left:56,top:56,width:124,height:124,borderRadius:"50%",cursor:o?"not-allowed":"pointer",border:`2px solid ${o?"rgba(255,255,255,0.12)":"#00ff88"}`,background:o?"rgba(20,24,40,0.92)":"radial-gradient(circle at 50% 35%, #134d3a, #0b2a22 70%)",color:o?"#667":"#eafff5",boxShadow:o?"none":"0 0 22px rgba(0,255,136,0.25)",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:2,padding:8},children:[(0,n.jsx)("span",{style:{fontSize:22,fontWeight:900,letterSpacing:2},children:i?"•••":"SCAN"}),(0,n.jsx)("span",{style:{fontSize:11,fontWeight:700,opacity:.85,lineHeight:1.25,textAlign:"center"},children:s}),a&&(0,n.jsx)("span",{style:{fontSize:10,opacity:.6,textAlign:"center"},children:a})]})]}),(0,n.jsxs)("div",{style:{flex:1,minWidth:260},children:[(0,n.jsx)("div",{style:{fontSize:10,fontWeight:800,letterSpacing:1,color:"#6b7090",textTransform:"uppercase",marginBottom:8},children:"Speed"}),(0,n.jsx)("div",{role:"radiogroup","aria-label":"Scan speed",style:{display:"grid",gridTemplateColumns:"repeat(3, 1fr)",gap:6},children:c.PACE_NAMES.map(e=>{let i=c.PACES[e],o=d===e,s="slow"===e?"#00E5FF":"medium"===e?"#FFD700":"#FF7043";return(0,n.jsxs)("button",{type:"button",role:"radio","aria-checked":o,disabled:t||!l,onClick:()=>l?.(e),title:`${i.pagePause} s before each page, ${i.chunkCooldown/60} min more after every 10, profiles ${i.profileGap} s apart`,style:{padding:"10px 8px",borderRadius:10,cursor:t?"not-allowed":"pointer",textAlign:"left",border:`1.5px solid ${o?s:"rgba(255,255,255,0.1)"}`,background:o?`${s}1a`:"rgba(255,255,255,0.03)",color:"#ddd"},children:[(0,n.jsx)("div",{style:{fontSize:14,fontWeight:800,color:o?s:"#ccd"},children:i.label}),(0,n.jsxs)("div",{style:{fontSize:11,color:"#8a8fa8",marginTop:2},children:["~",(0,c.searchesPerHour)(e)," searches an hour"]}),(0,n.jsxs)("div",{style:{fontSize:10.5,color:"#6b7090",marginTop:1},children:[i.pagePause," s between pages"]})]},e)})}),(0,n.jsx)("div",{style:{marginTop:10,fontSize:12.5,color:"#b8c4c4",lineHeight:1.6},children:e?null==y?(0,n.jsx)(n.Fragment,{children:"No daily cap is set."}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("b",{style:{color:m},children:y})," of ",f," searches left today",y>0&&(0,n.jsxs)(n.Fragment,{children:[" · at ",(0,c.paceOf)(d).label,", ",(0,c.durationText)((0,c.paceSeconds)(d,y))," to use them"]}),"."]}):(0,n.jsx)(n.Fragment,{children:"Today’s searches show here once the scanner can read them."})}),(0,n.jsx)("div",{style:{marginTop:4,fontSize:11.5,color:"#778",lineHeight:1.55},children:"Fast is how the scanner has always run; Medium and Slow only add waiting, so fewer searches an hour reach LinkedIn. Your daily budget stays the cap at every speed: slower spreads it out, it doesn’t shrink it. Slower lowers the odds of a check from LinkedIn; it can’t promise there won’t be one."})]})]})}var f=e.i(26005);let x={daily:50,monthly:250},y="1px solid rgba(255,255,255,0.1)",b={S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"},m=[25,50,100,200,500],j=[100,250,500,1e3,0],w=[10,25,50,100],k=e=>new Date(e).toLocaleDateString(void 0,{month:"short",day:"numeric"});function v({cooldown:e,onLift:i,disabled:o}){let[s,a]=(0,t.useState)(!1);return e?(0,n.jsxs)("div",{role:"status",style:{padding:"12px 14px",borderRadius:8,fontSize:13,lineHeight:1.6,background:"rgba(255,80,80,0.08)",border:"1px solid rgba(255,80,80,0.35)",color:"#f3c9c9"},children:[(0,n.jsxs)("b",{style:{color:"#ff8080"},children:["Scanning is paused until ",new Date(e.until).toLocaleString(void 0,{weekday:"short",month:"short",day:"numeric",hour:"numeric",minute:"2-digit"}),"."]})," ",e.reason,". Nothing that searches LinkedIn will run until then, so the account can recover.",(0,n.jsx)("div",{style:{marginTop:8,display:"flex",gap:8,alignItems:"center",flexWrap:"wrap"},children:s?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{style:{fontSize:12.5},children:"Only if people search works normally for you on linkedin.com right now."}),(0,n.jsx)("button",{onClick:()=>{a(!1),i()},style:{...W,color:"#ff8080"},children:"Yes, lift it"}),(0,n.jsx)("button",{onClick:()=>a(!1),style:W,children:"Keep it"})]}):(0,n.jsx)("button",{onClick:()=>a(!0),disabled:o,style:W,children:"Lift it early…"})})]}):null}function S({used:e,cap:t}){let i=t?Math.min(100,Math.round(e/t*100)):0;return(0,n.jsx)("div",{style:{height:5,borderRadius:3,background:"rgba(255,255,255,0.07)",overflow:"hidden",marginTop:4},children:(0,n.jsx)("div",{style:{height:"100%",width:`${i}%`,background:i>=100?"#ff6b6b":i>=75?"#FFD700":"#3498DB"}})})}function I({li:e,onSetLimits:t,disabled:i}){if(!e)return null;let{limits:o}=e,s=e.unreadable?"?":e.searchesToday,a=e.unreadable?"?":e.profilesToday,r=e=>t({...o,...e}),l=e=>{let n=function(e={},n={}){return Number(n.daily)>100&&Number(n.daily)>Number(e.daily)?`${n.daily} searches a day is more than LinkedIn has put up with. A real account was restricted after 373 searches in 24 hours, run back to back. The default is ${x.daily} a day.
11
-
12
- Set ${n.daily} a day anyway?`:0===n.monthly&&0!==e.monthly?`With no monthly cap, only the daily budget stops a scan. A real account was restricted after 373 searches in 24 hours with no monthly cap set.
13
-
14
- Turn the monthly cap off anyway?`:null}(o,{...o,...e});(!n||window.confirm(n))&&r(e)},d=function({daily:e,monthly:n}={}){if(!(({daily:e,monthly:n}={})=>Number(e)>100||0===n)({daily:e,monthly:n}))return null;let t=["A real account was restricted after 373 searches in 24 hours."];return Number(e)>100&&t.push(`${e} a day can use up a free account's month in a day or two.`),0===n&&t.push("With no monthly cap, nothing but the daily budget stops a long run."),t.join(" ")}(o);return(0,n.jsxs)("div",{style:{padding:"12px 14px",borderRadius:8,border:y,background:"rgba(255,255,255,0.03)",fontSize:12.5,color:"#b8c4c4"},children:[(0,n.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(210px, 1fr))",gap:14},children:[(0,n.jsxs)("div",{children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("b",{style:{color:"#fff"},children:s})," of ",o.daily||"no limit"," searches in the last 24 hours"]}),(0,n.jsx)(S,{used:e.searchesToday||0,cap:o.daily})]}),(0,n.jsxs)("div",{children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("b",{style:{color:"#fff"},children:e.searchesMonth})," of ",o.monthly||"no limit"," this month · resets ",k(e.monthResets)]}),(0,n.jsx)(S,{used:e.searchesMonth,cap:o.monthly})]}),(0,n.jsxs)("div",{children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("b",{style:{color:"#fff"},children:a})," of ",o.profiles," profile views today"]}),(0,n.jsx)(S,{used:e.unreadable?o.profiles:e.profilesToday,cap:o.profiles})]})]}),(0,n.jsxs)("div",{style:{display:"flex",gap:8,alignItems:"center",flexWrap:"wrap",marginTop:10},children:[(0,n.jsx)("span",{children:"Budget:"}),(0,n.jsx)("select",{value:o.daily,disabled:i,onChange:e=>l({daily:Number(e.target.value)}),style:z,children:m.map(e=>(0,n.jsxs)("option",{value:e,children:[e," a day"]},e))}),(0,n.jsx)("select",{value:o.monthly,disabled:i,onChange:e=>l({monthly:Number(e.target.value)}),style:z,children:j.map(e=>(0,n.jsx)("option",{value:e,children:e?`${e} a month`:"no monthly cap (Premium)"},e))}),(0,n.jsx)("select",{value:o.profiles,disabled:i,onChange:e=>r({profiles:Number(e.target.value)}),style:z,children:w.map(e=>(0,n.jsxs)("option",{value:e,children:[e," profile views a day"]},e))})]}),(0,n.jsx)("div",{style:{marginTop:8,color:"#778",lineHeight:1.6},children:"Every page of someone’s connections is one search. LinkedIn limits a free account’s people searches by the month (it doesn’t say how many; reports put it around 250–350), resetting on the 1st. When a budget is used, a scan saves what it read and stops; the next one carries on from the same page."}),d&&(0,n.jsxs)("div",{style:{marginTop:8,display:"flex",gap:10,alignItems:"center",flexWrap:"wrap",color:"#FFD700",lineHeight:1.6},children:[(0,n.jsx)("b",{style:{flex:1,minWidth:200},children:d}),(0,n.jsxs)("button",{onClick:()=>r(x),disabled:i,style:{...z,cursor:i?"not-allowed":"pointer",color:"#FFD700",borderColor:"rgba(255,215,0,0.4)"},children:["Back to ",x.daily," a day, ",x.monthly," a month"]})]}),(0,n.jsx)("div",{style:{marginTop:6,color:"#778",lineHeight:1.6},children:"Each circle scan opens the person’s profile once, which is one profile view. Profile views are what LinkedIn restricted an account for, after about 20 in an hour. The scanner opens at most one a minute, and once today’s are used, a scan stops before the next profile and tries that person next time."})]})}function C({paused:e=[],onResume:i,onResumeAll:o,disabled:s}){let[a,r]=(0,t.useState)(!1);if(!e.length)return null;let l=e.filter(e=>e.legacy).length,d=a?e:e.slice(0,8);return(0,n.jsxs)("div",{style:{borderRadius:8,border:y,background:"rgba(255,255,255,0.03)"},children:[(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"10px 14px",borderBottom:y,flexWrap:"wrap"},children:[(0,n.jsxs)("div",{style:{flex:1,minWidth:200},children:[(0,n.jsxs)("b",{style:{fontSize:13.5},children:["Paused — ",e.length," ",1===e.length?"list":"lists"," with more to read"]}),(0,n.jsxs)("div",{style:{fontSize:12,color:"#8b9a9a",marginTop:2},children:["Each carries on from the page it stopped at",l?`; ${l} were read to page 10 before whole lists were read`:"","."]})]}),(0,n.jsx)("button",{onClick:o,disabled:s,style:{...T,opacity:s?.4:1,cursor:s?"not-allowed":"pointer",background:s?"rgba(255,255,255,0.06)":"linear-gradient(135deg, #3498DB, #9B59B6)"},children:"Resume all"})]}),(0,n.jsx)("div",{children:d.map(e=>(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"8px 14px",borderBottom:"1px solid rgba(255,255,255,0.04)"},children:[(0,n.jsx)("span",{style:{width:8,height:8,borderRadius:"50%",background:b[e.tier]||"#667",flexShrink:0}}),(0,n.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,n.jsx)("div",{style:{fontSize:13,fontWeight:600,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.name}),(0,n.jsxs)("div",{style:{fontSize:11.5,color:"#8b9a9a"},children:["Read to page ",e.pagesRead," · carries on at ",e.nextPage,e.at?` \xb7 ${k(e.at)}`:"",e.unclear>=2?" · came back unclear twice, so it waits at the back of Resume all":""]})]}),(0,n.jsx)("button",{onClick:()=>i(e),disabled:s,style:{...T,padding:"6px 12px",fontSize:12,opacity:s?.4:1,cursor:s?"not-allowed":"pointer"},children:"Resume"})]},e.id))}),e.length>8&&(0,n.jsx)("button",{onClick:()=>r(!a),style:{...W,padding:"10px 14px"},children:a?"Show fewer":`Show all ${e.length}`})]})}let T={padding:"8px 14px",borderRadius:7,fontSize:13,fontWeight:700,cursor:"pointer",border:y,background:"rgba(255,255,255,0.08)",color:"#fff"},W={background:"none",border:"none",color:"#8fb8d6",cursor:"pointer",fontSize:12.5,fontWeight:600,padding:0},z={padding:"6px 8px",borderRadius:6,fontSize:12.5,fontWeight:600,background:"rgba(255,255,255,0.08)",color:"#fff",border:y};var B=e.i(8819),F=e.i(98197);e.i(77170);var R=e.i(69083),P=e.i(56899);let D={color:"#3498DB"};function $({onDone:e}){let[i,o]=(0,t.useState)([]),[s,a]=(0,t.useState)(null),[r,l]=(0,t.useState)(null);async function d(){a("pick"),l(null);let n=await (0,P.saveSettings)({sectorFocus:{sectors:i,strength:"lean"},fieldAsked:!0});n.settings?e(n.settings.sectorFocus.sectors):(l(n.error),a(null))}async function c(){a("skip"),l(null),await (0,P.saveSettings)({fieldAsked:!0}),e([])}return(0,n.jsxs)("section",{"aria-labelledby":"field-question","data-field-question":!0,style:{margin:"8px 0 0",padding:"20px 22px 0",borderRadius:12,border:B.LINE,background:"rgba(255,255,255,0.03)"},children:[(0,n.jsx)("div",{style:{fontSize:12,color:"#788",textTransform:"uppercase",letterSpacing:.6},children:"Before you scan · optional"}),(0,n.jsx)("h2",{id:"field-question",style:{fontSize:18,fontWeight:700,margin:"6px 0 4px"},children:"What field are you in?"}),(0,n.jsx)(B.Body,{style:{marginTop:0,marginBottom:14},children:"Pick up to three. Companies in your field count for more when your network is scored, so the people there rank higher. You can change it anytime in Settings."}),(0,n.jsx)(F.default,{sectors:i,onChange:o,disabled:!!s}),(0,n.jsxs)("div",{style:{position:"sticky",bottom:0,margin:"16px -22px 0",padding:"12px 22px 16px",borderTop:B.LINE,borderRadius:"0 0 11px 11px",background:"#111121"},children:[(0,n.jsxs)("div",{style:{display:"flex",gap:8,flexWrap:"wrap"},children:[(0,n.jsx)(B.Btn,{primary:!0,onClick:d,disabled:!i.length||!!s,children:"pick"===s?"Saving…":"Continue"}),(0,n.jsx)(B.Btn,{onClick:c,disabled:!!s,children:"Skip for now"})]}),r&&(0,n.jsx)(B.Status,{tone:"bad",children:r})]})]})}function L({sectors:e}){return e.length?(0,n.jsxs)(B.Status,{tone:"ok",children:["Your field: ",e.map(e=>(0,R.sectorByKey)(e).label).join(" · "),". Your first scan is scored with it. Change it anytime in ",(0,n.jsx)(s.default,{href:"/settings#sector",style:D,children:"Settings"}),"."]}):(0,n.jsxs)(B.Status,{children:["No field for now. You can pick one anytime in ",(0,n.jsx)(s.default,{href:"/settings#sector",style:D,children:"Settings"}),"."]})}let M="1px solid rgba(255,255,255,0.1)",A={photos:"Saving profile photos to this computer",install:"Installing the scanner",setup:"Setting up the scanner",login:"Waiting for you to sign in",full:"Scanning your whole network",refresh:"Checking for new connections","auto-bridge":"Mapping 2nd-degree connections","auto-bridge-retry":"Mapping 2nd degree, hidden ones included",resume:"Carrying on with one paused list","resume-all":"Carrying on with every paused list"};function N(){let e;(0,t.useEffect)(()=>{"updates"===new URLSearchParams(window.location.search).get("check")&&window.location.replace("/settings?check=updates")},[]);let[o,h]=(0,t.useState)(null),[p,g]=(0,t.useState)(!1),[x,y]=(0,t.useState)(10),[b,m]=(0,t.useState)(["S","A"]),[j,w]=H("six-degrees-bridge-order","newest"),[k,S]=H("six-degrees-bridge-pages-v2",100),[T,W]=H("six-degrees-bridge-finish",!0),[z,B]=H("six-degrees-experimental-auto",!1),[F,R]=H(a.HIDE_CHROME_KEY,!1),[P,D]=(0,t.useState)(null),[N,O]=(0,t.useState)(null),_=(0,t.useRef)(null),[ee,en]=(0,t.useState)(void 0),[et,ei]=(0,t.useState)(null),eo=(0,i.useSearchParams)().get("scan"),[es,ea]=(0,t.useState)(null);(0,t.useEffect)(()=>{if(!eo)return;let e=!0;return(0,a.pickedPerson)(eo).then(n=>{e&&ea(n?.person?n:null)},()=>{}),()=>{e=!1}},[eo]);let er=(0,t.useCallback)(async()=>{try{let e=await fetch("/api/scraper");h(await e.json())}catch{h(e=>e||{ready:!1,checks:{},log:[]})}},[]);async function el(){D(null),await (0,a.stopScrape)().catch(e=>D(e.message)),er()}async function ed(e,n={}){D(null),g(!0);try{let t=await fetch("/api/scraper",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify((0,a.scanRequest)(e,n,F))}),i=await t.json();t.ok||D(i.error||"Could not start.")}catch(e){D(e.message)}finally{g(!1),er()}}(0,t.useEffect)(()=>{er();let e=setInterval(er,1500);return()=>clearInterval(e)},[er]),(0,t.useEffect)(()=>{if(l.IS_DEMO)return;let e=!1;return fetch("/api/settings").then(e=>e.ok?e.json():null).then(n=>{e||en(n?.settings||null)}).catch(()=>{e||en(null)}),()=>{e=!0}},[]),(0,t.useEffect)(()=>{_.current&&(_.current.scrollTop=_.current.scrollHeight)},[o?.log?.length]);let ec=o?.checks||{},eh=o?.running,ep={...e=function(e){let n=e?.checks||{},t=(n,t,i)=>e?.running&&e.action===n?i:t;if(n.dependencies)return"bundled"===n.pythonSource?{done:!0,text:"Ready. The scanner and its Python come with the app, so there is nothing to install.",button:null}:"custom"===n.pythonSource?{done:!0,text:`Ready, on the Python named in SIX_DEGREES_PYTHON (${n.pythonPath}).`,button:null}:{done:!0,text:"Installed.",button:null};let i=n.ownPython&&"bundled"!==n.ownPython.source?`The Python named in SIX_DEGREES_PYTHON didn't work (${n.ownPython.problem}), so the scanner needs setting up another way. `:"";if(n.installFrom)return{done:!1,text:i+("downloaded"===n.installFrom.source?"Its own Python is already here. One more step, about a minute: it installs the browser-automation packages into it.":"One-time, about a minute. Downloads the browser-automation packages."),button:{action:"install",label:t("install","Install","Installing…")}};if(n.download){let e=Math.round(n.download.size/1048576);return{done:!1,text:`${i}${function(e){if(!e?.version)return"This computer has no Python the scanner can use.";let[n,t]=String(e.version).split(".").map(Number);return 3===n&&t>=10&&t<=14&&!1===e.venv?`This computer's Python ${e.version} can't make the scanner's own environment (on Ubuntu or Debian, python3-venv isn't installed).`:`This computer has Python ${e.version}, and the scanner needs 3.10 to 3.14.`}(n.systemPython)} Set up the scanner downloads its own Python ${n.download.version} (${e} MB, from GitHub) and the scanner's packages (from PyPI) into your data folder. Nothing else on this computer changes. About two minutes.`,button:{action:"setup",label:t("setup","Set up the scanner","Setting up…")}}}return{done:!1,text:`${i}No Python 3.10 to 3.14 was found on this machine. Install one from python.org, then reload.`,button:null}}(o),note:function(e,{done:n,button:t}){if(e?.source!=="bundled")return null;let i=/SIGKILL|code signature|not valid for use in process|quarantine|not permitted/i.test(e.problem||""),o=[`The Python that comes with the app didn't work (${e.problem}).`];return i&&o.push("macOS may have blocked it."),!1===e.retry&&o.push("Six Degrees won't try it again until you restart it."),n?o.push("The scanner uses another Python on this computer instead."):t?o.push(`To scan now, use ${r[t.action]} below: it gives the scanner a Python of its own in your data folder.`):o.push("To scan now, install Python 3.10 to 3.14 from python.org, then reload."),o.join(" ")}(o?.checks?.ownPython,e)};o&&ec.dependencies;let eg=o&&!ec.chrome,eu=o&&!ec.scriptsFound,ef=o?.ready&&!eh,ex=o?.linkedin,ey=!!ex?.cooldown,eb=ef&&!ey,em=o?.network||{first:0,second:0,third:0},ej=em.first,ew=o&&ep.done?ec.signedIn?0===ej?3:4:2:1,ek=N??ew,ev=!l.IS_DEMO&&!et&&function(e,n){if(!e)return null;let t=e.network;return!!t&&!t.first&&!t.second&&!t.third&&!e.running&&(void 0===n?null:!!(n&&!n.fieldAsked&&!n.sectorFocus?.sectors?.length))}(o,ee),eS=o&&!eh&&null!=o.exitCode&&0!==o.exitCode,eI=eS?o.failure?.length?o.failure.join("\n"):[...o.log||[]].reverse().find(e=>!/^Stopped \(exit/.test(e)&&!/Warning|warnings\.warn/.test(e)):null;return(0,n.jsxs)("div",{style:{minHeight:"100vh",background:"#0a0a1a",color:"#fff",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},children:[(0,n.jsx)("header",{style:{padding:"20px 30px",borderBottom:M},children:(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:12,flexWrap:"wrap"},children:[(0,n.jsx)(s.default,{href:"/",style:{textDecoration:"none"},children:(0,n.jsx)("span",{style:{fontSize:28,fontWeight:700,background:"linear-gradient(135deg, #FFD700, #9B59B6, #3498DB)",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"},children:"Six Degrees"})}),(0,n.jsx)(f.default,{active:"scan"}),(0,n.jsx)(s.default,{href:"/settings",title:"Settings","aria-label":"Settings",style:{width:32,height:32,borderRadius:"50%",flexShrink:0,background:"rgba(255,255,255,0.06)",color:"#888",fontSize:16,textDecoration:"none",display:"flex",alignItems:"center",justifyContent:"center"},children:"⚙"})]})}),(0,n.jsxs)("div",{style:{maxWidth:720,margin:"0 auto",padding:"32px 24px 64px"},children:[(0,n.jsxs)("div",{style:{padding:"26px 26px 22px",borderRadius:16,marginBottom:22,position:"relative",overflow:"hidden",background:"radial-gradient(120% 140% at 0% 0%, rgba(0,255,136,0.10), rgba(52,152,219,0.06) 45%, rgba(255,255,255,0.02) 75%)",border:"1px solid rgba(0,255,136,0.22)"},children:[(0,n.jsx)("div",{style:{fontSize:11,fontWeight:800,letterSpacing:1.6,color:"#00ff88"},children:"YOUR SCANNER"}),(0,n.jsx)("h1",{style:{fontSize:27,fontWeight:800,margin:"6px 0 8px",lineHeight:1.2},children:ej>0?"Your network is mapped. Send the scanner further.":"Map your network in four steps."}),(0,n.jsx)("div",{style:{fontSize:14.5,color:"#aab7c4",lineHeight:1.6,maxWidth:560},children:"It works in your own Chrome on this Mac, slowly and in the open, and keeps everything here. You launch it; it does the reading; you watch it go."}),(0,n.jsx)("div",{style:{display:"flex",gap:"8px 18px",flexWrap:"wrap",marginTop:16},children:["Never posts or messages anyone","Never sees your password","Nothing leaves this Mac","Stops the moment you say"].map(e=>(0,n.jsxs)("span",{style:{fontSize:12.5,color:"#cfe8dc",display:"flex",alignItems:"center",gap:6},children:[(0,n.jsx)("span",{style:{color:"#00ff88",fontWeight:900},children:"✓"}),e]},e))})]}),null===ev&&(0,n.jsx)("p",{style:{color:"#778",fontSize:13},children:"Checking your setup…"}),ev&&(0,n.jsx)($,{onDone:function(e){ei({sectors:e}),window.scrollTo(0,0)}}),et&&(0,n.jsx)(L,{sectors:et.sectors}),!1===ev&&(0,n.jsxs)(n.Fragment,{children:[es?.person.id===eo&&(0,n.jsx)(E,{pick:es,pages:k,setPages:S,li:ex,running:eh,s:o,canSearch:eb,busy:p,onUnpick:function(){ea(null);try{window.history.replaceState(null,"",window.location.pathname)}catch{}},onStart:()=>ed("bridge",{id:es.person.id,maxPages:k})}),ej>0&&!eh&&(0,n.jsx)(J,{children:(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:14,flexWrap:"wrap"},children:[(0,n.jsxs)("div",{style:{flex:1,minWidth:200},children:[(0,n.jsxs)("b",{children:[ej.toLocaleString()," connections"]}),em.second>0&&(0,n.jsxs)(n.Fragment,{children:[", plus ",em.second.toLocaleString()," people in their circles"]}),em.third>0&&(0,n.jsxs)(n.Fragment,{children:[" and ",em.third.toLocaleString()," from company scans"]}),"."," ",(0,n.jsx)("span",{style:{color:"#9aa"},children:"Your galaxy is ready."})]}),(0,n.jsx)(s.default,{href:"/",style:{padding:"9px 18px",borderRadius:7,fontSize:13.5,fontWeight:700,color:"#0a0a1a",textDecoration:"none",background:"linear-gradient(135deg, #FFD700, #FF6B35)"},children:"See your network →"})]})}),o?.photosWaiting>0&&!eh&&(0,n.jsx)(J,{children:(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:14,flexWrap:"wrap"},children:[(0,n.jsxs)("div",{style:{flex:1,minWidth:200},children:[(0,n.jsxs)("b",{children:[o.photosWaiting.toLocaleString()," ",1===o.photosWaiting?"photo isn’t":"photos aren’t"," saved on this computer yet."]})," ",(0,n.jsx)("span",{style:{color:"#9aa"},children:"An older version kept them as links to LinkedIn. The app doesn’t load photos from LinkedIn while you browse, so those people show initials until the photos are saved here: now, or at the end of your next scan. An expired link can’t be saved; that person’s photo comes back when they’re next scanned."}),o&&!ec.dependencies&&(0,n.jsx)("div",{style:{color:"#8b9a9a",fontSize:12.5,marginTop:6},children:"Set up the scanner first (step 1 below): it saves them."})]}),(0,n.jsx)(X,{onClick:()=>ed("photos"),disabled:p||!ec.dependencies,children:"Save photos"})]})}),eS&&(0,n.jsxs)(J,{tone:"bad",children:[(0,n.jsx)("b",{children:"The last run stopped before it finished."}),eI&&(0,n.jsx)("div",{style:{marginTop:6,color:"#e8c4c4",whiteSpace:"pre-wrap",fontFamily:"ui-monospace, SFMono-Regular, Menlo, monospace",fontSize:12.5},children:eI}),(0,n.jsx)("div",{style:{color:"#9aa",marginTop:6},children:"The full log is below."})]}),eu&&(0,n.jsxs)(J,{tone:"bad",children:[(0,n.jsx)("b",{children:"Can’t find the scanner files."}),(0,n.jsx)("br",{}),(0,n.jsxs)("span",{style:{color:"#9aa"},children:["Expected ",(0,n.jsx)("code",{style:Y,children:"scripts/scrape.py"})," next to the app. If you downloaded a zip, run the app from inside the project folder."]})]}),eg&&(0,n.jsxs)(J,{tone:"bad",children:[(0,n.jsx)("b",{children:"Google Chrome isn’t installed."}),(0,n.jsx)("br",{}),(0,n.jsxs)("span",{style:{color:"#9aa"},children:["The scanner drives your real Chrome. Install it from"," ",(0,n.jsx)("a",{href:"https://www.google.com/chrome/",target:"_blank",rel:"noreferrer",style:{color:"#3498DB"},children:"google.com/chrome"}),", then reload this page."]})]}),o&&ep.note&&(0,n.jsx)(J,{tone:ep.done?void 0:"bad",children:ep.note}),(0,n.jsx)(U,{current:ew,view:ek,onView:O,steps:[{key:1,label:"Get ready",done:ep.done},{key:2,label:"Sign in",done:!!ec.signedIn},{key:3,label:"Who you know",done:ej>0},{key:4,label:"Who they know",done:em.second>0}]}),1===ek&&(0,n.jsx)(K,{step:1,title:"Get your scanner ready",time:"A minute or two, once",body:o?ep.text:"Checking…",launch:o&&ep.button&&(0,n.jsx)(q,{onClick:()=>ed(ep.button.action),disabled:p||eh,children:ep.button.label})}),2===ek&&(0,n.jsx)(K,{step:2,title:"Sign in to LinkedIn, once",time:"You do this part",body:ec.signedIn?"Signed in on this Mac. If LinkedIn ever asks for a security check, or a scan says you were signed out, open LinkedIn here and finish it by hand.":"A Chrome window opens. Sign in with your email and password there: the scanner never sees them. (“Continue with Google” can’t work in it, because Google blocks its sign-in in automated browsers.)",launch:ec.dependencies&&(0,n.jsx)(q,{onClick:()=>ed("login"),disabled:p||eh,quiet:!!ec.signedIn,children:eh&&"login"===o.action?"Waiting for you…":ec.signedIn?"Open LinkedIn again":"Open LinkedIn"})}),3===ek&&(0,n.jsx)(K,{step:3,title:"Map the people you know",time:"About a minute and a half for 750 people",body:"It reads your connections list and saves everyone here. After the first time, Check for new only looks at who you've added since.",launch:(0,n.jsx)(q,{onClick:()=>ed("full"),disabled:!eb,quiet:ej>0,children:eh&&"full"===o.action?"Scanning…":ej>0?"Scan it all again":"Scan my network"}),more:(0,n.jsx)(X,{onClick:()=>ed("refresh"),disabled:!eb,primary:ej>0,children:eh&&"refresh"===o.action?"Checking…":"Check for new"})}),4===ek&&(0,n.jsxs)(K,{step:4,title:"Map who they know",time:"A small batch a day, slowly",body:(0,n.jsxs)(n.Fragment,{children:["It opens your connections one at a time and reads who ",(0,n.jsx)("i",{children:"they"})," know: that fills Degrees, Separation and Outlink. Every round picks up where the last one stopped."]}),children:[(0,n.jsx)(v,{cooldown:ex?.cooldown,disabled:p,onLift:()=>ed("lift-cooldown")}),(0,n.jsxs)("div",{style:{display:"flex",gap:24,flexWrap:"wrap",alignItems:"center",marginTop:4},children:[(0,n.jsx)(u,{li:ex,running:!!eh,scanning:!!(eh&&o?.action?.startsWith("auto-bridge")),disabled:!eb||"score"===j&&!b.length,label:eh&&o?.action==="auto-bridge"?"Mapping…":"Map 2nd degree",sublabel:x?`${x} people`:"everyone",onScan:()=>ed("auto-bridge",{maxBridges:x,tiers:"score"===j?b:[],order:j,maxPages:k,deeper:T,experimental:z}),onPace:p?void 0:e=>ed("set-limits",{...ex?.limits||{},pace:e})}),(0,n.jsxs)("div",{style:{flex:"1 1 230px",display:"flex",flexDirection:"column",gap:12},children:[(0,n.jsxs)("label",{style:{display:"flex",gap:10,alignItems:"center",fontSize:13,color:"#cfd8d8"},children:["This round",(0,n.jsxs)("select",{value:x,onChange:e=>y(Number(e.target.value)),disabled:eh,style:G,children:[(0,n.jsx)("option",{value:5,children:"5 people"}),(0,n.jsx)("option",{value:10,children:"10 people"}),(0,n.jsx)("option",{value:25,children:"25 people"}),(0,n.jsx)("option",{value:0,children:"everyone — not advised"})]})]}),(0,n.jsxs)("label",{style:{display:"flex",gap:10,alignItems:"center",fontSize:13,color:"#cfd8d8"},children:["Start with",(0,n.jsxs)("select",{value:j,onChange:e=>w(e.target.value),disabled:eh,style:G,children:[(0,n.jsx)("option",{value:"newest",children:"Newest connections"}),(0,n.jsx)("option",{value:"score",children:"Highest tier"})]})]}),"score"===j&&(0,n.jsxs)("div",{style:{display:"flex",gap:8,alignItems:"center",flexWrap:"wrap"},children:[(0,n.jsx)("span",{style:{fontSize:12,color:"#8b9a9a"},children:"Work through"}),["S","A","B","C","D"].map(e=>{let t=b.includes(e);return(0,n.jsx)("button",{onClick:()=>m(n=>n.includes(e)?n.filter(n=>n!==e):[...n,e]),disabled:eh,style:{width:30,height:28,borderRadius:7,fontSize:12,fontWeight:700,cursor:eh?"not-allowed":"pointer",border:M,background:t?"rgba(52,152,219,0.22)":"rgba(255,255,255,0.05)",color:t?"#cfe6f7":"#667"},children:e},e)}),(0,n.jsx)("span",{style:{fontSize:11.5,color:"#667"},children:b.length?"":"pick at least one"})]}),"newest"===j&&(0,n.jsxs)("div",{style:{fontSize:12,color:"#8b9a9a",lineHeight:1.6},children:["Goes by the date you connected, newest first, across every tier. Run"," ",(0,n.jsx)("b",{children:"Check for new"})," first so your latest connections are in the list."]}),(0,n.jsx)(V,{})]})]})]}),eh&&(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:12,marginTop:20,padding:"14px 16px",borderRadius:8,background:"rgba(0,255,136,0.06)",border:"1px solid rgba(0,255,136,0.3)"},children:[(0,n.jsx)(Q,{}),(0,n.jsxs)("div",{style:{flex:1,fontSize:13.5},children:[(0,n.jsx)("div",{style:{fontSize:11,fontWeight:800,letterSpacing:1.2,color:"#00ff88",marginBottom:2},children:"YOUR SCANNER IS WORKING"}),(0,n.jsx)("b",{children:A[o.action]||"Working"}),o.progress&&(0,n.jsx)(Z,{p:o.progress,action:o.action}),(0,n.jsx)("div",{style:{color:"#8b9a9a",fontSize:12.5,marginTop:2},children:"Stopping closes the browser cleanly and keeps everything found so far."})]}),(0,n.jsx)(X,{onClick:el,tone:"bad",children:"Stop"})]}),(0,n.jsxs)("details",{style:{margin:"18px 0 4px",borderRadius:10,border:M,background:"rgba(255,255,255,0.02)"},children:[(0,n.jsxs)("summary",{style:{padding:"12px 16px",cursor:"pointer",fontSize:13.5,fontWeight:650,color:"#cfd8d8"},children:["Fine-tune the scanner",(0,n.jsx)("span",{style:{fontWeight:500,color:"#778",marginLeft:8},children:"daily budget, how much of each list, the hidden window, paused lists"})]}),(0,n.jsxs)("div",{style:{padding:"4px 16px 16px",display:"flex",flexDirection:"column",gap:12},children:[(0,n.jsx)(I,{li:ex,disabled:p,onSetLimits:e=>ed("set-limits",e)}),(0,n.jsxs)("label",{style:{display:"flex",gap:10,alignItems:"center",fontSize:12.5,color:"#cfd8d8"},children:["Read up to",(0,n.jsxs)("select",{value:k,onChange:e=>S(Number(e.target.value)),disabled:eh,style:G,children:[(0,n.jsx)("option",{value:100,children:"every page, to the end of their list"}),(0,n.jsx)("option",{value:50,children:"50 pages each"}),(0,n.jsx)("option",{value:25,children:"25 pages each"}),(0,n.jsx)("option",{value:10,children:"10 pages (~100 people) each"})]})]}),(0,n.jsxs)("label",{style:{display:"flex",gap:8,alignItems:"center",fontSize:12.5,color:"#cfd8d8",cursor:eh?"not-allowed":"pointer"},children:[(0,n.jsx)("input",{type:"checkbox",checked:T,onChange:e=>W(e.target.checked),disabled:eh}),"Also finish people already mapped, from the page each one stopped at"]}),(0,n.jsxs)("label",{style:{display:"flex",gap:8,alignItems:"flex-start",fontSize:12.5,color:"#b8c4c4",cursor:eh?"default":"pointer"},children:[(0,n.jsx)("input",{type:"checkbox",checked:z,disabled:eh,style:{marginTop:3},onChange:e=>{B(e.target.checked),window.dispatchEvent(new Event("six-degrees:experimental"))}}),(0,n.jsxs)("span",{children:[(0,n.jsx)("b",{style:{color:"#FFD700"},children:"Experimental:"})," all-day pacing. Up to 8 pages in a sitting, then an hour’s rest; searches only from 9:00 to 18:00; never more than 40 searches in a day or 200 in a week, however high your budget; two days’ rest after any check from LinkedIn; at the budget it waits instead of stopping; and it saves every page. It also reads LinkedIn’s own data beside the page text, to fill gaps and measure how the two compare. It keeps running while the app is open."]})]}),(0,n.jsxs)("label",{style:{display:"flex",gap:8,alignItems:"flex-start",fontSize:12.5,color:"#b8c4c4",cursor:eh?"default":"pointer"},children:[(0,n.jsx)("input",{type:"checkbox",checked:F,disabled:eh,style:{marginTop:3},onChange:e=>R(e.target.checked)}),(0,n.jsxs)("span",{children:[(0,n.jsx)("b",{style:{color:"#FFD700"},children:"Hide the Chrome window while scanning."})," Every scan runs with no window popping up; the status bar still shows what it’s doing, and Stop still works. Signing in always opens the window.",(0,n.jsx)("span",{style:{display:"block",marginTop:4,color:"#e0a080"},children:"The risks: a hidden Chrome is easier for LinkedIn to tell apart from a person, so it may make a warning or restriction more likely. If LinkedIn asks you to check it’s you (a code, a puzzle, signing in again) you won’t see it, and the scan will stop instead of waiting for you. Untick this and scan again to see what LinkedIn wants. It changes nothing about pacing or your daily budget."})]})]}),(0,n.jsxs)("div",{style:{fontSize:12,color:"#FFD700",lineHeight:1.6},children:["Every page is a LinkedIn search, so at ",(0,c.paceOf)(ex?.limits?.pace).label," it rests"," ",(0,c.paceOf)(ex?.limits?.pace).pagePause," seconds before each one and"," ",(0,c.paceOf)(ex?.limits?.pace).chunkCooldown/60==1?"a minute":`${(0,c.paceOf)(ex?.limits?.pace).chunkCooldown/60} minutes`," after every 10, and a long list can take"," ","about ",(0,d.circleScanCost)(k,ex?.limits?.pace).minutes," minutes a person. LinkedIn shows 100 pages of anyone’s connections at most. Free accounts have a monthly search limit: if LinkedIn says it has been reached, the scan saves what it read and stops, and carries on from that page next time. Keep batches small."]}),(0,n.jsxs)("div",{children:[(0,n.jsx)(X,{onClick:()=>ed("auto-bridge-retry",{maxBridges:x,tiers:"score"===j?b:[],order:j,maxPages:k,deeper:T}),disabled:!eb||"score"===j&&!b.length,children:"Retry hidden ones"}),(0,n.jsx)("span",{style:{fontSize:12,color:"#8b9a9a",marginLeft:10},children:"People whose list was hidden last time, in case they've opened it."})]}),(0,n.jsx)(C,{paused:o?.paused||[],disabled:!eb,onResume:e=>ed("resume",{id:e.id}),onResumeAll:()=>ed("resume-all",{maxBridges:x})})]})]}),P&&(0,n.jsx)(J,{tone:"bad",children:P}),o?.log?.length>0&&(0,n.jsxs)("details",{open:eS,style:{marginTop:20},children:[(0,n.jsxs)("summary",{style:{display:"flex",alignItems:"center",gap:10,cursor:"pointer",margin:"8px 0",fontSize:12,color:"#788",textTransform:"uppercase",letterSpacing:.6},children:[eh&&(0,n.jsx)(Q,{}),eh?"What it’s doing (the log)":"The last run’s log"]}),(0,n.jsx)("pre",{ref:_,style:{background:"rgba(0,0,0,0.45)",border:M,borderRadius:8,padding:14,maxHeight:280,overflow:"auto",margin:0,fontSize:12.5,lineHeight:1.7,color:"#b9c6c6",fontFamily:"ui-monospace, SFMono-Regular, Menlo, monospace",whiteSpace:"pre-wrap",wordBreak:"break-word"},children:o.log.join("\n")})]})]}),(0,n.jsxs)("div",{style:{marginTop:32,paddingTop:20,borderTop:M,fontSize:13.5,color:"#8b9a9a"},children:["Checking for updates has moved to"," ",(0,n.jsx)(s.default,{href:"/settings#updates",style:{color:"#3498DB"},children:"Settings →"})]}),(0,n.jsxs)("p",{style:{color:"#667",fontSize:12.5,lineHeight:1.7,marginTop:32},children:["Automating LinkedIn may go against its User Agreement, and accounts have been restricted for it. This runs locally against your own account, at your own risk. LinkedIn’s own CSV export is the supported route and needs none of this —"," ",(0,n.jsx)(s.default,{href:"/import",style:{color:"#3498DB"},children:"import a CSV instead"}),"."]})]}),(0,n.jsx)("style",{children:`@keyframes spin { to { transform: rotate(360deg) } }
15
- @keyframes slide { 0% { transform: translateX(-100%) } 100% { transform: translateX(300%) } }`})]})}function E({pick:e,pages:t,setPages:i,li:o,running:a,s:r,canSearch:l,busy:c,onStart:h,onUnpick:p}){let{person:g,circle:u}=e,f=String(g.name||"").trim().split(/\s+/)[0]||"them",x=(0,d.circleScanCost)(t,o?.limits?.pace),y=a&&r?.target?.id===g.id,b=o?.leftToday!=null&&o.leftToday<x.searches;return(0,n.jsxs)("div",{style:{margin:"16px 0",padding:"16px 18px",borderRadius:10,fontSize:13.5,lineHeight:1.6,background:"rgba(0,255,136,0.05)",border:"1px solid rgba(0,255,136,0.3)"},children:[(0,n.jsx)("div",{style:{fontSize:11,fontWeight:700,color:"#00ff88",letterSpacing:.6,textTransform:"uppercase",marginBottom:4},children:"Scan one circle"}),(0,n.jsxs)("div",{style:{fontSize:16,fontWeight:700},children:[g.name," ",(0,n.jsxs)("span",{style:{fontSize:12,color:O[g.tier]||"#888"},children:[g.tier,"-tier"]})]}),g.unlocked_from_name&&(0,n.jsxs)("div",{style:{fontSize:12.5,color:"#9aa"},children:["Was in ",g.unlocked_from_name,"’s circle"]}),y?(0,n.jsxs)("div",{style:{marginTop:10},children:[(0,n.jsxs)("b",{children:["Scanning ",f,"’s circle."]})," It saves every 10 pages, and"," ",(0,n.jsx)(s.default,{href:`/?chain=${encodeURIComponent(g.id)}`,style:{color:"#00ff88"},children:"Bridge Chains shows it filling in →"})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{style:{color:"#b8c4c4",marginTop:10},children:["It costs ",(0,n.jsxs)("b",{children:[x.profileViews," profile view"]})," to find their list, then ",(0,n.jsx)("b",{children:"one LinkedIn search for every page"})," of it: up to ",x.searches," ",1===x.searches?"page":"pages",", about ",x.minutes," minutes.",o?.leftToday!=null&&(0,n.jsxs)(n.Fragment,{children:[" ",(0,n.jsx)("b",{children:o.leftToday})," of your ",o.limits?.daily," searches a day are left",b?"; the scan stops when they run out, and can carry on from that page later":"","."]})]}),"scanned"===u&&(0,n.jsx)("div",{style:{color:"#FFD700",fontSize:12.5,marginTop:6},children:"Their circle is already scanned. This reads their whole list again from page 1; to carry on from where a read stopped, use Resume on their card or in the Paused list below."}),"hidden"===u&&(0,n.jsx)("div",{style:{color:"#FFD700",fontSize:12.5,marginTop:6},children:"Their list was hidden last time it was tried. Trying again costs a profile view."}),(0,n.jsxs)("div",{style:{display:"flex",gap:10,alignItems:"center",flexWrap:"wrap",marginTop:12},children:[(0,n.jsxs)(X,{onClick:h,disabled:!l||c,primary:!0,children:["Scan ",f,"’s circle"]}),(0,n.jsxs)("select",{value:t,onChange:e=>i(Number(e.target.value)),disabled:a,style:G,"aria-label":"How many pages of their list to read",children:[(0,n.jsx)("option",{value:100,children:"every page, to the end of their list"}),(0,n.jsx)("option",{value:50,children:"up to 50 pages"}),(0,n.jsx)("option",{value:25,children:"up to 25 pages"}),(0,n.jsx)("option",{value:10,children:"up to 10 pages (~100 people)"})]}),(0,n.jsx)(X,{onClick:p,children:"Not now"})]}),!l&&(0,n.jsx)("div",{style:{fontSize:12.5,color:"#8b9a9a",marginTop:8},children:a?"Something else is running. One scan at a time: this one can start when it finishes.":o?.cooldown?"Scanning is paused for now (see below).":"The scanner isn’t ready yet: finish the steps below first."})]})]})}let O={S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"};function H(e,n){let[i,o]=(0,t.useState)(n);return(0,t.useEffect)(()=>{try{let n=localStorage.getItem(e);null!==n&&o(JSON.parse(n))}catch{}},[e]),[i,n=>{o(n);try{localStorage.setItem(e,JSON.stringify(n))}catch{}}]}let Y={background:"rgba(255,255,255,0.08)",padding:"1px 5px",borderRadius:4},G={padding:"9px 10px",borderRadius:7,fontSize:13.5,fontWeight:600,background:"rgba(255,255,255,0.08)",color:"#fff",border:M},_=`
16
- @keyframes stepPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(0,255,136,.45); } 50% { box-shadow: 0 0 0 7px rgba(0,255,136,0); } }
17
- .journey-now { animation: stepPulse 2.2s ease-in-out infinite; }
18
- .launch-go { transition: transform .15s ease, box-shadow .2s ease, filter .2s ease; }
19
- .launch-go:not(:disabled):hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(0,255,136,.35); filter: brightness(1.08); }
20
- .launch-go:not(:disabled):active { transform: translateY(0) scale(.98); }
21
- @media (prefers-reduced-motion: reduce) { .journey-now { animation: none; } }
22
- `;function U({steps:e,current:t,view:i,onView:o}){return(0,n.jsxs)("div",{role:"tablist","aria-label":"Scanning, step by step",style:{display:"flex",alignItems:"flex-start",margin:"4px 0 14px"},children:[(0,n.jsx)("style",{children:_}),e.map((s,a)=>{let r=s.key===t&&!s.done,l=s.key===i,d=s.done?"#00ff88":r?"#fff":"#667";return(0,n.jsxs)("div",{style:{flex:1,display:"flex",alignItems:"flex-start",minWidth:0},children:[(0,n.jsxs)("button",{type:"button",role:"tab","aria-selected":l,onClick:()=>o(s.key===t?null:s.key),style:{flex:"0 0 auto",width:76,display:"flex",flexDirection:"column",alignItems:"center",gap:7,background:"none",border:"none",cursor:"pointer",padding:0},children:[(0,n.jsx)("span",{className:r?"journey-now":void 0,style:{width:38,height:38,borderRadius:"50%",display:"grid",placeItems:"center",fontSize:15,fontWeight:800,background:s.done?"rgba(0,255,136,0.16)":r?"linear-gradient(135deg, #00ff88, #1abc9c)":"rgba(255,255,255,0.05)",color:s.done?"#00ff88":r?"#04140c":"#778",border:`2px solid ${l?"#fff":s.done?"rgba(0,255,136,0.55)":r?"transparent":"rgba(255,255,255,0.12)"}`},children:s.done?"✓":s.key}),(0,n.jsx)("span",{style:{fontSize:12,fontWeight:l?800:650,color:d,textAlign:"center",lineHeight:1.25,maxWidth:76,overflowWrap:"break-word"},children:s.label})]}),a<e.length-1&&(0,n.jsx)("span",{"aria-hidden":"true",style:{flex:1,height:2,marginTop:19,borderRadius:1,minWidth:8,background:s.done?"linear-gradient(90deg, rgba(0,255,136,0.7), rgba(0,255,136,0.25))":"rgba(255,255,255,0.1)"}})]},s.key)})]})}function K({step:e,title:t,time:i,body:o,launch:s,more:a,children:r}){return(0,n.jsxs)("div",{style:{padding:"20px 22px",borderRadius:14,marginBottom:8,background:"rgba(255,255,255,0.035)",border:"1px solid rgba(255,255,255,0.1)"},children:[(0,n.jsxs)("div",{style:{display:"flex",alignItems:"baseline",gap:10,flexWrap:"wrap"},children:[(0,n.jsxs)("span",{style:{fontSize:11,fontWeight:800,letterSpacing:1.2,color:"#778"},children:["STEP ",e]}),(0,n.jsx)("span",{style:{fontSize:19,fontWeight:800},children:t}),i&&(0,n.jsxs)("span",{style:{fontSize:12,color:"#8fd9b6",marginLeft:"auto"},children:["⏱ ",i]})]}),(0,n.jsx)("div",{style:{fontSize:14,color:"#9fb0bb",lineHeight:1.6,margin:"8px 0 14px",maxWidth:600},children:o}),r,(s||a)&&(0,n.jsxs)("div",{style:{display:"flex",gap:10,alignItems:"center",flexWrap:"wrap"},children:[s,a]})]})}function q({children:e,onClick:t,disabled:i,quiet:o=!1}){return(0,n.jsxs)("button",{type:"button",className:"launch-go",onClick:t,disabled:i,style:{display:"inline-flex",alignItems:"center",gap:10,padding:o?"10px 18px":"13px 26px",borderRadius:12,fontSize:o?14:16,fontWeight:800,cursor:i?"not-allowed":"pointer",color:i?"#667":o?"#cfe8dc":"#04140c",border:o?"1px solid rgba(0,255,136,0.35)":"none",background:i?"rgba(255,255,255,0.06)":o?"rgba(0,255,136,0.08)":"linear-gradient(135deg, #00ff88, #1abc9c)",boxShadow:i||o?"none":"0 4px 22px rgba(0,255,136,0.25)"},children:[(0,n.jsx)("span",{"aria-hidden":"true",style:{fontSize:o?11:13},children:"▶"}),e]})}function V(){return(0,n.jsxs)("details",{style:{fontSize:12.5,color:"#8b9a9a",lineHeight:1.6},children:[(0,n.jsx)("summary",{style:{cursor:"pointer",color:"#aab7c4",fontWeight:600},children:"Why so slow?"}),(0,n.jsxs)("div",{style:{marginTop:6},children:["This is the part LinkedIn notices. While this app was being built, a real account was restricted for a while after roughly ",(0,n.jsx)("b",{children:"19 people in one sitting"}),". So: a small batch, a day’s rest, another batch, and stop the moment LinkedIn mentions unusual activity. Most people hide their connections; those are noted and never tried again. A list is read to the end, saving every 10 pages, and a stopped read carries on from the same page."]})]})}function X({children:e,onClick:t,disabled:i,primary:o,tone:s}){return(0,n.jsx)("button",{onClick:t,disabled:i,style:{padding:"9px 18px",borderRadius:7,fontSize:13.5,fontWeight:650,color:i?"#667":"#fff",background:i?"rgba(255,255,255,0.05)":"bad"===s?"rgba(255,80,80,0.15)":o?"linear-gradient(135deg, #9B59B6, #3498DB)":"rgba(255,255,255,0.08)",border:M,cursor:i?"not-allowed":"pointer"},children:e})}function J({children:e,tone:t}){return(0,n.jsx)("div",{style:{margin:"16px 0",padding:"14px 16px",borderRadius:8,fontSize:13.5,lineHeight:1.6,background:"bad"===t?"rgba(255,80,80,0.08)":"rgba(255,255,255,0.05)",border:`1px solid ${"bad"===t?"rgba(255,80,80,0.3)":"rgba(255,255,255,0.12)"}`},children:e})}function Z({p:e,action:t}){let i;if("saving"===e.kind)return(0,n.jsxs)("div",{style:{margin:"8px 0 6px"},children:[(0,n.jsx)("div",{role:"progressbar","aria-label":"Saving",style:{height:8,borderRadius:4,overflow:"hidden",background:"rgba(255,255,255,0.08)",marginBottom:6},children:(0,n.jsx)("div",{style:{width:"35%",height:"100%",borderRadius:4,background:"linear-gradient(90deg, #9B59B6, #3498DB)",animation:"slide 1.2s ease-in-out infinite"}})}),(0,n.jsx)("div",{style:{fontSize:12.5,color:"#cfe6f7"},children:"Saving to your network and fetching photos — this can take a minute or two."})]});let o=Math.max(0,Math.min(100,Math.round(e.done/e.total*100)));return i="download"===e.kind?`Downloading Python: ${e.done.toFixed(1)} of ${e.total.toFixed(1)} MB \xb7 ${o}%`:"batch"===e.kind?`Person ${e.current} of ${e.total}`:"refresh"===t?`Looked at ${e.done.toLocaleString()} so far — stops once it reaches people already saved`:`${e.done.toLocaleString()} of ${e.total.toLocaleString()} connections \xb7 ${o}%`,(0,n.jsxs)("div",{style:{margin:"8px 0 6px"},children:["refresh"!==t&&(0,n.jsx)("div",{role:"progressbar","aria-valuemin":0,"aria-valuemax":e.total,"aria-valuenow":e.done,"aria-label":i,style:{height:8,borderRadius:4,overflow:"hidden",background:"rgba(255,255,255,0.08)",marginBottom:6},children:(0,n.jsx)("div",{style:{width:`${o}%`,height:"100%",borderRadius:4,background:"linear-gradient(90deg, #9B59B6, #3498DB)",transition:"width 0.6s ease"}})}),(0,n.jsx)("div",{style:{fontSize:12.5,color:"#cfe6f7"},children:i})]})}function Q(){return(0,n.jsx)("span",{style:{width:11,height:11,borderRadius:"50%",display:"inline-block",border:"2px solid rgba(255,255,255,0.2)",borderTopColor:"#3498DB",animation:"spin 0.8s linear infinite"}})}e.s(["default",0,function(){return(0,n.jsx)(o.default,{children:(0,n.jsx)(t.Suspense,{children:(0,n.jsx)(N,{})})})}],68863)}]);
@@ -1,2 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,85957,e=>{"use strict";var t=e.i(43476),n=e.i(71645),o=e.i(26005),i=e.i(99883),r=e.i(18566),l=e.i(40996),s=e.i(19821),a=e.i(64745),d=e.i(7837),c=e.i(2776);e.i(47716);var h=e.i(36534),p=e.i(77899),u=e.i(17983),f=e.i(43079),g=e.i(52048),x=e.i(47560),y=e.i(94657),m=e.i(7214),b=e.i(89154),v=e.i(82044),j=e.i(39160);let k=Object.freeze({live:!1,spread:1,pull:1,links:1}),S={fontSize:10.5,color:"#667",lineHeight:1.45,marginTop:6},w=[{key:"spread",label:"Spread",min:.2,max:4,step:.05,tip:"How hard bubbles push each other apart."},{key:"pull",label:"Pull to their group",min:0,max:4,step:.05,tip:"How hard each bubble keeps to its sector. At 0 they find their own shape."},{key:"links",label:"Pull along lines",min:0,max:6,step:.05,tip:"How hard two bubbles joined by a line pull together."}];function M({colourBy:e,onColourBy:n,physics:o,onPhysics:i,heatHint:r}){return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{style:H,children:"Colour"}),(0,t.jsx)(_,{value:e,onChange:n,options:[["sector","Sector"],["heat","Heat"]]}),"heat"===e&&(0,t.jsx)("div",{style:S,children:r}),(0,t.jsx)("div",{style:H,children:"Physics"}),(0,t.jsx)(_,{value:o.live?"on":"off",onChange:e=>i({...o,live:"on"===e}),options:[["off","Still"],["on","Live"]]}),o.live?(0,t.jsxs)("div",{style:{marginTop:8},children:[w.map(e=>(0,t.jsxs)("label",{title:e.tip,style:{display:"block",marginBottom:6},children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",fontSize:11,color:"#aab"},children:[(0,t.jsx)("span",{children:e.label}),(0,t.jsxs)("span",{style:{color:o[e.key]===k[e.key]?"#556":"#cfe6f7",fontVariantNumeric:"tabular-nums"},children:[o[e.key].toFixed(2),"×"]})]}),(0,t.jsx)("input",{type:"range",min:e.min,max:e.max,step:e.step,value:o[e.key],onChange:t=>i({...o,[e.key]:Number(t.target.value)}),style:{width:"100%",accentColor:"#3498DB"}})]},e.key)),(0,t.jsx)("div",{style:S,children:"Drag a bubble and the ones joined to it follow. Click still opens it."}),(0,t.jsx)("button",{type:"button",onClick:()=>i({...k,live:!0}),style:{marginTop:6,padding:"4px 10px",borderRadius:6,fontSize:10.5,cursor:"pointer",border:"1px solid rgba(255,255,255,0.1)",background:"rgba(255,255,255,0.04)",color:"#aab"},children:"Reset the forces"})]}):(0,t.jsx)("div",{style:S,children:"Live lets the bubbles move: drag them, and change the forces that lay the map out."})]})}function z(e,t){let[,o]=(0,n.useState)(0),i=(0,n.useRef)(null),r=(0,n.useRef)(!1);return(0,n.useEffect)(()=>{if(!t.live||!e.nodes.length)return;let n=0,r=(0,f.forceSimulation)(e.nodes).force("x",(0,g.forceX)(e=>e.ax).strength(.12*t.pull)).force("y",(0,x.forceY)(e=>e.ay).strength(.12*t.pull)).force("collide",(0,h.forceCollide)(e=>e.r+3).iterations(2)).force("charge",(0,u.forceManyBody)().strength(-25*t.spread)).force("link",(0,p.forceLink)(e.edges).id(e=>e.id).strength(e=>(e.k??.1)*t.links).distance(60*Math.sqrt(t.spread))).alpha(.15).on("tick",()=>{n||(n=requestAnimationFrame(()=>{n=0,o(e=>e+1)}))});return i.current=r,()=>{r.stop(),cancelAnimationFrame(n),i.current=null}},[e,t.live,t.spread,t.pull,t.links]),{drag:t.live?(e,t)=>{let n=i.current;if(!n)return;let o=e.currentTarget.ownerSVGElement,l=o?.getScreenCTM();if(!l)return;let s=l.inverse(),a=e=>{let t=o.createSVGPoint();return t.x=e.clientX,t.y=e.clientY,t.matrixTransform(s)},d={x:e.clientX,y:e.clientY};r.current=!1;let c=e=>{Math.hypot(e.clientX-d.x,e.clientY-d.y)>3&&(r.current=!0);let n=a(e);t.fx=n.x,t.fy=n.y},h=()=>{t.fx=null,t.fy=null,n.alphaTarget(0),window.removeEventListener("pointermove",c),window.removeEventListener("pointerup",h)},p=a(e);t.fx=p.x,t.fy=p.y,n.alphaTarget(.08).restart(),window.addEventListener("pointermove",c),window.addEventListener("pointerup",h)}:null,clicked:()=>!r.current||(r.current=!1,!1)}}function C({id:e}){return(0,t.jsx)("defs",{children:[0,1,2,3,4,5].map(n=>(0,t.jsxs)("radialGradient",{id:`${e}-${n}`,children:[(0,t.jsx)("stop",{offset:"0",stopColor:(0,j.heatColour)(n/5),stopOpacity:.16+.07*n}),(0,t.jsx)("stop",{offset:"1",stopColor:(0,j.heatColour)(n/5),stopOpacity:0})]},n))})}function B({id:e,nodes:n,heat:o}){return(0,t.jsx)("g",{style:{mixBlendMode:"screen",pointerEvents:"none"},children:n.filter(e=>o(e)>=.5).map(n=>(0,t.jsx)("circle",{cx:n.x,cy:n.y,r:1.9*n.r+18,fill:`url(#${e}-${Math.round(5*o(n))})`},n.id))})}var F=e.i(44902);let $=[...b.INDUSTRIES,b.UNKNOWN_INDUSTRY],R=e=>Number(e||0).toLocaleString("en-US"),T={value:{label:"Cluster value",of:e=>e.value,k:2},size:{label:"Cluster size",of:e=>e.size,k:2.6},s:{label:"S tier inside",of:e=>e.S,k:6}};function I({d1:e=[],d2:o=[],top:i=null,look:l=null,colourBy:s="sector",physics:a=k}){let d=(0,r.useRouter)(),[c,h]=(0,n.useState)("value"),[p,u]=(0,n.useState)("scanned"),[f,g]=(0,n.useState)(()=>(0,F.makeGrid)([1])),[x,y]=(0,n.useState)(()=>new Set),[j,S]=(0,n.useState)(""),[w,M]=(0,n.useState)(!0),[z,C]=(0,n.useState)("top"),B=(0,n.useMemo)(()=>(function(e=[],t=[],{maxLinks:n=400}={}){let o=new Set((e||[]).map(e=>e.id)),i=new Map,r=new Map;for(let e of t||[]){let t=e?.source_connection_id;if(null==t||!o.has(t))continue;let n=(0,m.keyFor)(e),l=i.get(t);l||i.set(t,l=new Map),l.has(n)||l.set(n,e);let s=r.get(n);s||r.set(n,s=new Set),s.add(t)}let l=(e||[]).map(e=>{let t=i.get(e.id),n=0,o=0,l=0;if(t)for(let[e,i]of t)"S"===i.tier?n++:"A"===i.tier&&o++,r.get(e)?.size===1&&l++;let s=t?t.size:0;return{person:e,id:e.id,key:(0,m.keyFor)(e),size:s,S:n,A:o,value:(({size:e=0,S:t=0,A:n=0}={})=>e+2*t+n)({size:s,S:n,A:o}),only:l,share:s?l/s:0}}),s=new Map;for(let e of r.values()){if(e.size<2||e.size>8)continue;let t=[...e].sort();for(let e=0;e<t.length;e++)for(let n=e+1;n<t.length;n++){let o=`${t[e]}\u0000${t[n]}`;s.set(o,(s.get(o)||0)+1)}}let a=[...s].map(([e,t])=>{let[n,o]=e.split("\0");return{a:n,b:o,shared:t}}).sort((e,t)=>t.shared-e.shared||(e.a<t.a?-1:1)).slice(0,n),d=l.filter(e=>e.size>0).map(e=>e.value).sort((e,t)=>e-t);return{people:l,links:a,rank:e=>{let t=l.find(t=>t.id===e);if(!t||!t.size||d.length<2)return null;let n=0;for(;n<d.length&&d[n]<t.value;)n++;return n/(d.length-1)}}})(e,o),[e,o]),D=(0,n.useMemo)(()=>(0,F.gridCounts)({1:B.people.filter(e=>"all"===p||e.size>0).map(e=>e.person)}),[B,p]),A=(0,n.useMemo)(()=>{let e=new Map;for(let t of B.people)e.set(t.id,(0,b.industryOf)((0,b.companyOf)(t.person),t.person.headline));return e},[B]),O=(0,n.useMemo)(()=>B.people.filter(e=>e.size>0).length,[B]),L=(0,n.useMemo)(()=>{let e=j.trim().toLowerCase();return B.people.filter(t=>("all"===p||t.size>0)&&(0,F.shows)(f,t.person.tier,1)&&!x.has(A.get(t.id).key)&&(!e||String(t.person.name||"").toLowerCase().includes(e))).sort((e,t)=>t.value-e.value||t.size-e.size)},[B,p,f,x,j,A]),N=(0,n.useMemo)(()=>{let e=new Map;for(let t of B.people){if("all"!==p&&!t.size)continue;let n=A.get(t.id).key;e.set(n,(e.get(n)||0)+1)}return $.filter(t=>e.get(t.key)).map(t=>({...t,count:e.get(t.key)})).sort((e,t)=>t.count-e.count)},[B,p,A]);return(0,t.jsxs)("div",{style:{flex:1,minHeight:0,display:"flex"},children:[(0,t.jsxs)(U,{open:w,onToggle:()=>M(e=>!e),children:[i,(0,t.jsx)("div",{style:H,children:"Filter"}),(0,t.jsx)("input",{value:j,onChange:e=>S(e.target.value),placeholder:"Find a person",style:{width:"100%",boxSizing:"border-box",padding:"6px 10px",borderRadius:7,border:"1px solid rgba(255,255,255,0.1)",background:"rgba(255,255,255,0.05)",color:"#fff",fontSize:13,marginBottom:8}}),(0,t.jsx)("div",{style:{display:"flex",flexDirection:"column",gap:8},children:(0,t.jsx)(_,{value:p,onChange:u,options:[["scanned",`Scanned (${R(O)})`],["all",`All (${R(B.people.length)})`]]})}),(0,t.jsx)("div",{style:{marginTop:12},children:(0,t.jsx)(v.TierGrid,{grid:f,counts:D,onChange:g,mode:"paths"})}),(0,t.jsx)("div",{style:H,children:"Sectors"}),(0,t.jsx)("div",{style:{display:"flex",gap:6,flexWrap:"wrap"},children:N.map(e=>{let n=x.has(e.key);return(0,t.jsxs)("button",{title:n?"Show on the map":"Hide from the map",onClick:()=>y(t=>{let n=new Set(t);return n.has(e.key)?n.delete(e.key):n.add(e.key),n}),style:{display:"inline-flex",alignItems:"center",gap:6,padding:"3px 10px",borderRadius:14,cursor:"pointer",border:`1px solid ${e.color}55`,background:n?"transparent":`${e.color}14`,color:"#cfd8d8",fontSize:11.5,opacity:n?.4:1},children:[(0,t.jsx)("span",{style:{width:7,height:7,borderRadius:"50%",background:e.color}}),e.label," ",(0,t.jsx)("span",{style:{color:"#778"},children:R(e.count)})]},e.key)})}),(0,t.jsx)("div",{style:{fontSize:10.5,color:"#667",marginTop:6},children:"Inferred from where each connection works."}),(0,t.jsx)("div",{style:H,children:"Read the map"}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",marginBottom:4},children:"Bubble size"}),(0,t.jsx)(_,{value:c,onChange:h,options:Object.entries(T).map(([e,t])=>[e,t.label])}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",margin:"10px 0 4px"},children:"Names"}),(0,t.jsx)(_,{value:z,onChange:C,options:[["top","Biggest"],["all","All"],["none","None"]]}),l]}),(0,t.jsx)("div",{style:{flex:1,minWidth:0,display:"flex",flexDirection:"column",paddingTop:40,boxSizing:"border-box"},children:(0,t.jsx)(W,{people:L,links:B.links,sizeBy:T[c],sectorOf:A,rank:B.rank,names:z,colourBy:s,physics:a,onOpen:e=>d.push(`/?chain=${encodeURIComponent(e)}`)})})]})}function W({people:e,links:o,sizeBy:i,sectorOf:r,rank:l,onOpen:s,names:a="top",colourBy:d="sector",physics:c=k}){let y=(0,n.useRef)(null),{w:m,h:v}=P(y),[S,w]=(0,n.useState)(null),M=(0,n.useMemo)(()=>{let t=e.slice(0,400),n=new Set(t.map(e=>e.id)),l=[...new Set(t.map(e=>r.get(e.id).key))],s=new Map(l.map((e,t)=>{let n=t/Math.max(1,l.length)*Math.PI*2-Math.PI/2;return[e,{x:260*Math.cos(n),y:260*Math.sin(n)}]})),a=t.map(e=>{let t=s.get(r.get(e.id).key);return{id:e.id,p:e,sector:r.get(e.id),r:e.size?4+Math.sqrt(Math.max(0,i.of(e)))*i.k:3,x:t.x+(E(String(e.id))-.5)*40,y:t.y+(E(`${e.id}#`)-.5)*40,ax:t.x,ay:t.y}}),d=o.filter(e=>n.has(e.a)&&n.has(e.b)).map(e=>({source:e.a,target:e.b,weight:e.shared,k:Math.min(.25,.02*e.shared)})),c=(0,f.forceSimulation)(a).force("x",(0,g.forceX)(e=>s.get(e.sector.key).x).strength(.12)).force("y",(0,x.forceY)(e=>s.get(e.sector.key).y).strength(.12)).force("collide",(0,h.forceCollide)(e=>e.r+3)).force("charge",(0,u.forceManyBody)().strength(-25)).force("link",(0,p.forceLink)(d).id(e=>e.id).strength(e=>e.k).distance(60)).stop();for(let e=0;e<320;e++)c.tick();let y=a.flatMap(e=>[e.x-e.r,e.x+e.r]),m=a.flatMap(e=>[e.y-e.r,e.y+e.r]),v=a.length?{x:Math.min(...y)-60,y:Math.min(...m)-40,w:Math.max(...y)-Math.min(...y)+120,h:Math.max(...m)-Math.min(...m)+80}:{x:-300,y:-300,w:600,h:600},j=l.map(e=>{let t=a.filter(t=>t.sector.key===e),n=t.reduce((e,t)=>e+t.x,0)/t.length,o=t.reduce((e,t)=>e+t.y,0)/t.length,i=Math.hypot(n,o)||1,r=n/i,l=o/i,s=Math.max(...t.map(e=>(e.x-n)*r+(e.y-o)*l+e.r));return{key:e,x:n+r*(s+16),y:o+l*(s+16)+4,anchor:r>.35?"start":r<-.35?"end":"middle",ind:(0,b.industryByKey)(e)}});for(let e of j){let t=7.5*e.ind.label.length,n="start"===e.anchor?e.x:"end"===e.anchor?e.x-t:e.x-t/2,o=Math.max(v.x+v.w,n+t+10);v.x=Math.min(v.x,n-10),v.w=o-v.x;let i=Math.max(v.y+v.h,e.y+12);v.y=Math.min(v.y,e.y-18),v.h=i-v.y}return v.h+=Math.max(60,.1*v.h),{nodes:a,edges:d,box:v,labels:j,cut:Math.max(0,e.length-t.length)}},[e,o,i,r]),{drag:F,clicked:$}=z(M,c),T=(0,n.useMemo)(()=>(0,j.heatBy)(M.nodes,e=>(function({size:e=0,S:t=0,A:n=0}={}){return e?(3*t+2*n+Math.max(0,e-t-n))/e:-1})(e.p)),[M]),I="heat"===d,A=S?M.nodes.find(e=>e.id===S):null,O=(0,n.useMemo)(()=>{if(!S)return null;let e=new Set([S]);for(let t of M.edges)t.source.id===S&&e.add(t.target.id),t.target.id===S&&e.add(t.source.id);return e},[S,M]),L=(0,n.useMemo)(()=>new Set("none"===a?[]:M.nodes.filter(e=>e.p.size).slice(0,"all"===a?1/0:28).map(e=>e.id)),[M,a]),N=m&&v?Math.min(m/M.box.w,v/M.box.h):1,_=(m-M.box.w*N)/2,U=(v-M.box.h*N)/2;return(0,t.jsxs)("div",{ref:y,style:{flex:1,minHeight:360,position:"relative"},children:[m>0&&(0,t.jsxs)("svg",{width:m,height:v,viewBox:`${M.box.x} ${M.box.y} ${M.box.w} ${M.box.h}`,style:{display:"block",touchAction:F?"none":void 0},children:[I&&(0,t.jsx)(C,{id:"pplheat"}),I&&(0,t.jsx)(B,{id:"pplheat",nodes:M.nodes.filter(e=>e.p.size),heat:T}),(0,t.jsx)("g",{children:M.edges.map((e,n)=>{let o=S&&(e.source.id===S||e.target.id===S);return(0,t.jsx)("line",{x1:e.source.x,y1:e.source.y,x2:e.target.x,y2:e.target.y,stroke:o?"#FF6B35":"#8fa6c0",strokeOpacity:o?.8:S?.03:.09,strokeWidth:o?1+Math.log2(1+e.weight):.4+.4*Math.log2(1+e.weight)},n)})}),M.labels.map(e=>(0,t.jsx)("text",{x:e.x,y:e.y,textAnchor:e.anchor,fontSize:13,fontWeight:800,fill:e.ind.color,opacity:.85,children:e.ind.label},e.key)),M.nodes.map(e=>{let{p:n}=e,o=O&&!O.has(e.id);return(0,t.jsxs)("g",{transform:`translate(${e.x},${e.y})`,style:{cursor:F?"grab":n.size?"pointer":"default"},opacity:o?.18:1,onMouseEnter:()=>w(e.id),onMouseLeave:()=>w(null),onPointerDown:F?t=>F(t,e):void 0,onClick:()=>{$()&&n.size&&s(e.id)},children:[(0,t.jsx)("circle",{r:e.r,fill:n.size?I?(0,j.heatColour)(T(e)):e.sector.color:"#3a3f55",fillOpacity:n.size?.92:.6,stroke:S===e.id?"#fff":n.S?"#FFD700":"rgba(0,0,0,0.35)",strokeWidth:S===e.id?2.5:n.S?Math.min(4,1+n.S/40):.6}),n.size>0&&n.only>0&&(0,t.jsx)("circle",{r:e.r*Math.sqrt(n.share)*.85,fill:"#fff",fillOpacity:.3}),(L.has(e.id)||S===e.id)&&(0,t.jsx)("text",{y:e.r+11,textAnchor:"middle",fontSize:10,fill:"#e6edf0",style:{pointerEvents:"none"},paintOrder:"stroke",stroke:"rgba(0,0,0,0.6)",strokeWidth:3,children:n.person.name})]},e.id)})]}),A&&(0,t.jsx)(D,{n:A,at:{x:_+(A.x-M.box.x)*N,y:U+(A.y-M.box.y)*N,r:A.r*N},w:m,rank:l(A.id)}),(0,t.jsxs)("div",{style:{position:"absolute",left:12,bottom:10,fontSize:11,color:"#778",lineHeight:1.6,pointerEvents:"none"},children:["Bubble = one of your connections, sized by ",i.label.toLowerCase()," (value: S tier counts 3, A tier 2, everyone else 1)",I?"; colour = how strong their cluster is, person for person, cold to white hot":"","; white centre = the share of their cluster only they can open; gold ring = S tier inside.",(0,t.jsx)("br",{}),"A line = two of your connections whose clusters share people. Grey = not scanned yet.",M.cut?` Showing the 400 largest of ${R(M.cut+400)}.`:""]})]})}function D({n:e,at:n,w:o,rank:i}){let{p:r}=e,l=n.x+n.r+14+280>o?Math.max(8,n.x-n.r-14-280):n.x+n.r+14,s=[r.person.role,(0,b.companyOf)(r.person)].filter(Boolean).join(" @ ")||r.person.headline||"";return(0,t.jsxs)("div",{style:{position:"absolute",left:l,top:Math.max(8,n.y-70),width:280,pointerEvents:"none",zIndex:5,padding:"12px 14px",borderRadius:12,background:"rgba(8,10,22,0.96)",border:`1px solid ${e.sector.color}99`,boxShadow:"0 12px 40px rgba(0,0,0,0.6)",fontSize:12,lineHeight:1.45,color:"#ddd"},children:[(0,t.jsx)("div",{style:{fontSize:15,fontWeight:800,color:"#fff"},children:r.person.name}),(0,t.jsxs)("div",{style:{fontSize:11.5,color:"#8a8fa8"},children:[s,r.person.tier?` \xb7 ${r.person.tier}-tier`:""," · ",e.sector.label]}),r.size?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:"6px 10px",margin:"10px 0 8px"},children:[(0,t.jsx)(A,{value:R(r.value),label:"cluster value",color:"#FFD700"}),(0,t.jsx)(A,{value:R(r.size),label:"people in their cluster"}),(0,t.jsx)(A,{value:`${R(r.S)} S \xb7 ${R(r.A)} A`,label:"the strongest among them",color:"#FFD700"}),(0,t.jsx)(A,{value:`${R(r.only)} (${Math.round(100*r.share)}%)`,label:"only through them",color:"#00E5FF"})]}),(0,t.jsxs)("div",{style:{fontSize:11.5,color:"#aab"},children:[1===i?"The most valuable cluster you’ve scanned. ":null!=i?`Worth more than ${Math.round(100*i)}% of the clusters you’ve scanned. `:"","Click to open it in Bridge Chains."]})]}):(0,t.jsx)("div",{style:{fontSize:11.5,color:"#aab",marginTop:8},children:"Their circle isn’t scanned yet, so there’s no cluster to size."})]})}function A({value:e,label:n,color:o="#fff"}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{style:{fontSize:15,fontWeight:800,color:o},children:e}),(0,t.jsx)("div",{style:{fontSize:10.5,color:"#8a8fa8"},children:n})]})}let O={S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"},L="1px solid rgba(255,255,255,0.1)",N=[...b.INDUSTRIES,b.UNKNOWN_INDUSTRY];function E(e){let t=0x811c9dc5;for(let n=0;n<e.length;n++)t=Math.imul(t^e.charCodeAt(n),0x1000193);return(t>>>0)%1e3/1e3}function _({value:e,onChange:n,options:o}){return(0,t.jsx)("div",{style:{display:"flex",borderRadius:7,overflow:"hidden",border:L},children:o.map(([o,i])=>(0,t.jsx)("button",{onClick:()=>n(o),style:{padding:"5px 10px",fontSize:11.5,fontWeight:600,border:"none",cursor:"pointer",background:e===o?"rgba(52,152,219,0.25)":"transparent",color:e===o?"#cfe6f7":"#8b9a9a"},children:i},o))})}function P(e){let[t,o]=(0,n.useState)({w:0,h:0});return(0,n.useEffect)(()=>{let t=e.current;if(!t)return;let n=()=>{let e=t.getBoundingClientRect();o(t=>t.w===Math.round(e.width)&&t.h===Math.round(e.height)?t:{w:Math.round(e.width),h:Math.round(e.height)})};n();let i=new ResizeObserver(n);return i.observe(t),()=>i.disconnect()},[e]),t}function U({open:e,onToggle:n,children:o}){return e?(0,t.jsxs)("aside",{style:{width:300,flexShrink:0,height:"100%",overflowY:"auto",boxSizing:"border-box",padding:"16px 14px",borderRight:"1px solid rgba(52,152,219,0.15)",background:"rgba(10,15,30,0.65)",fontSize:13},children:[(0,t.jsxs)("button",{type:"button",onClick:n,style:{display:"flex",alignItems:"center",gap:6,width:"100%",marginBottom:14,padding:"6px 12px",borderRadius:6,cursor:"pointer",background:"rgba(255,255,255,0.06)",border:"1px solid rgba(255,255,255,0.1)",color:"#aaa",fontSize:12,fontWeight:600},children:[(0,t.jsx)("span",{style:{fontSize:16},children:"›"})," Close"]}),o]}):(0,t.jsxs)("button",{type:"button",onClick:n,style:{position:"fixed",left:16,top:140,zIndex:30,cursor:"pointer",height:36,borderRadius:18,padding:"0 14px 0 10px",display:"flex",alignItems:"center",gap:6,background:"rgba(52,152,219,0.15)",border:"2px solid rgba(52,152,219,0.5)",color:"#3498DB",fontWeight:700,boxShadow:"0 0 12px rgba(52,152,219,0.3)",backdropFilter:"blur(8px)"},children:[(0,t.jsx)("span",{style:{fontSize:18},children:"›"}),(0,t.jsx)("span",{style:{fontSize:11,fontWeight:600},children:"Filters"})]})}let H={fontSize:9,fontWeight:700,color:"#555",letterSpacing:1,margin:"14px 0 6px",textTransform:"uppercase"};function Y(e,t){return(!t.grid||!!(0,F.shows)(t.grid,e.tier,Number(e.degree)||1))&&("senior"!==t.seniority||!!(0,b.isSenior)(e.headline))&&("csuite"!==t.seniority||!((0,b.getSeniority)(e.headline).level<6))}function G({show:e,onShow:n}){return(0,t.jsxs)("div",{style:{marginBottom:6},children:[(0,t.jsx)("div",{style:{...H,marginTop:0},children:"Bubbles are"}),(0,t.jsx)(_,{value:e,onChange:n,options:[["companies","Companies"],["people","People"]]})]})}function X({d1:e=[],d2:o=[],d3:i=[],initialShow:r="companies",onOpenCompany:l}){let[s,a]=(0,n.useState)(r),[d,c]=(0,n.useState)(()=>({seniority:"all",grid:(0,F.makeGrid)([1,2,3])})),[h,p]=(0,n.useState)("sector"),[u,f]=(0,n.useState)(k),[g,x]=(0,n.useState)(()=>new Set),[y,m]=(0,n.useState)(""),[v,j]=(0,n.useState)(null),[S,w]=(0,n.useState)(!0),[z,C]=(0,n.useState)("people"),[B,$]=(0,n.useState)("top"),R=(0,n.useMemo)(()=>[...e,...o,...i],[e,o,i]),T=(0,n.useMemo)(()=>(0,F.gridCounts)({1:e,2:o,3:i}),[e,o,i]),W=(0,n.useMemo)(()=>(0,b.buildCompanyIndex)(R),[R]),D=(0,n.useMemo)(()=>(0,b.companyLinks)(e,o),[e,o]),A=(0,n.useMemo)(()=>{let e=y.trim().toLowerCase(),t=[];for(let n of W.values()){if(g.has(n.industry.key)||e&&!n.name.toLowerCase().includes(e))continue;let o=n.people.filter(e=>Y(e,d));o.length&&t.push({...n,shown:o})}return t.sort((e,t)=>t.shown.length-e.shown.length)},[W,d,g,y]),O=(0,n.useMemo)(()=>{let e=new Map(N.map(e=>[e.key,{...e,people:[],companies:new Map}])),t=new Set;for(let n of R){let o=n.profile_url||`id:${n.id}`;if(t.has(o)||(t.add(o),!Y(n,d)))continue;let i=(0,b.companyOf)(n),r=i?W.get(i)?.industry||(0,b.industryOf)(i,n.headline):(0,b.industryOf)(null,n.headline),l=e.get(r.key);l.people.push(n),i&&l.companies.set(i,(l.companies.get(i)||0)+1)}return[...e.values()].filter(e=>e.people.length).sort((e,t)=>t.people.length-e.people.length)},[R,W,d]),L=v?.kind==="company"?W.get(v.key):v?.kind==="industry"?O.find(e=>e.key===v.key):null,E=e=>(0,t.jsx)(M,{colourBy:h,onColourBy:p,physics:u,onPhysics:f,heatHint:e});return"people"===s?(0,t.jsx)(I,{d1:e,d2:o,top:(0,t.jsx)(G,{show:s,onShow:a}),colourBy:h,physics:u,look:E("How strong each cluster is, person for person (S counts 3, A 2, the rest 1): the hotter, the stronger. Size is still how big it is.")}):(0,t.jsxs)("div",{style:{display:"flex",flex:1,minHeight:0},children:[(0,t.jsxs)(U,{open:S,onToggle:()=>w(e=>!e),children:[(0,t.jsx)(G,{show:s,onShow:a}),(0,t.jsx)(q,{filters:d,setFilters:c,counts:T,query:y,setQuery:m,industries:O,hidden:g,setHidden:x,onIndustry:e=>j({kind:"industry",key:e})}),(0,t.jsx)("div",{style:H,children:"Read the map"}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",marginBottom:4},children:"Bubble size"}),(0,t.jsx)(_,{value:z,onChange:C,options:[["people","Your people"],["sa","S & A there"],["known","You know"]]}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",margin:"10px 0 4px"},children:"Names"}),(0,t.jsx)(_,{value:B,onChange:$,options:[["top","Biggest"],["all","All"],["none","None"]]}),E("How strong your people at each company are: the average power score of the five strongest. The hotter, the stronger; size is still how many.")]}),(0,t.jsx)("div",{style:{flex:1,minWidth:0,display:"flex",flexDirection:"column",paddingTop:40,boxSizing:"border-box"},children:(0,t.jsx)(K,{companies:A,links:D,focus:v,sizeBy:z,labels:B,colourBy:h,physics:u,onCompany:e=>j({kind:"company",key:e}),onIndustry:e=>j({kind:"industry",key:e}),onClear:()=>j(null)})}),L&&(0,t.jsx)(Z,{focus:v,data:L,index:W,links:D,d1:e,d2:o,filters:d,onClose:()=>j(null),onCompany:e=>j({kind:"company",key:e}),onIndustry:e=>j({kind:"industry",key:e}),onOpenCompany:l})]})}function q({filters:e,setFilters:n,counts:o,query:i,setQuery:r,industries:l,hidden:s,setHidden:a,onIndustry:d}){let c=(e,t)=>n(n=>({...n,[e]:t}));return(0,t.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:8},children:[(0,t.jsx)("div",{style:H,children:"Filter"}),(0,t.jsx)("input",{value:i,onChange:e=>r(e.target.value),placeholder:"Find a company",style:{padding:"6px 10px",borderRadius:7,border:L,background:"rgba(255,255,255,0.05)",color:"#fff",fontSize:13,width:"100%",boxSizing:"border-box"}}),(0,t.jsx)(v.TierGrid,{grid:e.grid,counts:o,onChange:e=>c("grid",e),mode:"paths"}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",marginTop:-10},children:"Level"}),(0,t.jsx)(_,{value:e.seniority,onChange:e=>c("seniority",e),options:[["all","Any level"],["senior","Director+"],["csuite","C-suite"]]}),(0,t.jsx)("div",{style:H,children:"Industries"}),(0,t.jsxs)("div",{style:{display:"flex",gap:6,flexWrap:"wrap"},children:[l.map(e=>{let n=s.has(e.key);return(0,t.jsxs)("span",{style:{display:"inline-flex",borderRadius:14,border:`1px solid ${e.color}55`,overflow:"hidden",opacity:n?.4:1},children:[(0,t.jsx)("button",{title:n?"Show on the map":"Hide from the map",onClick:()=>a(t=>{let n=new Set(t);return n.has(e.key)?n.delete(e.key):n.add(e.key),n}),style:{padding:"3px 7px",border:"none",background:`${e.color}22`,cursor:"pointer",color:e.color,fontSize:11},children:"●"}),(0,t.jsxs)("button",{onClick:()=>d(e.key),title:"Analyse this industry",style:{padding:"3px 9px 3px 5px",border:"none",background:"transparent",cursor:"pointer",color:"#cfd8d8",fontSize:11.5},children:[e.label," ",(0,t.jsx)("span",{style:{color:"#778"},children:e.people.length})]})]},e.key)}),(0,t.jsx)("span",{style:{fontSize:11,color:"#667",alignSelf:"center"},children:"Inferred from companies and headlines. ● hides one; its name opens it."})]})]})}function K({companies:e,links:o,focus:i,onCompany:r,onIndustry:l,onClear:s,sizeBy:a="people",labels:d="top",colourBy:c="sector",physics:y=k}){let v=(0,n.useRef)(null),{w:S,h:w}=P(v),[M,F]=(0,n.useState)(null),$=(0,n.useMemo)(()=>{let t=e.slice(0,140),n=new Set(t.map(e=>e.name)),i=[...new Set(t.map(e=>e.industry.key))],r=new Map(i.map((e,t)=>{let n=t/Math.max(1,i.length)*Math.PI*2-Math.PI/2;return[e,{x:260*Math.cos(n),y:260*Math.sin(n)}]})),l=t.map(e=>({id:e.name,co:e,r:4+Math.sqrt("sa"===a?e.shown.filter(e=>"S"===e.tier||"A"===e.tier).length:"known"===a?e.d1:e.shown.length)*("people"===a?3.4:5),x:r.get(e.industry.key).x+(E(e.name)-.5)*40,y:r.get(e.industry.key).y+(E(e.name+"#")-.5)*40,ax:r.get(e.industry.key).x,ay:r.get(e.industry.key).y})),s=o.filter(e=>n.has(e.a)&&n.has(e.b)).map(e=>({source:e.a,target:e.b,weight:e.weight,via:e.via.size,k:Math.min(.25,.03*e.weight)})),d=(0,f.forceSimulation)(l).force("x",(0,g.forceX)(e=>r.get(e.co.industry.key).x).strength(.12)).force("y",(0,x.forceY)(e=>r.get(e.co.industry.key).y).strength(.12)).force("collide",(0,h.forceCollide)(e=>e.r+3)).force("charge",(0,u.forceManyBody)().strength(-25)).force("link",(0,p.forceLink)(s).id(e=>e.id).strength(e=>e.k).distance(60)).stop();for(let e=0;e<320;e++)d.tick();let c=l.flatMap(e=>[e.x-e.r,e.x+e.r]),y=l.flatMap(e=>[e.y-e.r,e.y+e.r]),m=l.length?{x:Math.min(...c)-60,y:Math.min(...y)-40,w:Math.max(...c)-Math.min(...c)+120,h:Math.max(...y)-Math.min(...y)+80}:{x:-300,y:-300,w:600,h:600},v=i.map(e=>{let t=l.filter(t=>t.co.industry.key===e),n=t.reduce((e,t)=>e+t.x,0)/t.length,o=t.reduce((e,t)=>e+t.y,0)/t.length,i=Math.hypot(n,o)||1,r=n/i,s=o/i,a=Math.max(...t.map(e=>(e.x-n)*r+(e.y-o)*s+e.r));return{key:e,x:n+r*(a+16),y:o+s*(a+16)+4,anchor:r>.35?"start":r<-.35?"end":"middle",ind:(0,b.industryByKey)(e)}});for(let e of v){let t=7.5*e.ind.label.length,n="start"===e.anchor?e.x:"end"===e.anchor?e.x-t:e.x-t/2,o=Math.max(m.x+m.w,n+t+10);m.x=Math.min(m.x,n-10),m.w=o-m.x;let i=Math.max(m.y+m.h,e.y+12);m.y=Math.min(m.y,e.y-18),m.h=i-m.y}return m.h+=Math.max(60,.1*m.h),{nodes:l,edges:s,box:m,labels:v,cut:Math.max(0,e.length-t.length)}},[e,o,a]),{drag:R,clicked:T}=z($,y),I=(0,n.useMemo)(()=>{let e=new Map($.nodes.map(e=>[e.id,function(e=[]){let t=e.map(m.score).sort((e,t)=>t-e).slice(0,5);return t.length?t.reduce((e,t)=>e+t,0)/t.length:0}(e.co.shown)]));return(0,j.heatBy)($.nodes,t=>e.get(t.id))},[$]),W="heat"===c,D=M||(i?.kind==="company"?i.key:null),A=i?.kind==="industry"?i.key:null,L=(0,n.useMemo)(()=>{if(!D)return null;let e=new Set([D]);for(let t of $.edges)t.source.id===D&&e.add(t.target.id),t.target.id===D&&e.add(t.source.id);return e},[D,$]),N=(0,n.useMemo)(()=>new Set("none"===d?[]:("all"===d?$.nodes:[...$.nodes].sort((e,t)=>t.r-e.r).slice(0,28)).map(e=>e.id)),[$,d]);return(0,t.jsxs)("div",{ref:v,style:{flex:1,minHeight:360,position:"relative"},onClick:s,children:[S>0&&(0,t.jsxs)("svg",{width:S,height:w,viewBox:`${$.box.x} ${$.box.y} ${$.box.w} ${$.box.h}`,style:{display:"block",touchAction:R?"none":void 0},children:[W&&(0,t.jsx)(C,{id:"coheat"}),W&&(0,t.jsx)(B,{id:"coheat",nodes:$.nodes,heat:I}),(0,t.jsx)("g",{children:$.edges.map((e,n)=>{let o=D&&(e.source.id===D||e.target.id===D);return(0,t.jsx)("line",{x1:e.source.x,y1:e.source.y,x2:e.target.x,y2:e.target.y,stroke:o?"#FF6B35":"#8fa6c0",strokeOpacity:o?.8:D?.04:.14,strokeWidth:o?1+Math.log2(1+e.weight):.4+.5*Math.log2(1+e.weight)},n)})}),$.labels.map(e=>(0,t.jsx)("text",{x:e.x,y:e.y,textAnchor:e.anchor,fontSize:13,fontWeight:800,fill:e.ind.color,opacity:A&&A!==e.key?.25:.85,style:{cursor:"pointer"},onClick:t=>{t.stopPropagation(),l(e.key)},children:e.ind.label},e.key)),$.nodes.map(e=>{let n=L&&!L.has(e.id)||A&&e.co.industry.key!==A,o=i?.kind==="company"&&i.key===e.id;return(0,t.jsxs)("g",{transform:`translate(${e.x},${e.y})`,style:{cursor:R?"grab":"pointer"},opacity:n?.18:1,onMouseEnter:()=>F(e.id),onMouseLeave:()=>F(null),onPointerDown:R?t=>R(t,e):void 0,onClick:t=>{t.stopPropagation(),T()&&r(e.id)},children:[(0,t.jsx)("title",{children:`${e.co.name} \xb7 ${e.co.industry.label} (inferred)
2
- ${e.co.d1} you know \xb7 ${e.co.d2} reachable${e.co.d3?` \xb7 ${e.co.d3} further`:""}`}),(0,t.jsx)("circle",{r:e.r,fill:W?(0,j.heatColour)(I(e)):e.co.industry.color,fillOpacity:W?.9:.75,stroke:o?"#fff":e.co.S?O.S:"rgba(0,0,0,0.35)",strokeWidth:o?2.5:e.co.S?1.5:.6}),e.co.d1>0&&(0,t.jsx)("circle",{r:e.r*Math.sqrt(e.co.d1/Math.max(1,e.co.people.length)),fill:"#fff",fillOpacity:.35}),(N.has(e.id)||e.id===D||o)&&(0,t.jsx)("text",{y:e.r+11,textAnchor:"middle",fontSize:10,fill:"#e6edf0",style:{pointerEvents:"none"},children:e.co.name})]},e.id)})]}),(0,t.jsxs)("div",{style:{position:"absolute",left:12,bottom:10,fontSize:11,color:"#778",lineHeight:1.6,pointerEvents:"none"},children:["Bubble = a company, sized by your people there; ",W?"colour = how strong they are, cold to white hot":"colour = its industry","; white centre = the share you already know; gold ring = an S-tier person inside.",(0,t.jsx)("br",{}),"A line = one of your connections at one company knows people at the other.",$.cut?` Showing the 140 largest; ${$.cut} smaller companies are in Companies.`:""]})]})}function V({parts:e,total:n}){return(0,t.jsx)("div",{style:{display:"flex",height:6,borderRadius:3,overflow:"hidden",background:"rgba(255,255,255,0.06)"},children:e.map(([e,o],i)=>(0,t.jsx)("div",{style:{width:`${e/Math.max(1,n)*100}%`,background:o}},i))})}function Q({p:e,note:n}){return(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,padding:"5px 0",fontSize:12.5},children:[(0,t.jsx)("span",{style:{width:7,height:7,borderRadius:"50%",background:O[e.tier]||"#667",flexShrink:0}}),(0,t.jsxs)("div",{style:{minWidth:0,flex:1},children:[(0,t.jsx)("div",{style:{fontWeight:600,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.name}),(0,t.jsx)("div",{style:{fontSize:11,color:"#8b9a9a",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:n||e.headline})]})]})}function Z({focus:e,data:o,index:i,links:r,d1:l,d2:s,filters:a,onClose:d,onCompany:c,onIndustry:h,onOpenCompany:p}){let u,f,g,x="company"===e.kind,y=o.people.filter(e=>Y(e,a)),m=(0,n.useMemo)(()=>{let e=new Map;for(let t of y){let n=(0,b.getSeniority)(t.headline);e.set(n.label,{n:(e.get(n.label)?.n||0)+1,level:n.level})}return[...e.entries()].sort((e,t)=>t[1].level-e[1].level)},[y]),v=(0,n.useMemo)(()=>x?(0,b.waysInto)(o.name,l,s):null,[x,o,l,s]),j=(0,n.useMemo)(()=>x?r.filter(e=>e.a===o.name||e.b===o.name).map(e=>({name:e.a===o.name?e.b:e.a,weight:e.weight})).sort((e,t)=>t.weight-e.weight).slice(0,8):[],[x,r,o]),k=[...y].sort((e,t)=>(Number(t.power_score)||0)-(Number(e.power_score)||0)).slice(0,6),S=x?o.industry:o,w=y.filter(e=>1===e.degree).length,M=y.filter(e=>2===e.degree).length,z=x?[]:[...o.companies.entries()].sort((e,t)=>t[1]-e[1]).slice(0,10);return(0,t.jsxs)("aside",{style:{width:360,flexShrink:0,borderLeft:L,overflow:"auto",padding:16,background:"rgba(255,255,255,0.02)"},children:[(0,t.jsx)("button",{onClick:d,style:{background:"none",border:"none",color:"#888",cursor:"pointer",fontSize:12,padding:0},children:"✕ Close"}),(0,t.jsxs)("div",{style:{fontSize:10,letterSpacing:1,color:"#8b9a9a",marginTop:8},children:[x?"COMPANY":"INDUSTRY"," ANALYZER"]}),(0,t.jsx)("h2",{style:{margin:"4px 0 6px",fontSize:20},children:x?o.name:o.label}),x&&h?(0,t.jsxs)("button",{type:"button",onClick:()=>h(S.key),title:`Open ${S.label}: everyone there and its top companies`,style:{fontSize:11,padding:"2px 8px",borderRadius:10,border:"none",cursor:"pointer",background:`${S.color}22`,color:S.color},children:[S.label," · inferred →"]}):(0,t.jsxs)("span",{style:{fontSize:11,padding:"2px 8px",borderRadius:10,background:`${S.color}22`,color:S.color},children:[S.label,x?" · inferred":""]}),x&&(0,t.jsx)(ee,{name:o.name}),(0,t.jsx)("div",{style:{display:"grid",gridTemplateColumns:"repeat(3, 1fr)",gap:8,margin:"14px 0"},children:[[w,"you know","#00ff88"],[M,"reachable","#FF6B35"],[y.filter(e=>(0,b.isSenior)(e.headline)).length,"director+","#FFD700"]].map(([e,n,o])=>(0,t.jsxs)("div",{style:{padding:8,borderRadius:8,background:"rgba(255,255,255,0.04)",textAlign:"center"},children:[(0,t.jsx)("div",{style:{fontSize:20,fontWeight:800,color:o},children:e}),(0,t.jsx)("div",{style:{fontSize:10.5,color:"#8b9a9a"},children:n})]},n))}),(0,t.jsx)(J,{title:"By level",children:m.map(([e,{n}])=>(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"110px 1fr 28px",gap:8,alignItems:"center",fontSize:11.5,marginBottom:4},children:[(0,t.jsx)("span",{style:{color:"#aab7b7"},children:e}),(0,t.jsx)(V,{total:y.length,parts:[[n,"#3498DB"]]}),(0,t.jsx)("span",{style:{color:"#778",textAlign:"right"},children:n})]},e))}),x&&v&&(0,t.jsxs)(J,{title:"Ways in",children:[v.direct.length>0&&(0,t.jsxs)("div",{style:{fontSize:11,color:"#00ff88",margin:"2px 0"},children:["You already know ",v.direct.length," here"]}),(u=new Map(v.bridges.map(({bridge:e,n:t})=>[e.id,t])),f=[...v.direct].sort((e,t)=>(u.get(t.id)||0)-(u.get(e.id)||0)).slice(0,4),g=new Set(v.direct.map(e=>e.id)),(0,t.jsxs)(t.Fragment,{children:[f.map(e=>(0,t.jsx)(Q,{p:e,note:u.get(e.id)?`works here \xb7 knows ${u.get(e.id)} here`:`works here \xb7 ${e.headline||""}`},e.id)),v.bridges.filter(({bridge:e})=>!g.has(e.id)).slice(0,5).map(({bridge:e,n})=>(0,t.jsx)(Q,{p:e,note:`knows ${n} ${1===n?"person":"people"} here`},e.id))]})),!v.direct.length&&!v.bridges.length&&(0,t.jsx)("div",{style:{fontSize:12,color:"#778"},children:"No one you know links here yet."})]}),(0,t.jsx)(J,{title:x?"Most powerful people here":"Most powerful people in this industry",children:k.map(e=>(0,t.jsx)(Q,{p:e,note:`${1===e.degree?"you know them":2===e.degree?"2nd degree":"3rd+"} \xb7 ${e.headline||""}`},e.id))}),x&&j.length>0&&(0,t.jsx)(J,{title:"Connected companies",children:(0,t.jsx)("div",{style:{display:"flex",gap:6,flexWrap:"wrap"},children:j.map(e=>(0,t.jsxs)("button",{onClick:()=>c(e.name),style:{padding:"3px 9px",borderRadius:10,border:L,background:`${i.get(e.name)?.industry.color||"#666"}22`,color:"#dfe6e9",fontSize:11.5,cursor:"pointer"},children:[e.name," ",(0,t.jsx)("span",{style:{color:"#778"},children:e.weight})]},e.name))})}),!x&&(0,t.jsx)(J,{title:"Companies",children:z.map(([e,n])=>(0,t.jsxs)("div",{onClick:()=>c(e),style:{display:"grid",gridTemplateColumns:"1fr 60px 24px",gap:8,alignItems:"center",fontSize:12,padding:"3px 0",cursor:"pointer"},children:[(0,t.jsx)("span",{style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e}),(0,t.jsx)(V,{total:z[0][1],parts:[[n,S.color]]}),(0,t.jsx)("span",{style:{color:"#778",textAlign:"right"},children:n})]},e))}),x&&p&&(0,t.jsxs)("button",{onClick:()=>p(o),style:{marginTop:14,width:"100%",padding:"10px",borderRadius:8,border:"none",cursor:"pointer",fontWeight:700,background:"linear-gradient(135deg, #00ff88, #3498DB)",color:"#000"},children:["Path to the top of ",o.name," →"]})]})}function J({title:e,children:n}){return(0,t.jsxs)("div",{style:{marginTop:14},children:[(0,t.jsx)("div",{style:{fontSize:10.5,letterSpacing:.8,color:"#8b9a9a",fontWeight:700,marginBottom:6},children:e.toUpperCase()}),n]})}function ee({name:e}){let{companies:n,setScore:o}=(0,y.useCompanyScores)(),i=n?.find(t=>t.name===e);if(!i)return null;let r={yours:"your score",known:"known list",network:"estimated",default:"unknown company"}[i.source];return(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginTop:10,fontSize:12,color:"#aab7b7"},children:["Company score ",(0,t.jsx)("b",{style:{color:"#fff",fontSize:15},children:i.score}),"/10 · ",r,(0,t.jsx)("span",{style:{marginLeft:"auto"},children:(0,t.jsx)(y.ScorePicker,{company:i,onSet:o,compact:!0})})]})}var et=e.i(15812),en=e.i(30215),eo=e.i(22016),ei=e.i(36774);let er=[["map","Map"],["companies","Companies"]];function el(){let{userId:e}=(0,et.useUser)(),[c,h]=(0,n.useState)([]),[p,u]=(0,n.useState)(null),[f,g]=(0,n.useState)([]),[x,y]=(0,n.useState)(!0),[m,v]=(0,n.useState)([]),[j,k]=(0,n.useState)([]),[S,w]=(0,n.useState)([]),M=(0,r.useSearchParams)().get("tab"),[z,C]=(0,n.useState)(()=>er.some(([e])=>e===M)?M:"map"),B=(0,r.useRouter)();(0,n.useEffect)(()=>{"scores"===M&&B.replace("/settings#companies")},[M,B]),(0,n.useEffect)(()=>p?void(0,i.setNotchTabs)(null):((0,i.setNotchTabs)({items:er.map(([e,t])=>({key:e,label:t})),current:z,onPick:C}),()=>(0,i.setNotchTabs)(null)),[z,p]);let[F,$]=(0,n.useState)(0),[R,T]=(0,n.useState)(!1);(0,n.useEffect)(()=>{!a.IS_DEMO&&e&&t();async function t(){let t=(0,d.hasCsvNetwork)()?(0,d.loadCsvNetwork)():null;T(!!t);let n=[],o=[],i=[];if(t)n=t.degree1,o=t.degree2||[];else{let t=await (0,s.loadNetwork)(e);n=t.degree1,o=t.degree2,i=t.degree3}v(n),k(o),w(i||[]);let r={},l=new Set;[...n,...o,...i].forEach(e=>{if(l.has(e.profile_url))return;l.add(e.profile_url);let t=(0,b.companyOf)(e);t&&(r[t]||(r[t]={name:t,d1:0,d2:0,d3:0,sCount:0,aCount:0,people:[]}),1===e.degree?r[t].d1++:2===e.degree?r[t].d2++:r[t].d3++,"S"===e.tier&&r[t].sCount++,"A"===e.tier&&r[t].aCount++,r[t].people.push(e))}),h(Object.values(r).filter(e=>e.d1+e.d2+e.d3>=3).sort((e,t)=>3*t.sCount+2*t.aCount+t.d1+t.d2+t.d3-(3*e.sCount+2*e.aCount+e.d1+e.d2+e.d3))),y(!1)}},[e,F]);let[I,W]=(0,n.useState)(!1),[D,A]=(0,n.useState)([]),O=(0,en.default)(),L=!I&&O.running?(0,l.busyReason)(O):null;function N(e){let t=new Set(m.map(e=>e.profile_url)),n=new Set([...m,...j].map(e=>e.profile_url)),o=new Map,i=0;for(let n of e)t.has(n.profile_url||n.profileUrl)&&(i++,o.set(n.id,(o.get(n.id)||0)+1));return e.map(e=>({...e,connected:t.has(e.profile_url||e.profileUrl),known:n.has(e.profile_url||e.profileUrl),seniority:(0,b.getSeniority)(e.headline),mutualCount:i-(o.get(e.id)||0)}))}function E(e){u(e),g(N(e.people))}async function _(){if(a.IS_DEMO||R||!p)return;let e=!1;try{e="1"===localStorage.getItem("six-degrees-company-scan-ok")}catch{}if(!e){if(!window.confirm("Company scans are experimental: they have not been tested against live LinkedIn yet, so the results may be incomplete. Like any scan, it opens a Chrome window and counts toward the profile views LinkedIn watches.\n\nRun it anyway?"))return;try{localStorage.setItem("six-degrees-company-scan-ok","1")}catch{}}W(!0),A(["Checking the scanner..."]);let t=(0,l.notReadyMessage)(await (0,l.scraperStatus)().catch(()=>null));if(t){A([t]),W(!1);return}try{let e=await (0,l.runScrape)("company",{name:p.name,onLog:A});if(0===e.exitCode){A(e=>[...e,"Loading the new people..."]);let e=await fetch(`/api/connections?scanned_company=${encodeURIComponent(p.name)}&limit=500`),t=(await e.json()).connections||[];t.length?(g(N(t)),A(e=>[...e,`${t.length} people at ${p.name}.`])):A(e=>[...e,"Nothing new was found."])}}catch(e){A([e.message||"Failed to start the scan"])}finally{W(!1)}}let P=new Map;for(let e of m)P.has(e.id)||P.set(e.id,e);let U=new Set(m.map(e=>e.profile_url)),H={},Y=0;f.forEach(e=>{let t=e.seniority.key;H[t]||(H[t]={...e.seniority,people:[]}),e.connected&&Y++;let n=Math.min(90,12*e.mutualCount);e.seniority.level<=1?n+=20:e.seniority.level<=2?n+=10:e.seniority.level>=5&&(n-=10),n=Math.max(5,Math.min(95,n)),e.connected&&(n=100);let o=null;if(2===e.degree&&e.source_connection_id){let t=P.get(e.source_connection_id);t&&(o=t.name)}let i={0:5,1:10,2:20,3:35,4:50,5:75,6:100}[e.seniority.level]||10;H[t].people.push({...e,likelihood:n,bridgeName:o,xp:i})}),Object.values(H).forEach(e=>e.people.sort((e,t)=>t.likelihood-e.likelihood));let G=Object.values(H).sort((e,t)=>t.level-e.level);return a.IS_DEMO?(0,t.jsxs)("div",{style:{minHeight:"100vh",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:12,background:"#0a0a1a",color:"rgba(255,255,255,0.7)",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},children:[(0,t.jsx)("h1",{style:{fontSize:20,fontWeight:700,margin:0,color:"#fff"},children:"Not part of the demo"}),(0,t.jsx)("p",{style:{fontSize:13,margin:0},children:"The public demo includes the Network Circle and Degrees views only."}),(0,t.jsx)(eo.default,{href:"/",style:{fontSize:13,color:"#888",textDecoration:"none"},children:"← Back to the network"})]}):x?(0,t.jsx)("div",{style:{minHeight:"100vh",display:"flex",alignItems:"center",justifyContent:"center",background:"#0a0a1a",color:"#fff"},children:"Loading..."}):(0,t.jsxs)("div",{style:{height:"100vh",background:"#0a0a1a",color:"#fff",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',display:"flex",flexDirection:"column",overflow:"hidden"},children:[(0,t.jsx)("header",{style:{padding:"20px 30px",borderBottom:"1px solid rgba(255,255,255,0.1)",flexShrink:0},children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:12},children:[(0,t.jsx)(eo.default,{href:"/",style:{textDecoration:"none"},children:(0,t.jsx)("h1",{style:{fontSize:28,fontWeight:700,margin:0,background:"linear-gradient(135deg, #FFD700, #9B59B6, #3498DB)",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"},children:"Six Degrees"})}),(0,t.jsx)(o.default,{active:"paths",csvMode:R}),(0,t.jsx)(eo.default,{href:"/settings",title:"Settings","aria-label":"Settings",style:{width:32,height:32,borderRadius:"50%",flexShrink:0,background:"rgba(255,255,255,0.06)",color:"#888",fontSize:16,textDecoration:"none",display:"flex",alignItems:"center",justifyContent:"center"},children:"⚙"})]})}),p&&(0,t.jsx)("div",{style:{padding:"10px 24px",borderBottom:"1px solid rgba(255,255,255,0.08)",flexShrink:0},children:(0,t.jsx)("div",{style:{display:"flex",alignItems:"center",gap:12},children:p&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("button",{onClick:()=>{u(null),g([])},style:{background:"none",border:"none",color:"#888",cursor:"pointer",fontSize:12},children:"← Companies"}),(0,t.jsx)("span",{style:{fontSize:13,fontWeight:600},children:p.name}),(0,t.jsxs)("span",{style:{fontSize:11,color:"#888"},children:[Y,"/",f.length," connected"]}),R?(0,t.jsx)("span",{style:{marginLeft:"auto",fontSize:11,color:"#888"},children:"Scanning needs your own network"}):(0,t.jsx)("button",{onClick:_,disabled:I||!!L,title:L?`${L}. One scan at a time.`:void 0,style:{marginLeft:"auto",padding:"5px 12px",borderRadius:6,border:"none",cursor:I||L?"not-allowed":"pointer",background:I||L?"#333":"rgba(0,255,136,0.15)",color:I||L?"#555":"#00ff88",fontSize:11,fontWeight:600},children:I?"Scanning...":L?"Scanner busy":"+ Scan Full Company"}),(0,t.jsx)("span",{title:"Not yet tested against live LinkedIn. Results may be incomplete.",style:{fontSize:9.5,fontWeight:800,letterSpacing:.6,padding:"3px 7px",borderRadius:20,border:"1px solid rgba(255,215,0,0.45)",color:"#FFD700"},children:"EXPERIMENTAL"})]})})}),p||"companies"===z?(0,t.jsx)("div",{style:{flex:1,overflow:"auto",padding:"16px 24px"},children:(0,t.jsxs)("div",{style:{maxWidth:700,margin:"0 auto"},children:[!p&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("p",{style:{fontSize:13,color:"#888",marginBottom:16},children:["Pick a company to see your path to the top. Based on ",m.length+j.length," people in your network."]}),(0,t.jsx)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:10},children:c.slice(0,60).map(e=>(0,t.jsxs)("button",{onClick:()=>E(e),style:{padding:"14px",borderRadius:10,border:"none",cursor:"pointer",textAlign:"left",background:"rgba(255,255,255,0.04)",transition:"background 0.15s",borderLeft:`3px solid ${e.sCount>0?"#FFD700":e.aCount>0?"#9B59B6":"#3498DB"}`},onMouseEnter:e=>e.currentTarget.style.background="rgba(255,255,255,0.08)",onMouseLeave:e=>e.currentTarget.style.background="rgba(255,255,255,0.04)",children:[(0,t.jsx)("div",{style:{fontSize:14,fontWeight:700,color:"#fff",marginBottom:4},children:e.name}),(0,t.jsxs)("div",{style:{display:"flex",gap:8,fontSize:10,color:"#888"},children:[(0,t.jsxs)("span",{style:{color:"#00ff88"},children:[e.d1," connected"]}),(0,t.jsxs)("span",{children:[e.d2+e.d3," locked"]})]}),(0,t.jsxs)("div",{style:{display:"flex",gap:6,marginTop:4,fontSize:9},children:[e.sCount>0&&(0,t.jsxs)("span",{style:{color:"#FFD700",fontWeight:600},children:[e.sCount,"S"]}),e.aCount>0&&(0,t.jsxs)("span",{style:{color:"#9B59B6",fontWeight:600},children:[e.aCount,"A"]}),(0,t.jsxs)("span",{style:{color:"#555"},children:[e.d1+e.d2," total"]})]}),(0,t.jsx)("div",{style:{height:3,background:"rgba(255,255,255,0.08)",borderRadius:2,marginTop:6},children:(0,t.jsx)("div",{style:{height:"100%",borderRadius:2,width:`${e.d1/Math.max(e.d1+e.d2+e.d3,1)*100}%`,background:e.sCount>0?"#FFD700":"#00ff88"}})})]},e.name))})]}),I&&(0,t.jsxs)("div",{style:{padding:"10px",borderRadius:8,background:"rgba(0,255,136,0.06)",border:"1px solid rgba(0,255,136,0.2)",marginBottom:12},children:[(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,marginBottom:4},children:[(0,t.jsx)("div",{style:{width:6,height:6,borderRadius:"50%",background:"#00ff88",animation:"pulse 1s infinite"}}),(0,t.jsx)("span",{style:{fontSize:10,fontWeight:600,color:"#00ff88"},children:"Scanning LinkedIn..."})]}),(0,t.jsx)("div",{style:{fontFamily:"monospace",fontSize:9,color:"#777",maxHeight:60,overflow:"auto"},children:D.map((e,n)=>(0,t.jsx)("div",{children:e},n))})]}),p&&G.map(e=>(0,t.jsxs)("div",{style:{marginBottom:16},children:[(0,t.jsxs)("div",{style:{padding:"8px 12px",borderRadius:6,marginBottom:4,background:e.level>=5?"rgba(255,215,0,0.08)":e.level>=3?"rgba(155,89,182,0.08)":"rgba(52,152,219,0.08)",borderLeft:`3px solid ${e.level>=5?"#FFD700":e.level>=3?"#9B59B6":"#3498DB"}`,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("span",{style:{fontSize:12,fontWeight:700,color:e.level>=5?"#FFD700":e.level>=3?"#9B59B6":"#3498DB"},children:e.label}),e.level>=5&&(0,t.jsx)("span",{style:{fontSize:9,color:"#FF6B35",marginLeft:8,fontWeight:700},children:"TARGET"})]}),(0,t.jsxs)("div",{style:{display:"flex",gap:8,alignItems:"center"},children:[(0,t.jsxs)("span",{style:{fontSize:9,color:"#FF6B35",fontWeight:600},children:["+",e.people.filter(e=>!e.connected).reduce((e,t)=>e+(t.xp||0),0)," XP"]}),(0,t.jsxs)("span",{style:{fontSize:10,color:"#666"},children:[e.people.filter(e=>e.connected).length,"/",e.people.length]})]})]}),e.people.map((n,o)=>(0,t.jsx)(es,{p:n,level:e,companyPeople:f,d1Urls:U,selectedCompany:p},n.id||o))]},e.key))]})}):(0,t.jsx)(X,{d1:m,d2:j,d3:S,initialShow:"people"===M?"people":"companies",onOpenCompany:e=>E({...e,sCount:e.S,aCount:e.A})})]})}function es({p:e,level:o,companyPeople:i,d1Urls:r,selectedCompany:l}){let[s,a]=(0,n.useState)(!1),d=[];if(s&&!e.connected){let t=i.filter(t=>t.seniority.level>e.seniority.level&&!r.has(t.profile_url||t.profileUrl)),n=i.filter(t=>t.seniority.level===e.seniority.level&&t.id!==e.id),o=t.length;o>0&&d.push({icon:"⬆️",text:`Adding them gives you a mutual with ${o} people above in the hierarchy`,color:"#00ff88"});let l=n.filter(e=>r.has(e.profile_url||e.profileUrl)).length;l>0?d.push({icon:"🤝",text:`${l} people at their level already connected — high social proof`,color:"#FFD700"}):d.push({icon:"🎯",text:"First connection at this level — opens a new layer",color:"#3498DB"}),e.bridgeName&&d.push({icon:"🔗",text:`Reachable through ${e.bridgeName} — warm intro possible`,color:"#FF6B35"}),e.seniority.level>=5?d.push({icon:"👑",text:`${e.seniority.label} — decision maker, high strategic value but low accept rate`,color:"#FFD700"}):e.seniority.level>=3?d.push({icon:"📊",text:`${e.seniority.label} — middle management, good balance of access and accept rate`,color:"#9B59B6"}):d.push({icon:"✅",text:`${e.seniority.label} — highest accept rate, builds mutual foundation for people above`,color:"#00ff88"}),e.likelihood>=60?d.push({icon:"🔥",text:`${e.likelihood}% likely to accept — strong mutual overlap + approachable role`,color:"#00ff88"}):e.likelihood>=30?d.push({icon:"⚡",text:`${e.likelihood}% likely — moderate chance, add more people at their level first`,color:"#FFD700"}):d.push({icon:"🔒",text:`${e.likelihood}% likely — low chance right now, build more connections below them first`,color:"#ff5050"})}return(0,t.jsxs)("div",{style:{borderBottom:"1px solid rgba(255,255,255,0.03)"},children:[(0,t.jsxs)("div",{onClick:()=>a(!s),style:{display:"flex",alignItems:"center",gap:8,padding:"6px 8px",cursor:"pointer",opacity:e.connected?.7:1},onMouseEnter:e=>e.currentTarget.style.background="rgba(255,255,255,0.04)",onMouseLeave:e=>e.currentTarget.style.background="transparent",children:[(0,t.jsx)("span",{style:{fontSize:8,color:"#555",flexShrink:0,width:10},children:s?"▾":"▸"}),(0,t.jsx)("div",{style:{width:18,height:18,borderRadius:"50%",flexShrink:0,fontSize:8,display:"flex",alignItems:"center",justifyContent:"center",background:e.connected?"rgba(0,255,136,0.2)":"rgba(255,255,255,0.05)",color:e.connected?"#00ff88":"#555",border:`1px solid ${e.connected?"rgba(0,255,136,0.3)":"rgba(255,255,255,0.1)"}`},children:e.connected?"✓":"🔒"}),(0,ei.localPhoto)(e.profile_image_url||e.imageUrl)?(0,t.jsx)("img",{src:(0,ei.localPhoto)(e.profile_image_url||e.imageUrl),alt:"",style:{width:26,height:26,borderRadius:"50%",objectFit:"cover",flexShrink:0},onError:e=>e.target.style.display="none"}):(0,t.jsx)("div",{style:{width:26,height:26,borderRadius:"50%",flexShrink:0,fontSize:10,fontWeight:700,background:"#333",color:"#888",display:"flex",alignItems:"center",justifyContent:"center"},children:e.name?.charAt(0)}),(0,t.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,t.jsx)("div",{style:{fontSize:11,fontWeight:600,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.name}),(0,t.jsx)("div",{style:{fontSize:8,color:"#666",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.headline?.substring(0,45)})]}),!e.connected&&e.bridgeName&&(0,t.jsxs)("span",{style:{fontSize:8,color:"#FF6B35",flexShrink:0,maxWidth:55,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:["via ",e.bridgeName.split(" ")[0]]}),!e.connected&&(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,flexShrink:0},children:[(0,t.jsxs)("span",{style:{fontSize:8,fontWeight:700,color:"#FF6B35"},children:["+",e.xp]}),(0,t.jsxs)("div",{style:{fontSize:9,fontWeight:700,minWidth:30,textAlign:"right",color:e.likelihood>=60?"#00ff88":e.likelihood>=30?"#FFD700":"#ff5050"},children:[e.likelihood,"%"]})]}),!e.connected&&(0,t.jsx)("a",{href:e.profile_url||e.profileUrl,target:"_blank",rel:"noopener noreferrer",onClick:e=>e.stopPropagation(),style:{padding:"3px 7px",borderRadius:4,fontSize:8,fontWeight:700,background:"#0077B5",color:"#fff",textDecoration:"none",flexShrink:0},children:"Add"})]}),s&&(0,t.jsxs)("div",{style:{padding:"8px 12px 10px 44px",background:"rgba(255,255,255,0.02)",borderTop:"1px solid rgba(255,255,255,0.04)"},children:[(0,t.jsx)("div",{style:{fontSize:11,color:"#aaa",marginBottom:8},children:e.headline||"No headline available"}),(0,t.jsxs)("div",{style:{display:"flex",gap:6,alignItems:"center",marginBottom:8,flexWrap:"wrap"},children:[(0,t.jsxs)("div",{style:{display:"inline-block",padding:"2px 8px",borderRadius:4,fontSize:9,fontWeight:600,background:e.seniority.level>=5?"rgba(255,215,0,0.1)":e.seniority.level>=3?"rgba(155,89,182,0.1)":"rgba(52,152,219,0.1)",color:e.seniority.level>=5?"#FFD700":e.seniority.level>=3?"#9B59B6":"#3498DB",border:`1px solid ${e.seniority.level>=5?"rgba(255,215,0,0.2)":e.seniority.level>=3?"rgba(155,89,182,0.2)":"rgba(52,152,219,0.2)"}`},children:[e.seniority.label," · Level ",e.seniority.level]}),!e.connected&&(0,t.jsxs)("div",{style:{display:"inline-block",padding:"2px 8px",borderRadius:4,fontSize:9,fontWeight:700,background:"rgba(255,107,53,0.1)",color:"#FF6B35",border:"1px solid rgba(255,107,53,0.2)"},children:["+",e.xp," XP"]})]}),!e.connected&&d.length>0&&(0,t.jsxs)("div",{style:{marginTop:4},children:[(0,t.jsx)("div",{style:{fontSize:9,fontWeight:700,color:"#888",letterSpacing:.5,marginBottom:4},children:"STRATEGIC VALUE"}),d.map((e,n)=>(0,t.jsxs)("div",{style:{display:"flex",gap:6,alignItems:"flex-start",padding:"2px 0",fontSize:10,color:"#bbb"},children:[(0,t.jsx)("span",{style:{fontSize:11,lineHeight:1},children:e.icon}),(0,t.jsx)("span",{style:{color:e.color},children:e.text})]},n))]}),e.connected&&(0,t.jsxs)("div",{style:{fontSize:10,color:"#00ff88",fontWeight:600},children:["✓ Already connected — contributes as mutual for others at ",l?.name]})]})]})}e.s(["default",0,function(){return(0,t.jsx)(c.default,{children:(0,t.jsx)(n.Suspense,{children:(0,t.jsx)(el,{})})})}],85957)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,2776,e=>{"use strict";var t=e.i(43476),n=e.i(15812);e.s(["default",0,function({children:e}){let{userId:r,ready:i}=(0,n.useUser)();return i&&r?e:(0,t.jsx)("div",{style:{minHeight:"100vh",display:"flex",alignItems:"center",justifyContent:"center",background:"#0a0a1a",color:"#fff",padding:24,textAlign:"center",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},children:i?(0,t.jsxs)("div",{style:{maxWidth:420},children:[(0,t.jsx)("div",{style:{fontSize:18,fontWeight:700,marginBottom:8},children:"Can’t reach Six Degrees’ local server"}),(0,t.jsx)("div",{style:{color:"#888",fontSize:14,lineHeight:1.6},children:"The page loaded but the app behind it is not answering. If you started it from a terminal, check that window for an error, then reload this page."})]}):(0,t.jsx)("div",{style:{fontSize:18,fontWeight:600},children:"Loading…"})})}])},8819,e=>{"use strict";var t=e.i(43476);let n="1px solid rgba(255,255,255,0.1)";function r({children:e,style:n}){return(0,t.jsx)("div",{style:{fontSize:13.5,color:"#8b9a9a",lineHeight:1.6,marginTop:4,...n},children:e})}e.s(["Body",0,r,"Btn",0,function({children:e,onClick:r,disabled:i,primary:o,tone:l,type:s="button"}){return(0,t.jsx)("button",{type:s,onClick:r,disabled:i,style:{padding:"9px 18px",borderRadius:7,fontSize:13.5,fontWeight:650,color:i?"#667":"#fff",border:n,background:i?"rgba(255,255,255,0.05)":"bad"===l?"rgba(255,80,80,0.15)":o?"linear-gradient(135deg, #9B59B6, #3498DB)":"rgba(255,255,255,0.08)",cursor:i?"not-allowed":"pointer"},children:e})},"FONT",0,'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',"LINE",0,n,"Mono",0,function({children:e}){return(0,t.jsx)("code",{style:{background:"rgba(255,255,255,0.08)",padding:"1px 5px",borderRadius:4,wordBreak:"break-all"},children:e})},"Section",0,function({id:e,title:i,intro:o,children:l}){return(0,t.jsxs)("section",{id:e,style:{padding:"24px 0",borderBottom:n,scrollMarginTop:16},children:[(0,t.jsx)("h2",{style:{fontSize:16,fontWeight:650,margin:"0 0 6px"},children:i}),o&&(0,t.jsx)(r,{style:{marginTop:0,marginBottom:12},children:o}),l]})},"Status",0,function({children:e,tone:n}){return(0,t.jsxs)("div",{role:"status",style:{marginTop:10,padding:"10px 14px",borderRadius:8,fontSize:13.5,lineHeight:1.6,color:"ok"===n?"#00ff88":"bad"===n?"#ff7676":"#e8e8ee",background:"ok"===n?"rgba(0,255,136,0.08)":"bad"===n?"rgba(255,80,80,0.08)":"rgba(255,255,255,0.05)",border:`1px solid ${"ok"===n?"rgba(0,255,136,0.3)":"bad"===n?"rgba(255,80,80,0.3)":"rgba(255,255,255,0.12)"}`},children:["ok"===n&&"✓ ",e]})}])},99201,e=>{"use strict";var t=e.i(43476),n=e.i(71645),r=e.i(18566),i=e.i(19821),o=e.i(5258),l=e.i(48235);let s={height:10,borderRadius:6},a={background:"rgba(52,152,219,0.06)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(52,152,219,0.2)"};function d({degree1:e=[],degree2:n=[],skips:r=[]}){let i=function(e=[],t=[],n=[]){let r=(0,l.reachIndex)(e,t,{skips:n}),i=e=>{let t=(0,l.circleState)(e,r);return"scanned"===t?"mapped":t},o={mapped:0,hidden:0,todo:0},s={};for(let t of e){let e=i(t);o[e]+=1;let n=t.tier||"D";s[n]=s[n]||{mapped:0,hidden:0,todo:0,total:0},s[n][e]+=1,s[n].total+=1}let a=e.length,d=o.mapped+o.hidden;return{...o,total:a,resolved:d,percent:a?Math.round(d/a*100):0,batches:Math.ceil(o.todo/25),byTier:s}}(e,n,r);if(!i.total)return null;let u=e=>i.total?e/i.total*100:0,g=0===i.todo;return(0,t.jsxs)("div",{style:a,children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"baseline",marginBottom:10},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,margin:0,color:"#3498DB"},children:"2nd-degree mapping"}),(0,t.jsx)("span",{style:{fontSize:12,color:g?"#00ff88":"#8b9a9a",fontWeight:600},children:g?"Everything reachable is mapped":`${i.percent}%`})]}),(0,t.jsxs)("div",{style:{...s,display:"flex",overflow:"hidden",background:"rgba(255,255,255,0.06)"},children:[(0,t.jsx)("div",{style:{width:`${u(i.mapped)}%`,background:"#00ff88"}}),(0,t.jsx)("div",{style:{width:`${u(i.hidden)}%`,background:"rgba(255,255,255,0.22)"}})]}),(0,t.jsxs)("div",{style:{display:"flex",gap:16,marginTop:10,fontSize:12,flexWrap:"wrap"},children:[(0,t.jsx)(c,{color:"#00ff88",label:"mapped",value:i.mapped}),(0,t.jsx)(c,{color:"rgba(255,255,255,0.35)",label:"hidden",value:i.hidden}),(0,t.jsx)(c,{color:"rgba(255,255,255,0.12)",label:"to go",value:i.todo}),(0,t.jsxs)("span",{style:{color:"#667",marginLeft:"auto"},children:["of ",i.total]})]}),i.hidden>0&&(0,t.jsx)("p",{style:{fontSize:11.5,color:"#667",margin:"10px 0 0",lineHeight:1.6},children:"Hidden means they keep their connections private — that will not change, and it does not count against you."}),!g&&(0,t.jsxs)("p",{style:{fontSize:11.5,color:"#8b9a9a",margin:"10px 0 0",lineHeight:1.6},children:[i.todo," left — about ",(0,t.jsxs)("b",{children:[i.batches," ",1===i.batches?"batch":"batches"]})," of ",25,". Run one, leave it a while, run another. Long unbroken runs are what gets an account restricted."]}),(0,t.jsx)("div",{style:{marginTop:16,display:"flex",flexDirection:"column",gap:7},children:["S","A","B","C","D"].filter(e=>i.byTier[e]?.total).map(e=>{let n=i.byTier[e];return(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:10,fontSize:11},children:[(0,t.jsx)("span",{style:{width:14,color:o.TIER_COLORS_CLASSIC[e],fontWeight:700},children:e}),(0,t.jsxs)("div",{style:{flex:1,height:5,borderRadius:3,display:"flex",overflow:"hidden",background:"rgba(255,255,255,0.06)"},children:[(0,t.jsx)("div",{style:{width:`${n.mapped/n.total*100}%`,background:o.TIER_COLORS_CLASSIC[e]}}),(0,t.jsx)("div",{style:{width:`${n.hidden/n.total*100}%`,background:"rgba(255,255,255,0.22)"}})]}),(0,t.jsxs)("span",{style:{color:"#667",width:62,textAlign:"right"},children:[n.mapped,"/",n.total]})]},e)})})]})}function c({color:e,label:n,value:r}){return(0,t.jsxs)("span",{style:{display:"flex",alignItems:"center",gap:6,color:"#8b9a9a"},children:[(0,t.jsx)("span",{style:{width:8,height:8,borderRadius:2,background:e}}),(0,t.jsx)("b",{style:{color:"#e2e8f0"},children:r})," ",n]})}var u=e.i(64745),g=e.i(2776),h=e.i(15812),f=e.i(69083),p=e.i(22016),y=e.i(64666),m=e.i(8819);let b={S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"},x=e=>`${Math.round(100*e)}%`;function v(){let{userId:e}=(0,h.useUser)(),[r,o]=(0,n.useState)(null),[l,s]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(!e)return;let t=!0;return(0,i.loadNetwork)(e).then(e=>{t&&o(function({degree1:e=[],degree2:t=[],ties:n=0}={}){let r=new Map;for(let e of t)e?.source_connection_id!=null&&r.set(e.source_connection_id,(r.get(e.source_connection_id)||0)+1);let i=(0,y.exclusiveReach)(t,e),o=e.length,l=Math.max(0,Number(n)||0),s=o?o-2*l/o:0,a=new Map(e.map(e=>[e.id,e])),d=[...i.entries()].sort((e,t)=>t[1].reach-e[1].reach||String(e[0]).localeCompare(String(t[0]))).slice(0,5).map(([e,t])=>{let n=a.get(e)||{};return{id:e,name:n.name||"",company:n.company||"",tier:n.tier||"",circle:r.get(e)||0,only:t.only,share:t.total?t.only/t.total:0}});return{circles:r.size,early:r.size<5,twoWays:(0,y.redundancy)(t,e),effective:{n:o,ties:l,size:s,efficiency:o?s/o:0},top:d}}(e))}).catch(()=>{t&&s(!0)}),()=>{t=!1}},[e]);let a={padding:"12px 14px",borderRadius:8,border:m.LINE,background:"rgba(255,255,255,0.03)"};return(0,t.jsxs)("section",{id:"health",style:{marginTop:20},children:[(0,t.jsx)("h2",{style:{fontSize:16,margin:"0 0 6px"},children:"Network health"}),l&&(0,t.jsx)(m.Body,{children:"Couldn’t read your network just now."}),!l&&!r&&(0,t.jsx)(m.Body,{children:"Reading your network…"}),r&&0===r.circles&&(0,t.jsx)(m.Body,{children:"Scan a few of your connections’ circles (the Scan page, step 4) and this shows how your network holds together."}),r&&r.circles>0&&(0,t.jsxs)(t.Fragment,{children:[r.early&&(0,t.jsxs)("div",{style:{fontSize:12.5,color:"#FFD700",margin:"4px 0 10px"},children:["An early estimate: ",r.circles," ",1===r.circles?"circle":"circles"," scanned. These get sharper as you scan more."]}),(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(220px, 1fr))",gap:10},children:[(0,t.jsxs)("div",{style:a,children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700},children:x(r.twoWays)}),(0,t.jsx)("div",{style:{fontSize:12.5,color:"#b8c4c4"},children:"of your 2nd degree you reach two or more ways"}),(0,t.jsx)("div",{style:{fontSize:11.5,color:"#778",marginTop:4},children:"Higher is safer: lose one connection and they’re still reachable."})]}),(0,t.jsxs)("div",{style:a,children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700},children:Math.round(r.effective.size).toLocaleString()}),(0,t.jsxs)("div",{style:{fontSize:12.5,color:"#b8c4c4"},children:["effective reach of your ",r.effective.n.toLocaleString()," connections (",x(r.effective.efficiency)," non-overlapping)"]}),(0,t.jsxs)("div",{style:{fontSize:11.5,color:"#778",marginTop:4},children:["From ",r.effective.ties.toLocaleString()," ",1===r.effective.ties?"tie":"ties"," between your connections seen in circle scans so far, so it can only come down as you scan more."]})]})]}),r.top.length>0&&(0,t.jsxs)("div",{style:{...a,marginTop:10,padding:0},children:[(0,t.jsx)("div",{style:{padding:"10px 14px",fontSize:12.5,color:"#b8c4c4",borderBottom:m.LINE},children:"Your connections who reach the most people no one else does"}),r.top.map((e,n)=>(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"8px 14px",borderBottom:n<r.top.length-1?"1px solid rgba(255,255,255,0.04)":"none",fontSize:13},children:[(0,t.jsxs)("span",{style:{width:22,color:"#778"},children:["#",n+1]}),(0,t.jsx)("span",{style:{width:8,height:8,borderRadius:"50%",background:b[e.tier]||"#667",flexShrink:0}}),(0,t.jsxs)("span",{style:{flex:1,minWidth:0,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:[(0,t.jsx)("b",{children:e.name}),e.company?(0,t.jsxs)("span",{style:{color:"#8b9a9a"},children:[" · ",e.company]}):null]}),(0,t.jsxs)("span",{style:{color:"#b8c4c4",whiteSpace:"nowrap"},children:[e.circle.toLocaleString()," in circle"]}),(0,t.jsxs)("span",{style:{color:"#00ff88",whiteSpace:"nowrap"},children:[e.only.toLocaleString()," only them (",x(e.share),")"]}),(0,t.jsx)(p.default,{href:`/?chain=${encodeURIComponent(e.id)}`,style:{color:"#3498DB",textDecoration:"none",whiteSpace:"nowrap"},children:"Explore →"})]},e.id))]})]})]})}let S={1:"Observer",11:"Connector",31:"Networker",51:"Strategist",76:"Architect"};function w(){let{userId:e,userName:o,userProfile:l}=(0,h.useUser)(),s=(0,r.useRouter)(),a="insights"===(0,r.useSearchParams)().get("view")?"insights":"profile",c=l||{name:o||"User",headline:"",sectors:[],goals:[]},[g,y]=(0,n.useState)(null),[m,b]=(0,n.useState)(!0),[x,w]=(0,n.useState)([]),[k,C]=(0,n.useState)({total:0,sent:0,accepted:0}),[M,B]=(0,n.useState)({degree1:[],degree2:[],skips:[]}),[z,I]=(0,n.useState)(null);if((0,n.useEffect)(()=>{!u.IS_DEMO&&e&&t();async function t(){fetch("/api/settings").then(e=>e.json().then(t=>e.ok&&t.settings?t:Promise.reject(Error(t.error)))).then(e=>I(e.settings.sectorFocus||{sectors:[],strength:"lean"})).catch(()=>I({failed:!0}));let t=await (0,i.loadNetwork)(e),n=t.degree1,r=t.degree2,o={S:0,A:0,B:0,C:0,D:0};n.forEach(e=>{o[e.tier]=(o[e.tier]||0)+1});let l={S:0,A:0,B:0,C:0,D:0};r.forEach(e=>{l[e.tier]=(l[e.tier]||0)+1});let s=[...new Set(r.map(e=>e.source_connection_id).filter(Boolean))].length,a=n.filter(e=>e.is_catalyst).length,d={};n.forEach(e=>{e.company&&(d[e.company]=(d[e.company]||0)+1)});let c=Object.entries(d).sort((e,t)=>t[1]-e[1]).slice(0,10),u=100*o.S+40*o.A+15*o.B+5*o.C+ +o.D+200*s+150*a+50*l.S+n.length,g=Math.floor(Math.sqrt(u/10)),h=g*g*10,f=(g+1)*(g+1)*10;y({d1Count:n.length,d2Count:r.length,tiers:o,d2Tiers:l,clusters:s,catalysts:a,networkPower:u,level:g,xpProgress:(u-h)/(f-h)*100,topCompanies:c,unlockedPaths:0}),fetch("/api/scraper").then(e=>e.json()).then(e=>B({degree1:n,degree2:r,skips:e.skips||[]})).catch(()=>B({degree1:n,degree2:r,skips:[]})),fetch(`/api/notifications?userId=${e}`).then(e=>e.json()).then(e=>w(e.notifications||[])).catch(()=>{}),fetch("/api/queue").then(e=>e.json()).then(e=>{let t=e.items||[];C({total:t.length,sent:t.filter(e=>"sent"===e.status).length,accepted:t.filter(e=>"accepted"===e.status).length})}).catch(()=>{}),b(!1)}},[e]),u.IS_DEMO)return(0,t.jsxs)("div",{style:{minHeight:"100vh",background:"#0a0a1a",color:"rgba(255,255,255,0.7)",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:12,textAlign:"center",padding:24,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},children:[(0,t.jsx)("h2",{style:{margin:0,fontSize:20,fontWeight:700,color:"#fff"},children:"Not part of the demo"}),(0,t.jsx)("p",{style:{margin:0,fontSize:13},children:"The public demo includes the Network Circle and Degrees views only."}),(0,t.jsx)(p.default,{href:"/",style:{fontSize:12,color:"rgba(255,255,255,0.5)",textDecoration:"none"},children:"← Back to the network"})]});if(m)return(0,t.jsx)("div",{style:{minHeight:"100vh",display:"flex",alignItems:"center",justifyContent:"center",background:"#0a0a1a",color:"#fff"},children:"Loading profile..."});let F={S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"},R=[{label:"First S-Tier",done:g.tiers.S>0,icon:"👑"},{label:"100 Connections",done:g.d1Count>=100,icon:"🔗"},{label:"500 Connections",done:g.d1Count>=500,icon:"🌐"},{label:"First Cluster",done:g.clusters>0,icon:"🔭"},{label:"10 Clusters",done:g.clusters>=10,icon:"🏰"},{label:"50 S-Tier",done:g.tiers.S>=50,icon:"💎"},{label:"Catalyst Found",done:g.catalysts>0,icon:"⚡"},{label:"Level 25",done:g.level>=25,icon:"🎯"},{label:"Level 50",done:g.level>=50,icon:"🚀"},{label:"D2 S-Tier > 50",done:g.d2Tiers.S>=50,icon:"🌟"}];return(0,t.jsxs)("div",{style:{height:"100vh",background:"#0a0a1a",color:"#fff",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',display:"flex",flexDirection:"column",overflow:"hidden"},children:[(0,t.jsxs)("header",{style:{padding:"16px 24px",borderBottom:"1px solid rgba(255,255,255,0.1)",display:"flex",alignItems:"center",gap:16},children:[(0,t.jsxs)(p.default,{href:"/",style:{display:"flex",alignItems:"center",gap:6,color:"#888",textDecoration:"none",fontSize:13,fontWeight:600,padding:"6px 14px",borderRadius:6,background:"rgba(255,255,255,0.06)",border:"1px solid rgba(255,255,255,0.1)"},children:[(0,t.jsx)("span",{style:{fontSize:16},children:"←"})," Back to Map"]}),(0,t.jsx)("h1",{style:{fontSize:22,fontWeight:700,margin:0,background:"linear-gradient(135deg, #FFD700, #9B59B6, #3498DB)",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"},children:"Profile"}),(0,t.jsx)("div",{role:"tablist","aria-label":"Profile or Insights",style:{display:"flex",gap:3,marginLeft:8,padding:3,borderRadius:9,background:"rgba(255,255,255,0.06)"},children:[["profile","Profile"],["insights","Insights"]].map(([e,n])=>(0,t.jsxs)("button",{type:"button",role:"tab","aria-selected":a===e,onClick:()=>s.replace("insights"===e?"/profile?view=insights":"/profile",{scroll:!1}),style:{padding:"6px 14px",borderRadius:7,border:"none",cursor:"pointer",fontSize:13,fontWeight:700,background:a===e?"linear-gradient(135deg, #FFD700, #FF6B35)":"transparent",color:a===e?"#000":"#aab"},children:["insights"===e?"✦ ":"",n]},e))})]}),(0,t.jsx)("div",{style:{flex:1,overflow:"auto",padding:"30px 20px"},children:"insights"===a?(0,t.jsxs)("div",{style:{maxWidth:820,margin:"0 auto"},children:[(0,t.jsx)("div",{style:{fontSize:13,color:"#8a8fa8",lineHeight:1.6},children:"How your network holds together, from the circles you’ve scanned. Only your own numbers, never a comparison with anyone else’s."}),(0,t.jsx)(v,{})]}):(0,t.jsxs)("div",{style:{maxWidth:700,margin:"0 auto"},children:[(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.05)",borderRadius:16,padding:32,marginBottom:24,border:"1px solid rgba(255,215,0,0.2)",textAlign:"center"},children:[(0,t.jsx)("div",{style:{width:100,height:100,borderRadius:"50%",margin:"0 auto 16px",background:"linear-gradient(135deg, #FFD700, #FF6B35)",display:"flex",alignItems:"center",justifyContent:"center",fontSize:36,fontWeight:800,color:"#000",boxShadow:"0 0 30px rgba(255,215,0,0.3)"},children:g.level}),(0,t.jsx)("div",{style:{fontSize:24,fontWeight:700,marginBottom:4},children:c.name}),(0,t.jsx)("div",{style:{fontSize:14,color:"#888",marginBottom:4},children:c.headline}),(0,t.jsx)("div",{style:{display:"inline-block",padding:"4px 16px",borderRadius:20,background:"rgba(255,215,0,0.15)",border:"1px solid rgba(255,215,0,0.3)",color:"#FFD700",fontSize:13,fontWeight:700,marginBottom:16},children:function(e){let t="Observer";for(let[n,r]of Object.entries(S))e>=parseInt(n)&&(t=r);return t}(g.level)}),(0,t.jsxs)("div",{style:{maxWidth:300,margin:"0 auto"},children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",fontSize:10,color:"#666",marginBottom:4},children:[(0,t.jsxs)("span",{children:["Level ",g.level]}),(0,t.jsxs)("span",{children:["Level ",g.level+1]})]}),(0,t.jsx)("div",{style:{height:8,background:"rgba(255,255,255,0.1)",borderRadius:4},children:(0,t.jsx)("div",{style:{height:"100%",width:`${Math.min(g.xpProgress,100)}%`,background:"linear-gradient(90deg, #FFD700, #FF6B35)",borderRadius:4,transition:"width 1s ease"}})}),(0,t.jsxs)("div",{style:{fontSize:10,color:"#888",marginTop:4},children:["Network Power: ",g.networkPower.toLocaleString()]})]})]}),(0,t.jsx)(d,{degree1:M.degree1,degree2:M.degree2,skips:M.skips}),(0,t.jsxs)("div",{style:{background:"rgba(255,107,53,0.06)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,107,53,0.2)"},children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:12},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,margin:0,color:"#FF6B35"},children:"Queue Progress"}),(0,t.jsx)(p.default,{href:"/queue",style:{fontSize:11,color:"#FF6B35",textDecoration:"none",fontWeight:600},children:"View Queue →"})]}),(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr 1fr",gap:12},children:[(0,t.jsxs)("div",{style:{textAlign:"center"},children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700,color:"#FFA500"},children:k.total}),(0,t.jsx)("div",{style:{fontSize:10,color:"#888"},children:"In Queue"})]}),(0,t.jsxs)("div",{style:{textAlign:"center"},children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700,color:"#3498DB"},children:k.sent}),(0,t.jsx)("div",{style:{fontSize:10,color:"#888"},children:"Sent"})]}),(0,t.jsxs)("div",{style:{textAlign:"center"},children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700,color:"#00ff88"},children:k.accepted}),(0,t.jsx)("div",{style:{fontSize:10,color:"#888"},children:"Accepted"})]})]})]}),x.length>0&&(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsxs)("h3",{style:{fontSize:14,fontWeight:700,marginTop:0,marginBottom:12},children:["Recent Activity (",x.filter(e=>!e.seen).length," new)"]}),(0,t.jsx)("div",{style:{display:"flex",flexDirection:"column",gap:6,maxHeight:200,overflowY:"auto"},children:x.slice(0,10).map(e=>(0,t.jsxs)("div",{style:{display:"flex",gap:8,alignItems:"center",padding:"6px 8px",borderRadius:6,background:e.seen?"transparent":"rgba(255,215,0,0.05)",borderLeft:e.seen?"none":"2px solid #FFD700"},children:[(0,t.jsx)("span",{style:{fontSize:16},children:e.icon||"📌"}),(0,t.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,t.jsx)("div",{style:{fontSize:12,fontWeight:600,color:e.seen?"#888":"#fff"},children:e.title}),e.message&&(0,t.jsx)("div",{style:{fontSize:10,color:"#666"},children:e.message})]}),(0,t.jsx)("span",{style:{fontSize:9,color:"#555",flexShrink:0},children:new Date(e.created_at).toLocaleDateString()})]},e.id))})]}),(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr 1fr",gap:12,marginBottom:24},children:[(0,t.jsx)(j,{label:"Connections",value:g.d1Count}),(0,t.jsx)(j,{label:"Degree-2 Reach",value:g.d2Count}),(0,t.jsx)(j,{label:"Clusters",value:g.clusters}),(0,t.jsx)(j,{label:"S-Tier",value:g.tiers.S,color:"#FFD700"}),(0,t.jsx)(j,{label:"A-Tier",value:g.tiers.A,color:"#9B59B6"}),(0,t.jsx)(j,{label:"Catalysts",value:g.catalysts,color:"#00ff88"})]}),(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,marginTop:0,marginBottom:12},children:"Tier Distribution"}),["S","A","B","C","D"].map(e=>{let n=g.tiers[e]||0,r=g.d1Count>0?n/g.d1Count*100:0;return(0,t.jsxs)("div",{style:{marginBottom:8},children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",fontSize:11,marginBottom:2},children:[(0,t.jsxs)("span",{style:{color:F[e],fontWeight:600},children:[e,"-Tier"]}),(0,t.jsxs)("span",{style:{color:"#888"},children:[n," (",r.toFixed(1),"%)"]})]}),(0,t.jsx)("div",{style:{height:6,background:"rgba(255,255,255,0.08)",borderRadius:3},children:(0,t.jsx)("div",{style:{height:"100%",width:`${r}%`,background:F[e],borderRadius:3}})})]},e)})]}),(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,marginTop:0,marginBottom:12},children:"Degree-2 Reach"}),(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:12},children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{style:{fontSize:24,fontWeight:700,color:"#FF6B35"},children:g.d2Count}),(0,t.jsx)("div",{style:{fontSize:11,color:"#888"},children:"People reachable via bridges"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{style:{fontSize:24,fontWeight:700,color:"#FFD700"},children:g.d2Tiers.S}),(0,t.jsx)("div",{style:{fontSize:11,color:"#888"},children:"S-Tier degree-2"})]})]})]}),(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsxs)("h3",{style:{fontSize:14,fontWeight:700,marginTop:0,marginBottom:12},children:["Milestones (",R.filter(e=>e.done).length,"/",R.length,")"]}),(0,t.jsx)("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:8},children:R.map((e,n)=>(0,t.jsxs)("div",{style:{padding:"8px 10px",borderRadius:8,fontSize:12,background:e.done?"rgba(255,215,0,0.08)":"rgba(255,255,255,0.02)",border:`1px solid ${e.done?"rgba(255,215,0,0.2)":"rgba(255,255,255,0.05)"}`,color:e.done?"#FFD700":"#555",display:"flex",alignItems:"center",gap:6},children:[(0,t.jsx)("span",{style:{fontSize:16},children:e.done?e.icon:"🔒"}),(0,t.jsx)("span",{style:{fontWeight:e.done?600:400},children:e.label})]},n))})]}),(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,marginBottom:24,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,marginTop:0,marginBottom:12},children:"Top Companies in Your Network"}),g.topCompanies.map(([e,n],r)=>(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",padding:"4px 0",borderBottom:r<g.topCompanies.length-1?"1px solid rgba(255,255,255,0.04)":"none",fontSize:12},children:[(0,t.jsx)("span",{children:e}),(0,t.jsx)("span",{style:{color:"#888"},children:n})]},r))]}),(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:12,padding:20,border:"1px solid rgba(255,255,255,0.08)"},children:[(0,t.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:12},children:[(0,t.jsx)("h3",{style:{fontSize:14,fontWeight:700,margin:0},children:"Your Sectors"}),(0,t.jsxs)(p.default,{href:"/settings#sector",style:{fontSize:11,color:"#3498DB",textDecoration:"none",fontWeight:600},children:[z?.sectors?.length?"Change":z&&!z.failed?"Pick in Settings":"Settings"," →"]})]}),z?z.failed?(0,t.jsx)("div",{style:{fontSize:12,color:"#ff7676"},children:"Couldn’t load your sectors. Reload this page, or open Settings to see them."}):z.sectors?.length?(0,t.jsxs)("div",{style:{display:"flex",flexWrap:"wrap",gap:6,alignItems:"center"},children:[z.sectors.map(e=>{let n=(0,f.sectorByKey)(e);return(0,t.jsx)("span",{style:{padding:"4px 12px",borderRadius:20,fontSize:11,fontWeight:600,background:`${n.color}26`,border:`1px solid ${n.color}66`,color:n.color},children:n.label},e)}),(0,t.jsxs)("span",{style:{fontSize:11,color:"#888"},children:["strong"===z.strength?"Strong":"Lean",": companies here count for more in your scores."]})]}):(0,t.jsx)("div",{style:{fontSize:12,color:"#888"},children:"None picked. Pick up to three in Settings and companies in them count for more in your scores."}):(0,t.jsx)("div",{style:{fontSize:12,color:"#888"},children:"Loading…"})]})]})})]})}function j({label:e,value:n,color:r}){return(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.04)",borderRadius:10,padding:"14px 12px",border:"1px solid rgba(255,255,255,0.08)",textAlign:"center"},children:[(0,t.jsx)("div",{style:{fontSize:22,fontWeight:700,color:r||"#fff"},children:n}),(0,t.jsx)("div",{style:{fontSize:10,color:"#888",marginTop:2},children:e})]})}e.s(["default",0,function(){return(0,t.jsx)(n.Suspense,{fallback:null,children:(0,t.jsx)(g.default,{children:(0,t.jsx)(w,{})})})}],99201)},64666,e=>{"use strict";var t=e.i(7214);function n(e=[],r=[]){let i=new Set((r||[]).map(t.keyFor)),o=new Map;for(let n of e||[]){let e=n?.source_connection_id;if(null==e)continue;let r=(0,t.keyFor)(n);if(i.has(r))continue;let l=o.get(r);l||o.set(r,l=new Set),l.add(e)}let l=new Map;for(let e of o.values())for(let t of e){let n=l.get(t)||{reach:0,only:0,total:0};n.reach+=1/e.size,n.total+=1,1===e.size&&(n.only+=1),l.set(t,n)}return l}e.s(["bridgeOverlap",0,function(e=[],r=[]){let i=n(e,r),o=new Set((r||[]).map(t.keyFor)),l=new Map;for(let n of e||[]){let e=n?.source_connection_id;if(null==e)continue;let r=(0,t.keyFor)(n);if(o.has(r))continue;let i=l.get(r);i||l.set(r,i=new Set),i.add(e)}let s=new Map;for(let e of l.values()){if(e.size<2)continue;let t=[...e];for(let e=0;e<t.length;e++)for(let n=e+1;n<t.length;n++){let r=t[e]<t[n]?`${t[e]}|${t[n]}`:`${t[n]}|${t[e]}`;s.set(r,(s.get(r)||0)+1)}}let a=new Map;for(let[e,t]of s){let[n,r]=e.split("|"),o=i.get(n).total+i.get(r).total-t,l=o?t/o:0;for(let[e,i]of[[n,r],[r,n]]){let n=a.get(e);(!n||l>n.share)&&a.set(e,{with:i,share:l,shared:t})}}return a},"exclusiveReach",0,n,"redundancy",0,function(e=[],t=[]){let r=n(e,t),i=0,o=0;for(let e of r.values())i+=e.reach,o+=e.only;return i?1-o/i:0}])},89154,e=>{"use strict";var t=e.i(90179);function n(e){let n=(0,t.readTitle)(e);return{key:n.key,label:n.label,level:n.level}}function r(e){return(0,t.currentCompany)(e)}let i=[{key:"defense",label:"Government, Defense & Aerospace",color:"#7f8c8d",words:/\b(government|federal|state of|county|city of|defen[cs]e|army|navy|air force|marine corps|military|dod|nasa|aerospace|lockheed|northrop|boeing|raytheon|l3harris|leidos|blue origin|spacex|public sector)\b/i},{key:"finance",label:"Finance & Investing",color:"#2ecc71",words:/\b(bank|banking|capital|ventures?|vc|investments?|investor|fund|private equity|growth equity|asset management|wealth|trading|trader|hedge|crypto|blockchain|web3|defi|fintech|stripe|coinbase|blackrock|robinhood|goldman|morgan stanley|jpmorgan|chase|bny|mellon|wells fargo|citi|citigroup|capital one|fidelity|vanguard|schwab|visa|mastercard|amex|american express|paypal|insurance|accounting|cpa|financial)\b/i},{key:"health",label:"Healthcare & Biotech",color:"#e74c3c",words:/\b(health|healthcare|medical|medicine|hospital|clinic|pharma|pharmaceutical|biotech|nurse|nursing|physician|doctor|dental|therapy|therapist|wellness)\b/i},{key:"education",label:"Education",color:"#f1c40f",words:/\b(university|college|school|education|student|professor|teacher|academy|phd|faculty|alumni)\b/i},{key:"media",label:"Marketing & Media",color:"#e67e22",words:/\b(marketing|brand|branding|advertising|agency|media|content|social media|creative|creator|influencer|pr|public relations|communications|tiktok|pinterest|youtube|growth marketing)\b/i},{key:"entertainment",label:"Entertainment & Gaming",color:"#9b59b6",words:/\b(entertainment|film|movie|music|records|gaming|games?|esports|studio|studios|netflix|disney|spotify|hollywood|theater|theatre|sports)\b/i},{key:"tech",label:"Tech, Software & AI",color:"#3498db",words:/\b(software|saas|engineer|engineering|developer|tech|technology|technologies|ai|artificial intelligence|machine learning|ml|data|cloud|cyber|security|devops|product manager|google|microsoft|apple|meta|amazon|nvidia|openai|anthropic|palantir|salesforce|oracle|ibm|intel|app|apps|startup|platform|labs?)\b/i},{key:"consulting",label:"Consulting, Legal & Services",color:"#1abc9c",words:/\b(consulting|consultant|consultancy|deloitte|accenture|mckinsey|kpmg|pwc|ey|bain|bcg|legal|law|lawyer|attorney|paralegal|recruiting|recruiter|staffing|talent)\b/i},{key:"realestate",label:"Real Estate & Construction",color:"#d35400",words:/\b(real estate|realtor|realty|property|properties|construction|architecture|architect|mortgage|homes|housing|builders?)\b/i},{key:"consumer",label:"Retail, Consumer & Hospitality",color:"#ff79c6",words:/\b(retail|e-?commerce|shopify|consumer|cpg|fashion|apparel|beauty|cosmetics|food|beverage|restaurant|hospitality|hotel|travel|tourism|coca-cola|nike|store|shop)\b/i},{key:"industry",label:"Manufacturing, Energy & Logistics",color:"#95a5a6",words:/\b(manufacturing|energy|oil|gas|solar|utilities|automotive|tesla|siemens|ge|general electric|honeywell|3m|logistics|supply chain|shipping|freight|fedex|ups|industrial|mining|chemicals?)\b/i},{key:"nonprofit",label:"Nonprofit & Community",color:"#bdc3c7",words:/\b(nonprofit|non-profit|foundation|charity|ngo|church|ministry|volunteer)\b/i}],o={key:"unknown",label:"Unclear",color:"#555c66"},l=Object.fromEntries([...i,o].map(e=>[e.key,e])),s=e=>l[e]||o;function a(e,t){for(let n of[e,t]){if(!n)continue;let e=i.find(e=>e.words.test(n));if(e)return e}return o}let d=(e,t)=>a(e,t).key,c=e=>n(e).level>=4;e.s(["INDUSTRIES",0,i,"UNKNOWN_INDUSTRY",0,o,"buildCompanyIndex",0,function(e=[]){let n=new Map,r=e=>(n.has(e)||n.set(e,(0,t.rolesWithCompanies)(e)),n.get(e)),{industries:i}=(0,t.networkCompanies)(e,{industryOf:d,rolesOf:r}),o=new Map;for(let t of e){let e=t.profile_url||`id:${t.id}`,n=o.get(e);(!n||(t.degree||9)<(n.degree||9))&&o.set(e,t)}let l=new Map;for(let e of o.values()){let t=r(e).find(e=>!e.former)?.company;if(!t)continue;let n=l.get(t);n||(n={name:t,people:[],d1:0,d2:0,d3:0,S:0,A:0,senior:0},l.set(t,n)),n.people.push(e),1===e.degree?n.d1++:2===e.degree?n.d2++:n.d3++,"S"===e.tier&&n.S++,"A"===e.tier&&n.A++,c(e.headline)&&n.senior++}for(let e of l.values())e.industry=s(i.get(e.name));return l},"companyLinks",0,function(e=[],t=[]){let n=new Map;for(let t of e){let e=r(t);e&&n.set(t.id,e)}let i=new Map;for(let e of t){let t=n.get(e.source_connection_id),o=r(e);if(!t||!o||t===o)continue;let[l,s]=t<o?[t,o]:[o,t],a=`${l}\u0000${s}`,d=i.get(a);d||(d={a:l,b:s,weight:0,via:new Set},i.set(a,d)),d.weight++,d.via.add(e.source_connection_id)}return[...i.values()]},"companyOf",0,r,"getSeniority",0,n,"industryByKey",0,s,"industryOf",0,a,"isSenior",0,c,"waysInto",0,function(e,t=[],n=[]){let i=t.filter(t=>r(t)===e),o=new Map;for(let t of n)r(t)===e&&o.set(t.source_connection_id,(o.get(t.source_connection_id)||0)+1);let l=new Map(t.map(e=>[e.id,e]));return{direct:i,bridges:[...o.entries()].map(([e,t])=>({bridge:l.get(e),n:t})).filter(e=>e.bridge).sort((e,t)=>t.n-e.n||(Number(t.bridge.power_score)||0)-(Number(e.bridge.power_score)||0))}}])},19821,e=>{"use strict";async function t(e){let t=e?`/api/network?userId=${encodeURIComponent(e)}`:"/api/network",n=await fetch(t);if(!n.ok)throw Error(`Failed to load network (${n.status})`);let r=await n.json();return{degree1:r.degree1||[],degree2:r.degree2||[],degree3:r.degree3||[],ties:Number(r.ties)||0}}e.s(["loadNetwork",0,t])},48235,51798,e=>{"use strict";let t={fast:{label:"Fast",pagePause:20,chunkCooldown:60,profileGap:60},medium:{label:"Medium",pagePause:45,chunkCooldown:180,profileGap:90},slow:{label:"Slow",pagePause:90,chunkCooldown:300,profileGap:120}},n=e=>t[e]||t.fast;function r(e,t){let r=n(e),i=Math.max(0,Math.floor(Number(t)||0));return i*(6+r.pagePause)+Math.floor(i/10)*r.chunkCooldown}e.s(["PACES",0,t,"PACE_NAMES",0,["slow","medium","fast"],"durationText",0,function(e){if(!(e>=60))return"under a minute";let t=Math.round(e/60);if(t<60)return`about ${t} min`;let n=Math.floor(t/60),r=t%60;return`about ${n} h${r?` ${r} min`:""}`},"paceOf",0,n,"paceSeconds",0,r,"searchesPerHour",0,function(e){let t=n(e);return Math.round(3600/(6+t.pagePause+t.chunkCooldown/10))}],51798);var i=e.i(7214);function o(e,t){return e?t.scanned.has(e.id)||e.profile_url&&t.read?.has((0,i.keyFor)(e))?"scanned":e.profile_url&&t.hidden.has((0,i.keyFor)(e))?"hidden":"todo":"todo"}function l(e,t){if(!e||1!==e.degree||null==e.unlocked_from_bridge_id)return null;let n=o(e,t);return"todo"===n?"ready":n}e.s(["circleScanCost",0,function(e=100,t="fast"){let n=Math.max(1,Math.min(100,Math.round(e)||100)),i=t&&"fast"!==t?Math.max(5,Math.round(r(t,n)/60)):n>=100?55:Math.max(5,Math.round(.55*n));return{profileViews:1,searches:n,minutes:i}},"circleState",0,o,"reachIndex",0,function(e=[],t=[],n={}){let r=new Set;for(let e of t||[])e?.source_connection_id!=null&&r.add(e.source_connection_id);let o=new Set;for(let e of n?.skips||[])e?.profileUrl&&o.add((0,i.keyFor)({profile_url:e.profileUrl}));let l=new Set;for(let e of n?.read||[])e&&l.add((0,i.keyFor)({profile_url:e}));let s=new Map;for(let[e,t]of Object.entries(n?.lists||{}))e&&t&&s.set((0,i.keyFor)({profile_url:e}),t);let a=new Map;for(let t of e||[]){let e=t?.unlocked_from_bridge_id;if(null==e||1!==t.degree)continue;let n=a.get(e);n||a.set(e,n=[]),n.push(t)}return{scanned:r,read:l,hidden:o,reachedFrom:a,lists:s}},"reachState",0,l,"readyByCircle",0,function(e){let t=new Map;for(let[n,r]of e.reachedFrom){let i=r.filter(t=>"ready"===l(t,e)).length;i&&t.set(n,i)}return t},"readyToScan",0,function(e,t){return(e||[]).filter(e=>"ready"===l(e,t)).sort(i.compareBridges)},"scanBars",0,function(e,t){let n=o(e,t),r=e?.profile_url?t.lists?.get((0,i.keyFor)(e)):null;return"hidden"===n?null:r?r.more?r.total?Math.max(1,Math.min(4,Math.round(5*Math.min(1,10*r.pages/r.total)))):2:5:"scanned"===n?2:null}],48235)},69083,e=>{"use strict";var t=e.i(89154);let n=new Map(t.INDUSTRIES.map(e=>[e.key,e.color])),r=new Map([...t.INDUSTRIES.map(e=>[e.key,Object.freeze({key:e.key,label:e.label,color:e.color,group:e.key,kind:"industry"})]),...Object.entries({software:["Software & SaaS","tech","function"],"ai-data":["AI & Data","tech","function"],cybersecurity:["Cybersecurity","tech","function"],telecom:["Telecom","tech","industry"],fintech:["Fintech & Payments","finance","industry"],banking:["Banking & Lending","finance","industry"],"vc-pe":["Venture Capital & Private Equity","finance","industry"],wealth:["Wealth & Asset Management","finance","industry"],insurance:["Insurance","finance","industry"],accounting:["Accounting & Tax","finance","function"],crypto:["Crypto & Web3","finance","industry"],hospitals:["Hospitals & Clinics","health","industry"],dental:["Dental","health","industry"],"pharma-biotech":["Pharma & Biotech","health","industry"],"medical-devices":["Medical Devices","health","industry"],"mental-health":["Mental Health","health","industry"],"fitness-wellness":["Fitness & Wellness","health","industry"],veterinary:["Veterinary & Animal Care","health","industry"],k12:["K-12 Education","education","industry"],"higher-ed":["Higher Education","education","industry"],"marketing-advertising":["Marketing & Advertising","media","function"],"pr-comms":["PR & Communications","media","function"],"media-publishing":["Media & Publishing","media","industry"],"creator-economy":["Creator Economy","media","industry"],"film-tv-music":["Film, TV & Music","entertainment","industry"],"gaming-esports":["Gaming & Esports","entertainment","industry"],sports:["Sports","entertainment","industry"],"ecommerce-retail":["E-commerce & Retail","consumer","industry"],"consumer-goods":["Consumer Goods","consumer","industry"],restaurants:["Restaurants & Food Service","consumer","industry"],"hospitality-travel":["Hospitality & Travel","consumer","industry"],"beauty-personal-care":["Beauty & Personal Care","consumer","industry"],logistics:["Logistics & Supply Chain","industry","industry"],manufacturing:["Manufacturing","industry","industry"],energy:["Energy & Utilities","industry","industry"],automotive:["Automotive","industry","industry"],agriculture:["Agriculture & Farming","industry","industry"],"aerospace-defense":["Aerospace & Defense","defense","industry"],military:["Military","defense","industry"],government:["Government & Public Sector","defense","industry"],legal:["Legal","consulting","function"],"management-consulting":["Management Consulting","consulting","function"],"hr-recruiting":["HR & Recruiting","consulting","function"],"security-services":["Security Services","consulting","function"],"real-estate":["Real Estate","realestate","industry"],"construction-trades":["Construction & Trades","realestate","industry"],charities:["Nonprofits & Charities","nonprofit","industry"],"social-work":["Social Work & Human Services","nonprofit","industry"],faith:["Faith & Ministry","nonprofit","industry"]}).map(([e,[r,i,o]])=>[e,Object.freeze({key:e,label:r,color:n.get(i)||t.UNKNOWN_INDUSTRY.color,group:i,kind:o})])]);e.s(["sectorByKey",0,function(e){return r.get(e)||{key:e,label:t.UNKNOWN_INDUSTRY.label,color:t.UNKNOWN_INDUSTRY.color,group:null,kind:null}}])},7214,36774,e=>{"use strict";let t=/^[A-Za-z0-9_-]+\.(webp|jpg|jpeg|png)$/,n="/avatars/";function r(e){return"string"==typeof e&&e.startsWith(n)&&t.test(e.slice(n.length))?e:null}e.s(["localPhoto",0,r],36774);let i={S:0,A:1,B:2,C:3,D:4};function o(e){let t=parseFloat(e?.power_score);return Number.isFinite(t)?t:0}function l(e){return Math.round(10*o(e))/10}function s(e){return String(e?.profile_url||"").split(/[?#]/)[0].replace(/\/+$/,"")||`id:${e?.id}`}let a=(e,t)=>String(e??"").localeCompare(String(t??""),void 0,{numeric:!0});function d(e,t){return(i[e.tier]??9)-(i[t.tier]??9)||o(t)-o(e)||String(e.name||"").localeCompare(String(t.name||""))||a(e.id,t.id)}function c(e,t){return e.bridge&&t.bridge?d(e.bridge,t.bridge):e.bridge?-1:t.bridge?1:a(e.id,t.id)}function u(e,t){return t.score-e.score||t.waysIn-e.waysIn||c(e.routes[0]||g,t.routes[0]||g)||String(e.person.name||"").localeCompare(String(t.person.name||""))||(e.key<t.key?-1:+(e.key>t.key))}let g={id:null,bridge:null};function h(e){let t=String(e||"").trim().split(/\s+/).filter(Boolean);return t.length<2?t[0]||"":`${t[0]} ${t[t.length-1].charAt(0)}.`}function f(e,t){let n=String(e||"");return t<=1?n?"…":"":n.length>t?`${n.slice(0,t-1)}…`:n}e.s(["TIERS",0,["S","A","B","C","D"],"compareBridges",0,d,"comparePower",0,u,"convergeLayout",0,function(e,t=800,n=!1,{cards:r=!1,mutuals:i=0}={}){let o=r?46:n?40:34,l=Math.round(t*(n?.44:.36)),s=Math.round(t*(n?.8:r?.6:.62)),a=[],d=null;for(let t of e?.routes||[])t.bridge?a.push({id:t.id,bridge:t.bridge,unresolved:!1,count:1}):d?d.count++:a.push(d={id:null,bridge:null,unresolved:!0,count:1});let c=Math.max(0,Math.floor(Number(i)||0)-(e?.waysIn||0)),u=Math.min(60,c),g=r?12:11,p=r?220:n?96:120,y=Math.max(1,Math.floor(p/g)+1),m=Math.ceil(u/y),b=u?40+m*g:0,x=Math.max(0,a.length-1)*o+b,v=Math.max(n?190:r?250:220,32+x+48),S=v/2,w=S-x/2,j=Math.max(4,Math.floor((l-10-42)/6)),k=a.map((e,t)=>{let n=e.unresolved?`can't be named (${e.count})`:e.bridge.name||"";return{...e,x:l,y:w+t*o,r:6,primary:0===t&&!e.unresolved,label:n.length<=j?n:f(e.unresolved?n:h(n),j)}}),C={x:s,y:S,r:17*!r,rings:r?[]:[32,50,70].filter(e=>e<=S-4)},M=k.map(t=>({key:e?.key,bridgeId:t.id,primary:t.primary,unresolved:t.unresolved,tier:t.bridge?.tier??null,x1:t.x,y1:t.y,x2:C.x,y2:C.y})),B={x:20,y:S,r:14},z=k.map(e=>({id:e.id,x1:B.x,y1:B.y,x2:e.x,y2:e.y})),I=e?[{key:e.key,p:e,x:C.x,y:C.y,r:C.r,rings:C.rings,big:!0,label:""}]:[],F=w+Math.max(0,a.length-1)*o+40,R=r?l-236+8:l-p,D=Array.from({length:u},(e,t)=>({x:R+t%y*g,y:F+Math.floor(t/y)*g})),_=e?.waysIn?e.waysIn/(e.waysIn+c):1;return{width:t,height:v,you:B,target:C,people:I,bridges:k,links:M,spokes:z,ghosts:D,unscanned:c,ghostLabel:u?{x:R,y:F-13}:null,drawn:_}},"keyFor",0,s,"mapCount",0,function(e,t=10){let n=Math.max(0,Math.min(100,Number(e)||0));return n<=50?t:Math.max(1,Math.round(t*(100-n)/50))},"mostMutuals",0,function(e=[],t=()=>0,n=7){return[...e].sort((e,n)=>Math.max(t(n)||0,n.waysIn)-Math.max(t(e)||0,e.waysIn)||n.waysIn-e.waysIn||u(e,n)).slice(0,n)},"routeIndex",0,function(e=[]){let t=new Map;for(let n of e||[]){let e=s(n),r=t.get(e);r||(r=new Set,t.set(e,r)),r.add(n.source_connection_id??null)}return t},"routesFor",0,function(e,t,n){return e?[...t?.get(s(e))??(null!=e.source_connection_id?new Set([e.source_connection_id]):new Set)].map(e=>({id:e,bridge:n?.get(e)??null})).sort(c):[]},"score",0,o,"score1",0,l,"separationPeople",0,function(e=[],t=[]){let n=new Map;for(let e of t||[])n.set(e.id,e);let i=new Map,o=new Map;for(let t of e||[]){let e=s(t);o.set(t.id,e);let n=i.get(e);n?function(e,t){let n=l(e)-l(t);if(n)return n>0;let i=!!r(e.profile_image_url);return!!r(t.profile_image_url)!==i?i:0>a(e.id,t.id)}(t,n.person)&&(n.person=t):(n={key:e,person:t,rowIds:[],routeIds:new Set},i.set(e,n)),n.rowIds.push(t.id),n.routeIds.add(t.source_connection_id??null)}let d={people:i.size,byTier:{S:0,A:0,B:0,C:0,D:0},multi:0,bridges:0,unresolvedIds:0,peopleOnlyUnresolved:0,onlyUnresolvedVia:0},g=new Set,h=new Set,f=new Set,p=[];for(let e of i.values()){let t=[...e.routeIds].map(e=>({id:e,bridge:n.get(e)??null}));t.sort(c);let r=t.filter(e=>e.bridge);for(let e of t)(e.bridge?g:h).add(e.id);if(!r.length)for(let e of(d.peopleOnlyUnresolved++,t))f.add(e.id);let{person:i}=e,o=i.tier;void 0!==d.byTier[o]&&d.byTier[o]++,t.length>1&&d.multi++,p.push({key:e.key,person:i,score:l(i),tier:o,routes:t,waysIn:t.length,rowIds:e.rowIds,haystack:[i.name,i.headline,i.company,i.role,...r.map(e=>e.bridge.name)].filter(Boolean).join("\n").toLowerCase(),rank:0,tied:!1})}return d.bridges=g.size,d.unresolvedIds=h.size,d.onlyUnresolvedVia=f.size,p.sort(u),function(e){for(let t=0;t<e.length;t++){let n=e[t],r=e[t-1],i=r&&r.score===n.score&&r.waysIn===n.waysIn;n.rank=i?r.rank:t+1,i&&(n.tied=!0,r.tied=!0)}}(p),{people:p,rowToKey:o,summary:d}},"shortName",0,h,"summitLayout",0,function(e=[],t=800,n=!1,{cards:r=!1}={}){let i=r?50:n?36:26,o=Math.round(.42*t),l=Math.round(.58*t),s=e.map((e,n)=>{var o;return{key:e.key,p:e,x:l,y:16+n*i,r:r?0:(o=e.waysIn)>=4?8.5:3===o?7:2===o?5.5:4,label:f(`#${e.rank}${e.tied?"=":""} ${e.person.name||""}`,Math.floor((t-l-60)/6.2))}}),a=new Map,c="\0unresolved";for(let e of s)for(let t of e.p.routes){let n=t.bridge?t.id:c,r=a.get(n);r||(r={id:t.bridge?t.id:null,bridge:t.bridge,unresolved:!t.bridge,ys:[],count:0},a.set(n,r)),r.count++,r.ys.push(e.y)}let u=[...a.values()].map(e=>({...e,bary:e.ys.reduce((e,t)=>e+t,0)/e.ys.length}));u.sort((e,t)=>e.bary-t.bary||e.unresolved-t.unresolved||(e.bridge&&t.bridge?d(e.bridge,t.bridge):0));let g=s.length?s[s.length-1].y:16,p=function(e=[],t=18,n=0){let r=[];e.forEach((e,n)=>{for(r.push({sum:e-n*t,count:1});r.length>1&&r[r.length-2].sum/r[r.length-2].count>r[r.length-1].sum/r[r.length-1].count;){let e=r.pop();r[r.length-1].sum+=e.sum,r[r.length-1].count+=e.count}});let i=r.flatMap(e=>Array(e.count).fill(e.sum/e.count)).map((e,n)=>e+n*t),o=i.length&&i[0]<n?n-i[0]:0;return i.map(e=>e+o)}(u.map(e=>e.bary),r?36:18,16),y=Math.max(4,Math.floor((o-10-42)/6));u.forEach((e,t)=>{if(e.x=o,e.y=p[t],e.r=5,e.unresolved)e.label=f(`can't be named (${e.count})`,y);else{let t=e.bridge.name||"";e.label=t.length<=y?t:f(h(t),y)}delete e.ys});let m=new Map(u.map(e=>[e.unresolved?c:e.id,e]));for(let e of u)e.onlyFor=0,e.bestFor=0;for(let e of s){let t=e.p.routes[0],n=t?m.get(t.bridge?t.id:c):null;n&&n.bestFor++,1===e.p.waysIn&&n&&n.onlyFor++}let b=[];for(let e of s){let t=new Set;e.p.routes.forEach((n,r)=>{let i=n.bridge?n.id:c;if(t.has(i))return;t.add(i);let o=m.get(i);b.push({key:e.key,bridgeId:o.id,primary:0===r&&!o.unresolved,unresolved:o.unresolved,tier:o.bridge?.tier??null,x1:o.x,y1:o.y,x2:e.x,y2:e.y})})}let x=Math.max(g,u.length?u[u.length-1].y:0),v=s.length?Math.ceil(x+16):0,S={x:20,y:s.length?(16+Math.max(g,x))/2:16,r:14},w=u.map(e=>({id:e.id,x1:S.x,y1:S.y,x2:e.x,y2:e.y}));return{width:t,height:v,you:S,people:s,bridges:u,links:b,spokes:w}}],7214)},5258,e=>{"use strict";e.s(["TIER_COLORS_CLASSIC",0,{S:"#FFD700",A:"#9B59B6",B:"#3498DB",C:"#95A5A6",D:"#BDC3C7"},"TIER_ORDER",0,["S","A","B","C","D"],"initialsFor",0,function(e){let t=String(e||"").trim().split(/\s+/).filter(Boolean);return 0===t.length?"?":(t[0].charAt(0)+(t.length>1?t[t.length-1].charAt(0):"")).toUpperCase()}])}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,26005,e=>{"use strict";var t=e.i(43476),n=e.i(22016),r=e.i(64745);let o=[{key:"network",label:"Network Circle",short:"Circle",on:{background:"#fff",color:"#000"},off:{background:"transparent",color:"#888"}},{key:"degrees",label:"Degrees",on:{background:"linear-gradient(135deg, #FFD700, #FF6B35)",color:"#000"},off:{background:"rgba(255,255,255,0.12)",color:"#fff"}},{key:"separation",label:"Separation",on:{background:"linear-gradient(135deg, #00E5FF, #FFD700 55%, #FF7043)",color:"#000"},off:{background:"rgba(255,255,255,0.12)",color:"#fff"}}],l=[{key:"paths",href:"/paths",label:"Paths",color:"#00ff88",on:"linear-gradient(135deg, #00ff88, #3498DB)",demo:!0},{key:"outlink",href:"/queue",label:"Outlink",color:"#FF6B35",on:"linear-gradient(135deg, #FF6B35, #FFD700)",own:!0},{key:"scan",href:"/setup",label:"Scan",color:"#666",on:"linear-gradient(135deg, #00ff88, #1abc9c)",own:!0}];e.s(["default",0,function({active:e,isMobile:a=!1,csvMode:i=!1,onMode:s,children:c,after:d}){let u={padding:a?"6px 10px":"8px 16px",borderRadius:6,border:"none",fontSize:a?11:13,fontWeight:600,textDecoration:"none"};return(0,t.jsxs)("div",{id:"main-tabs",style:{display:"flex",gap:a?2:4,background:"rgba(255,255,255,0.08)",borderRadius:8,padding:a?2:3,flexWrap:a?"wrap":"nowrap"},children:[o.map(r=>{let o={...u,cursor:"pointer",...e===r.key?r.on:r.off},l=a&&r.short?r.short:r.label;return s?(0,t.jsx)("button",{type:"button",onClick:()=>s(r.key),style:o,children:l},r.key):(0,t.jsx)(n.default,{href:`/?mode=${r.key}`,style:{...o,display:"flex",alignItems:"center"},children:l},r.key)}),c,l.filter(e=>!r.IS_DEMO&&(!e.own||!i)).map(r=>{let o=e===r.key;return(0,t.jsxs)(n.default,{href:r.href,title:r.title,"aria-current":o?"page":void 0,style:{...u,display:"flex",alignItems:"center",gap:4,background:o?r.on:"rgba(255,255,255,0.06)",color:o?"#000":r.color},children:[r.label,r.badge&&(0,t.jsx)("span",{style:{fontSize:9,opacity:.7,marginLeft:2},children:r.badge})]},r.key)}),d]})}])},94657,e=>{"use strict";var t=e.i(43476),n=e.i(71645),r=e.i(7837);let o=e=>`${e.name} ${e.was} → ${e.estimated?"estimated":e.now}`,l=e=>({padding:"6px 12px",borderRadius:7,cursor:"pointer",fontSize:12,fontWeight:700,border:e?"none":"1px solid rgba(255,255,255,0.15)",background:e?"linear-gradient(135deg, #00ff88, #3498DB)":"transparent",color:e?"#000":"#cfd8d8"});function a({onAnswered:e}){var i;let s,c,[d,u]=(0,n.useState)(null),[f,p]=(0,n.useState)(!1),[g,m]=(0,n.useState)(()=>new Set),[h,y]=(0,n.useState)(!1),[b,w]=(0,n.useState)(null);if((0,n.useEffect)(()=>{if((0,r.csvNetworkSource)())return;let e=!1;return fetch("/api/company-scores/legacy").then(e=>e.json()).then(t=>{!e&&t.offer?.companies?.length&&(u(t.offer),m(new Set(t.offer.companies.map(e=>e.name))))}).catch(()=>{}),()=>{e=!0}},[]),!d)return null;let x=async t=>{y(!0),w(null);try{let n=await fetch("/api/company-scores/legacy",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({keep:t})}),r=await n.json();if(!n.ok&&!r.kept)throw Error(r.error||"Could not save your answer.");u(null),e?.({kept:r.kept||[],scored:r.scored||0,error:n.ok?null:r.error})}catch(e){w(e.message)}finally{y(!1)}};return(0,t.jsxs)("section",{"aria-label":"Built-in scores changed",style:{marginBottom:14,padding:14,borderRadius:10,border:"1px solid rgba(255,215,0,0.35)",background:"rgba(255,215,0,0.06)",fontSize:12.5,color:"#cfd8d8",lineHeight:1.6},children:[(0,t.jsx)("b",{style:{color:"#fff"},children:"Built-in scores changed in this version:"})," ",(s=(i=d.companies).slice(0,3).map(o).join(", "),(c=i.length-3)>0?`${s} and ${c} more`:s),"."," ","Keep any of the old ones as your own?",(0,t.jsx)("div",{style:{marginTop:4,color:"#8b9a9a"},children:"The built-in list now holds only companies most professionals would recognise, scored the same for everyone; anything else is estimated from your network. A score you keep is yours, like one you set below, and Auto hands it back."}),f&&(0,t.jsx)("ul",{style:{listStyle:"none",padding:0,margin:"10px 0 0",display:"grid",gap:4},children:d.companies.map(e=>(0,t.jsx)("li",{children:(0,t.jsxs)("label",{style:{display:"flex",gap:8,alignItems:"baseline",cursor:"pointer"},children:[(0,t.jsx)("input",{type:"checkbox",checked:g.has(e.name),disabled:h,onChange:()=>{let t;return t=e.name,m(e=>{let n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n})}}),(0,t.jsxs)("span",{children:[(0,t.jsx)("b",{style:{color:"#fff"},children:e.name})," ",e.was," → ",e.estimated?`estimated (${e.now})`:e.now,(0,t.jsxs)("span",{style:{color:"#778"},children:[` \xb7 ${e.people} ${1===e.people?"person":"people"} there now`,e.names.length>1&&` \xb7 for ${e.names.join(", ")}`]})]})]})},e.name))}),(0,t.jsxs)("div",{style:{display:"flex",gap:8,marginTop:10,flexWrap:"wrap"},children:[f?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("button",{disabled:h||!g.size,onClick:()=>x([...g]),style:{...l(!0),opacity:h||!g.size?.5:1},children:["Keep ",g.size," ",1===g.size?"score":"scores"]}),(0,t.jsx)("button",{disabled:h,onClick:()=>p(!1),style:l(!1),children:"Back"})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("button",{disabled:h,onClick:()=>x(d.companies.map(e=>e.name)),style:l(!0),children:"Keep all"}),(0,t.jsx)("button",{disabled:h,onClick:()=>p(!0),style:l(!1),children:"Choose…"})]}),(0,t.jsx)("button",{disabled:h,onClick:()=>x([]),style:l(!1),children:"No thanks"})]}),b&&(0,t.jsx)("div",{role:"alert",style:{marginTop:8,color:"#e74c3c"},children:b})]})}let i="1px solid rgba(255,255,255,0.1)",s={yours:{label:"your score",color:"#00ff88"},known:{label:"known list",color:"#3498DB"},data:{label:"public data",color:"#1abc9c"},network:{label:"estimated: many of your people",color:"#FF6B35"},default:{label:"unknown company",color:"#778"}};async function c(){let e=await fetch("/api/company-scores"),t=await e.json();if(!e.ok)throw Error(t.error||"Could not load company scores");return t.companies}function d(){let[e,t]=(0,n.useState)(null),[r,o]=(0,n.useState)(null);return(0,n.useEffect)(()=>{let e=!1;return c().then(n=>{e||t(n)}).catch(t=>{e||o(t.message)}),()=>{e=!0}},[]),{companies:e,error:r,setScore:(0,n.useCallback)(async(e,n)=>{let r=await fetch("/api/company-scores",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:e,score:n})}),o=await r.json();if(!r.ok)throw Error(o.error||"Could not save");return t(await c()),o},[]),reload:(0,n.useCallback)(async()=>t(await c()),[])}}function u({company:e,onSet:r,compact:o}){let[l,a]=(0,n.useState)(!1),s=async t=>{a(!0);try{await r(e.name,"auto"===t?null:Number(t))}finally{a(!1)}};return(0,t.jsxs)("select",{disabled:l,value:"yours"===e.source?String(e.score):"auto",onChange:e=>s(e.target.value),title:"Set this company's score. Auto uses the known list or an estimate.",style:{padding:o?"2px 4px":"4px 6px",borderRadius:6,border:i,background:"#11131c",color:"#dfe6e9",fontSize:12},children:[(0,t.jsxs)("option",{value:"auto",children:["Auto (","yours"===e.source?e.suggested??"est.":e.score,")"]}),[10,9,8,7,6,5,4,3,2,1].map(e=>(0,t.jsx)("option",{value:e,children:e},e))]})}e.s(["ScorePicker",0,u,"default",0,function({onRescored:e,version:r=0}){let{companies:o,error:l,setScore:c,reload:f}=d();(0,n.useEffect)(()=>{r&&f().catch(()=>{})},[r,f]);let[p,g]=(0,n.useState)(""),[m,h]=(0,n.useState)("all"),[y,b]=(0,n.useState)(150),[w,x]=(0,n.useState)(null),k=e=>{x(e),setTimeout(()=>x(null),3500)},v=async(t,n)=>{let r=await c(t,n);k(`${t}: ${null==n?"back to auto":`set to ${n}`} \xb7 rescored ${r.scored} people`),e?.()},S=async({kept:t,scored:n,error:r})=>{if(!t.length)return k("Keeping the new built-in scores.");k(r||`Kept ${t.length} old ${1===t.length?"score":"scores"} as your own \xb7 rescored ${n} people`),await f().catch(()=>{}),e?.()},j=(0,n.useMemo)(()=>{if(!o)return[];let e=p.trim().toLowerCase();return o.filter(t=>(!e||t.name.toLowerCase().includes(e))&&("all"===m||t.source===m))},[o,p,m]);if(l)return(0,t.jsx)("div",{style:{padding:24,color:"#e74c3c"},children:l});if(!o)return(0,t.jsx)("div",{style:{padding:24,color:"#778"},children:"Loading companies…"});let C=e=>o.filter(t=>t.source===e).length;return(0,t.jsxs)("div",{style:{flex:1,overflow:"auto",padding:16},children:[(0,t.jsxs)("div",{style:{maxWidth:980,margin:"0 auto"},children:[(0,t.jsx)(a,{onAnswered:S}),(0,t.jsxs)("div",{style:{padding:14,borderRadius:10,border:i,background:"rgba(255,255,255,0.03)",fontSize:12.5,color:"#cfd8d8",lineHeight:1.6},children:[(0,t.jsx)("b",{style:{color:"#fff"},children:"How a power score works."})," power = ",(0,t.jsx)("b",{children:"title"})," × ",(0,t.jsx)("b",{children:"company weight"})," + bonus. The title (student 1 … founder or C-suite 10) comes from someone’s roles, with former roles at 70%; an audience of their own counts like a title (1M+ followers like a director). The company weight runs from 0.725 for a company we don’t know (or none found), the middle of the scale, to 1.0 (a company scored 10), so seniority counts for more at a bigger company. The bonus is at most +1.5, for investor, YC, an audience in the millions or the top award of any field, and counts half at an unknown company. A 1st-degree person whose circle is unusually strong gets up to +2 more: up to +1 for a high share of it at A or S, or +1 for every 25 people there. Tiers are graded on your network’s curve unless you choose the fixed scale (",(0,t.jsx)("a",{href:"#tiers",style:{color:"#3498DB"},children:"Tiers"}),", above): your top 3% are S, the next 12% A, the next 25% B (it only lifts, and never lifts anyone under 4 into S or A). On the fixed scale, S ≥ 7.5 · A ≥ 5.5 · B ≥ 4 · C ≥ 2.5.",(0,t.jsxs)("div",{style:{marginTop:6,color:"#8b9a9a"},children:["So a VP at a 10 scores 9.0, a founder at an unknown company 7.3, a director at an unknown company 5.4, and an intern at a 10 scores 2.0. Set a company’s score below and everyone there is rescored. Companies in the sectors you pick (",(0,t.jsx)("a",{href:"#sector",style:{color:"#3498DB"},children:"Your sector"}),", above) get +1 or +2; a score you set is never changed."]})]}),(0,t.jsxs)("div",{style:{display:"flex",gap:8,alignItems:"center",flexWrap:"wrap",margin:"14px 0 10px"},children:[(0,t.jsx)("input",{value:p,onChange:e=>g(e.target.value),placeholder:"Find a company",style:{padding:"6px 10px",borderRadius:7,border:i,background:"rgba(255,255,255,0.05)",color:"#fff",fontSize:13,minWidth:180}}),[["all",`All ${o.length}`],["known",`Known list ${C("known")}`],["data",`Public data ${C("data")}`],["yours",`Yours ${C("yours")}`],["network",`Estimated ${C("network")}`],["default",`Unknown ${C("default")}`]].map(([e,n])=>(0,t.jsx)("button",{onClick:()=>h(e),style:{padding:"5px 10px",borderRadius:7,border:i,cursor:"pointer",fontSize:11.5,fontWeight:600,background:m===e?"rgba(52,152,219,0.25)":"transparent",color:m===e?"#cfe6f7":"#8b9a9a"},children:n},e))]}),(0,t.jsxs)("div",{style:{borderRadius:10,border:i,overflow:"hidden"},children:[(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 70px 70px 70px 60px 180px 110px",gap:8,padding:"8px 12px",fontSize:10.5,letterSpacing:.6,color:"#8b9a9a",background:"rgba(255,255,255,0.04)"},children:[(0,t.jsx)("span",{children:"COMPANY"}),(0,t.jsx)("span",{style:{textAlign:"right"},children:"PEOPLE"}),(0,t.jsx)("span",{style:{textAlign:"right"},children:"YOU KNOW"}),(0,t.jsx)("span",{style:{textAlign:"right"},children:"DIRECTOR+"}),(0,t.jsx)("span",{style:{textAlign:"right"},children:"SCORE"}),(0,t.jsx)("span",{children:"SOURCE"}),(0,t.jsx)("span",{children:"SET"})]}),j.slice(0,y).map(e=>(0,t.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"1fr 70px 70px 70px 60px 180px 110px",gap:8,padding:"7px 12px",alignItems:"center",borderTop:"1px solid rgba(255,255,255,0.05)",fontSize:12.5},children:[(0,t.jsxs)("span",{style:{display:"flex",alignItems:"center",gap:8,minWidth:0},children:[(0,t.jsx)("span",{title:`${e.industry.label} (inferred)`,style:{width:8,height:8,borderRadius:"50%",background:e.industry.color,flexShrink:0}}),(0,t.jsx)("span",{style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:e.name})]}),(0,t.jsx)("span",{style:{textAlign:"right"},children:e.people}),(0,t.jsx)("span",{style:{textAlign:"right",color:e.d1?"#00ff88":"#556"},children:e.d1}),(0,t.jsx)("span",{style:{textAlign:"right",color:e.senior?"#FFD700":"#556"},children:e.senior}),(0,t.jsx)("b",{style:{textAlign:"right",fontSize:15},children:e.score}),(0,t.jsxs)("span",{style:{fontSize:11,color:s[e.source]?.color},children:[s[e.source]?.label,e.sectorBonus>0&&(0,t.jsxs)("span",{style:{color:"#00ff88"},children:[" + ",e.sectorBonus," your sector"]})]}),(0,t.jsx)(u,{company:e,onSet:v,compact:!0})]},e.name))]}),j.length>y&&(0,t.jsxs)("button",{onClick:()=>b(e=>e+300),style:{marginTop:10,padding:"7px 14px",borderRadius:8,border:i,background:"rgba(255,255,255,0.05)",color:"#dfe6e9",cursor:"pointer",fontSize:12},children:["Show more (",j.length-y," left)"]})]}),w&&(0,t.jsx)("div",{role:"status",style:{position:"fixed",bottom:24,left:"50%",transform:"translateX(-50%)",padding:"10px 18px",borderRadius:24,background:"linear-gradient(135deg, #00ff88, #3498DB)",color:"#000",fontWeight:800,fontSize:13,zIndex:50},children:w})]})},"useCompanyScores",0,d],94657)},2776,e=>{"use strict";var t=e.i(43476),n=e.i(15812);e.s(["default",0,function({children:e}){let{userId:r,ready:o}=(0,n.useUser)();return o&&r?e:(0,t.jsx)("div",{style:{minHeight:"100vh",display:"flex",alignItems:"center",justifyContent:"center",background:"#0a0a1a",color:"#fff",padding:24,textAlign:"center",fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},children:o?(0,t.jsxs)("div",{style:{maxWidth:420},children:[(0,t.jsx)("div",{style:{fontSize:18,fontWeight:700,marginBottom:8},children:"Can’t reach Six Degrees’ local server"}),(0,t.jsx)("div",{style:{color:"#888",fontSize:14,lineHeight:1.6},children:"The page loaded but the app behind it is not answering. If you started it from a terminal, check that window for an error, then reload this page."})]}):(0,t.jsx)("div",{style:{fontSize:18,fontWeight:600},children:"Loading…"})})}])},89154,e=>{"use strict";var t=e.i(90179);function n(e){let n=(0,t.readTitle)(e);return{key:n.key,label:n.label,level:n.level}}function r(e){return(0,t.currentCompany)(e)}let o=[{key:"defense",label:"Government, Defense & Aerospace",color:"#7f8c8d",words:/\b(government|federal|state of|county|city of|defen[cs]e|army|navy|air force|marine corps|military|dod|nasa|aerospace|lockheed|northrop|boeing|raytheon|l3harris|leidos|blue origin|spacex|public sector)\b/i},{key:"finance",label:"Finance & Investing",color:"#2ecc71",words:/\b(bank|banking|capital|ventures?|vc|investments?|investor|fund|private equity|growth equity|asset management|wealth|trading|trader|hedge|crypto|blockchain|web3|defi|fintech|stripe|coinbase|blackrock|robinhood|goldman|morgan stanley|jpmorgan|chase|bny|mellon|wells fargo|citi|citigroup|capital one|fidelity|vanguard|schwab|visa|mastercard|amex|american express|paypal|insurance|accounting|cpa|financial)\b/i},{key:"health",label:"Healthcare & Biotech",color:"#e74c3c",words:/\b(health|healthcare|medical|medicine|hospital|clinic|pharma|pharmaceutical|biotech|nurse|nursing|physician|doctor|dental|therapy|therapist|wellness)\b/i},{key:"education",label:"Education",color:"#f1c40f",words:/\b(university|college|school|education|student|professor|teacher|academy|phd|faculty|alumni)\b/i},{key:"media",label:"Marketing & Media",color:"#e67e22",words:/\b(marketing|brand|branding|advertising|agency|media|content|social media|creative|creator|influencer|pr|public relations|communications|tiktok|pinterest|youtube|growth marketing)\b/i},{key:"entertainment",label:"Entertainment & Gaming",color:"#9b59b6",words:/\b(entertainment|film|movie|music|records|gaming|games?|esports|studio|studios|netflix|disney|spotify|hollywood|theater|theatre|sports)\b/i},{key:"tech",label:"Tech, Software & AI",color:"#3498db",words:/\b(software|saas|engineer|engineering|developer|tech|technology|technologies|ai|artificial intelligence|machine learning|ml|data|cloud|cyber|security|devops|product manager|google|microsoft|apple|meta|amazon|nvidia|openai|anthropic|palantir|salesforce|oracle|ibm|intel|app|apps|startup|platform|labs?)\b/i},{key:"consulting",label:"Consulting, Legal & Services",color:"#1abc9c",words:/\b(consulting|consultant|consultancy|deloitte|accenture|mckinsey|kpmg|pwc|ey|bain|bcg|legal|law|lawyer|attorney|paralegal|recruiting|recruiter|staffing|talent)\b/i},{key:"realestate",label:"Real Estate & Construction",color:"#d35400",words:/\b(real estate|realtor|realty|property|properties|construction|architecture|architect|mortgage|homes|housing|builders?)\b/i},{key:"consumer",label:"Retail, Consumer & Hospitality",color:"#ff79c6",words:/\b(retail|e-?commerce|shopify|consumer|cpg|fashion|apparel|beauty|cosmetics|food|beverage|restaurant|hospitality|hotel|travel|tourism|coca-cola|nike|store|shop)\b/i},{key:"industry",label:"Manufacturing, Energy & Logistics",color:"#95a5a6",words:/\b(manufacturing|energy|oil|gas|solar|utilities|automotive|tesla|siemens|ge|general electric|honeywell|3m|logistics|supply chain|shipping|freight|fedex|ups|industrial|mining|chemicals?)\b/i},{key:"nonprofit",label:"Nonprofit & Community",color:"#bdc3c7",words:/\b(nonprofit|non-profit|foundation|charity|ngo|church|ministry|volunteer)\b/i}],l={key:"unknown",label:"Unclear",color:"#555c66"},a=Object.fromEntries([...o,l].map(e=>[e.key,e])),i=e=>a[e]||l;function s(e,t){for(let n of[e,t]){if(!n)continue;let e=o.find(e=>e.words.test(n));if(e)return e}return l}let c=(e,t)=>s(e,t).key,d=e=>n(e).level>=4;e.s(["INDUSTRIES",0,o,"UNKNOWN_INDUSTRY",0,l,"buildCompanyIndex",0,function(e=[]){let n=new Map,r=e=>(n.has(e)||n.set(e,(0,t.rolesWithCompanies)(e)),n.get(e)),{industries:o}=(0,t.networkCompanies)(e,{industryOf:c,rolesOf:r}),l=new Map;for(let t of e){let e=t.profile_url||`id:${t.id}`,n=l.get(e);(!n||(t.degree||9)<(n.degree||9))&&l.set(e,t)}let a=new Map;for(let e of l.values()){let t=r(e).find(e=>!e.former)?.company;if(!t)continue;let n=a.get(t);n||(n={name:t,people:[],d1:0,d2:0,d3:0,S:0,A:0,senior:0},a.set(t,n)),n.people.push(e),1===e.degree?n.d1++:2===e.degree?n.d2++:n.d3++,"S"===e.tier&&n.S++,"A"===e.tier&&n.A++,d(e.headline)&&n.senior++}for(let e of a.values())e.industry=i(o.get(e.name));return a},"companyLinks",0,function(e=[],t=[]){let n=new Map;for(let t of e){let e=r(t);e&&n.set(t.id,e)}let o=new Map;for(let e of t){let t=n.get(e.source_connection_id),l=r(e);if(!t||!l||t===l)continue;let[a,i]=t<l?[t,l]:[l,t],s=`${a}\u0000${i}`,c=o.get(s);c||(c={a:a,b:i,weight:0,via:new Set},o.set(s,c)),c.weight++,c.via.add(e.source_connection_id)}return[...o.values()]},"companyOf",0,r,"getSeniority",0,n,"industryByKey",0,i,"industryOf",0,s,"isSenior",0,d,"waysInto",0,function(e,t=[],n=[]){let o=t.filter(t=>r(t)===e),l=new Map;for(let t of n)r(t)===e&&l.set(t.source_connection_id,(l.get(t.source_connection_id)||0)+1);let a=new Map(t.map(e=>[e.id,e]));return{direct:o,bridges:[...l.entries()].map(([e,t])=>({bridge:a.get(e),n:t})).filter(e=>e.bridge).sort((e,t)=>t.n-e.n||(Number(t.bridge.power_score)||0)-(Number(e.bridge.power_score)||0))}}])},39160,84278,e=>{"use strict";var t=e.i(7214),n=e.i(7837);function r(e){let t=String(e||"").trim();if(!t)return null;let n=t.match(/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2})(?::(\d{2}))?(?:\s*UTC)?$/);if(n)return Date.UTC(+n[1],n[2]-1,+n[3],+n[4],+n[5],+(n[6]||0));if(n=t.match(/^(\d{1,2})\/(\d{1,2})\/(\d{2,4}),?\s+(\d{1,2}):(\d{2})\s*(AM|PM)?$/i)){let e=100>+n[3]?2e3+ +n[3]:+n[3],t=n[4]%12;return"PM"===(n[6]||"").toUpperCase()&&(t+=12),Date.UTC(e,n[1]-1,+n[2],t,+n[5])}if(n=t.match(/^([A-Za-z]{3,9})\s+(\d{4})$/)){let e=Date.parse(`1 ${n[1]} ${n[2]} UTC`);return Number.isNaN(e)?null:e}let r=Date.parse(/\d{4}$/.test(t)?`${t} UTC`:t);return Number.isNaN(r)?null:r}let o=e=>(0,t.keyFor)({profile_url:e});function l(e=[]){let t=new Map;for(let n of e){let e=o(n["sender profile url"]),r=n["conversation id"];r&&e&&(t.has(e)||t.set(e,new Set),t.get(e).add(r))}let n=null;for(let[e,r]of t)(!n||r.size>t.get(n).size)&&(n=e);return n}let a=e=>{let t=f(e);return t?`name:${t}`:null},i=/sponsored/i,s=/in\s?mail/i,c=/linkedin\.com\/(company|showcase|school)\//i,d=e=>/^(yes|true|1)$/i.test(String(e||"").trim());function u(e,t){if(!e||!e.total)return"never";let n=t-e.last;return n<=2592e6||e.recent>=3?"warm":n<=31536e6?"cool":"dormant"}let f=e=>String(e||"").split(",")[0].normalize("NFD").replace(/[̀-ͯ]/g,"").toLowerCase().replace(/[^a-z0-9 ]+/g," ").replace(/\s+/g," ").trim();e.s(["buildConversations",0,function(e=[],{keepText:t=!1}={}){let n=l(e),u=new Map;for(let t of e)n&&o(t["sender profile url"])===n&&t.from&&u.set(t.from,(u.get(t.from)||0)+1);let p=f([...u].sort((e,t)=>t[1]-e[1])[0]?.[0]||""),g=e=>!!e&&(e===n||!!p&&e===`name:${p}`),m={},h=new Map,y=0,b=0;for(let n of e){let e=n["conversation id"],l=r(n.date);if(!e||null==l){b+=1;continue}if(d(n["is message draft"])){y+=1;continue}let u=o(n["sender profile url"])||a(n.from);u&&n.from&&!m[u]&&(m[u]=String(n.from).trim());let f=String(n["recipient profile urls"]||"").split(/[,;\s]+/).filter(Boolean).map(o),p=String(n.to||"").split(",").map(e=>e.trim()).filter(Boolean),w=f.length?f:p.map(a).filter(Boolean);f.length&&f.length===p.length&&f.forEach((e,t)=>{m[e]||(m[e]=p[t])}),f.length||p.forEach(e=>{let t=a(e);t&&!m[t]&&(m[t]=e)}),h.has(e)||h.set(e,{id:e,title:"",everyone:new Set,messages:[],kind:null,folder:"",newest:-1/0});let x=h.get(e);u&&x.everyone.add(u),w.forEach(e=>x.everyone.add(e)),x.kind=x.kind||function(e){let t=String(e.folder||""),n=String(e["conversation title"]||"");return i.test(t)||i.test(n)||c.test(String(e["sender profile url"]||""))?"sponsored":s.test(t)||s.test(n)?"inmail":null}(n),l>=x.newest&&(x.newest=l,x.folder=String(n.folder||"").trim().toLowerCase().slice(0,30));let k={t:l,fromMe:g(u)};t&&(k.text=[n.subject,n.content].map(e=>String(e||"").trim()).filter(Boolean).join("\n\n"),!x.title&&n["conversation title"]&&(x.title=String(n["conversation title"]).trim())),x.messages.push(k)}let w=[];for(let e of h.values()){let n=[...e.everyone].filter(e=>e&&!g(e)).sort();e.messages.sort((e,t)=>e.t-t.t);let r={id:e.id,people:n,group:n.length>1,kind:e.kind,folder:e.folder,messages:e.messages};t&&(r.title=e.title),w.push(r)}for(let e of Object.keys(m))g(e)&&delete m[e];return{self:n,conversations:w,names:m,drafts:y,skipped:b}},"buildInvitations",0,function(e=[],{keepText:t=!1}={}){let n=[];for(let l of e){let e=String(l.direction||"").toUpperCase();if("INCOMING"!==e&&"OUTGOING"!==e)continue;let i="INCOMING"===e?"in":"out",s=String(("in"===i?l.from:l.to)||"").trim(),c=o("in"===i?l.inviterprofileurl:l.inviteeprofileurl),d=(c&&/\/in\//.test(c)?c:null)||a(s);if(!d)continue;let u=r(l["sent at"]),f={id:`${i}|${d}|${u??""}`,dir:i,key:d,name:s.slice(0,120),t:u};t&&String(l.message||"").trim()&&(f.note=String(l.message).trim().slice(0,2e3)),n.push(f)}return n.sort((e,t)=>(t.t||0)-(e.t||0))},"careerChapters",0,function(e=[],t=[],n=Date.now()){let l=e.map(e=>({company:e["company name"]||"",title:e.title||"",from:r(e["started on"]),to:r(e["finished on"])})).filter(e=>e.company&&null!=e.from).sort((e,t)=>e.from-t.from),a=t.map(e=>({url:o(e.url||e.profile_url),t:r(e["connected on"]||e.connected_on)})).filter(e=>null!=e.t);return l.map(e=>{let t=e.to??n,r=a.filter(n=>n.t>=e.from&&n.t<t);return{...e,to:e.to,made:r.length,people:r.map(e=>e.url)}})},"conversationSummary",0,function(e){let t=e.messages[e.messages.length-1];return{id:e.id,people:e.people,group:e.group,kind:e.kind||null,folder:e.folder||"",last:t?t.t:null,lastFromThem:t?!t.fromMe:null,count:e.messages.length,mine:e.messages.filter(e=>e.fromMe).length}},"invitationSplit",0,function(e=[]){let t=0,n=0;for(let r of e){let e=String(r.direction||"").toUpperCase();"INCOMING"===e?t+=1:"OUTGOING"===e&&(n+=1)}return{incoming:t,outgoing:n,total:t+n}},"messageStats",0,function(e=[]){let t=l(e),n=new Map;for(let t of e){let e=o(t["sender profile url"]),l=t["conversation id"];if(!l||!e)continue;let a=String(t["recipient profile urls"]||"").split(/[,;\s]+/).filter(Boolean).map(o),i=r(t.date);if(null==i)continue;n.has(l)||n.set(l,{people:new Set,msgs:[]});let s=n.get(l);s.people.add(e),a.forEach(e=>s.people.add(e)),s.msgs.push({from:e,t:i})}let a=0,i=new Map;for(let e of n.values()){let n=[...e.people].filter(e=>e!==t);if(1!==n.length||!e.people.has(t))continue;let r=n[0],o=i.get(r)||{last:0,lastFromThem:!1,total:0,times:[]};for(let n of e.msgs)o.total+=1,o.times.push(n.t),n.t>=o.last&&(o.last=n.t,o.lastFromThem=n.from!==t),n.t>a&&(a=n.t);i.set(r,o)}for(let e of i.values())e.recent=e.times.filter(e=>e>a-7776e6).length,delete e.times;return{self:t,asOf:a||null,people:i}},"nameKey",0,f,"postingEffect",0,function(e=[],t=[]){let n=e.map(e=>({t:r(e.date),link:e.sharelink||e["share link"]||""})).filter(e=>null!=e.t).sort((e,t)=>e.t-t.t),o=t.map(e=>r(e["connected on"]||e.connected_on)).filter(e=>null!=e).sort((e,t)=>e-t);if(!o.length)return{posts:[],usualWeek:0,afterPosts:0};let l=Math.max(6048e5,o[o.length-1]-o[0]),a=o.length/l*6048e5,i=n.map(e=>({...e,week:o.filter(t=>t>=e.t&&t<e.t+6048e5).length})),s=i.length?i.reduce((e,t)=>e+t.week,0)/i.length:0;return{posts:i,usualWeek:a,afterPosts:s}},"readTable",0,function(e,t){let r=(0,n.parseCsv)(String(e||"")),o=r.findIndex(e=>e.some(e=>e.trim().toLowerCase()===t.toLowerCase()));if(o<0)return[];let l=r[o].map(e=>e.trim().toLowerCase());return r.slice(o+1).filter(e=>e.some(e=>e.trim())).map(e=>Object.fromEntries(l.map((t,n)=>[t,(e[n]??"").trim()])))},"warmthOf",0,u],84278);let p="six-degrees-galaxy-lab",g="six-degrees-galaxy-layouts",m=Object.freeze({on:!0,gravity:0,rings:1,push:15,pull:1,distance:1,dotSize:1,lines:1,sizeBy:"power",names:"key",branch:!1,colourBy:"tier",speed:15,loop:!1,labels:!0,v:2}),h=["gravity","rings","push","pull","distance","dotSize","lines","sizeBy","names","branch","colourBy","speed","loop"],y=Object.freeze({gravity:.25,rings:0,push:25,pull:2.5,distance:.35,sizeBy:"reach"}),b=Object.freeze({gravity:0,rings:3,push:6,pull:4,distance:.22,sizeBy:"power"}),w=new Set,x=null;function k(){return x||(x=function(){try{let e=JSON.parse(localStorage.getItem(p)||"null");if(!e||"object"!=typeof e)return m;return{...m,...e,...e.v===m.v?{}:{branch:!1},v:m.v,on:!0}}catch{return m}}()),x}function v(e){x=null===e?{...m,labels:k().labels}:{...k(),...e,on:!0};try{localStorage.setItem(p,JSON.stringify(x))}catch{}w.forEach(e=>e())}let S=null,j=new Set;function C(){if(!S){try{S=JSON.parse(localStorage.getItem(g)||"[]")}catch{S=[]}Array.isArray(S)||(S=[])}return S}function M(e){S=e;try{localStorage.setItem(g,JSON.stringify(e))}catch{}j.forEach(e=>e())}let F=new Set,I={at:null,playing:!1,min:null,max:null,of:0,find:"",fly:0,found:0,social:void 0},N=null;function O(e){let t={...I,...e};Object.keys(e).every(e=>Object.is(t[e],I[e]))||(I=t,F.forEach(e=>e()))}function T(){cancelAnimationFrame(N),N=null,O({playing:!1})}let $=null;function A(e){let n=new Map;for(let[r,o]of Object.entries(e?.people||{}))n.set((0,t.keyFor)({profile_url:r}),{...o});for(let[r,o]of Object.entries(e?.live||{})){let e=(0,t.keyFor)({profile_url:r}),l=n.get(e)||{total:0,recent:0};o.last&&(!l.last||o.last>l.last)&&(l.last=o.last,"boolean"==typeof o.lastFromThem&&(l.lastFromThem=o.lastFromThem)),l.unread=o.unread,l.total=Math.max(l.total||0,1),n.set(e,l)}let r=Math.max(e?.asOf||0,e?.liveAt&&Date.parse(e.liveAt)||0);for(let e of n.values())(e.last||0)>r&&(r=e.last);return{merged:n,asOf:r,chapters:e?.chapters||[],posts:e?.posts?.posts||[]}}let B={1:"#4FC3F7",2:"#BA68C8",3:"#FFB74D"},E=["#FF6B6B","#4ECDC4","#FFD93D","#A29BFE","#00B894","#FD79A8","#74B9FF","#E17055"],z={warm:"#FF7043",cool:"#4FC3F7",dormant:"#8D6E63",never:"#546E7A"},D="#4a5568",_=["#2b1b6b","#6a1b9a","#c2185b","#f4511e","#ffb300","#fff3b0"];function L(e){let t=Math.max(0,Math.min(1,Number(e)||0))*(_.length-1),n=Math.min(_.length-2,Math.floor(t)),r=t-n,o=_[n],l=_[n+1];return`#${[1,3,5].map(e=>Math.round(parseInt(o.slice(e,e+2),16)*(1-r)+parseInt(l.slice(e,e+2),16)*r).toString(16).padStart(2,"0")).join("")}`}function R(e=[],t=()=>0){let n=[...new Set(e.map(t))].sort((e,t)=>e-t),r=new Map(n.map((e,t)=>[e,n.length>1?t/(n.length-1):1]));return e=>r.get(t(e))??0}let U=e=>String(e||"").trim().toLowerCase();e.s(["CLUSTERS",0,y,"LAB_DEFAULTS",0,m,"ORBIT",0,b,"applyLayout",0,function(e){let t=C().find(t=>t.name===e);t&&v(Object.fromEntries(h.filter(e=>e in t.settings).map(e=>[e,t.settings[e]])))},"bornTimes",0,function(e,t){let n=new Map(e.map(e=>[e.id,e])),r=new Map,o=(e,l=0)=>{if(r.has(e.id))return r.get(e.id);let a=-1/0,i=t.get(e.id);if(1===e.degree||null==i||l>6){let t=e.connected_date?Date.parse(e.connected_date):NaN;a=Number.isNaN(t)?-1/0:t}return null!=i&&n.has(i)&&l<=6&&(a=Math.max(a,o(n.get(i),l+1))),r.set(e.id,a),a};return e.map(e=>o(e))},"chapterAt",0,function(e,t){let n=null;for(let r of e?.chapters||[])Number.isFinite(r.from)&&r.from<=t&&(!n||r.from>n.from)&&(n=r);return n&&(!Number.isFinite(n.to)||n.to>t)?n:null},"clockNow",0,()=>I,"colourScheme",0,function(e,n,r,o){if("degree"===e)return{of:e=>B[Math.min(e.degree||1,3)],legend:[["1st",B[1]],["2nd",B[2]],["3rd+",B[3]]]};if("company"===e){let e=new Map;for(let t of n){let n=U(t.company);if(!n)continue;let r=e.get(n)||{name:String(t.company).trim(),n:0};r.n+=1,e.set(n,r)}let t=[...e.entries()].filter(([,e])=>e.n>1).sort((e,t)=>t[1].n-e[1].n).slice(0,E.length),r=new Map(t.map(([e],t)=>[e,E[t]]));return{of:e=>r.get(U(e.company))||D,legend:[...t.map(([,e],t)=>[e.name,E[t]]),["Other",D]]}}if("heat"===e){let e=function(e=[]){return R(e,t.score)}(n);return{of:t=>L(e(t)),heat:e,legend:[["Cold",L(.1)],["Warm",L(.45)],["Hot",L(.75)],["Hottest",L(1)]]}}return"warmth"===e&&o?{of:e=>1===(e.degree||1)?z[u(o.merged.get((0,t.keyFor)(e)),o.asOf)]:"#2d3748",legend:[["Warm",z.warm],["Cool",z.cool],["Dormant",z.dormant],["Never messaged",z.never]]}:{of:e=>r[e.tier]||"#666",legend:Object.entries(r)}},"effectiveLab",0,e=>e.on?e:e.labels===m.labels?m:{...m,labels:e.labels},"findMatches",0,function(e,t){let n=String(t||"").trim().toLowerCase();if(n.length<2)return null;let r=new Set;for(let t of e)[t.name,t.company,t.role,t.headline].some(e=>e&&String(e).toLowerCase().includes(n))&&r.add(t.id);return r},"forgetLayout",0,function(e){M(C().filter(t=>t.name!==e))},"heatBy",0,R,"heatColour",0,L,"labNow",0,k,"layoutOf",0,function(e){let t=t=>Object.entries(t).every(([t,n])=>e[t]===n);return["gravity","rings","push","pull","distance"].every(t=>e[t]===m[t])?"rings":t(y)?"clusters":t(b)?"orbit":null},"layoutsNow",0,C,"loadSocial",0,function(){return $||($=fetch("/api/social").then(e=>e.ok?e.json():{}).then(e=>{O({social:e.social?A(e.social):null})}).catch(()=>O({social:null}))),$},"mergeSocial",0,A,"milestones",0,function(e){let t=[];for(let n of e?.chapters||[])Number.isFinite(n.from)&&t.push({t:n.from,kind:"job",label:n.company});for(let n of e?.posts||[])Number.isFinite(n.t)&&t.push({t:n.t,kind:"post",label:"You posted"});return t.sort((e,t)=>e.t-t.t)},"pause",0,T,"play",0,function e(){if(null==I.min||null==I.max||I.max<=I.min)return;let t=I.max-I.min,n=1e3*Math.max(1,Number(k().speed)||15),r=null==I.at||I.at>=I.max?I.min:I.at,o=performance.now()-(r-I.min)/t*n;O({at:r,playing:!0});let l=r=>{let a=Math.min(I.max,I.min+(r-o)/n*t);if(O({at:a}),a>=I.max){N=null,O({playing:!1}),k().loop&&setTimeout(()=>{N||I.at!==I.max||(O({at:I.min}),e())},1200);return}N=requestAnimationFrame(l)};cancelAnimationFrame(N),N=requestAnimationFrame(l)},"reachCounts",0,function(e,t){let n=new Map(e.map(e=>[e.id,0]));for(let r of e){let e=t.get(r.id);for(let r=0;null!=e&&r<7;r++)n.set(e,(n.get(e)||0)+1),e=t.get(e)}return n},"saveLayout",0,function(e){let t=String(e||"").trim().slice(0,40);if(!t)return;let n=k(),r=Object.fromEntries(h.map(e=>[e,n[e]]));M([...C().filter(e=>e.name!==t),{name:t,settings:r}])},"setClock",0,O,"setLab",0,v,"stopReplay",0,function(){T(),O({at:null})},"watchClock",0,function(e){return F.add(e),()=>F.delete(e)},"watchLab",0,function(e){w.add(e);let t=t=>{t.key===p&&(x=null,e())};return window.addEventListener("storage",t),()=>{w.delete(e),window.removeEventListener("storage",t)}},"watchLayouts",0,function(e){return j.add(e),()=>j.delete(e)}],39160)},19821,e=>{"use strict";async function t(e){let t=e?`/api/network?userId=${encodeURIComponent(e)}`:"/api/network",n=await fetch(t);if(!n.ok)throw Error(`Failed to load network (${n.status})`);let r=await n.json();return{degree1:r.degree1||[],degree2:r.degree2||[],degree3:r.degree3||[],ties:Number(r.ties)||0}}e.s(["loadNetwork",0,t])},7214,36774,e=>{"use strict";let t=/^[A-Za-z0-9_-]+\.(webp|jpg|jpeg|png)$/,n="/avatars/";function r(e){return"string"==typeof e&&e.startsWith(n)&&t.test(e.slice(n.length))?e:null}e.s(["localPhoto",0,r],36774);let o={S:0,A:1,B:2,C:3,D:4};function l(e){let t=parseFloat(e?.power_score);return Number.isFinite(t)?t:0}function a(e){return Math.round(10*l(e))/10}function i(e){return String(e?.profile_url||"").split(/[?#]/)[0].replace(/\/+$/,"")||`id:${e?.id}`}let s=(e,t)=>String(e??"").localeCompare(String(t??""),void 0,{numeric:!0});function c(e,t){return(o[e.tier]??9)-(o[t.tier]??9)||l(t)-l(e)||String(e.name||"").localeCompare(String(t.name||""))||s(e.id,t.id)}function d(e,t){return e.bridge&&t.bridge?c(e.bridge,t.bridge):e.bridge?-1:t.bridge?1:s(e.id,t.id)}function u(e,t){return t.score-e.score||t.waysIn-e.waysIn||d(e.routes[0]||f,t.routes[0]||f)||String(e.person.name||"").localeCompare(String(t.person.name||""))||(e.key<t.key?-1:+(e.key>t.key))}let f={id:null,bridge:null};function p(e){let t=String(e||"").trim().split(/\s+/).filter(Boolean);return t.length<2?t[0]||"":`${t[0]} ${t[t.length-1].charAt(0)}.`}function g(e,t){let n=String(e||"");return t<=1?n?"…":"":n.length>t?`${n.slice(0,t-1)}…`:n}e.s(["TIERS",0,["S","A","B","C","D"],"compareBridges",0,c,"comparePower",0,u,"convergeLayout",0,function(e,t=800,n=!1,{cards:r=!1,mutuals:o=0}={}){let l=r?46:n?40:34,a=Math.round(t*(n?.44:.36)),i=Math.round(t*(n?.8:r?.6:.62)),s=[],c=null;for(let t of e?.routes||[])t.bridge?s.push({id:t.id,bridge:t.bridge,unresolved:!1,count:1}):c?c.count++:s.push(c={id:null,bridge:null,unresolved:!0,count:1});let d=Math.max(0,Math.floor(Number(o)||0)-(e?.waysIn||0)),u=Math.min(60,d),f=r?12:11,m=r?220:n?96:120,h=Math.max(1,Math.floor(m/f)+1),y=Math.ceil(u/h),b=u?40+y*f:0,w=Math.max(0,s.length-1)*l+b,x=Math.max(n?190:r?250:220,32+w+48),k=x/2,v=k-w/2,S=Math.max(4,Math.floor((a-10-42)/6)),j=s.map((e,t)=>{let n=e.unresolved?`can't be named (${e.count})`:e.bridge.name||"";return{...e,x:a,y:v+t*l,r:6,primary:0===t&&!e.unresolved,label:n.length<=S?n:g(e.unresolved?n:p(n),S)}}),C={x:i,y:k,r:17*!r,rings:r?[]:[32,50,70].filter(e=>e<=k-4)},M=j.map(t=>({key:e?.key,bridgeId:t.id,primary:t.primary,unresolved:t.unresolved,tier:t.bridge?.tier??null,x1:t.x,y1:t.y,x2:C.x,y2:C.y})),F={x:20,y:k,r:14},I=j.map(e=>({id:e.id,x1:F.x,y1:F.y,x2:e.x,y2:e.y})),N=e?[{key:e.key,p:e,x:C.x,y:C.y,r:C.r,rings:C.rings,big:!0,label:""}]:[],O=v+Math.max(0,s.length-1)*l+40,T=r?a-236+8:a-m,$=Array.from({length:u},(e,t)=>({x:T+t%h*f,y:O+Math.floor(t/h)*f})),A=e?.waysIn?e.waysIn/(e.waysIn+d):1;return{width:t,height:x,you:F,target:C,people:N,bridges:j,links:M,spokes:I,ghosts:$,unscanned:d,ghostLabel:u?{x:T,y:O-13}:null,drawn:A}},"keyFor",0,i,"mapCount",0,function(e,t=10){let n=Math.max(0,Math.min(100,Number(e)||0));return n<=50?t:Math.max(1,Math.round(t*(100-n)/50))},"mostMutuals",0,function(e=[],t=()=>0,n=7){return[...e].sort((e,n)=>Math.max(t(n)||0,n.waysIn)-Math.max(t(e)||0,e.waysIn)||n.waysIn-e.waysIn||u(e,n)).slice(0,n)},"routeIndex",0,function(e=[]){let t=new Map;for(let n of e||[]){let e=i(n),r=t.get(e);r||(r=new Set,t.set(e,r)),r.add(n.source_connection_id??null)}return t},"routesFor",0,function(e,t,n){return e?[...t?.get(i(e))??(null!=e.source_connection_id?new Set([e.source_connection_id]):new Set)].map(e=>({id:e,bridge:n?.get(e)??null})).sort(d):[]},"score",0,l,"score1",0,a,"separationPeople",0,function(e=[],t=[]){let n=new Map;for(let e of t||[])n.set(e.id,e);let o=new Map,l=new Map;for(let t of e||[]){let e=i(t);l.set(t.id,e);let n=o.get(e);n?function(e,t){let n=a(e)-a(t);if(n)return n>0;let o=!!r(e.profile_image_url);return!!r(t.profile_image_url)!==o?o:0>s(e.id,t.id)}(t,n.person)&&(n.person=t):(n={key:e,person:t,rowIds:[],routeIds:new Set},o.set(e,n)),n.rowIds.push(t.id),n.routeIds.add(t.source_connection_id??null)}let c={people:o.size,byTier:{S:0,A:0,B:0,C:0,D:0},multi:0,bridges:0,unresolvedIds:0,peopleOnlyUnresolved:0,onlyUnresolvedVia:0},f=new Set,p=new Set,g=new Set,m=[];for(let e of o.values()){let t=[...e.routeIds].map(e=>({id:e,bridge:n.get(e)??null}));t.sort(d);let r=t.filter(e=>e.bridge);for(let e of t)(e.bridge?f:p).add(e.id);if(!r.length)for(let e of(c.peopleOnlyUnresolved++,t))g.add(e.id);let{person:o}=e,l=o.tier;void 0!==c.byTier[l]&&c.byTier[l]++,t.length>1&&c.multi++,m.push({key:e.key,person:o,score:a(o),tier:l,routes:t,waysIn:t.length,rowIds:e.rowIds,haystack:[o.name,o.headline,o.company,o.role,...r.map(e=>e.bridge.name)].filter(Boolean).join("\n").toLowerCase(),rank:0,tied:!1})}return c.bridges=f.size,c.unresolvedIds=p.size,c.onlyUnresolvedVia=g.size,m.sort(u),function(e){for(let t=0;t<e.length;t++){let n=e[t],r=e[t-1],o=r&&r.score===n.score&&r.waysIn===n.waysIn;n.rank=o?r.rank:t+1,o&&(n.tied=!0,r.tied=!0)}}(m),{people:m,rowToKey:l,summary:c}},"shortName",0,p,"summitLayout",0,function(e=[],t=800,n=!1,{cards:r=!1}={}){let o=r?50:n?36:26,l=Math.round(.42*t),a=Math.round(.58*t),i=e.map((e,n)=>{var l;return{key:e.key,p:e,x:a,y:16+n*o,r:r?0:(l=e.waysIn)>=4?8.5:3===l?7:2===l?5.5:4,label:g(`#${e.rank}${e.tied?"=":""} ${e.person.name||""}`,Math.floor((t-a-60)/6.2))}}),s=new Map,d="\0unresolved";for(let e of i)for(let t of e.p.routes){let n=t.bridge?t.id:d,r=s.get(n);r||(r={id:t.bridge?t.id:null,bridge:t.bridge,unresolved:!t.bridge,ys:[],count:0},s.set(n,r)),r.count++,r.ys.push(e.y)}let u=[...s.values()].map(e=>({...e,bary:e.ys.reduce((e,t)=>e+t,0)/e.ys.length}));u.sort((e,t)=>e.bary-t.bary||e.unresolved-t.unresolved||(e.bridge&&t.bridge?c(e.bridge,t.bridge):0));let f=i.length?i[i.length-1].y:16,m=function(e=[],t=18,n=0){let r=[];e.forEach((e,n)=>{for(r.push({sum:e-n*t,count:1});r.length>1&&r[r.length-2].sum/r[r.length-2].count>r[r.length-1].sum/r[r.length-1].count;){let e=r.pop();r[r.length-1].sum+=e.sum,r[r.length-1].count+=e.count}});let o=r.flatMap(e=>Array(e.count).fill(e.sum/e.count)).map((e,n)=>e+n*t),l=o.length&&o[0]<n?n-o[0]:0;return o.map(e=>e+l)}(u.map(e=>e.bary),r?36:18,16),h=Math.max(4,Math.floor((l-10-42)/6));u.forEach((e,t)=>{if(e.x=l,e.y=m[t],e.r=5,e.unresolved)e.label=g(`can't be named (${e.count})`,h);else{let t=e.bridge.name||"";e.label=t.length<=h?t:g(p(t),h)}delete e.ys});let y=new Map(u.map(e=>[e.unresolved?d:e.id,e]));for(let e of u)e.onlyFor=0,e.bestFor=0;for(let e of i){let t=e.p.routes[0],n=t?y.get(t.bridge?t.id:d):null;n&&n.bestFor++,1===e.p.waysIn&&n&&n.onlyFor++}let b=[];for(let e of i){let t=new Set;e.p.routes.forEach((n,r)=>{let o=n.bridge?n.id:d;if(t.has(o))return;t.add(o);let l=y.get(o);b.push({key:e.key,bridgeId:l.id,primary:0===r&&!l.unresolved,unresolved:l.unresolved,tier:l.bridge?.tier??null,x1:l.x,y1:l.y,x2:e.x,y2:e.y})})}let w=Math.max(f,u.length?u[u.length-1].y:0),x=i.length?Math.ceil(w+16):0,k={x:20,y:i.length?(16+Math.max(f,w))/2:16,r:14},v=u.map(e=>({id:e.id,x1:k.x,y1:k.y,x2:e.x,y2:e.y}));return{width:t,height:x,you:k,people:i,bridges:u,links:b,spokes:v}}],7214)}]);