@oxyhq/services 22.12.4 → 22.13.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 (446) hide show
  1. package/README.md +16 -46
  2. package/lib/commonjs/index.js +18 -12
  3. package/lib/commonjs/index.js.map +1 -1
  4. package/lib/commonjs/ui/boot/runProviderColdBoot.js +51 -9
  5. package/lib/commonjs/ui/boot/runProviderColdBoot.js.map +1 -1
  6. package/lib/commonjs/ui/client.js +0 -13
  7. package/lib/commonjs/ui/client.js.map +1 -1
  8. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js +27 -4
  9. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js.map +1 -1
  10. package/lib/commonjs/ui/components/OxyAuthChooser.js +72 -1123
  11. package/lib/commonjs/ui/components/OxyAuthChooser.js.map +1 -1
  12. package/lib/commonjs/ui/components/OxyConsentScreen.js +50 -12
  13. package/lib/commonjs/ui/components/OxyConsentScreen.js.map +1 -1
  14. package/lib/commonjs/ui/components/OxyProvider.js +4 -4
  15. package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
  16. package/lib/commonjs/ui/components/OxySignInButton.js +74 -40
  17. package/lib/commonjs/ui/components/OxySignInButton.js.map +1 -1
  18. package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js +527 -0
  19. package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js.map +1 -0
  20. package/lib/commonjs/ui/components/authChooser/SignInEntryView.js +90 -0
  21. package/lib/commonjs/ui/components/authChooser/SignInEntryView.js.map +1 -0
  22. package/lib/commonjs/ui/components/authChooser/SignInRequestView.js +144 -0
  23. package/lib/commonjs/ui/components/authChooser/SignInRequestView.js.map +1 -0
  24. package/lib/commonjs/ui/components/authChooser/SignUpView.js +188 -0
  25. package/lib/commonjs/ui/components/authChooser/SignUpView.js.map +1 -0
  26. package/lib/commonjs/ui/components/authChooser/TroubleDisclosure.js +63 -0
  27. package/lib/commonjs/ui/components/authChooser/TroubleDisclosure.js.map +1 -0
  28. package/lib/commonjs/ui/components/authChooser/primitives.js +169 -0
  29. package/lib/commonjs/ui/components/authChooser/primitives.js.map +1 -0
  30. package/lib/commonjs/ui/components/authChooser/requestSurfaces.js +149 -0
  31. package/lib/commonjs/ui/components/authChooser/requestSurfaces.js.map +1 -0
  32. package/lib/commonjs/ui/components/authChooser/signInProgress.js +54 -0
  33. package/lib/commonjs/ui/components/authChooser/signInProgress.js.map +1 -0
  34. package/lib/commonjs/ui/components/{oxyAuthChooserStyles.js → authChooser/styles.js} +19 -1
  35. package/lib/commonjs/ui/components/authChooser/styles.js.map +1 -0
  36. package/lib/commonjs/ui/components/authChooser/types.js +59 -0
  37. package/lib/commonjs/ui/components/authChooser/types.js.map +1 -0
  38. package/lib/commonjs/ui/components/authChooser/useUsernameAvailability.js +50 -0
  39. package/lib/commonjs/ui/components/authChooser/useUsernameAvailability.js.map +1 -0
  40. package/lib/commonjs/ui/context/OxyContext.js +205 -30
  41. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  42. package/lib/commonjs/ui/context/commitSessionFlow.js +46 -0
  43. package/lib/commonjs/ui/context/commitSessionFlow.js.map +1 -1
  44. package/lib/commonjs/ui/context/hooks/useAuthOperations.js +15 -2
  45. package/lib/commonjs/ui/context/hooks/useAuthOperations.js.map +1 -1
  46. package/lib/commonjs/ui/context/useOxyAccountGraph.js +13 -5
  47. package/lib/commonjs/ui/context/useOxyAccountGraph.js.map +1 -1
  48. package/lib/commonjs/ui/hooks/useSwitchableAccounts.js +6 -1
  49. package/lib/commonjs/ui/hooks/useSwitchableAccounts.js.map +1 -1
  50. package/lib/commonjs/ui/index.js +0 -13
  51. package/lib/commonjs/ui/index.js.map +1 -1
  52. package/lib/commonjs/ui/oauth/browserAuthTransport.js +170 -0
  53. package/lib/commonjs/ui/oauth/browserAuthTransport.js.map +1 -0
  54. package/lib/commonjs/ui/oauth/completeOAuthCode.js +78 -0
  55. package/lib/commonjs/ui/oauth/completeOAuthCode.js.map +1 -0
  56. package/lib/commonjs/ui/oauth/legacyRedirectLanes.js +48 -0
  57. package/lib/commonjs/ui/oauth/legacyRedirectLanes.js.map +1 -0
  58. package/lib/commonjs/ui/oauth/oauthHandshake.js +53 -0
  59. package/lib/commonjs/ui/oauth/oauthHandshake.js.map +1 -0
  60. package/lib/commonjs/ui/oauth/oauthPopup.js +276 -0
  61. package/lib/commonjs/ui/oauth/oauthPopup.js.map +1 -0
  62. package/lib/commonjs/ui/oauth/oauthPopupMessages.js +141 -0
  63. package/lib/commonjs/ui/oauth/oauthPopupMessages.js.map +1 -0
  64. package/lib/commonjs/ui/oauth/types.js +2 -0
  65. package/lib/commonjs/ui/oauth/types.js.map +1 -0
  66. package/lib/commonjs/ui/server.js +2 -5
  67. package/lib/commonjs/ui/server.js.map +1 -1
  68. package/lib/commonjs/ui/session/authStore.js +6 -75
  69. package/lib/commonjs/ui/session/authStore.js.map +1 -1
  70. package/lib/commonjs/ui/session/createSessionClient.js +11 -3
  71. package/lib/commonjs/ui/session/createSessionClient.js.map +1 -1
  72. package/lib/commonjs/ui/session/identityBinding.js +95 -0
  73. package/lib/commonjs/ui/session/identityBinding.js.map +1 -0
  74. package/lib/commonjs/ui/session/index.js +13 -0
  75. package/lib/commonjs/ui/session/index.js.map +1 -1
  76. package/lib/commonjs/ui/session/nativeSecureStorage.js +90 -0
  77. package/lib/commonjs/ui/session/nativeSecureStorage.js.map +1 -0
  78. package/lib/commonjs/ui/session/tokenTransport.js +11 -1
  79. package/lib/commonjs/ui/session/tokenTransport.js.map +1 -1
  80. package/lib/commonjs/ui/utils/crossOriginRestore.js +5 -4
  81. package/lib/commonjs/ui/utils/crossOriginRestore.js.map +1 -1
  82. package/lib/commonjs/ui/utils/deliveryPlatform.js +58 -0
  83. package/lib/commonjs/ui/utils/deliveryPlatform.js.map +1 -0
  84. package/lib/commonjs/ui/utils/oauthReturn.js +72 -46
  85. package/lib/commonjs/ui/utils/oauthReturn.js.map +1 -1
  86. package/lib/module/index.js +9 -4
  87. package/lib/module/index.js.map +1 -1
  88. package/lib/module/ui/boot/runProviderColdBoot.js +51 -9
  89. package/lib/module/ui/boot/runProviderColdBoot.js.map +1 -1
  90. package/lib/module/ui/client.js +0 -1
  91. package/lib/module/ui/client.js.map +1 -1
  92. package/lib/module/ui/components/OxyAccountDialogScreen.js +27 -4
  93. package/lib/module/ui/components/OxyAccountDialogScreen.js.map +1 -1
  94. package/lib/module/ui/components/OxyAuthChooser.js +76 -1128
  95. package/lib/module/ui/components/OxyAuthChooser.js.map +1 -1
  96. package/lib/module/ui/components/OxyConsentScreen.js +50 -12
  97. package/lib/module/ui/components/OxyConsentScreen.js.map +1 -1
  98. package/lib/module/ui/components/OxyProvider.js +4 -4
  99. package/lib/module/ui/components/OxyProvider.js.map +1 -1
  100. package/lib/module/ui/components/OxySignInButton.js +76 -42
  101. package/lib/module/ui/components/OxySignInButton.js.map +1 -1
  102. package/lib/module/ui/components/authChooser/AccountsMenuView.js +523 -0
  103. package/lib/module/ui/components/authChooser/AccountsMenuView.js.map +1 -0
  104. package/lib/module/ui/components/authChooser/SignInEntryView.js +85 -0
  105. package/lib/module/ui/components/authChooser/SignInEntryView.js.map +1 -0
  106. package/lib/module/ui/components/authChooser/SignInRequestView.js +139 -0
  107. package/lib/module/ui/components/authChooser/SignInRequestView.js.map +1 -0
  108. package/lib/module/ui/components/authChooser/SignUpView.js +184 -0
  109. package/lib/module/ui/components/authChooser/SignUpView.js.map +1 -0
  110. package/lib/module/ui/components/authChooser/TroubleDisclosure.js +59 -0
  111. package/lib/module/ui/components/authChooser/TroubleDisclosure.js.map +1 -0
  112. package/lib/module/ui/components/authChooser/primitives.js +163 -0
  113. package/lib/module/ui/components/authChooser/primitives.js.map +1 -0
  114. package/lib/module/ui/components/authChooser/requestSurfaces.js +139 -0
  115. package/lib/module/ui/components/authChooser/requestSurfaces.js.map +1 -0
  116. package/lib/module/ui/components/authChooser/signInProgress.js +50 -0
  117. package/lib/module/ui/components/authChooser/signInProgress.js.map +1 -0
  118. package/lib/module/ui/components/{oxyAuthChooserStyles.js → authChooser/styles.js} +19 -1
  119. package/lib/module/ui/components/authChooser/styles.js.map +1 -0
  120. package/lib/module/ui/components/authChooser/types.js +55 -0
  121. package/lib/module/ui/components/authChooser/types.js.map +1 -0
  122. package/lib/module/ui/components/authChooser/useUsernameAvailability.js +46 -0
  123. package/lib/module/ui/components/authChooser/useUsernameAvailability.js.map +1 -0
  124. package/lib/module/ui/context/OxyContext.js +208 -33
  125. package/lib/module/ui/context/OxyContext.js.map +1 -1
  126. package/lib/module/ui/context/commitSessionFlow.js +45 -0
  127. package/lib/module/ui/context/commitSessionFlow.js.map +1 -1
  128. package/lib/module/ui/context/hooks/useAuthOperations.js +15 -2
  129. package/lib/module/ui/context/hooks/useAuthOperations.js.map +1 -1
  130. package/lib/module/ui/context/useOxyAccountGraph.js +13 -5
  131. package/lib/module/ui/context/useOxyAccountGraph.js.map +1 -1
  132. package/lib/module/ui/hooks/useSwitchableAccounts.js +6 -1
  133. package/lib/module/ui/hooks/useSwitchableAccounts.js.map +1 -1
  134. package/lib/module/ui/index.js +0 -1
  135. package/lib/module/ui/index.js.map +1 -1
  136. package/lib/module/ui/oauth/browserAuthTransport.js +167 -0
  137. package/lib/module/ui/oauth/browserAuthTransport.js.map +1 -0
  138. package/lib/module/ui/oauth/completeOAuthCode.js +75 -0
  139. package/lib/module/ui/oauth/completeOAuthCode.js.map +1 -0
  140. package/lib/module/ui/oauth/legacyRedirectLanes.js +44 -0
  141. package/lib/module/ui/oauth/legacyRedirectLanes.js.map +1 -0
  142. package/lib/module/ui/oauth/oauthHandshake.js +50 -0
  143. package/lib/module/ui/oauth/oauthHandshake.js.map +1 -0
  144. package/lib/module/ui/oauth/oauthPopup.js +268 -0
  145. package/lib/module/ui/oauth/oauthPopup.js.map +1 -0
  146. package/lib/module/ui/oauth/oauthPopupMessages.js +135 -0
  147. package/lib/module/ui/oauth/oauthPopupMessages.js.map +1 -0
  148. package/lib/module/ui/oauth/types.js +2 -0
  149. package/lib/module/ui/oauth/types.js.map +1 -0
  150. package/lib/module/ui/server.js +0 -2
  151. package/lib/module/ui/server.js.map +1 -1
  152. package/lib/module/ui/session/authStore.js +5 -75
  153. package/lib/module/ui/session/authStore.js.map +1 -1
  154. package/lib/module/ui/session/createSessionClient.js +11 -3
  155. package/lib/module/ui/session/createSessionClient.js.map +1 -1
  156. package/lib/module/ui/session/identityBinding.js +89 -0
  157. package/lib/module/ui/session/identityBinding.js.map +1 -0
  158. package/lib/module/ui/session/index.js +5 -2
  159. package/lib/module/ui/session/index.js.map +1 -1
  160. package/lib/module/ui/session/nativeSecureStorage.js +88 -0
  161. package/lib/module/ui/session/nativeSecureStorage.js.map +1 -0
  162. package/lib/module/ui/session/tokenTransport.js +11 -1
  163. package/lib/module/ui/session/tokenTransport.js.map +1 -1
  164. package/lib/module/ui/utils/crossOriginRestore.js +6 -5
  165. package/lib/module/ui/utils/crossOriginRestore.js.map +1 -1
  166. package/lib/module/ui/utils/deliveryPlatform.js +55 -0
  167. package/lib/module/ui/utils/deliveryPlatform.js.map +1 -0
  168. package/lib/module/ui/utils/oauthReturn.js +73 -47
  169. package/lib/module/ui/utils/oauthReturn.js.map +1 -1
  170. package/lib/typescript/commonjs/index.d.ts +4 -1
  171. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  172. package/lib/typescript/commonjs/ui/boot/runProviderColdBoot.d.ts +34 -2
  173. package/lib/typescript/commonjs/ui/boot/runProviderColdBoot.d.ts.map +1 -1
  174. package/lib/typescript/commonjs/ui/client.d.ts +0 -1
  175. package/lib/typescript/commonjs/ui/client.d.ts.map +1 -1
  176. package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
  177. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts +21 -29
  178. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts.map +1 -1
  179. package/lib/typescript/commonjs/ui/components/OxyConsentScreen.d.ts.map +1 -1
  180. package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts.map +1 -1
  181. package/lib/typescript/commonjs/ui/components/OxySignInButton.d.ts +17 -12
  182. package/lib/typescript/commonjs/ui/components/OxySignInButton.d.ts.map +1 -1
  183. package/lib/typescript/commonjs/ui/components/authChooser/AccountsMenuView.d.ts +38 -0
  184. package/lib/typescript/commonjs/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -0
  185. package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts +32 -0
  186. package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts.map +1 -0
  187. package/lib/typescript/commonjs/ui/components/authChooser/SignInRequestView.d.ts +34 -0
  188. package/lib/typescript/commonjs/ui/components/authChooser/SignInRequestView.d.ts.map +1 -0
  189. package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts +34 -0
  190. package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts.map +1 -0
  191. package/lib/typescript/commonjs/ui/components/authChooser/TroubleDisclosure.d.ts +43 -0
  192. package/lib/typescript/commonjs/ui/components/authChooser/TroubleDisclosure.d.ts.map +1 -0
  193. package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts +55 -0
  194. package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts.map +1 -0
  195. package/lib/typescript/commonjs/ui/components/authChooser/requestSurfaces.d.ts +54 -0
  196. package/lib/typescript/commonjs/ui/components/authChooser/requestSurfaces.d.ts.map +1 -0
  197. package/lib/typescript/commonjs/ui/components/authChooser/signInProgress.d.ts +26 -0
  198. package/lib/typescript/commonjs/ui/components/authChooser/signInProgress.d.ts.map +1 -0
  199. package/lib/typescript/{module/ui/components/oxyAuthChooserStyles.d.ts → commonjs/ui/components/authChooser/styles.d.ts} +19 -1
  200. package/lib/typescript/commonjs/ui/components/authChooser/styles.d.ts.map +1 -0
  201. package/lib/typescript/commonjs/ui/components/authChooser/types.d.ts +85 -0
  202. package/lib/typescript/commonjs/ui/components/authChooser/types.d.ts.map +1 -0
  203. package/lib/typescript/commonjs/ui/components/authChooser/useUsernameAvailability.d.ts +16 -0
  204. package/lib/typescript/commonjs/ui/components/authChooser/useUsernameAvailability.d.ts.map +1 -0
  205. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
  206. package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts +40 -0
  207. package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts.map +1 -1
  208. package/lib/typescript/commonjs/ui/context/hooks/useAuthOperations.d.ts +11 -2
  209. package/lib/typescript/commonjs/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  210. package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts +44 -1
  211. package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts.map +1 -1
  212. package/lib/typescript/commonjs/ui/context/useOxyAccountGraph.d.ts +7 -1
  213. package/lib/typescript/commonjs/ui/context/useOxyAccountGraph.d.ts.map +1 -1
  214. package/lib/typescript/commonjs/ui/hooks/useSwitchableAccounts.d.ts.map +1 -1
  215. package/lib/typescript/commonjs/ui/index.d.ts +0 -1
  216. package/lib/typescript/commonjs/ui/index.d.ts.map +1 -1
  217. package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts +56 -0
  218. package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts.map +1 -0
  219. package/lib/typescript/commonjs/ui/oauth/completeOAuthCode.d.ts +49 -0
  220. package/lib/typescript/commonjs/ui/oauth/completeOAuthCode.d.ts.map +1 -0
  221. package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts +40 -0
  222. package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts.map +1 -0
  223. package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts +50 -0
  224. package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts.map +1 -0
  225. package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts +83 -0
  226. package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts.map +1 -0
  227. package/lib/typescript/commonjs/ui/oauth/oauthPopupMessages.d.ts +67 -0
  228. package/lib/typescript/commonjs/ui/oauth/oauthPopupMessages.d.ts.map +1 -0
  229. package/lib/typescript/commonjs/ui/oauth/types.d.ts +176 -0
  230. package/lib/typescript/commonjs/ui/oauth/types.d.ts.map +1 -0
  231. package/lib/typescript/commonjs/ui/server.d.ts +0 -2
  232. package/lib/typescript/commonjs/ui/server.d.ts.map +1 -1
  233. package/lib/typescript/commonjs/ui/session/authStore.d.ts +3 -7
  234. package/lib/typescript/commonjs/ui/session/authStore.d.ts.map +1 -1
  235. package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts +8 -1
  236. package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts.map +1 -1
  237. package/lib/typescript/commonjs/ui/session/identityBinding.d.ts +66 -0
  238. package/lib/typescript/commonjs/ui/session/identityBinding.d.ts.map +1 -0
  239. package/lib/typescript/commonjs/ui/session/index.d.ts +6 -2
  240. package/lib/typescript/commonjs/ui/session/index.d.ts.map +1 -1
  241. package/lib/typescript/commonjs/ui/session/nativeSecureStorage.d.ts +25 -0
  242. package/lib/typescript/commonjs/ui/session/nativeSecureStorage.d.ts.map +1 -0
  243. package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts +8 -1
  244. package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts.map +1 -1
  245. package/lib/typescript/commonjs/ui/types/navigation.d.ts +44 -0
  246. package/lib/typescript/commonjs/ui/types/navigation.d.ts.map +1 -1
  247. package/lib/typescript/commonjs/ui/utils/crossOriginRestore.d.ts.map +1 -1
  248. package/lib/typescript/commonjs/ui/utils/deliveryPlatform.d.ts +33 -0
  249. package/lib/typescript/commonjs/ui/utils/deliveryPlatform.d.ts.map +1 -0
  250. package/lib/typescript/commonjs/ui/utils/oauthReturn.d.ts +30 -16
  251. package/lib/typescript/commonjs/ui/utils/oauthReturn.d.ts.map +1 -1
  252. package/lib/typescript/module/index.d.ts +4 -1
  253. package/lib/typescript/module/index.d.ts.map +1 -1
  254. package/lib/typescript/module/ui/boot/runProviderColdBoot.d.ts +34 -2
  255. package/lib/typescript/module/ui/boot/runProviderColdBoot.d.ts.map +1 -1
  256. package/lib/typescript/module/ui/client.d.ts +0 -1
  257. package/lib/typescript/module/ui/client.d.ts.map +1 -1
  258. package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
  259. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts +21 -29
  260. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts.map +1 -1
  261. package/lib/typescript/module/ui/components/OxyConsentScreen.d.ts.map +1 -1
  262. package/lib/typescript/module/ui/components/OxyProvider.d.ts.map +1 -1
  263. package/lib/typescript/module/ui/components/OxySignInButton.d.ts +17 -12
  264. package/lib/typescript/module/ui/components/OxySignInButton.d.ts.map +1 -1
  265. package/lib/typescript/module/ui/components/authChooser/AccountsMenuView.d.ts +38 -0
  266. package/lib/typescript/module/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -0
  267. package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts +32 -0
  268. package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts.map +1 -0
  269. package/lib/typescript/module/ui/components/authChooser/SignInRequestView.d.ts +34 -0
  270. package/lib/typescript/module/ui/components/authChooser/SignInRequestView.d.ts.map +1 -0
  271. package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts +34 -0
  272. package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts.map +1 -0
  273. package/lib/typescript/module/ui/components/authChooser/TroubleDisclosure.d.ts +43 -0
  274. package/lib/typescript/module/ui/components/authChooser/TroubleDisclosure.d.ts.map +1 -0
  275. package/lib/typescript/module/ui/components/authChooser/primitives.d.ts +55 -0
  276. package/lib/typescript/module/ui/components/authChooser/primitives.d.ts.map +1 -0
  277. package/lib/typescript/module/ui/components/authChooser/requestSurfaces.d.ts +54 -0
  278. package/lib/typescript/module/ui/components/authChooser/requestSurfaces.d.ts.map +1 -0
  279. package/lib/typescript/module/ui/components/authChooser/signInProgress.d.ts +26 -0
  280. package/lib/typescript/module/ui/components/authChooser/signInProgress.d.ts.map +1 -0
  281. package/lib/typescript/{commonjs/ui/components/oxyAuthChooserStyles.d.ts → module/ui/components/authChooser/styles.d.ts} +19 -1
  282. package/lib/typescript/module/ui/components/authChooser/styles.d.ts.map +1 -0
  283. package/lib/typescript/module/ui/components/authChooser/types.d.ts +85 -0
  284. package/lib/typescript/module/ui/components/authChooser/types.d.ts.map +1 -0
  285. package/lib/typescript/module/ui/components/authChooser/useUsernameAvailability.d.ts +16 -0
  286. package/lib/typescript/module/ui/components/authChooser/useUsernameAvailability.d.ts.map +1 -0
  287. package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
  288. package/lib/typescript/module/ui/context/commitSessionFlow.d.ts +40 -0
  289. package/lib/typescript/module/ui/context/commitSessionFlow.d.ts.map +1 -1
  290. package/lib/typescript/module/ui/context/hooks/useAuthOperations.d.ts +11 -2
  291. package/lib/typescript/module/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  292. package/lib/typescript/module/ui/context/oxyContextTypes.d.ts +44 -1
  293. package/lib/typescript/module/ui/context/oxyContextTypes.d.ts.map +1 -1
  294. package/lib/typescript/module/ui/context/useOxyAccountGraph.d.ts +7 -1
  295. package/lib/typescript/module/ui/context/useOxyAccountGraph.d.ts.map +1 -1
  296. package/lib/typescript/module/ui/hooks/useSwitchableAccounts.d.ts.map +1 -1
  297. package/lib/typescript/module/ui/index.d.ts +0 -1
  298. package/lib/typescript/module/ui/index.d.ts.map +1 -1
  299. package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts +56 -0
  300. package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts.map +1 -0
  301. package/lib/typescript/module/ui/oauth/completeOAuthCode.d.ts +49 -0
  302. package/lib/typescript/module/ui/oauth/completeOAuthCode.d.ts.map +1 -0
  303. package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts +40 -0
  304. package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts.map +1 -0
  305. package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts +50 -0
  306. package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts.map +1 -0
  307. package/lib/typescript/module/ui/oauth/oauthPopup.d.ts +83 -0
  308. package/lib/typescript/module/ui/oauth/oauthPopup.d.ts.map +1 -0
  309. package/lib/typescript/module/ui/oauth/oauthPopupMessages.d.ts +67 -0
  310. package/lib/typescript/module/ui/oauth/oauthPopupMessages.d.ts.map +1 -0
  311. package/lib/typescript/module/ui/oauth/types.d.ts +176 -0
  312. package/lib/typescript/module/ui/oauth/types.d.ts.map +1 -0
  313. package/lib/typescript/module/ui/server.d.ts +0 -2
  314. package/lib/typescript/module/ui/server.d.ts.map +1 -1
  315. package/lib/typescript/module/ui/session/authStore.d.ts +3 -7
  316. package/lib/typescript/module/ui/session/authStore.d.ts.map +1 -1
  317. package/lib/typescript/module/ui/session/createSessionClient.d.ts +8 -1
  318. package/lib/typescript/module/ui/session/createSessionClient.d.ts.map +1 -1
  319. package/lib/typescript/module/ui/session/identityBinding.d.ts +66 -0
  320. package/lib/typescript/module/ui/session/identityBinding.d.ts.map +1 -0
  321. package/lib/typescript/module/ui/session/index.d.ts +6 -2
  322. package/lib/typescript/module/ui/session/index.d.ts.map +1 -1
  323. package/lib/typescript/module/ui/session/nativeSecureStorage.d.ts +25 -0
  324. package/lib/typescript/module/ui/session/nativeSecureStorage.d.ts.map +1 -0
  325. package/lib/typescript/module/ui/session/tokenTransport.d.ts +8 -1
  326. package/lib/typescript/module/ui/session/tokenTransport.d.ts.map +1 -1
  327. package/lib/typescript/module/ui/types/navigation.d.ts +44 -0
  328. package/lib/typescript/module/ui/types/navigation.d.ts.map +1 -1
  329. package/lib/typescript/module/ui/utils/crossOriginRestore.d.ts.map +1 -1
  330. package/lib/typescript/module/ui/utils/deliveryPlatform.d.ts +33 -0
  331. package/lib/typescript/module/ui/utils/deliveryPlatform.d.ts.map +1 -0
  332. package/lib/typescript/module/ui/utils/oauthReturn.d.ts +30 -16
  333. package/lib/typescript/module/ui/utils/oauthReturn.d.ts.map +1 -1
  334. package/package.json +6 -8
  335. package/src/index.ts +19 -5
  336. package/src/ui/boot/__tests__/coldBootWebAuthMode.test.ts +281 -0
  337. package/src/ui/boot/runProviderColdBoot.ts +83 -13
  338. package/src/ui/client.ts +0 -1
  339. package/src/ui/components/OxyAccountDialogScreen.tsx +33 -4
  340. package/src/ui/components/OxyAuthChooser.tsx +100 -1230
  341. package/src/ui/components/OxyConsentScreen.tsx +56 -13
  342. package/src/ui/components/OxyProvider.tsx +4 -4
  343. package/src/ui/components/OxySignInButton.tsx +119 -78
  344. package/src/ui/components/__tests__/OxyConsentScreen.test.tsx +27 -0
  345. package/src/ui/components/authChooser/AccountsMenuView.tsx +569 -0
  346. package/src/ui/components/authChooser/SignInEntryView.tsx +115 -0
  347. package/src/ui/components/authChooser/SignInRequestView.tsx +163 -0
  348. package/src/ui/components/authChooser/SignUpView.tsx +174 -0
  349. package/src/ui/components/authChooser/TroubleDisclosure.tsx +81 -0
  350. package/src/ui/components/authChooser/primitives.tsx +144 -0
  351. package/src/ui/components/authChooser/requestSurfaces.tsx +116 -0
  352. package/src/ui/components/authChooser/signInProgress.ts +54 -0
  353. package/src/ui/components/{oxyAuthChooserStyles.ts → authChooser/styles.ts} +18 -0
  354. package/src/ui/components/authChooser/types.ts +101 -0
  355. package/src/ui/components/authChooser/useUsernameAvailability.ts +60 -0
  356. package/src/ui/context/OxyContext.tsx +226 -24
  357. package/src/ui/context/__tests__/commitSessionFlow.test.ts +102 -0
  358. package/src/ui/context/commitSessionFlow.ts +64 -0
  359. package/src/ui/context/hooks/useAuthOperations.ts +26 -1
  360. package/src/ui/context/oxyContextTypes.ts +45 -1
  361. package/src/ui/context/useOxyAccountGraph.ts +19 -5
  362. package/src/ui/hooks/useSwitchableAccounts.ts +12 -1
  363. package/src/ui/index.ts +0 -1
  364. package/src/ui/oauth/__tests__/browserAuthTransport.test.ts +335 -0
  365. package/src/ui/oauth/__tests__/completeOAuthCode.test.ts +142 -0
  366. package/src/ui/oauth/__tests__/oauthPopup.test.ts +352 -0
  367. package/src/ui/oauth/__tests__/oauthPopupMessages.test.ts +189 -0
  368. package/src/ui/oauth/__tests__/sharedCompletionPath.test.ts +174 -0
  369. package/src/ui/oauth/browserAuthTransport.ts +193 -0
  370. package/src/ui/oauth/completeOAuthCode.ts +93 -0
  371. package/src/ui/oauth/legacyRedirectLanes.ts +43 -0
  372. package/src/ui/oauth/oauthHandshake.ts +74 -0
  373. package/src/ui/oauth/oauthPopup.ts +277 -0
  374. package/src/ui/oauth/oauthPopupMessages.ts +136 -0
  375. package/src/ui/oauth/types.ts +150 -0
  376. package/src/ui/server.ts +0 -2
  377. package/src/ui/session/__tests__/createSessionClient.test.ts +26 -0
  378. package/src/ui/session/__tests__/tokenTransport.test.ts +34 -0
  379. package/src/ui/session/authStore.ts +5 -89
  380. package/src/ui/session/createSessionClient.ts +15 -2
  381. package/src/ui/session/identityBinding.ts +116 -0
  382. package/src/ui/session/index.ts +6 -2
  383. package/src/ui/session/nativeSecureStorage.ts +98 -0
  384. package/src/ui/session/tokenTransport.ts +14 -1
  385. package/src/ui/types/navigation.ts +44 -1
  386. package/src/ui/utils/__tests__/crossOriginRestore.test.ts +17 -0
  387. package/src/ui/utils/crossOriginRestore.ts +9 -13
  388. package/src/ui/utils/deliveryPlatform.ts +65 -0
  389. package/src/ui/utils/oauthReturn.ts +79 -65
  390. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
  391. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
  392. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
  393. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
  394. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
  395. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
  396. package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
  397. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
  398. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
  399. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
  400. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
  401. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
  402. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
  403. package/lib/commonjs/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
  404. package/lib/commonjs/ui/components/FontLoader.js +0 -35
  405. package/lib/commonjs/ui/components/FontLoader.js.map +0 -1
  406. package/lib/commonjs/ui/components/FontLoader.native.js +0 -88
  407. package/lib/commonjs/ui/components/FontLoader.native.js.map +0 -1
  408. package/lib/commonjs/ui/components/oxyAuthChooserStyles.js.map +0 -1
  409. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
  410. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
  411. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
  412. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
  413. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
  414. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
  415. package/lib/module/assets/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
  416. package/lib/module/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
  417. package/lib/module/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
  418. package/lib/module/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
  419. package/lib/module/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
  420. package/lib/module/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
  421. package/lib/module/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
  422. package/lib/module/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
  423. package/lib/module/ui/components/FontLoader.js +0 -29
  424. package/lib/module/ui/components/FontLoader.js.map +0 -1
  425. package/lib/module/ui/components/FontLoader.native.js +0 -83
  426. package/lib/module/ui/components/FontLoader.native.js.map +0 -1
  427. package/lib/module/ui/components/oxyAuthChooserStyles.js.map +0 -1
  428. package/lib/typescript/commonjs/ui/components/FontLoader.d.ts +0 -24
  429. package/lib/typescript/commonjs/ui/components/FontLoader.d.ts.map +0 -1
  430. package/lib/typescript/commonjs/ui/components/FontLoader.native.d.ts +0 -13
  431. package/lib/typescript/commonjs/ui/components/FontLoader.native.d.ts.map +0 -1
  432. package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts.map +0 -1
  433. package/lib/typescript/module/ui/components/FontLoader.d.ts +0 -24
  434. package/lib/typescript/module/ui/components/FontLoader.d.ts.map +0 -1
  435. package/lib/typescript/module/ui/components/FontLoader.native.d.ts +0 -13
  436. package/lib/typescript/module/ui/components/FontLoader.native.d.ts.map +0 -1
  437. package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts.map +0 -1
  438. package/src/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
  439. package/src/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
  440. package/src/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
  441. package/src/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
  442. package/src/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
  443. package/src/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
  444. package/src/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
  445. package/src/ui/components/FontLoader.native.tsx +0 -88
  446. package/src/ui/components/FontLoader.tsx +0 -27
