@oxyhq/services 14.1.0 → 15.0.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 (262) hide show
  1. package/lib/commonjs/index.js +0 -17
  2. package/lib/commonjs/index.js.map +1 -1
  3. package/lib/commonjs/ui/components/SignInAccountChooser.js +189 -0
  4. package/lib/commonjs/ui/components/SignInAccountChooser.js.map +1 -0
  5. package/lib/commonjs/ui/components/SignInModal.js +350 -131
  6. package/lib/commonjs/ui/components/SignInModal.js.map +1 -1
  7. package/lib/commonjs/ui/context/OxyContext.js +340 -1547
  8. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  9. package/lib/commonjs/ui/context/hooks/useAuthOperations.js +61 -64
  10. package/lib/commonjs/ui/context/hooks/useAuthOperations.js.map +1 -1
  11. package/lib/commonjs/ui/hooks/useAuth.js +14 -33
  12. package/lib/commonjs/ui/hooks/useAuth.js.map +1 -1
  13. package/lib/commonjs/ui/hooks/usePasswordSignIn.js +170 -0
  14. package/lib/commonjs/ui/hooks/usePasswordSignIn.js.map +1 -0
  15. package/lib/commonjs/ui/hooks/useProfileEditing.js +2 -5
  16. package/lib/commonjs/ui/hooks/useProfileEditing.js.map +1 -1
  17. package/lib/commonjs/ui/hooks/useSessionManagement.js +2 -2
  18. package/lib/commonjs/ui/hooks/useSessionManagement.js.map +1 -1
  19. package/lib/commonjs/ui/navigation/routes.js +1 -0
  20. package/lib/commonjs/ui/navigation/routes.js.map +1 -1
  21. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js +93 -68
  22. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js.map +1 -1
  23. package/lib/commonjs/ui/screens/EditProfileScreen.js +187 -0
  24. package/lib/commonjs/ui/screens/EditProfileScreen.js.map +1 -0
  25. package/lib/commonjs/ui/screens/ManageAccountScreen.js +3 -7
  26. package/lib/commonjs/ui/screens/ManageAccountScreen.js.map +1 -1
  27. package/lib/commonjs/ui/screens/OxyAuthScreen.js +231 -95
  28. package/lib/commonjs/ui/screens/OxyAuthScreen.js.map +1 -1
  29. package/lib/commonjs/ui/screens/ProfileScreen.js +15 -2
  30. package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
  31. package/lib/commonjs/ui/screens/linkFormat.js +38 -0
  32. package/lib/commonjs/ui/screens/linkFormat.js.map +1 -0
  33. package/lib/commonjs/ui/session/authStore.js +146 -0
  34. package/lib/commonjs/ui/session/authStore.js.map +1 -0
  35. package/lib/commonjs/ui/session/createSessionClient.js +23 -17
  36. package/lib/commonjs/ui/session/createSessionClient.js.map +1 -1
  37. package/lib/commonjs/ui/session/index.js +13 -7
  38. package/lib/commonjs/ui/session/index.js.map +1 -1
  39. package/lib/commonjs/ui/session/tokenTransport.js +19 -31
  40. package/lib/commonjs/ui/session/tokenTransport.js.map +1 -1
  41. package/lib/commonjs/ui/utils/isWebBrowser.js +13 -0
  42. package/lib/commonjs/ui/utils/isWebBrowser.js.map +1 -0
  43. package/lib/commonjs/utils/deviceFlowSignIn.js +13 -16
  44. package/lib/commonjs/utils/deviceFlowSignIn.js.map +1 -1
  45. package/lib/module/index.js +0 -5
  46. package/lib/module/index.js.map +1 -1
  47. package/lib/module/ui/components/SignInAccountChooser.js +183 -0
  48. package/lib/module/ui/components/SignInAccountChooser.js.map +1 -0
  49. package/lib/module/ui/components/SignInModal.js +352 -134
  50. package/lib/module/ui/components/SignInModal.js.map +1 -1
  51. package/lib/module/ui/context/OxyContext.js +342 -1551
  52. package/lib/module/ui/context/OxyContext.js.map +1 -1
  53. package/lib/module/ui/context/hooks/useAuthOperations.js +60 -63
  54. package/lib/module/ui/context/hooks/useAuthOperations.js.map +1 -1
  55. package/lib/module/ui/hooks/useAuth.js +14 -33
  56. package/lib/module/ui/hooks/useAuth.js.map +1 -1
  57. package/lib/module/ui/hooks/usePasswordSignIn.js +165 -0
  58. package/lib/module/ui/hooks/usePasswordSignIn.js.map +1 -0
  59. package/lib/module/ui/hooks/useProfileEditing.js +2 -5
  60. package/lib/module/ui/hooks/useProfileEditing.js.map +1 -1
  61. package/lib/module/ui/hooks/useSessionManagement.js +1 -1
  62. package/lib/module/ui/hooks/useSessionManagement.js.map +1 -1
  63. package/lib/module/ui/navigation/routes.js +1 -0
  64. package/lib/module/ui/navigation/routes.js.map +1 -1
  65. package/lib/module/ui/screens/EditProfileFieldScreen.js +91 -66
  66. package/lib/module/ui/screens/EditProfileFieldScreen.js.map +1 -1
  67. package/lib/module/ui/screens/EditProfileScreen.js +182 -0
  68. package/lib/module/ui/screens/EditProfileScreen.js.map +1 -0
  69. package/lib/module/ui/screens/ManageAccountScreen.js +3 -7
  70. package/lib/module/ui/screens/ManageAccountScreen.js.map +1 -1
  71. package/lib/module/ui/screens/OxyAuthScreen.js +233 -97
  72. package/lib/module/ui/screens/OxyAuthScreen.js.map +1 -1
  73. package/lib/module/ui/screens/ProfileScreen.js +15 -2
  74. package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
  75. package/lib/module/ui/screens/linkFormat.js +31 -0
  76. package/lib/module/ui/screens/linkFormat.js.map +1 -0
  77. package/lib/module/ui/session/authStore.js +143 -0
  78. package/lib/module/ui/session/authStore.js.map +1 -0
  79. package/lib/module/ui/session/createSessionClient.js +22 -16
  80. package/lib/module/ui/session/createSessionClient.js.map +1 -1
  81. package/lib/module/ui/session/index.js +9 -9
  82. package/lib/module/ui/session/index.js.map +1 -1
  83. package/lib/module/ui/session/tokenTransport.js +20 -33
  84. package/lib/module/ui/session/tokenTransport.js.map +1 -1
  85. package/lib/module/ui/utils/isWebBrowser.js +11 -0
  86. package/lib/module/ui/utils/isWebBrowser.js.map +1 -0
  87. package/lib/module/utils/deviceFlowSignIn.js +14 -17
  88. package/lib/module/utils/deviceFlowSignIn.js.map +1 -1
  89. package/lib/typescript/commonjs/index.d.ts +0 -1
  90. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  91. package/lib/typescript/commonjs/ui/components/SignInAccountChooser.d.ts +29 -0
  92. package/lib/typescript/commonjs/ui/components/SignInAccountChooser.d.ts.map +1 -0
  93. package/lib/typescript/commonjs/ui/components/SignInModal.d.ts +15 -10
  94. package/lib/typescript/commonjs/ui/components/SignInModal.d.ts.map +1 -1
  95. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts +36 -42
  96. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
  97. package/lib/typescript/commonjs/ui/context/hooks/useAuthOperations.d.ts +18 -23
  98. package/lib/typescript/commonjs/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  99. package/lib/typescript/commonjs/ui/hooks/mutations/useAccountMutations.d.ts +0 -2
  100. package/lib/typescript/commonjs/ui/hooks/mutations/useAccountMutations.d.ts.map +1 -1
  101. package/lib/typescript/commonjs/ui/hooks/useAuth.d.ts.map +1 -1
  102. package/lib/typescript/commonjs/ui/hooks/usePasswordSignIn.d.ts +31 -0
  103. package/lib/typescript/commonjs/ui/hooks/usePasswordSignIn.d.ts.map +1 -0
  104. package/lib/typescript/commonjs/ui/hooks/useProfileEditing.d.ts +0 -1
  105. package/lib/typescript/commonjs/ui/hooks/useProfileEditing.d.ts.map +1 -1
  106. package/lib/typescript/commonjs/ui/navigation/routes.d.ts +1 -1
  107. package/lib/typescript/commonjs/ui/navigation/routes.d.ts.map +1 -1
  108. package/lib/typescript/commonjs/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  109. package/lib/typescript/commonjs/ui/screens/EditProfileScreen.d.ts +14 -0
  110. package/lib/typescript/commonjs/ui/screens/EditProfileScreen.d.ts.map +1 -0
  111. package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts +1 -1
  112. package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  113. package/lib/typescript/commonjs/ui/screens/OxyAuthScreen.d.ts +13 -12
  114. package/lib/typescript/commonjs/ui/screens/OxyAuthScreen.d.ts.map +1 -1
  115. package/lib/typescript/commonjs/ui/screens/ProfileScreen.d.ts.map +1 -1
  116. package/lib/typescript/commonjs/ui/screens/linkFormat.d.ts +23 -0
  117. package/lib/typescript/commonjs/ui/screens/linkFormat.d.ts.map +1 -0
  118. package/lib/typescript/commonjs/ui/session/authStore.d.ts +33 -0
  119. package/lib/typescript/commonjs/ui/session/authStore.d.ts.map +1 -0
  120. package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts +19 -15
  121. package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts.map +1 -1
  122. package/lib/typescript/commonjs/ui/session/index.d.ts +9 -9
  123. package/lib/typescript/commonjs/ui/session/index.d.ts.map +1 -1
  124. package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts +13 -19
  125. package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts.map +1 -1
  126. package/lib/typescript/commonjs/ui/utils/isWebBrowser.d.ts +9 -0
  127. package/lib/typescript/commonjs/ui/utils/isWebBrowser.d.ts.map +1 -0
  128. package/lib/typescript/commonjs/utils/deviceFlowSignIn.d.ts +15 -13
  129. package/lib/typescript/commonjs/utils/deviceFlowSignIn.d.ts.map +1 -1
  130. package/lib/typescript/module/index.d.ts +0 -1
  131. package/lib/typescript/module/index.d.ts.map +1 -1
  132. package/lib/typescript/module/ui/components/SignInAccountChooser.d.ts +29 -0
  133. package/lib/typescript/module/ui/components/SignInAccountChooser.d.ts.map +1 -0
  134. package/lib/typescript/module/ui/components/SignInModal.d.ts +15 -10
  135. package/lib/typescript/module/ui/components/SignInModal.d.ts.map +1 -1
  136. package/lib/typescript/module/ui/context/OxyContext.d.ts +36 -42
  137. package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
  138. package/lib/typescript/module/ui/context/hooks/useAuthOperations.d.ts +18 -23
  139. package/lib/typescript/module/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  140. package/lib/typescript/module/ui/hooks/mutations/useAccountMutations.d.ts +0 -2
  141. package/lib/typescript/module/ui/hooks/mutations/useAccountMutations.d.ts.map +1 -1
  142. package/lib/typescript/module/ui/hooks/useAuth.d.ts.map +1 -1
  143. package/lib/typescript/module/ui/hooks/usePasswordSignIn.d.ts +31 -0
  144. package/lib/typescript/module/ui/hooks/usePasswordSignIn.d.ts.map +1 -0
  145. package/lib/typescript/module/ui/hooks/useProfileEditing.d.ts +0 -1
  146. package/lib/typescript/module/ui/hooks/useProfileEditing.d.ts.map +1 -1
  147. package/lib/typescript/module/ui/navigation/routes.d.ts +1 -1
  148. package/lib/typescript/module/ui/navigation/routes.d.ts.map +1 -1
  149. package/lib/typescript/module/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  150. package/lib/typescript/module/ui/screens/EditProfileScreen.d.ts +14 -0
  151. package/lib/typescript/module/ui/screens/EditProfileScreen.d.ts.map +1 -0
  152. package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts +1 -1
  153. package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  154. package/lib/typescript/module/ui/screens/OxyAuthScreen.d.ts +13 -12
  155. package/lib/typescript/module/ui/screens/OxyAuthScreen.d.ts.map +1 -1
  156. package/lib/typescript/module/ui/screens/ProfileScreen.d.ts.map +1 -1
  157. package/lib/typescript/module/ui/screens/linkFormat.d.ts +23 -0
  158. package/lib/typescript/module/ui/screens/linkFormat.d.ts.map +1 -0
  159. package/lib/typescript/module/ui/session/authStore.d.ts +33 -0
  160. package/lib/typescript/module/ui/session/authStore.d.ts.map +1 -0
  161. package/lib/typescript/module/ui/session/createSessionClient.d.ts +19 -15
  162. package/lib/typescript/module/ui/session/createSessionClient.d.ts.map +1 -1
  163. package/lib/typescript/module/ui/session/index.d.ts +9 -9
  164. package/lib/typescript/module/ui/session/index.d.ts.map +1 -1
  165. package/lib/typescript/module/ui/session/tokenTransport.d.ts +13 -19
  166. package/lib/typescript/module/ui/session/tokenTransport.d.ts.map +1 -1
  167. package/lib/typescript/module/ui/utils/isWebBrowser.d.ts +9 -0
  168. package/lib/typescript/module/ui/utils/isWebBrowser.d.ts.map +1 -0
  169. package/lib/typescript/module/utils/deviceFlowSignIn.d.ts +15 -13
  170. package/lib/typescript/module/utils/deviceFlowSignIn.d.ts.map +1 -1
  171. package/package.json +4 -4
  172. package/src/index.ts +0 -4
  173. package/src/ui/components/SignInAccountChooser.tsx +162 -0
  174. package/src/ui/components/SignInModal.tsx +309 -139
  175. package/src/ui/context/OxyContext.tsx +532 -1785
  176. package/src/ui/context/hooks/useAuthOperations.ts +65 -76
  177. package/src/ui/hooks/useAuth.ts +14 -35
  178. package/src/ui/hooks/usePasswordSignIn.ts +207 -0
  179. package/src/ui/hooks/useProfileEditing.ts +2 -8
  180. package/src/ui/hooks/useSessionManagement.ts +1 -1
  181. package/src/ui/navigation/routes.ts +2 -0
  182. package/src/ui/screens/EditProfileFieldScreen.tsx +102 -66
  183. package/src/ui/screens/EditProfileScreen.tsx +155 -0
  184. package/src/ui/screens/ManageAccountScreen.tsx +3 -7
  185. package/src/ui/screens/OxyAuthScreen.tsx +259 -112
  186. package/src/ui/screens/ProfileScreen.tsx +15 -2
  187. package/src/ui/screens/__tests__/linkFormat.test.ts +73 -0
  188. package/src/ui/screens/linkFormat.ts +37 -0
  189. package/src/ui/session/__tests__/createSessionClient.test.ts +22 -7
  190. package/src/ui/session/__tests__/tokenTransport.test.ts +37 -49
  191. package/src/ui/session/authStore.ts +164 -0
  192. package/src/ui/session/createSessionClient.ts +30 -17
  193. package/src/ui/session/index.ts +10 -9
  194. package/src/ui/session/tokenTransport.ts +26 -36
  195. package/src/ui/utils/isWebBrowser.ts +8 -0
  196. package/src/utils/__tests__/deviceFlowSignIn.test.ts +50 -131
  197. package/src/utils/deviceFlowSignIn.ts +19 -26
  198. package/lib/commonjs/ui/context/inSessionTokenRefresh.js +0 -243
  199. package/lib/commonjs/ui/context/inSessionTokenRefresh.js.map +0 -1
  200. package/lib/commonjs/ui/context/silentSessionRestore.js +0 -56
  201. package/lib/commonjs/ui/context/silentSessionRestore.js.map +0 -1
  202. package/lib/commonjs/ui/hooks/useWebSSO.js +0 -28
  203. package/lib/commonjs/ui/hooks/useWebSSO.js.map +0 -1
  204. package/lib/commonjs/ui/session/projectSessionState.js +0 -86
  205. package/lib/commonjs/ui/session/projectSessionState.js.map +0 -1
  206. package/lib/commonjs/ui/session/sessionClientHost.js +0 -30
  207. package/lib/commonjs/ui/session/sessionClientHost.js.map +0 -1
  208. package/lib/commonjs/ui/utils/activeAuthuser.js +0 -142
  209. package/lib/commonjs/ui/utils/activeAuthuser.js.map +0 -1
  210. package/lib/commonjs/utils/crossApex.js +0 -74
  211. package/lib/commonjs/utils/crossApex.js.map +0 -1
  212. package/lib/module/ui/context/inSessionTokenRefresh.js +0 -238
  213. package/lib/module/ui/context/inSessionTokenRefresh.js.map +0 -1
  214. package/lib/module/ui/context/silentSessionRestore.js +0 -53
  215. package/lib/module/ui/context/silentSessionRestore.js.map +0 -1
  216. package/lib/module/ui/hooks/useWebSSO.js +0 -24
  217. package/lib/module/ui/hooks/useWebSSO.js.map +0 -1
  218. package/lib/module/ui/session/projectSessionState.js +0 -79
  219. package/lib/module/ui/session/projectSessionState.js.map +0 -1
  220. package/lib/module/ui/session/sessionClientHost.js +0 -26
  221. package/lib/module/ui/session/sessionClientHost.js.map +0 -1
  222. package/lib/module/ui/utils/activeAuthuser.js +0 -134
  223. package/lib/module/ui/utils/activeAuthuser.js.map +0 -1
  224. package/lib/module/utils/crossApex.js +0 -69
  225. package/lib/module/utils/crossApex.js.map +0 -1
  226. package/lib/typescript/commonjs/ui/context/inSessionTokenRefresh.d.ts +0 -106
  227. package/lib/typescript/commonjs/ui/context/inSessionTokenRefresh.d.ts.map +0 -1
  228. package/lib/typescript/commonjs/ui/context/silentSessionRestore.d.ts +0 -36
  229. package/lib/typescript/commonjs/ui/context/silentSessionRestore.d.ts.map +0 -1
  230. package/lib/typescript/commonjs/ui/hooks/useWebSSO.d.ts +0 -19
  231. package/lib/typescript/commonjs/ui/hooks/useWebSSO.d.ts.map +0 -1
  232. package/lib/typescript/commonjs/ui/session/projectSessionState.d.ts +0 -45
  233. package/lib/typescript/commonjs/ui/session/projectSessionState.d.ts.map +0 -1
  234. package/lib/typescript/commonjs/ui/session/sessionClientHost.d.ts +0 -14
  235. package/lib/typescript/commonjs/ui/session/sessionClientHost.d.ts.map +0 -1
  236. package/lib/typescript/commonjs/ui/utils/activeAuthuser.d.ts +0 -67
  237. package/lib/typescript/commonjs/ui/utils/activeAuthuser.d.ts.map +0 -1
  238. package/lib/typescript/commonjs/utils/crossApex.d.ts +0 -55
  239. package/lib/typescript/commonjs/utils/crossApex.d.ts.map +0 -1
  240. package/lib/typescript/module/ui/context/inSessionTokenRefresh.d.ts +0 -106
  241. package/lib/typescript/module/ui/context/inSessionTokenRefresh.d.ts.map +0 -1
  242. package/lib/typescript/module/ui/context/silentSessionRestore.d.ts +0 -36
  243. package/lib/typescript/module/ui/context/silentSessionRestore.d.ts.map +0 -1
  244. package/lib/typescript/module/ui/hooks/useWebSSO.d.ts +0 -19
  245. package/lib/typescript/module/ui/hooks/useWebSSO.d.ts.map +0 -1
  246. package/lib/typescript/module/ui/session/projectSessionState.d.ts +0 -45
  247. package/lib/typescript/module/ui/session/projectSessionState.d.ts.map +0 -1
  248. package/lib/typescript/module/ui/session/sessionClientHost.d.ts +0 -14
  249. package/lib/typescript/module/ui/session/sessionClientHost.d.ts.map +0 -1
  250. package/lib/typescript/module/ui/utils/activeAuthuser.d.ts +0 -67
  251. package/lib/typescript/module/ui/utils/activeAuthuser.d.ts.map +0 -1
  252. package/lib/typescript/module/utils/crossApex.d.ts +0 -55
  253. package/lib/typescript/module/utils/crossApex.d.ts.map +0 -1
  254. package/src/ui/context/inSessionTokenRefresh.ts +0 -264
  255. package/src/ui/context/silentSessionRestore.ts +0 -53
  256. package/src/ui/hooks/useWebSSO.ts +0 -23
  257. package/src/ui/session/__tests__/projectSessionState.test.ts +0 -114
  258. package/src/ui/session/__tests__/sessionClientHost.test.ts +0 -43
  259. package/src/ui/session/projectSessionState.ts +0 -85
  260. package/src/ui/session/sessionClientHost.ts +0 -27
  261. package/src/ui/utils/activeAuthuser.ts +0 -142
  262. package/src/utils/crossApex.ts +0 -75