@@ -0,0 +1,83 @@
1
+ /**
2
+ * Popup lifecycle for the web OAuth transport.
3
+ *
4
+ * Owns the window itself — opening it, navigating it, watching it, and tearing
5
+ * every listener and timer down — and nothing else: message validation lives in
6
+ * `oauthPopupMessages.ts`, and the code exchange in `completeOAuthCode.ts`.
7
+ *
8
+ * Three browser realities shape this module:
9
+ *
10
+ * - **Gesture attribution.** `window.open` only succeeds while the user's click
11
+ * is still being handled. Anything awaited first (resolving the application,
12
+ * generating PKCE) loses it and the popup is silently blocked. So the window
13
+ * is opened EMPTY up front and navigated once the authorize URL exists —
14
+ * the same shape as `passkeyHubPopup.ts`.
15
+ * - **No close event.** A cross-origin popup fires nothing when the user
16
+ * dismisses it; polling `closed` is the only mechanism (as in core's
17
+ * `AccountDialogController.watchPopup`).
18
+ * - **No cross-origin reads.** The popup's URL, title, and document are all
19
+ * opaque. The authorization result arrives ONLY as a `postMessage`.
20
+ */
21
+ import type { OAuthPopupHandle, OAuthPopupOutcome } from './types';
22
+ /**
23
+ * Window name for the sign-in popup. Naming the target means a second press
24
+ * REUSES the same window instead of stacking a new one behind the first.
25
+ */
26
+ export declare const OXY_OAUTH_POPUP_WINDOW_NAME = "oxy-oauth";
27
+ /**
28
+ * How long a popup sign-in may stay unanswered (ms).
29
+ *
30
+ * Generous on purpose: the IdP surface can involve scanning a QR and approving
31
+ * on a phone, so this tracks the authorize handle's own ~5-minute lifetime
32
+ * rather than a UI-scale timeout. It is a backstop against a wedged popup, not
33
+ * a pace-setter — a user who gives up closes the window and gets the faster
34
+ * `closed` outcome.
35
+ */
36
+ export declare const DEFAULT_OAUTH_POPUP_TIMEOUT_MS = 300000;
37
+ /**
38
+ * Open a new, EMPTY sign-in popup.
39
+ *
40
+ * MUST be called SYNCHRONOUSLY from a user-gesture handler, before any `await`.
41
+ * Returns `null` when the browser blocked it, when `window.open` threw, and on
42
+ * hosts with no DOM (native / SSR) — never throws, because "no popup" is an
43
+ * ordinary outcome the caller answers by falling back to a redirect.
44
+ */
45
+ export declare function openOAuthPopup(): OAuthPopupHandle | null;
46
+ /**
47
+ * Point an already-open popup at the authorize URL. Returns `false` when the
48
+ * assignment threw (a window closed between opening and navigating), so the
49
+ * caller can fall back to a redirect instead of waiting on a dead window.
50
+ */
51
+ export declare function navigateOAuthPopup(popup: OAuthPopupHandle, url: string): boolean;
52
+ /** Close the popup if it is still open. Idempotent, null-safe, never throws. */
53
+ export declare function closeOAuthPopup(popup: OAuthPopupHandle | null): void;
54
+ /** Inputs for {@link awaitOAuthPopupResult}. */
55
+ export interface AwaitOAuthPopupOptions {
56
+ /** The exact window reference returned by {@link openOAuthPopup}. */
57
+ popup: OAuthPopupHandle;
58
+ /** Exact origin the IdP will post from (`new URL(authorizeUrl).origin`). */
59
+ expectedOrigin: string;
60
+ /** The CSRF `state` sent on the authorize request. */
61
+ expectedState: string;
62
+ /**
63
+ * EXACT registered redirect URI for this attempt. When the IdP cannot
64
+ * `postMessage` (no usable opener) it falls back to redirecting the popup;
65
+ * if that lands on the same origin, the result is read from the popup URL.
66
+ */
67
+ redirectUri: string;
68
+ /** @default DEFAULT_OAUTH_POPUP_TIMEOUT_MS */
69
+ timeoutMs?: number;
70
+ }
71
+ /**
72
+ * Wait for the popup to deliver an authorization result.
73
+ *
74
+ * Settles EXACTLY once, with a typed outcome for every path — code, IdP error,
75
+ * state mismatch, user-closed, timeout — and removes its listener, its close
76
+ * poll, and both timers before resolving, whatever the outcome. Messages that
77
+ * arrive after settling reach nothing, so a duplicate delivery is inert.
78
+ *
79
+ * Never rejects: closing the window and running out of time are expected
80
+ * outcomes, not exceptions.
81
+ */
82
+ export declare function awaitOAuthPopupResult(options: AwaitOAuthPopupOptions): Promise<OAuthPopupOutcome>;
83
+ //# sourceMappingURL=oauthPopup.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"oauthPopup.d.ts","sourceRoot":"","sources":["../../../../../src/ui/oauth/oauthPopup.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAIH,OAAO,KAAK,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEnE;;;GAGG;AACH,eAAO,MAAM,2BAA2B,cAAc,CAAC;AAKvD;;;;;;;;GAQG;AACH,eAAO,MAAM,8BAA8B,SAAU,CAAC;AAkCtD;;;;;;;GAOG;AACH,wBAAgB,cAAc,IAAI,gBAAgB,GAAG,IAAI,CASxD;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,gBAAgB,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAQhF;AAED,gFAAgF;AAChF,wBAAgB,eAAe,CAAC,KAAK,EAAE,gBAAgB,GAAG,IAAI,GAAG,IAAI,CAOpE;AA2CD,gDAAgD;AAChD,MAAM,WAAW,sBAAsB;IACrC,qEAAqE;IACrE,KAAK,EAAE,gBAAgB,CAAC;IACxB,4EAA4E;IAC5E,cAAc,EAAE,MAAM,CAAC;IACvB,sDAAsD;IACtD,aAAa,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,WAAW,EAAE,MAAM,CAAC;IACpB,8CAA8C;IAC9C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,sBAAsB,GAC9B,OAAO,CAAC,iBAAiB,CAAC,CAmF5B"}
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Runtime validation for the popup OAuth `postMessage` channel.
3
+ *
4
+ * Everything arriving on `window`'s `message` event is untrusted: any frame on
5
+ * the page, any other popup, and any browser extension can post to us. This
6
+ * module is the ONLY place that decides whether an incoming event is a genuine
7
+ * authorization response, and it answers with a value — never a thrown error.
8
+ *
9
+ * A message is accepted only when ALL of these hold:
10
+ * 1. `event.origin` is EXACTLY the authorize endpoint's origin,
11
+ * 2. `event.source` is the exact `Window` reference we opened,
12
+ * 3. `event.data` matches one of the two frozen message shapes,
13
+ * 4. the `state` it carries matches the one this RP sent.
14
+ *
15
+ * Failing (1)–(3) is indistinguishable from unrelated page traffic, so the
16
+ * message is IGNORED and the flow keeps waiting. Failing (4) means our own
17
+ * popup answered a different request than the one in flight, which is terminal:
18
+ * it is reported as a mismatch rather than left to hang until the timeout.
19
+ */
20
+ import type { OAuthPopupHandle, OxyOAuthMessage } from './types';
21
+ /** `postMessage` discriminator for a successful authorization. */
22
+ export declare const OXY_OAUTH_CODE_MESSAGE_TYPE = "oxy:oauth:code";
23
+ /** `postMessage` discriminator for a typed OAuth failure. */
24
+ export declare const OXY_OAUTH_ERROR_MESSAGE_TYPE = "oxy:oauth:error";
25
+ /** Verdict for one incoming `message` event. */
26
+ export type OAuthPopupMessageVerdict =
27
+ /** Not ours (wrong origin/source) or not a valid message — keep waiting. */
28
+ {
29
+ kind: 'ignore';
30
+ } | {
31
+ kind: 'code';
32
+ code: string;
33
+ state: string;
34
+ } | {
35
+ kind: 'oauth-error';
36
+ error: string;
37
+ errorDescription?: string;
38
+ }
39
+ /** Well-formed, from our popup, but bound to a different authorize request. */
40
+ | {
41
+ kind: 'state-mismatch';
42
+ };
43
+ /** What {@link readOAuthPopupMessage} validates an event against. */
44
+ export interface OAuthPopupMessageContext {
45
+ /** Exact origin of the authorize endpoint (`new URL(authorizeUrl).origin`). */
46
+ expectedOrigin: string;
47
+ /** The CSRF `state` this RP sent on the authorize request. */
48
+ expectedState: string;
49
+ /** The exact popup reference `window.open()` returned. */
50
+ popup: OAuthPopupHandle;
51
+ }
52
+ /**
53
+ * Parse untrusted `event.data` into one of the two frozen message shapes, or
54
+ * `null` when it is anything else (including `null`, primitives, arrays, and
55
+ * objects with missing/wrong-typed fields).
56
+ *
57
+ * Unknown extra properties are tolerated but never read: only the fields below
58
+ * are ever surfaced, so a hostile sender cannot smuggle values past this point.
59
+ */
60
+ export declare function parseOAuthPopupMessage(data: unknown): OxyOAuthMessage | null;
61
+ /**
62
+ * Classify one `message` event against the in-flight authorize request.
63
+ *
64
+ * Never throws. See the module header for the acceptance rules.
65
+ */
66
+ export declare function readOAuthPopupMessage(event: MessageEvent, context: OAuthPopupMessageContext): OAuthPopupMessageVerdict;
67
+ //# sourceMappingURL=oauthPopupMessages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"oauthPopupMessages.d.ts","sourceRoot":"","sources":["../../../../../src/ui/oauth/oauthPopupMessages.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAEjE,kEAAkE;AAClE,eAAO,MAAM,2BAA2B,mBAAmB,CAAC;AAE5D,6DAA6D;AAC7D,eAAO,MAAM,4BAA4B,oBAAoB,CAAC;AAE9D,gDAAgD;AAChD,MAAM,MAAM,wBAAwB;AAClC,4EAA4E;AAC1E;IAAE,IAAI,EAAE,QAAQ,CAAA;CAAE,GAClB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GAC7C;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,gBAAgB,CAAC,EAAE,MAAM,CAAA;CAAE;AACnE,+EAA+E;GAC7E;IAAE,IAAI,EAAE,gBAAgB,CAAA;CAAE,CAAC;AAE/B,qEAAqE;AACrE,MAAM,WAAW,wBAAwB;IACvC,+EAA+E;IAC/E,cAAc,EAAE,MAAM,CAAC;IACvB,8DAA8D;IAC9D,aAAa,EAAE,MAAM,CAAC;IACtB,0DAA0D;IAC1D,KAAK,EAAE,gBAAgB,CAAC;CACzB;AAkBD;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,OAAO,GAAG,eAAe,GAAG,IAAI,CAsB5E;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,YAAY,EACnB,OAAO,EAAE,wBAAwB,GAChC,wBAAwB,CA+B1B"}
@@ -0,0 +1,176 @@
1
+ /**
2
+ * Typed contracts shared by the browser "Sign in with Oxy" OAuth transports.
3
+ *
4
+ * Two transports deliver the same authorization code to the same completion
5
+ * path (see `completeOAuthCode.ts`):
6
+ *
7
+ * - `redirect` — the historical full-page hand-off to `auth.oxy.so/authorize`.
8
+ * The RP tab navigates away and comes back to its registered `redirect_uri`
9
+ * with `?code=…&state=…`; cold boot finishes the exchange.
10
+ * - `popup` — a small `auth.oxy.so` window opened from the user's click. The RP
11
+ * stays mounted with its route and unsaved state intact; the IdP delivers the
12
+ * result to `window.opener` via `postMessage` and closes itself.
13
+ *
14
+ * Only the authorization code, the CSRF `state`, and a typed OAuth error ever
15
+ * cross the `postMessage` channel. Access tokens, device secrets, and the PKCE
16
+ * `code_verifier` NEVER do — the opener keeps the verifier and performs the code
17
+ * exchange itself.
18
+ */
19
+ /** How a web relying party hands the user to the IdP for third-party sign-in. */
20
+ export type WebAuthMode = 'popup' | 'redirect';
21
+ /**
22
+ * Minimal structural handle over a popup `Window` — exactly what the popup
23
+ * transport needs: navigate it once the authorize URL is built, detect the user
24
+ * closing it (`closed`, polled — there is no cross-origin close event), and
25
+ * close it programmatically on completion. Satisfied directly by the value
26
+ * `window.open()` returns.
27
+ *
28
+ * Deliberately NOT `Window`: the transport must never read cross-origin
29
+ * properties off the popup, and a narrow handle makes that impossible to do by
30
+ * accident (and trivial to fake in tests).
31
+ */
32
+ export interface OAuthPopupHandle {
33
+ readonly closed: boolean;
34
+ close(): void;
35
+ location: {
36
+ href: string;
37
+ };
38
+ }
39
+ /**
40
+ * The RP-side OAuth handshake for one authorize request: the CSRF `state` sent
41
+ * to the IdP and the PKCE `code_verifier` replayed on the token exchange.
42
+ *
43
+ * In `redirect` mode it is persisted to `sessionStorage` across the full-page
44
+ * navigation; in `popup` mode it never leaves memory.
45
+ */
46
+ export interface OAuthHandshake {
47
+ /** Opaque CSRF token echoed back by the IdP and validated before any exchange. */
48
+ state: string;
49
+ /** The PKCE secret. Never crosses `postMessage`, a URL, or storage in popup mode. */
50
+ codeVerifier: string;
51
+ }
52
+ /** Successful authorization delivered by the IdP over `postMessage`. */
53
+ export interface OxyOAuthCodeMessage {
54
+ type: 'oxy:oauth:code';
55
+ code: string;
56
+ state: string;
57
+ }
58
+ /** Typed OAuth failure delivered by the IdP over `postMessage`. */
59
+ export interface OxyOAuthErrorMessage {
60
+ type: 'oxy:oauth:error';
61
+ error: string;
62
+ errorDescription?: string;
63
+ state?: string;
64
+ }
65
+ /** The ONLY two message shapes that may cross the popup channel. */
66
+ export type OxyOAuthMessage = OxyOAuthCodeMessage | OxyOAuthErrorMessage;
67
+ /** Session material handed to the provider's commit funnel after an exchange. */
68
+ export interface OAuthSessionCommitInput {
69
+ sessionId: string;
70
+ accessToken?: string;
71
+ deviceId?: string;
72
+ deviceSecret?: string;
73
+ userId: string;
74
+ expiresAt?: string;
75
+ user?: {
76
+ id: string;
77
+ username?: string;
78
+ avatar?: string;
79
+ };
80
+ }
81
+ /**
82
+ * Terminal outcome of one popup sign-in attempt. Every expected path — the user
83
+ * closing the window, a timeout, an IdP error — is a value, never a thrown
84
+ * exception.
85
+ */
86
+ export type OAuthPopupOutcome =
87
+ /** The IdP delivered an authorization code whose `state` matched. */
88
+ {
89
+ kind: 'code';
90
+ code: string;
91
+ state: string;
92
+ }
93
+ /** The IdP delivered a typed OAuth error (`access_denied`, `login_required`, …). */
94
+ | {
95
+ kind: 'oauth-error';
96
+ error: string;
97
+ errorDescription?: string;
98
+ }
99
+ /** A well-formed message from our popup carried the wrong `state`. */
100
+ | {
101
+ kind: 'state-mismatch';
102
+ }
103
+ /** The user dismissed the popup without completing sign-in. */
104
+ | {
105
+ kind: 'closed';
106
+ }
107
+ /** No result arrived within the allotted window. */
108
+ | {
109
+ kind: 'timed-out';
110
+ }
111
+ /** No DOM message host (SSR / native) — the popup transport does not apply. */
112
+ | {
113
+ kind: 'unsupported';
114
+ };
115
+ /** Why the shared completion path could not produce a session. */
116
+ export type OAuthCompletionFailure = 'state-mismatch' | 'exchange-failed';
117
+ /** Result of the ONE completion path both transports run. */
118
+ export type OAuthCompletionResult = {
119
+ ok: true;
120
+ } | {
121
+ ok: false;
122
+ reason: OAuthCompletionFailure;
123
+ };
124
+ /** Why the transport fell back to a full-page redirect. */
125
+ export type WebOAuthRedirectReason =
126
+ /** `webAuthMode: 'redirect'` — the configured transport. */
127
+ 'redirect-mode'
128
+ /** The browser refused `window.open` (blocker, or no gesture attribution). */
129
+ | 'popup-blocked'
130
+ /** The popup opened but could not be navigated to the authorize URL. */
131
+ | 'popup-navigation-failed';
132
+ /** Why a web sign-in attempt failed outright. */
133
+ export type WebOAuthFailureReason =
134
+ /** The handshake could not be persisted for the redirect return (no/blocked storage). */
135
+ 'handshake-storage'
136
+ /** The `state` returned by the IdP did not match the one we sent. */
137
+ | 'state-mismatch'
138
+ /** `POST /auth/oauth/token` or the session commit failed. */
139
+ | 'exchange-failed'
140
+ /** The IdP reported a typed OAuth error. */
141
+ | 'idp-error';
142
+ /** Why a web sign-in attempt was not applicable at all. */
143
+ export type WebOAuthUnsupportedReason =
144
+ /** Not a browser (native / SSR) — native uses `openAuthorizeUrlNative`. */
145
+ 'no-browser'
146
+ /** `sessionMode: 'identity'` has no third-party OAuth lane by construction. */
147
+ | 'identity-bound'
148
+ /** No `clientId` is configured on the provider. */
149
+ | 'missing-client-id';
150
+ /** Terminal, typed outcome of a web third-party sign-in attempt. */
151
+ export type WebOAuthSignInResult =
152
+ /** A session was committed; the RP is authenticated without a reload. */
153
+ {
154
+ status: 'signed-in';
155
+ }
156
+ /** The tab is navigating to the IdP; nothing else will resolve in this document. */
157
+ | {
158
+ status: 'redirecting';
159
+ via: WebOAuthRedirectReason;
160
+ }
161
+ /** The user dismissed the popup. */
162
+ | {
163
+ status: 'cancelled';
164
+ }
165
+ /** No result arrived within the allotted window. */
166
+ | {
167
+ status: 'timed-out';
168
+ } | {
169
+ status: 'failed';
170
+ reason: WebOAuthFailureReason;
171
+ description?: string;
172
+ } | {
173
+ status: 'unsupported';
174
+ reason: WebOAuthUnsupportedReason;
175
+ };
176
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/ui/oauth/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,iFAAiF;AACjF,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,UAAU,CAAC;AAE/C;;;;;;;;;;GAUG;AACH,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,KAAK,IAAI,IAAI,CAAC;IACd,QAAQ,EAAE;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC;CAC5B;AAED;;;;;;GAMG;AACH,MAAM,WAAW,cAAc;IAC7B,kFAAkF;IAClF,KAAK,EAAE,MAAM,CAAC;IACd,qFAAqF;IACrF,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,wEAAwE;AACxE,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,gBAAgB,CAAC;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf;AAED,mEAAmE;AACnE,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,iBAAiB,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,oEAAoE;AACpE,MAAM,MAAM,eAAe,GAAG,mBAAmB,GAAG,oBAAoB,CAAC;AAEzE,iFAAiF;AACjF,MAAM,WAAW,uBAAuB;IACtC,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,Y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,gBAAgB;AAClB,6DAA6D;GAC3D,iBAAiB;AACnB,4CAA4C;GAC1C,WAAW,CAAC;AAEhB,2DAA2D;AAC3D,MAAM,MAAM,yBAAyB;AACnC,2EAA2E;AACzE,YAAY;AACd,+EAA+E;GAC7E,gBAAgB;AAClB,mDAAmD;GACjD,mBAAmB,CAAC;AAExB,oEAAoE;AACpE,MAAM,MAAM,oBAAoB;AAC9B,yEAAyE;AACvE;IAAE,MAAM,EAAE,WAAW,CAAA;CAAE;AACzB,oFAAoF;GAClF;IAAE,MAAM,EAAE,aAAa,CAAC;IAAC,GAAG,EAAE,sBAAsB,CAAA;CAAE;AACxD,oCAAoC;GAClC;IAAE,MAAM,EAAE,WAAW,CAAA;CAAE;AACzB,oDAAoD;GAClD;IAAE,MAAM,EAAE,WAAW,CAAA;CAAE,GACvB;IAAE,MAAM,EAAE,QAAQ,CAAC;IAAC,MAAM,EAAE,qBAAqB,CAAC;IAAC,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,GACzE;IAAE,MAAM,EAAE,aAAa,CAAC;IAAC,MAAM,EAAE,yBAAyB,CAAA;CAAE,CAAC"}
@@ -13,8 +13,6 @@ export declare const LogoIcon: () => null;
13
13
  export declare const LogoText: () => null;
14
14
  export declare const FollowButton: () => null;
15
15
  export declare const OxyPayButton: () => null;
16
- export declare const FontLoader: () => null;
17
- export declare const setupFonts: () => Promise<boolean>;
18
16
  export declare const useOxy: () => {};
19
17
  export declare const useAuth: () => {};
20
18
  export declare const useFollow: () => {};
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../../src/ui/server.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAQH,eAAO,MAAM,WAAW,YAAgB,CAAC;AACzC,eAAO,MAAM,eAAe,YAAgB,CAAC;AAC7C,eAAO,MAAM,QAAQ,YAAgB,CAAC;AACtC,eAAO,MAAM,QAAQ,YAAgB,CAAC;AACtC,eAAO,MAAM,YAAY,YAAgB,CAAC;A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,EACH,eAAe,EACf,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,GACtB,MAAM,uBAAuB,CAAC;AAC/B,YAAY,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC"}
@@ -5,17 +5,13 @@
5
5
  * (`deviceId` + `deviceSecret`) per origin (web) / per device (native), and the
6
6
  * SDK re-mints the access token from that credential on cold boot. `@oxyhq/core`
7
7
  * owns the store shape + logic (`createWebAuthStateStore` /
8
- * `createNativeAuthStateStore`); this module only supplies the platform storage
8
+ * `createNativeAuthStateStore`); this module only selects the platform storage
9
9
  * seam:
10
10
  *
11
11
  * - web → `createWebAuthStateStore()` (localStorage, in-memory fallback).
12
12
  * - native → `createNativeAuthStateStore(secureKV)` for the SESSION blob over
13
- * `expo-secure-store` (AsyncStorage fallback).
14
- *
15
- * `expo-secure-store` is loaded via a runtime-computed dynamic import (the same
16
- * optional-native-module pattern `OxyProvider` uses for netinfo / keyboard
17
- * controller), so the web bundle never pulls it and a device without it falls
18
- * back to AsyncStorage rather than crashing.
13
+ * the shared `createNativeSecureKeyValueStorage()` adapter
14
+ * (`expo-secure-store`, AsyncStorage fallback).
19
15
  */
20
16
  import { type AuthStateStore } from '@oxyhq/core';
21
17
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"authStore.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/authStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,OAAO,EAGL,KAAK,cAAc,EAEpB,MAAM,aAAa,CAAC;AAmFrB;;;;;;GAMG;AACH,wBAAgB,4BAA4B,IAAI,cAAc,CAM7D"}
1
+ {"version":3,"file":"authStore.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/authStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAGL,KAAK,cAAc,EACpB,MAAM,aAAa,CAAC;AAIrB;;;;;;GAMG;AACH,wBAAgB,4BAA4B,IAAI,cAAc,CAM7D"}
@@ -25,8 +25,15 @@ import { SessionClient, createSessionClientHost, type OxyServices, type SessionS
25
25
  *
26
26
  * The realtime socket uses bearer when authenticated, or deviceId+deviceSecret
27
27
  * when signed out (after the one-shot join redirect).
28
+ *
29
+ * `getPinnedAccountId` reports the account an IDENTITY-BOUND provider
30
+ * (`sessionMode: 'identity'`) is pinned to, and `null` for every account-mode
31
+ * provider — which is exactly the value `SessionClient` and the transport read
32
+ * when the option is absent, so account mode is unchanged. While it reports an
33
+ * account, the client tracks device state truthfully but never re-binds its
34
+ * bearer to the device's mutable active account.
28
35
  */
29
- export declare function createSessionClient(oxyServices: OxyServices, onUnauthenticated?: (origin: SessionStateOrigin) => void): {
36
+ export declare function createSessionClient(oxyServices: OxyServices, onUnauthenticated?: (origin: SessionStateOrigin) => void, getPinnedAccountId?: () => string | null): {
30
37
  client: SessionClient;
31
38
  host: ReturnType<typeof createSessionClientHost>;
32
39
  };
@@ -1 +1 @@
1
- {"version":3,"file":"createSessionClient.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/createSessionClient.ts"],"names":[],"mappings":"AACA,OAAO,EACL,aAAa,EACb,uBAAuB,EACvB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EACxB,MAAM,aAAa,CAAC;AAGrB;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,WAAW,EACxB,iBAAiB,CAAC,EAAE,CAAC,MAAM,EAAE,kBAAkB,KAAK,IAAI,GACvD;IACD,MAAM,EAAE,aAAa,CAAC;IACtB,IAAI,EAAE,UAAU,CAAC,OAAO,uBAAuB,CAAC,CAAC;CAClD,CAKA"}
1
+ {"version":3,"file":"createSessionClient.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/createSessionClient.ts"],"names":[],"mappings":"AACA,OAAO,EACL,aAAa,EACb,uBAAuB,EACvB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EACxB,MAAM,aAAa,CAAC;AAGrB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,WAAW,EACxB,iBAAiB,CAAC,EAAE,CAAC,MAAM,EAAE,kBAAkB,KAAK,IAAI,EACxD,kBAAkB,CAAC,EAAE,MAAM,MAAM,GAAG,IAAI,GACvC;IACD,MAAM,EAAE,aAAa,CAAC;IACtB,IAAI,EAAE,UAAU,CAAC,OAAO,uBAAuB,CAAC,CAAC;CAClD,CAUA"}
@@ -0,0 +1,66 @@
1
+ /**
2
+ * Identity-bound sessions — the PLATFORM half of `sessionMode: 'identity'`.
3
+ *
4
+ * `@oxyhq/core` owns everything platform-agnostic about an identity-bound
5
+ * session: the pin store shapes, `resolveIdentityPin`,
6
+ * `establishIdentitySession`, and the pinned cold-boot / re-mint lanes. What it
7
+ * deliberately leaves out is WHICH pin store a given runtime should use, so this
8
+ * module supplies it — web `localStorage` vs the same native SecureStore adapter
9
+ * the device credential already persists through — and adds the one piece of
10
+ * state the provider needs on top: a memoised, SYNCHRONOUSLY readable pinned
11
+ * account id.
12
+ *
13
+ * Why the memo matters: `SessionClient.getPinnedAccountId` is a synchronous read
14
+ * on the socket/apply path, while resolving the pin is asynchronous (a storage
15
+ * read plus a keychain read, through `resolveIdentityPin`). The provider
16
+ * resolves it before the cold boot and after every (re-)established identity
17
+ * session; every read after that is free.
18
+ */
19
+ import { type IdentityBinding } from '@oxyhq/core';
20
+ /**
21
+ * The provider-scoped identity binding: the core {@link IdentityBinding} handed
22
+ * to the cold boot and the re-mint handler, plus the resolved pin the projection
23
+ * and `SessionClient` bind to.
24
+ */
25
+ export interface IdentitySessionBinding {
26
+ /** Handed to `runSessionColdBoot` and `installAuthRefreshHandler`. */
27
+ readonly binding: IdentityBinding;
28
+ /**
29
+ * The last resolved pinned account id, read synchronously. `null` until the
30
+ * first resolve lands, and after a resolve that found no usable pin.
31
+ */
32
+ getPinnedAccountId(): string | null;
33
+ /**
34
+ * Resolve the pin, reusing the memo once a pinned account is known.
35
+ * Concurrent callers share one in-flight resolve.
36
+ */
37
+ ensurePinnedAccountId(): Promise<string | null>;
38
+ /**
39
+ * Drop the memo and re-resolve. Used after a lane that may have rewritten or
40
+ * cleared the pin (the cold boot, or a re-established identity session).
41
+ */
42
+ refreshPinnedAccountId(): Promise<string | null>;
43
+ }
44
+ /**
45
+ * Thrown by every account-graph mutation while the provider runs in
46
+ * `sessionMode: 'identity'`.
47
+ *
48
+ * An identity-bound app's user is the owner of the local identity key — fixed,
49
+ * for the lifetime of that key. Switching it is not a temporarily-unavailable
50
+ * operation that could be retried, it is not part of this mode's contract at
51
+ * all, so the surfaces reject loudly rather than resolving to a no-op that would
52
+ * read to the caller as a successful switch.
53
+ */
54
+ export declare class IdentityBoundSessionError extends Error {
55
+ readonly operation: string;
56
+ readonly name = "IdentityBoundSessionError";
57
+ readonly code = "identity_bound_session";
58
+ constructor(operation: string);
59
+ }
60
+ /**
61
+ * Build the identity binding for this runtime. Called ONCE per provider mount,
62
+ * and ONLY when `sessionMode: 'identity'` — account-mode providers never
63
+ * construct a pin store.
64
+ */
65
+ export declare function createIdentitySessionBinding(): IdentitySessionBinding;
66
+ //# sourceMappingURL=identityBinding.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"identityBinding.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/identityBinding.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,OAAO,EAIL,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AAIrB;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACrC,sEAAsE;IACtE,QAAQ,CAAC,OAAO,EAAE,eAAe,CAAC;IAClC;;;OAGG;IACH,kBAAkB,IAAI,MAAM,GAAG,IAAI,CAAC;IACpC;;;OAGG;IACH,qBAAqB,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAChD;;;OAGG;IACH,sBAAsB,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;CAClD;AAED;;;;;;;;;GASG;AACH,qBAAa,yBAA0B,SAAQ,KAAK;IAGtC,QAAQ,CAAC,SAAS,EAAE,MAAM;IAFtC,SAAkB,IAAI,+BAA+B;IACrD,QAAQ,CAAC,IAAI,4BAA4B;gBACpB,SAAS,EAAE,MAAM;CAKvC;AAED;;;;GAIG;AACH,wBAAgB,4BAA4B,IAAI,sBAAsB,CAsCrE"}
@@ -4,12 +4,16 @@
4
4
  * `@oxyhq/core` owns the platform-agnostic `SessionClient`, its host adapter,