@@ -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,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EACL,YAAY,EACZ,iBAAiB,EACjB,YAAY,EACZ,2BAA2B,GAC5B,MAAM,uBAAuB,CAAC"}
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,24 +1,18 @@
1
- import type { OxyServices, TokenTransport } from '@oxyhq/core';
1
+ import { type AuthStateStore, type OxyServices, type TokenTransport } from '@oxyhq/core';
2
2
  /**
3
- * Platform `TokenTransport` for `SessionClient`: mints an access token when
4
- * none is currently held, reusing the SAME primitives `OxyContext`'s cold
5
- * boot already relies on (never re-implemented here):
3
+ * Platform `TokenTransport` for `SessionClient` (device-first model).
6
4
  *
7
- * - web: `oxyServices.silentSignIn()` (per-apex `/auth/silent` iframe).
8
- * - native: `oxyServices.signInWithSharedIdentity()` (app-group keychain).
5
+ * `ensureActiveToken` is the fallback the client uses when a `session_state`
6
+ * push arrived WITHOUT an embedded `activeToken` and the app currently holds no
7
+ * bearer. It mints one through the ONE unified refresh path
8
+ * (`refreshPersistedSession`): rotate the persisted refresh-token family
9
+ * (`POST /auth/refresh-token`) and, on native, fall back to the shared-keychain
10
+ * re-mint. There is no FedCM/silent-iframe arm anymore — the per-origin
11
+ * persisted refresh token is the durable web credential.
9
12
  *
10
- * Both primitives plant the token internally on success (the "Sign-In Token
11
- * Planting" rule) `ensureActiveToken` never calls `setTokens` itself.
12
- *
13
- * `ensureActiveToken` treats a PRESENT token as sufficient in this phase; it
14
- * does not decode/match the token's subject against `state.activeAccountId`
15
- * (that refinement is Fase 3-B). Account switching itself is server-driven
16
- * via the `activeToken` carried in the sync envelope — this transport is
17
- * only the fallback used when the envelope carried no token.
18
- *
19
- * A failed mint is logged and swallowed: it must never throw out of
20
- * `ensureActiveToken`, since that would crash the caller (the SessionClient
21
- * socket handler in Fase 3-B).
13
+ * Concurrent pushes coalesce onto one in-flight mint. A failure is logged and
14
+ * swallowed: this method must never throw out (it runs inside the socket state
15
+ * handler).
22
16
  */