5
5
  * and the pure `DeviceSessionState → services` projection helpers; those are
6
6
  * re-exported straight from core here so `OxyContext` has one import site.
7
- * `@oxyhq/services` supplies only the two platform pieces: the thin
7
+ * `@oxyhq/services` supplies only the platform pieces: the thin
8
8
  * `createSessionClient` factory (injects socket.io-client `io` + the
9
- * device-first token transport) and the `AuthStateStore` factory.
9
+ * device-first token transport), the `AuthStateStore` factory, and — for
10
+ * `sessionMode: 'identity'` — the identity binding (platform pin store + the
11
+ * memoised pinned account id).
10
12
  */
11
13
  export { createSessionClient } from './createSessionClient';
12
14
  export { createTokenTransport } from './tokenTransport';
13
15
  export { createPlatformAuthStateStore } from './authStore';
16
+ export { createIdentitySessionBinding, IdentityBoundSessionError } from './identityBinding';
17
+ export type { IdentitySessionBinding } from './identityBinding';
14
18
  export { createSessionClientHost, accountIdsOf, activeSessionIdOf, activeUserOf, deviceStateToClientSessions, } from '@oxyhq/core';
15
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EAAE,4BAA4B,EAAE,MAAM,aAAa,CAAC;AAC3D,OAAO,EACL,uBAAuB,EACvB,YAAY,EACZ,iBAAiB,EACjB,YAAY,EACZ,2BAA2B,GAC5B,MAAM,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EAAE,4BAA4B,EAAE,MAAM,aAAa,CAAC;AAC3D,OAAO,EAAE,4BAA4B,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAC;AAC5F,YAAY,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAChE,OAAO,EACL,uBAAuB,EACvB,YAAY,EACZ,iBAAiB,EACjB,YAAY,EACZ,2BAA2B,GAC5B,MAAM,aAAa,CAAC"}
@@ -0,0 +1,25 @@
1
+ /**
2
+ * The native secure key/value seam every durable `@oxyhq/core` store in this
3
+ * package is built on.
4
+ *
5
+ * `@oxyhq/core` owns the store LOGIC (`createNativeAuthStateStore` for the
6
+ * zero-cookie device credential, `createNativeIdentityPinStore` for the identity
7
+ * pin) and takes its persistence as an injected `NativeKeyValueStorage`. This
8
+ * module supplies that injection ONCE, so those stores can never drift onto
9
+ * different backings — a device credential in SecureStore and a pin in
10
+ * AsyncStorage would resolve differently after a keystore reset.
11
+ *
12
+ * `expo-secure-store` is loaded via a runtime-computed dynamic import (the same
13
+ * optional-native-module pattern `OxyProvider` uses for netinfo / keyboard
14
+ * controller), so the web bundle never pulls it and a device without it falls
15
+ * back to AsyncStorage rather than crashing.
16
+ */
17
+ import type { NativeKeyValueStorage } from '@oxyhq/core';
18
+ /**
19
+ * A native `NativeKeyValueStorage` that prefers `expo-secure-store` (encrypted
20
+ * at rest) and falls back to AsyncStorage when SecureStore is not installed.
21
+ * The SecureStore module is resolved lazily on first access so construction
22
+ * stays synchronous.
23
+ */
24
+ export declare function createNativeSecureKeyValueStorage(): NativeKeyValueStorage;
25
+ //# sourceMappingURL=nativeSecureStorage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nativeSecureStorage.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/nativeSecureStorage.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,aAAa,CAAC;AA0CzD;;;;;GAKG;AACH,wBAAgB,iCAAiC,IAAI,qBAAqB,CAiCzE"}
@@ -21,6 +21,13 @@ import { type OxyServices, type TokenTransport } from '@oxyhq/core';
21
21
  *
22
22
  * A failure is logged and swallowed: this method must never throw out (it runs
23
23
  * inside the socket state handler).
24
+ *
25
+ * `getPinnedAccountId` is the identity-bound escape hatch. Converging the bearer
26
+ * on `state.activeAccountId` is precisely what an identity-bound client must
27
+ * never do — its token is minted for the PINNED account by the cold boot /
28
+ * re-mint lane. `SessionClient` already bypasses the transport entirely while
29
+ * pinned; this guard is the services-side half of that contract, so no future
30
+ * wiring can reintroduce the convergence from this end.
24
31
  */
25
- export declare function createTokenTransport(oxyServices: OxyServices): TokenTransport;
32
+ export declare function createTokenTransport(oxyServices: OxyServices, getPinnedAccountId?: () => string | null): TokenTransport;
26
33
  //# sourceMappingURL=tokenTransport.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tokenTransport.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/tokenTransport.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,KAAK,WAAW,EAAE,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAG5E;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,oBAAoB,CAAC,WAAW,EAAE,WAAW,GAAG,cAAc,CA8B7E"}
1
+ {"version":3,"file":"tokenTransport.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/tokenTransport.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,KAAK,WAAW,EAAE,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAG5E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,WAAW,EACxB,kBAAkB,CAAC,EAAE,MAAM,MAAM,GAAG,IAAI,GACvC,cAAc,CAiChB"}
@@ -1,6 +1,8 @@
1
1
  import type { ReactNode, RefObject } from 'react';