23
- export declare function createTokenTransport(oxyServices: OxyServices): TokenTransport;
17
+ export declare function createTokenTransport(oxyServices: OxyServices, store: AuthStateStore): TokenTransport;
24
18
  //# sourceMappingURL=tokenTransport.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tokenTransport.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/tokenTransport.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAI/D;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,oBAAoB,CAAC,WAAW,EAAE,WAAW,GAAG,cAAc,CAiD7E"}
1
+ {"version":3,"file":"tokenTransport.d.ts","sourceRoot":"","sources":["../../../../../src/ui/session/tokenTransport.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,cAAc,EACpB,MAAM,aAAa,CAAC;AAGrB;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,WAAW,EACxB,KAAK,EAAE,cAAc,GACpB,cAAc,CAsChB"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Web-browser detection for `@oxyhq/services`.
3
+ *
4
+ * The predicate now lives ONCE in `@oxyhq/core` (`isWebBrowser`) so services and
5
+ * auth-sdk share the exact same DOM probe. This module re-exposes it under the
6
+ * existing internal import path so consumers stay unchanged.
7
+ */
8
+ export { isWebBrowser } from '@oxyhq/core';
9
+ //# sourceMappingURL=isWebBrowser.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isWebBrowser.d.ts","sourceRoot":"","sources":["../../../../../src/ui/utils/isWebBrowser.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC"}
@@ -30,9 +30,14 @@
30
30
  * claim->commit sequence here keeps native and web identical and
31
31
  * unit-testable.
32
32
  */
33
- import { type EstablishAfterClaimDeps, type SessionLoginResponse, type SsoEstablishClient, type User } from '@oxyhq/core';
33
+ import { type SessionLoginResponse, type User } from '@oxyhq/core';
34
34
  interface DeviceFlowClaimResult {
35
35
  accessToken?: string;
36
+ /** Rotating refresh-token family head minted by `/auth/session/claim` on the
37
+ * trusted lane. Not on the core method's typed return, so read defensively;
38
+ * threaded into `commitSession` so the QR sign-in persists a durable session
39
+ * that survives a reload without a redirect. */
40
+ refreshToken?: string;
36
41
  sessionId?: string;
37
42
  deviceId?: string;
38
43
  expiresAt?: string;
@@ -44,10 +49,8 @@ interface DeviceFlowClaimResult {
44
49
  * trivially unit-testable with a stub and never pulls the RN/Expo runtime into
45
50
  * a test bundle.
46
51
  *
47
- * Extends {@link SsoEstablishClient} (`requestSsoEstablishUrl`) so the WEB
48
- * post-claim durable-session hop can be driven off the same client.
49
52
  */
50
- export interface DeviceFlowClient extends SsoEstablishClient {
53
+ export interface DeviceFlowClient {
51
54
  /**
52
55
  * Exchange the device-flow `sessionToken` for the first access + refresh
53
56
  * token, planting them on the client. Single-use; replay is rejected by the
@@ -71,15 +74,14 @@ export interface CompleteDeviceFlowSignInOptions {
71
74
  * registers the account into the device's server-authoritative session set,
72
75
  * persists it durably, and hydrates the full user profile. Runs AFTER the
73
76
  * bearer is planted so its bearer-protected calls succeed.
77
+ *
78
+ * The `refreshToken` extra (optional; not on the public `SessionLoginResponse`
79
+ * type) carries the rotating refresh family so the commit funnel persists a
80
+ * durable session.
74
81
  */
75
- commitSession: (session: SessionLoginResponse) => Promise<void>;
76
- /**
77
- * Injectable web seams for the post-claim durable-session establish hop
78
- * ({@link establishIdpSessionAfterClaim}). Omit in production — the defaults
79
- * resolve to `window.*` (and no-op off-web / on native). Tests inject fakes to
80
- * drive the web path deterministically.
81
- */
82
- establishDeps?: EstablishAfterClaimDeps;
82
+ commitSession: (session: SessionLoginResponse & {
83
+ refreshToken?: string;
84
+ }) => Promise<void>;
83
85
  }
84
86
  /**
85
87
  * Complete a device-flow sign-in: claim the first access token with the secret
@@ -90,6 +92,6 @@ export interface CompleteDeviceFlowSignInOptions {
90
92
  * Throws if the claim did not return a usable session, or if either the claim
91
93
  * or the commit fails; callers surface a retry UI.
92
94
  */
93
- export declare function completeDeviceFlowSignIn({ oxyServices, sessionId, sessionToken, commitSession, establishDeps, }: CompleteDeviceFlowSignInOptions): Promise<User>;
95
+ export declare function completeDeviceFlowSignIn({ oxyServices, sessionId, sessionToken, commitSession, }: CompleteDeviceFlowSignInOptions): Promise<User>;
94
96
  export {};
95
97
  //# sourceMappingURL=deviceFlowSignIn.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"deviceFlowSignIn.d.ts","sourceRoot":"","sources":["../../../../src/utils/deviceFlowSignIn.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,EAGL,KAAK,uBAAuB,EAE5B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,IAAI,EACV,MAAM,a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AE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,IAAI,CAAC;CACb;AAED;;;;;;GAMG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;;OAIG;IACH,mBAAmB,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,OAAO,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAAC;CAC3F;AAED,MAAM,WAAW,+BAA+B;IAC9C,6EAA6E;IAC7E,WAAW,EAAE,gBAAgB,CAAC;IAC9B,+EAA+E;IAC/E,SAAS,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB;;;;;;;;;;OAUG;IACH,aAAa,EAAE,CAAC,OAAO,EAAE,oBAAoB,GAAG;QAAE,YAAY,CAAC,EAAE,MAAM,CAAA;KAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7F;AAED;;;;;;;;GAQG;AACH,wBAAsB,wBAAwB,CAAC,EAC7C,WAAW,EACX,SAAS,EACT,YAAY,EACZ,aAAa,GACd,EAAE,+BAA+B,GAAG,OAAO,CAAC,IAAI,CAAC,CA4CjD"}
@@ -47,7 +47,6 @@ export type { MutationStatus } from './ui/hooks/useMutationStatus.js';
47
47
  export { useOnlineStatus } from './ui/hooks/useOnlineStatus.js';
48
48
  export { handleAuthError, isInvalidSessionError, isTimeoutOrNetworkError, extractErrorMessage, } from './ui/utils/errorHandlers.js';
49
49
  export type { HandleAuthErrorOptions } from './ui/utils/errorHandlers.js';
50
- export { CrossApexDirectSignInError, isCrossApexWeb } from './utils/crossApex.js';
51
50
  export { useFileFiltering } from './ui/hooks/useFileFiltering.js';
52
51
  export type { ViewMode, SortBy, SortOrder } from './ui/hooks/useFileFiltering.js';
53
52
  export { default as Avatar } from './ui/components/Avatar.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src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E,MAAM,qCAAkC,CAAC;AAClF,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,mCAAgC,CAAC;AAC9E,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,qCAAkC,CAAC;AAGlF,OAAO,EAAE,OAAO,IAAI,qBAAqB,EAAE,MAAM,uCAAoC,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,qCAAkC,CAAC;AAClF,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,sCAAmC,CAAC;AACpF,OAAO,EAAE,OAAO,IAAI,qBAAqB,EAAE,MAAM,uCAAoC,CAAC;AAKtF,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,uCAAoC,CAAC;AACvF,YAAY,EAAE,SAAS,EAAE,MAAM,2BAAwB,CAAC;AAKxD,OAAO,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,gCAA6B,CAAC"}
@@ -0,0 +1,29 @@
1
+ import type React from 'react';
2
+ import type { SwitchableAccount } from '../hooks/useSwitchableAccounts.js';
3
+ export interface SignInAccountChooserProps {
4
+ /** Accounts available on this device / in the caller's graph, current first. */
5
+ accounts: SwitchableAccount[];
6
+ /** Selecting a row — the active account continues, others switch into. */
7
+ onSelectAccount: (account: SwitchableAccount) => void;
8
+ /** "Use another account" → reveal the sign-in options (password / QR / add). */
9
+ onUseAnother: () => void;
10
+ /** The account id currently being switched into (shows a per-row spinner). */
11
+ pendingAccountId?: string | null;
12
+ /** Disables every row while a selection is in flight. */
13
+ disabled?: boolean;
14
+ }
15
+ /**
16
+ * Google-style account chooser (React Native). Lists every account the user can
17
+ * continue as — device sign-ins + linked graph accounts, from
18
+ * {@link SwitchableAccount} — plus a "Use another account" affordance. Rendered
19
+ * as the FRONT screen of the sign-in surfaces (`SignInModal` web,
20
+ * `OxyAuthScreen` native) whenever accounts exist; selecting a row funnels into
21
+ * the SAME `switchToAccount` path the account switcher uses. When no accounts
22
+ * exist the surfaces skip this and show the sign-in options directly.
23
+ *
24
+ * Presentational + chrome-agnostic (no modal/sheet wrapper, no data fetching) so
25
+ * both containers reuse it and it is unit-testable in isolation.
26
+ */
27
+ export declare const SignInAccountChooser: React.FC<SignInAccountChooserProps>;
28
+ export default SignInAccountChooser;
29
+ //# sourceMappingURL=SignInAccountChooser.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SignInAccountChooser.d.ts","sourceRoot":"","sources":["../../../../../src/ui/components/SignInAccountChooser.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mCAAgC,CAAC;AAExE,MAAM,WAAW,yBAAyB;IACtC,gFAAgF;IAChF,QAAQ,EAAE,iBAAiB,EAAE,CAAC;IAC9B,0EAA0E;IAC1E,eAAe,EAAE,CAAC,OAAO,EAAE,iBAAiB,KAAK,IAAI,CAAC;IACtD,gFAAgF;IAChF,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,8EAA8E;IAC9E,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,yDAAyD;IACzD,QAAQ,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,oBAAoB,EAAE,KAAK,CAAC,EAAE,CAAC,yBAAyB,CA4EpE,CAAC;AAoDF,eAAe,oBAAoB,CAAC"}
@@ -1,16 +1,21 @@
1
1
  /**
2
- * SignInModal - Web-first centered sign-in modal (Continue with Oxy)
2
+ * SignInModal web-first centered sign-in modal.
3
3
  *
4
- * A semi-transparent full-screen modal whose primary action is the one-tap
5
- * "Continue with Oxy" approval flow. The QR code is demoted to a collapsed
6
- * "Sign in on another device" disclosure (you can't scan your own screen).
4
+ * Two phases, Google-style:
5
+ * 1. Account chooser (FRONT screen, shown when the device/user already has
6
+ * accounts): pick an account to continue as one tap switches through the
7
+ * SAME `switchToAccount` path the account switcher uses — or "Use another
8
+ * account" to reveal the sign-in options.
9
+ * 2. Sign-in options: the first-party password flow (identifier → password →
10
+ * optional 2FA, `usePasswordSignIn`) as the PRIMARY action, with the
11
+ * cross-app device flow (same-device deep-link + "sign in on another device"
12
+ * QR) as a SECONDARY option below an "or" divider.
7
13
  *
8
- * ALL of the auth-session machinery (session-token creation, QR data, socket +
9
- * polling, waiting/error/retry state, the open-auth handler, deep-link return,
10
- * and cleanup) lives in the shared `useOxyAuthSession` hook, which the native
11
- * `OxyAuthScreen` also consumes neither container re-implements the transport.
12
- *
13
- * Animates with a fade + scale effect.
14
+ * When there are no accounts the modal opens straight on the sign-in options.
15
+ * The device-flow machinery lives in the shared `useOxyAuthSession` hook (the
16
+ * native `OxyAuthScreen` consumes it too neither container re-implements the
17
+ * transport). Animates with a fade + scale; per-phase content cross-fades and
18
+ * respects reduced motion.
14
19
  */
15
20
  import type React from 'react';
16
21
  export declare const showSignInModal: () => void;
@@ -1 +1 @@
1
- {"version":3,"file":"SignInModal.d.ts","sourceRoot":"","sources":["../../../../../src/ui/components/SignInModal.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAwB/B,eAAO,MAAM,eAAe,YAI3B,CAAC;AAEF,eAAO,MAAM,eAAe,YAI3B,CAAC;AAEF,eAAO,MAAM,oBAAoB,eAAqB,CAAC;AAEvD,4CAA4C;AAC5C,eAAO,MAAM,sBAAsB,GAAI,UAAU,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,KAAG,CAAC,MAAM,IAAI,CAGxF,CAAC;AAEF,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EA8BxB,CAAC;AA8QF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"SignInModal.d.ts","sourceRoot":"","sources":["../../../../../src/ui/components/SignInModal.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AA8B/B,eAAO,MAAM,eAAe,YAI3B,CAAC;AAEF,eAAO,MAAM,eAAe,YAI3B,CAAC;AAEF,eAAO,MAAM,oBAAoB,eAAqB,CAAC;AAEvD,4CAA4C;AAC5C,eAAO,MAAM,sBAAsB,GAAI,UAAU,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,KAAG,CAAC,MAAM,IAAI,CAGxF,CAAC;AAEF,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAkBxB,CAAC;AAybF,eAAe,WAAW,CAAC"}
@@ -1,9 +1,7 @@
1
1
  import type React from 'react';
2
2
  import { type ReactNode } from 'react';
3
3
  import { OxyServices } from '@oxyhq/core';
4
- import type { User, ApiError, SessionLoginResponse } from '@oxyhq/core';
5
- import type { AccountNode, CreateAccountInput } from '@oxyhq/core';
6
- import type { ClientSession } from '@oxyhq/core';
4
+ import type { User, ApiError, SessionLoginResponse, AccountNode, CreateAccountInput, ClientSession } from '@oxyhq/core';
7
5
  import type { UseFollowHook } from '../hooks/useFollow.types.js';
8
6
  import { useLanguageManagement } from '../hooks/useLanguageManagement.js';
9
7
  import type { RouteName } from '../navigation/routes.js';
@@ -20,16 +18,12 @@ export interface OxyContextState {
20
18
  /**
21
19
  * Whether the initial auth determination has concluded.
22
20
  *
23
- * `false` from mount until the FIRST cold-boot session restore finishes
21
+ * `false` from mount until the FIRST device-first cold boot resolves
24
22
  * during that window `isAuthenticated: false` is UNDETERMINED, not a
25
- * definitive "logged out". Flips to `true` exactly once the restore concludes
23
+ * definitive "logged out". Flips to `true` exactly once the boot concludes
26
24
  * (a session was committed OR none exists) and never reverts. Consumers should
27
25
  * defer their first auth-dependent fetch until this is `true` so a cold-boot
28
26
  * web reload with an existing session does not fetch anonymous data.
29
- *
30
- * On native, cold boot runs only the `stored-session` step, so this resolves
31
- * promptly. It is set in the restore `finally`, so the success, no-session,
32
- * and error paths all reach `true` — it can never get stuck `false`.
33
27
  */
34
28
  isAuthResolved: boolean;
35
29
  isStorageReady: boolean;
@@ -45,22 +39,31 @@ export interface OxyContextState {
45
39
  * Sign in with a username/email + password.
46
40
  *
47
41
  * Commits a successful session into context state through the SAME path the
48
- * SSO / silent-restore steps use (so `isAuthenticated` / `user` update and
49
- * the session is persisted durably). Returns a discriminated result so the
50
- * caller can branch on the
51
- * two-factor-required case which creates NO session; the caller completes
52
- * the 2FA challenge with the returned `loginToken`.
53
- *
54
- * This is the keyless native sign-in path for the slimmed Accounts app, which
55
- * no longer holds a local cryptographic identity key.
42
+ * QR device-flow and cold boot use (so `isAuthenticated` / `user` update and
43
+ * the rotating refresh family is persisted). Returns a discriminated result
44
+ * so the caller can branch on the two-factor-required case — which creates NO
45
+ * session; the caller completes the 2FA challenge with the returned
46
+ * `loginToken` via {@link OxyContextState.completeTwoFactorSignIn}.
56
47
  */
57
48
  signInWithPassword: (identifier: string, password: string, opts?: {
58
49
  deviceName?: string;
59
50
  deviceFingerprint?: string;
60
51
  }) => Promise<PasswordSignInResult>;
61
52
  /**
62
- * Handle a session returned by web SSO.
63
- * Updates auth state, persists session metadata to storage.
53
+ * Complete a 2FA-gated password sign-in started by {@link signInWithPassword}.
54
+ * Presents the short-lived `loginToken` with a TOTP `token` or a `backupCode`;
55
+ * on success the session is committed exactly like a one-step sign-in.
56
+ */
57
+ completeTwoFactorSignIn: (params: {
58
+ loginToken: string;
59
+ token?: string;
60
+ backupCode?: string;
61
+ deviceName?: string;
62
+ }) => Promise<void>;
63
+ /**
64
+ * Commit a session obtained out-of-band (the "Sign in with Oxy" QR device
65
+ * flow). Plants tokens, persists the rotating refresh family, registers the
66
+ * account into the device set, and hydrates the full user profile.
64
67
  */
65
68
  handleWebSession: (session: SessionLoginResponse) => Promise<void>;
66
69
  logout: (targetSessionId?: string) => Promise<void>;
@@ -86,10 +89,9 @@ export interface OxyContextState {
86
89
  * supplied via the `clientId` prop. Required for the cross-app device
87
90
  * sign-in flow: the sign-in components send it to
88
91
  * `POST /auth/session/create` so the API can identify the requesting app by
89
- * its real registered client id (the consent identity is then resolved
90
- * server-side and shown by the central auth web). `null` when the consuming
91
- * app did not configure a client id — the device sign-in flow surfaces a
92
- * configuration error in that case.
92
+ * its real registered client id. `null` when the consuming app did not
93
+ * configure a client id the device sign-in flow surfaces a configuration
94
+ * error in that case.
93
95
  */
94
96
  clientId: string | null;
95
97
  oxyServices: OxyServices;
@@ -102,36 +104,29 @@ export interface OxyContextState {
102
104
  /** Every account the caller can access — own personal root, owned, and shared — from `listAccounts()`. */
103
105
  accounts: AccountNode[];
104
106
  /**
105
- * Switch the active session INTO an account from the {@link accounts} graph
106
- * (a managed org/project/bot, or an account shared with the caller).
107
+ * Switch the active session INTO an account from the {@link accounts} graph.
107
108
  *
108
- * Uniform with every other account switch: if the account is already on
109
- * this device's multi-account set, switches straight through the same
109
+ * Uniform with every other account switch: if the account is already on this
110
+ * device's multi-account set, switches straight through the same
110
111
  * server-authoritative `SessionClient.switchAccount()` path {@link switchSession}
111
- * uses — no re-minting, no session churn. Only the FIRST switch into an
112
- * account mints+plants a REAL session via `oxyServices.switchToAccount` and
113
- * registers it into the device set (server-set httpOnly `oxy_rt_<authuser>`
114
- * cookie), so it survives reload / `refresh-all` and appears in the device
115
- * account list exactly like a device sign-in from then on. Either way,
116
- * afterwards `user` IS the target account, every request authenticates as
117
- * it, and the account graph + all React Query data are refreshed/invalidated.
112
+ * uses. Only the FIRST switch into an account mints+plants a real session via
113
+ * `oxyServices.switchToAccount` and registers it into the device set, so it
114
+ * survives reload and appears in the device account list exactly like a device
115
+ * sign-in from then on. Either way, afterwards `user` IS the target account.
118
116
  */
119
117
  switchToAccount: (accountId: string) => Promise<void>;
120
118
  refreshAccounts: () => Promise<void>;
121
119
  createAccount: (data: CreateAccountInput) => Promise<AccountNode>;
122
120
  }
123
- declare const OxyContext: React.Context<OxyContextState | null>;
124
121
  /**
125
122
  * Result of {@link OxyContextState.signInWithPassword}.
126
123
  *
127
- * `'ok'` — the password was accepted and the resulting session has been
128
- * committed into context state (the SAME path SSO / silent-restore sessions
129
- * use), so `isAuthenticated` / `user` are updated and the session is durably persisted;
130
- * the caller can proceed (e.g. navigate into the app).
124
+ * `'ok'` — the password was accepted and the session committed (so
125
+ * `isAuthenticated` / `user` are updated and the refresh family persisted).
131
126
  *
132
127
  * `'2fa_required'` — the account has two-factor auth enabled, so NO session was
133
- * created. The caller must complete the challenge with the returned short-lived
134
- * `loginToken` (`POST /security/2fa/verify-login`) before a session exists.
128
+ * created. Complete the challenge with the returned short-lived `loginToken`
129
+ * via {@link OxyContextState.completeTwoFactorSignIn}.
135
130
  */
136
131
  export type PasswordSignInResult = {
137
132
  status: 'ok';
@@ -157,5 +152,4 @@ export interface OxyContextProviderProps {
157
152
  export declare const OxyProvider: React.FC<OxyContextProviderProps>;
158
153
  export declare const OxyContextProvider: React.FC<OxyContextProviderProps>;
159
154
  export declare const useOxy: () => OxyContextState;
160
- export default OxyContext;
161
155
  //# sourceMappingURL=OxyContext.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"OxyContext.d.ts","sourceRoot":"","sources":["../../../../../src/ui/context/OxyContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EASL,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,WAAW,EAAa,MAAM,aAAa,CAAC;AACrD,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACxE,OAAO,KAAK,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEnE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAqBjD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA0B,CAAC;AAC9D,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAgC,CAAC;AAavE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAsB,CAAC;AAmBtD,MA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EAAE,SAAS,CAAC;IACpB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,KAAK,IAAI,CAAC;IAChD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,CAAC;CACrC;AA4FD,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA+1BzD,CAAC;AAEF,eAAO,MAAM,kBAAkB,mCAAc,CAAC;AA0D9C,eAAO,MAAM,MAAM,QAAO,eAMzB,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { ApiError, SessionClient, User } from '@oxyhq/core';
1
+ import type { ApiError, AuthStateStore, SessionClient, User } from '@oxyhq/core';
2
2
  import type { AuthState } from '../../stores/authStore.js';
3
3
  import type { ClientSession } from '@oxyhq/core';
4
4
  import type { StorageInterface } from '../../utils/storageHelpers.js';
@@ -6,6 +6,15 @@ import type { OxyServices } from '@oxyhq/core';
6
6
  export interface UseAuthOperationsOptions {
7
7
  oxyServices: OxyServices;
8
8
  storage: StorageInterface | null;
9
+ /**
10
+ * The device-first persisted auth-state store. On EXPLICIT full sign-out the
11
+ * session blob is cleared (`store.clear()`) so a reload's cold boot finds no
12
+ * refresh family to restore; on sign-in a returned rotating refresh token is
13
+ * persisted so the next boot warm-restores without a redirect. The long-lived
14
+ * device token SURVIVES sign-out (the device is unchanged), so it is never
15
+ * cleared here.
16
+ */
17
+ store: AuthStateStore;
9
18
  activeSessionId: string | null;
10
19
  setActiveSessionId: (sessionId: string | null) => void;
11
20
  updateSessions: (sessions: ClientSession[], options?: {
@@ -13,14 +22,6 @@ export interface UseAuthOperationsOptions {
13
22
  }) => void;
14
23
  saveActiveSessionId: (sessionId: string) => Promise<void>;
15
24
  clearSessionState: () => Promise<void>;
16
- /**
17
- * Clear the durable returning-user hint (`storageKeys.priorSession`). Called
18
- * ONLY on EXPLICIT full sign-out — alongside `clearSsoBounceState()` — so the
19
- * next cold boot treats this device as a first-time anonymous visitor (no
20
- * forced `/sso` bounce). NEVER called on the passive token-expiry path, so an
21
- * expired session still recovers via a returning-user bounce. Best-effort.
22
- */
23
- clearPriorSessionHint: () => Promise<void>;
24
25
  /** Used only by `performSignIn`'s same-user duplicate-session dedup (legacy session-validate path; unrelated to the SessionClient device-account set). */
25
26
  switchSession: (sessionId: string) => Promise<User>;
26
27
  /**
@@ -50,23 +51,17 @@ export interface UseAuthOperationsResult {
50
51
  logoutAll: () => Promise<void>;
51
52
  }
52
53
  /**
53
- * Fire-and-forget the durable returning-user hint clear on explicit sign-out.
54
- *
55
- * Mirrors the synchronous, non-blocking nature of the sibling
56
- * `clearSsoBounceState()`: sign-out must NEVER block on (or fail because of) a
57
- * best-effort storage write. The clear is invoked synchronously (so unit tests
58
- * can assert it ran) but its async settle is detached; any rejection is logged,
59
- * never thrown.
60
- *
61
- * Exported so `OxyContext`'s `syncFromClient` zero-account branch (a REMOTE
62
- * full sign-out) can invoke the EXACT same cleanup as the LOCAL `logout` /
63
- * `logoutAll` paths below — a remote sign-out must be indistinguishable from
64
- * a local one to the next cold boot.
54
+ * Clear the persisted refresh-token family on an explicit full sign-out.
55
+ * Best-effort and non-blocking: sign-out must never fail because a storage
56
+ * write threw. Exported so `OxyContext`'s zero-account branch (a REMOTE full
57
+ * sign-out pushed over the socket) runs the EXACT same cleanup as the local
58
+ * `logout` / `logoutAll` paths a remote sign-out is indistinguishable from a
59
+ * local one to the next cold boot.
65
60
  */
66
- export declare function clearPriorSessionHintSafe(clearPriorSessionHint: () => Promise<void>, logger?: (message: string, error?: unknown) => void): void;
61
+ export declare function clearPersistedAuthSafe(store: AuthStateStore, logger?: (message: string, error?: unknown) => void): void;
67
62
  /**
68
63
  * Authentication operations using public key cryptography.
69
64
  * Accepts public key as parameter - identity management is handled by the app layer.
70
65
  */
71
- export declare const useAuthOperations: ({ oxyServices, activeSessionId, setActiveSessionId, updateSessions, saveActiveSessionId, clearSessionState, clearPriorSessionHint, switchSession, sessionClient, syncFromClient, applyLanguagePreference, onAuthStateChange, onError, loginSuccess, loginFailure, logoutStore, setAuthState, logger, }: UseAuthOperationsOptions) => UseAuthOperationsResult;
66
+ export declare const useAuthOperations: ({ oxyServices, store, activeSessionId, setActiveSessionId, updateSessions, saveActiveSessionId, clearSessionState, switchSession, sessionClient, syncFromClient, applyLanguagePreference, onAuthStateChange, onError, loginSuccess, loginFailure, logoutStore, setAuthState, logger, }: UseAuthOperationsOptions) => UseAuthOperationsResult;
72
67
  //# sourceMappingURL=useAuthOperations.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useAuthOperations.d.ts","sourceRoot":"","sources":["../../../../../../src/ui/context/hooks/useAuthOperations.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,aAAa,EAAwB,MAAM,aAAa,CAAC;AAIvE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+BAA4B,CAAC;AACnE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAU/C,MAAM,WAAW,wBAAwB;IACvC,WAAW,EAAE,WAAW,CAAC;IACzB,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IACjC,eAAe,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,kBAAkB,EAAE,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;IACvD,cAAc,EAAE,CAAC,QAAQ,EAAE,aA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,SAAS,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAChC;AAMD;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,cAAc,EACrB,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,OAAO,KAAK,IAAI,GAClD,IAAI,CAIN;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,GAAI,wRAmB/B,wBAAwB,KAAG,uBAsR7B,CAAC"}
@@ -22,7 +22,6 @@ export declare const useUpdateProfile: () => import("@tanstack/react-query").Use
22
22
  phone: import("zod").ZodOptional<import("zod").ZodString>;
23
23
  address: import("zod").ZodOptional<import("zod").ZodString>;
24
24
  birthday: import("zod").ZodOptional<import("zod").ZodString>;
25
- location: import("zod").ZodOptional<import("zod").ZodString>;
26
25
  locations: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodUnknown, "many">>;
27
26
  links: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
28
27
  linksMetadata: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
@@ -171,7 +170,6 @@ export declare const useUpdateAccountSettings: () => {
171
170
  phone?: string;
172
171
  address?: string;
173
172
  birthday?: string;
174
- location?: string;
175
173
  website?: string;
176
174
  createdAt?: string;
177
175
  updatedAt?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"useAccountMutations.d.ts","sourceRoot":"","sources":["../../../../../../src/ui/hooks/mutations/useAccountMutations.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,gBAAgB,EAChB,uBAAuB,EACvB,eAAe,EACf,IAAI,EACJ,eAAe,EAChB,MAAM,aAAa,CAAC;AAerB;;GAEG;AACH,eAAO,MAAM,gBAAgB;;;;;aA+PrB,CAAN;YAGa,CAAC;;aAEO,CAAA;YACd,CAAC;;;;;;;;;;;;;;;;;;;;;;UAgBE,CAAH;mBAIH,CAAF;aAAmC,CAAC;aAAmC,CAAC;;;U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AAE,MAAM,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACnC,QAAQ,CAAC,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC,CAAC;CACxI;AAED,4EAA4E;AAC5E,UAAU,YAAY;IACpB,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,KAAK,CAAC,EAAE,YAAY,EAAE,CAAC;IACvB,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAED;;;;GAIG;AACH,eAAO,MAAM,gCAAgC;;EAmD5C,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,wBAAwB;;EA+CpC,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB,uFAoBlC,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,aAAa;UAWd,gBAAgB;iBACT,SAAS,GAAG,QAAQ,GAAG,UAAU;eACnC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;iBACrB,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI;WAS5C,CAAC"}
1
+ {"version":3,"file":"useAccountMutations.d.ts","sourceRoot":"","sources":["../../../../../../src/ui/hooks/mutations/useAccountMutations.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,gBAAgB,EAChB,uBAAuB,EACvB,eAAe,EACf,I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C;;OAEG;IACH,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAC9B;AAED,MAAM,WAAW,aAAc,SAAQ,SAAS,EAAE,WAAW;IAC3D,6DAA6D;IAC7D,WAAW,EAAE,UAAU,CAAC,OAAO,MAAM,CAAC,CAAC,aAAa,CAAC,CAAC;IACtD,0EAA0E;IAC1E,eAAe,EAAE,UAAU,CAAC,OAAO,MAAM,CAAC,CAAC,iBAAiB,CAAC,CAAC;IAC9D,0CAA0C;IAC1C,gBAAgB,EAAE,UAAU,CAAC,OAAO,MAAM,CAAC,CAAC,kBAAkB,CAAC,CAAC;CACjE;AAED;;;;;;;;GAQG;AACH,wBAAgB,OAAO,IAAI,aAAa,CA8FvC"}
@@ -0,0 +1,31 @@
1
+ export type PasswordSignInStep = 'identifier' | 'password' | 'twoFactor';
2
+ export interface UsePasswordSignInOptions {
3
+ /** Fired once a session has been committed (the surface should close). */
4
+ onSignedIn?: () => void;
5
+ }
6
+ export interface UsePasswordSignInResult {
7
+ step: PasswordSignInStep;
8
+ identifier: string;
9
+ setIdentifier: (value: string) => void;
10
+ password: string;
11
+ setPassword: (value: string) => void;
12
+ /** The current 2FA input — a TOTP code or a backup code, per `useBackupCode`. */
13
+ code: string;
14
+ setCode: (value: string) => void;
15
+ useBackupCode: boolean;
16
+ setUseBackupCode: (value: boolean) => void;
17
+ error: string | null;
18
+ isSubmitting: boolean;
19
+ /** Advance identifier → password (validates a non-empty identifier). */
20
+ submitIdentifier: () => void;
21
+ /** Submit the password: commits a one-step session, or advances to 2FA. */
22
+ submitPassword: () => Promise<void>;
23
+ /** Submit the 2FA code / backup code and commit the session. */
24
+ submitTwoFactor: () => Promise<void>;
25
+ /** Step back one screen (2FA → password → identifier), clearing the error. */
26
+ back: () => void;
27
+ /** Reset every field back to the identifier step. */
28
+ reset: () => void;
29
+ }
30
+ export declare function usePasswordSignIn(options?: UsePasswordSignInOptions): UsePasswordSignInResult;
31
+ //# sourceMappingURL=usePasswordSignIn.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usePasswordSignIn.d.ts","sourceRoot":"","sources":["../../../../../src/ui/hooks/usePasswordSignIn.ts"],"names":[],"mappings":"AAkBA,MAAM,MAAM,kBAAkB,GAAG,YAAY,GAAG,UAAU,GAAG,WAAW,CAAC;AAEzE,MAAM,WAAW,wBAAwB;IACvC,0EAA0E;IAC1E,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;CACzB;AAED,MAAM,WAAW,uBAAuB;IACtC,IAAI,EAAE,kBAAkB,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,iFAAiF;IACjF,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACjC,aAAa,EAAE,OAAO,CAAC;IACvB,gBAAgB,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IAC3C,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,YAAY,EAAE,OAAO,CAAC;IACtB,wEAAwE;IACxE,gBAAgB,EAAE,MAAM,IAAI,CAAC;IAC7B,2EAA2E;IAC3E,cAAc,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IACpC,gEAAgE;IAChE,eAAe,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IACrC,8EAA8E;IAC9E,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,qDAAqD;IACrD,KAAK,EAAE,MAAM,IAAI,CAAC;CACnB;AAED,wBAAgB,iBAAiB,CAAC,OAAO,GAAE,wBAA6B,GAAG,uBAAuB,CA4JjG"}
@@ -20,7 +20,6 @@ export interface ProfileUpdateData {
20
20
  username?: string;
21
21
  email?: string;
22
22
  bio?: string;
23
- location?: string;
24
23
  locations?: ProfileLocation[];
25
24
  links?: string[];
26
25
  linksMetadata?: ProfileLinkMetadata[];
@@ -1 +1 @@
1
- {"version":3,"file":"useProfileEditing.d.ts","sourceRoot":"","sources":["../../../../../src/ui/hooks/useProfileEditing.ts"],"names":[],"mappings":"AAKA,UAAU,eAAe;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;CAC9C;AAED,UAAU,mBAAmB;IACzB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,EAAE,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,iBAAiB;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,eAAe,EAAE,CAAC;IAC9B,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,aAAa,CAAC,EAAE,mBAAmB,EAAE,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,KAAK,iBAAiB,GAAG,MAAM,GAAG,eAAe,EAAE,GAAG,mBAAmB,EAAE,CAAC;AAU5E;;;GAGG;AACH,eAA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AqDjF,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import type { ComponentType, ReactNode } from 'react';
2
2
  import type { BaseScreenProps } from '../types/navigation.js';
3
- export type RouteName = 'OxyAuth' | 'ManageAccount' | 'AccountVerification' | 'PaymentGateway' | 'Profile' | 'LanguageSelector' | 'PrivacySettings' | 'SearchSettings' | 'FileManagement' | 'HelpSupport' | 'FAQ' | 'Feedback' | 'LegalDocuments' | 'AppInfo' | 'PremiumSubscription' | 'WelcomeNewUser' | 'UserLinks' | 'HistoryView' | 'SavesCollections' | 'EditProfileField' | 'LearnMoreUsernames' | 'TrustCenter' | 'TrustLeaderboard' | 'TrustRewards' | 'TrustRules' | 'AboutTrust' | 'TrustFAQ' | 'FollowersList' | 'FollowingList' | 'AccountSwitcher' | 'CreateAccount' | 'AccountMembers' | 'AccountSettings' | 'AvatarCrop' | 'Notifications' | 'ConnectedApps' | 'Preferences';
3
+ export type RouteName = 'OxyAuth' | 'ManageAccount' | 'AccountVerification' | 'PaymentGateway' | 'Profile' | 'LanguageSelector' | 'PrivacySettings' | 'SearchSettings' | 'FileManagement' | 'HelpSupport' | 'FAQ' | 'Feedback' | 'LegalDocuments' | 'AppInfo' | 'PremiumSubscription' | 'WelcomeNewUser' | 'UserLinks' | 'HistoryView' | 'SavesCollections' | 'EditProfile' | 'EditProfileField' | 'LearnMoreUsernames' | 'TrustCenter' | 'TrustLeaderboard' | 'TrustRewards' | 'TrustRules' | 'AboutTrust' | 'TrustFAQ' | 'FollowersList' | 'FollowingList' | 'AccountSwitcher' | 'CreateAccount' | 'AccountMembers' | 'AccountSettings' | 'AvatarCrop' | 'Notifications' | 'ConnectedApps' | 'Preferences';
4
4
  export declare const getScreenComponent: (routeName: RouteName) => ComponentType<BaseScreenProps> | undefined;
5
5
  export declare const isValidRoute: (routeName: string) => routeName is RouteName;
6
6
  /**