2
2
  import type { QueryClient } from '@tanstack/react-query';
3
3
  import type { RouteName } from '../navigation/routes';
4
+ import type { SessionMode } from '@oxyhq/core';
5
+ import type { WebAuthMode } from '../oauth/types';
4
6
  export interface StepController {
5
7
  canGoBack: () => boolean;
6
8
  goBack: () => void;
@@ -59,6 +61,48 @@ export interface OxyProviderProps {
59
61
  * so a local/staging deployment targets its own IdP instead of production.
60
62
  */
61
63
  authorizeBaseUrl?: string;
64
+ /**
65
+ * Who owns this app's session.
66
+ *
67
+ * - `'account'` (default) — the device's ACTIVE account. Every ordinary Oxy
68
+ * app: any app sharing the device's `DeviceSession` can switch the active
69
+ * account and this one follows, sign-in surfaces and the account switcher
70
+ * are available, and `accounts` lists the account graph.
71
+ * - `'identity'` — the owner of this device's PRIMARY identity key, for as
72
+ * long as that key exists. The provider pins its authenticated user AND
73
+ * its bearer to the account that key authenticates as, so an account
74
+ * switch made by any sibling app changes the shared device state but never
75
+ * this app's user or token. Built for the identity vault (Commons).
76
+ *
77
+ * In `'identity'` mode the account-graph surfaces are disabled at the source
78
+ * rather than hidden in the UI: `accounts` stays empty and is never fetched,
79
+ * `switchToAccount` / `switchSession` reject with `IdentityBoundSessionError`,
80
+ * `accountDialogController` is `null` and `openAccountDialog()` does nothing,
81
+ * and the two web OAuth cold-boot lanes (authorization-code return + silent
82
+ * cross-origin restore) are skipped — all of them commit whichever account
83
+ * the IdP resolves, which is not necessarily the local key's owner.
84
+ *
85
+ * Read once at mount, like `baseURL` / `oxyServices`: changing it on a
86
+ * mounted provider does not re-bind the session.
87
+ * @default 'account'
88
+ */
89
+ sessionMode?: SessionMode;
90
+ /**
91
+ * How a WEB third-party "Sign in with Oxy" hands the user to the IdP.
92
+ *
93
+ * - `'redirect'` (default) — a full-page navigation to `auth.oxy.so`, which
94
+ * returns to the registered `redirect_uri` with `?code=`. The tab unmounts
95
+ * and remounts, so route and unsaved state are lost.
96
+ * - `'popup'` — a small `auth.oxy.so` window opened from the user's click.
97
+ * The app stays MOUNTED and becomes authenticated without a reload; the
98
+ * IdP delivers only the authorization code + `state` back to the opener
99
+ * via `postMessage` (never a token, device secret, or PKCE verifier). A
100
+ * blocked popup falls back to the redirect automatically.
101
+ *
102
+ * Native is unaffected — it always uses an in-app auth session.
103
+ * @default 'redirect'
104
+ */
105
+ webAuthMode?: WebAuthMode;
62
106
  queryClient?: QueryClient;
63
107
  /** Sync device credentials to auth.oxy.so after interactive sign-in. @default true */
64
108
  hubSync?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../../../../src/ui/types/navigation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAItD,MAAM,WAAW,cAAc;IAC3B,SAAS,EAAE,MAAM,OAAO,CAAC;IACzB,MAAM,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,eAAe;IAE5B,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,SAAS,EAAE,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;IACxE,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,mFAAmF;IACnF,SAAS,CAAC,EAAE,MAAM,OAAO,CAAC;IAC1B,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,eAAe,CAAC,EAAE,CAA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1 @@
1
- {"version":3,"file":"crossOriginRestore.d.ts","sourceRoot":"","sources":["../../../../../src/ui/utils/crossOriginRestore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAsB/C,8EAA8E;AAC9E,wBAAgB,2BAA2B,IAAI,OAAO,CAOrD;AAED,iFAAiF;AACjF,wBAAgB,+BAA+B,IAAI,IAAI,CAKtD;AAED,qEAAqE;AACrE,wBAAgB,6BAA6B,IAAI,IAAI,CAMpD;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,6BAA6B,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAIrE;AAED,MAAM,WAAW,yBAAyB;IACxC,WAAW,EAAE,WAAW,CAAC;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED;;;GAGG;AACH,wBAAsB,4BAA4B,CAChD,IAAI,EAAE,yBAAyB,GAC9B,OAAO,CAAC,OAAO,CAAC,CAiDlB;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,IAAI,gBAAgB,GAAG,kBAAkB,GAAG,IAAI,CA8BtF"}
1
+ {"version":3,"file":"crossOriginRestore.d.ts","sourceRoot":"","sources":["../../../../../src/ui/utils/crossOriginRestore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAuB/C,8EAA8E;AAC9E,wBAAgB,2BAA2B,IAAI,OAAO,CAOrD;AAED,iFAAiF;AACjF,wBAAgB,+BAA+B,IAAI,IAAI,CAKtD;AAED,qEAAqE;AACrE,wBAAgB,6BAA6B,IAAI,IAAI,CAMpD;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,6BAA6B,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAIrE;AAED,MAAM,WAAW,yBAAyB;IACxC,WAAW,EAAE,WAAW,CAAC;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED;;;GAGG;AACH,wBAAsB,4BAA4B,CAChD,IAAI,EAAE,yBAAyB,GAC9B,OAAO,CAAC,OAAO,CAAC,CAgDlB;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,IAAI,gBAAgB,GAAG,kBAAkB,GAAG,IAAI,CA0BtF"}