@oxy.so/services 4.0.6 → 6.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 (352) hide show
  1. package/README.md +1 -1
  2. package/lib/commonjs/assets/assets/signIn/slide-1.jpg +0 -0
  3. package/lib/commonjs/assets/assets/signIn/slide-1.jpg.d.ts +3 -0
  4. package/lib/commonjs/assets/assets/signIn/slide-2.jpg +0 -0
  5. package/lib/commonjs/assets/assets/signIn/slide-2.jpg.d.ts +3 -0
  6. package/lib/commonjs/assets/assets/signIn/slide-3.jpg +0 -0
  7. package/lib/commonjs/assets/assets/signIn/slide-3.jpg.d.ts +3 -0
  8. package/lib/commonjs/assets/assets/signIn/slide-4.jpg +0 -0
  9. package/lib/commonjs/assets/assets/signIn/slide-4.jpg.d.ts +3 -0
  10. package/lib/commonjs/assets/signIn/slide-1.jpg +0 -0
  11. package/lib/commonjs/assets/signIn/slide-2.jpg +0 -0
  12. package/lib/commonjs/assets/signIn/slide-3.jpg +0 -0
  13. package/lib/commonjs/assets/signIn/slide-4.jpg +0 -0
  14. package/lib/commonjs/index.js +45 -8
  15. package/lib/commonjs/index.js.map +1 -1
  16. package/lib/commonjs/ui/components/FollowButton.js +26 -1
  17. package/lib/commonjs/ui/components/FollowButton.js.map +1 -1
  18. package/lib/commonjs/ui/components/FollowTargetButton.js +6 -1
  19. package/lib/commonjs/ui/components/FollowTargetButton.js.map +1 -1
  20. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js +11 -58
  21. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js.map +1 -1
  22. package/lib/commonjs/ui/components/OxyAuthChooser.js +36 -44
  23. package/lib/commonjs/ui/components/OxyAuthChooser.js.map +1 -1
  24. package/lib/commonjs/ui/components/OxyProvider.js +0 -2
  25. package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
  26. package/lib/commonjs/ui/components/ProfileButton.js.map +1 -1
  27. package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js +29 -8
  28. package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js.map +1 -1
  29. package/lib/commonjs/ui/components/authChooser/primitives.js +7 -52
  30. package/lib/commonjs/ui/components/authChooser/primitives.js.map +1 -1
  31. package/lib/commonjs/ui/components/authChooser/signInFailureMessage.js +1 -7
  32. package/lib/commonjs/ui/components/authChooser/signInFailureMessage.js.map +1 -1
  33. package/lib/commonjs/ui/components/authChooser/styles.js +0 -31
  34. package/lib/commonjs/ui/components/authChooser/styles.js.map +1 -1
  35. package/lib/commonjs/ui/components/authChooser/types.js +2 -2
  36. package/lib/commonjs/ui/components/followButtonAccessibility.js +72 -0
  37. package/lib/commonjs/ui/components/followButtonAccessibility.js.map +1 -0
  38. package/lib/commonjs/ui/components/oauthNavigation.js +1 -1
  39. package/lib/commonjs/ui/components/signIn/InlineCommonsQr.js +161 -0
  40. package/lib/commonjs/ui/components/signIn/InlineCommonsQr.js.map +1 -0
  41. package/lib/commonjs/ui/components/signIn/OxyAccountPicker.js +111 -0
  42. package/lib/commonjs/ui/components/signIn/OxyAccountPicker.js.map +1 -0
  43. package/lib/commonjs/ui/components/signIn/OxyAuthScreen.js +160 -0
  44. package/lib/commonjs/ui/components/signIn/OxyAuthScreen.js.map +1 -0
  45. package/lib/commonjs/ui/components/signIn/OxySignInPanel.js +371 -0
  46. package/lib/commonjs/ui/components/signIn/OxySignInPanel.js.map +1 -0
  47. package/lib/commonjs/ui/components/signIn/OxySignUpPanel.js +78 -0
  48. package/lib/commonjs/ui/components/signIn/OxySignUpPanel.js.map +1 -0
  49. package/lib/commonjs/ui/components/signIn/artwork.js +21 -0
  50. package/lib/commonjs/ui/components/signIn/artwork.js.map +1 -0
  51. package/lib/commonjs/ui/components/signIn/passkeyError.js +46 -0
  52. package/lib/commonjs/ui/components/signIn/passkeyError.js.map +1 -0
  53. package/lib/commonjs/ui/components/signIn/signInMethods.js +46 -0
  54. package/lib/commonjs/ui/components/signIn/signInMethods.js.map +1 -0
  55. package/lib/commonjs/ui/context/OxyContext.js +16 -16
  56. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  57. package/lib/commonjs/ui/context/commitSessionFlow.js +0 -43
  58. package/lib/commonjs/ui/context/commitSessionFlow.js.map +1 -1
  59. package/lib/commonjs/ui/hooks/accountDialogSnapshot.js +15 -1
  60. package/lib/commonjs/ui/hooks/accountDialogSnapshot.js.map +1 -1
  61. package/lib/commonjs/ui/hooks/useDeviceSwitcher.js +1 -3
  62. package/lib/commonjs/ui/hooks/useDeviceSwitcher.js.map +1 -1
  63. package/lib/commonjs/ui/oauth/browserAuthTransport.js +11 -4
  64. package/lib/commonjs/ui/oauth/browserAuthTransport.js.map +1 -1
  65. package/lib/commonjs/ui/oauth/oauthHandshake.js +3 -0
  66. package/lib/commonjs/ui/oauth/oauthHandshake.js.map +1 -1
  67. package/lib/commonjs/ui/oauth/oauthPopup.js +2 -3
  68. package/lib/commonjs/ui/oauth/oauthPopup.js.map +1 -1
  69. package/lib/commonjs/ui/screens/ManageAccountScreen.js +2 -3
  70. package/lib/commonjs/ui/screens/ManageAccountScreen.js.map +1 -1
  71. package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js +1 -1
  72. package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
  73. package/lib/commonjs/ui/session/authStore.js +0 -21
  74. package/lib/commonjs/ui/session/authStore.js.map +1 -1
  75. package/lib/commonjs/ui/utils/accountDeletionHandoff.js +1 -1
  76. package/lib/commonjs/ui/utils/accountDeletionHandoff.js.map +1 -1
  77. package/lib/module/assets/assets/signIn/slide-1.jpg +0 -0
  78. package/lib/module/assets/assets/signIn/slide-1.jpg.d.ts +3 -0
  79. package/lib/module/assets/assets/signIn/slide-2.jpg +0 -0
  80. package/lib/module/assets/assets/signIn/slide-2.jpg.d.ts +3 -0
  81. package/lib/module/assets/assets/signIn/slide-3.jpg +0 -0
  82. package/lib/module/assets/assets/signIn/slide-3.jpg.d.ts +3 -0
  83. package/lib/module/assets/assets/signIn/slide-4.jpg +0 -0
  84. package/lib/module/assets/assets/signIn/slide-4.jpg.d.ts +3 -0
  85. package/lib/module/assets/signIn/slide-1.jpg +0 -0
  86. package/lib/module/assets/signIn/slide-2.jpg +0 -0
  87. package/lib/module/assets/signIn/slide-3.jpg +0 -0
  88. package/lib/module/assets/signIn/slide-4.jpg +0 -0
  89. package/lib/module/index.js +7 -6
  90. package/lib/module/index.js.map +1 -1
  91. package/lib/module/ui/components/FollowButton.js +26 -1
  92. package/lib/module/ui/components/FollowButton.js.map +1 -1
  93. package/lib/module/ui/components/FollowTargetButton.js +6 -1
  94. package/lib/module/ui/components/FollowTargetButton.js.map +1 -1
  95. package/lib/module/ui/components/OxyAccountDialogScreen.js +14 -59
  96. package/lib/module/ui/components/OxyAccountDialogScreen.js.map +1 -1
  97. package/lib/module/ui/components/OxyAuthChooser.js +37 -45
  98. package/lib/module/ui/components/OxyAuthChooser.js.map +1 -1
  99. package/lib/module/ui/components/OxyProvider.js +0 -2
  100. package/lib/module/ui/components/OxyProvider.js.map +1 -1
  101. package/lib/module/ui/components/ProfileButton.js.map +1 -1
  102. package/lib/module/ui/components/authChooser/AccountsMenuView.js +21 -2
  103. package/lib/module/ui/components/authChooser/AccountsMenuView.js.map +1 -1
  104. package/lib/module/ui/components/authChooser/primitives.js +1 -44
  105. package/lib/module/ui/components/authChooser/primitives.js.map +1 -1
  106. package/lib/module/ui/components/authChooser/signInFailureMessage.js +1 -7
  107. package/lib/module/ui/components/authChooser/signInFailureMessage.js.map +1 -1
  108. package/lib/module/ui/components/authChooser/styles.js +0 -31
  109. package/lib/module/ui/components/authChooser/styles.js.map +1 -1
  110. package/lib/module/ui/components/authChooser/types.js +2 -2
  111. package/lib/module/ui/components/followButtonAccessibility.js +66 -0
  112. package/lib/module/ui/components/followButtonAccessibility.js.map +1 -0
  113. package/lib/module/ui/components/oauthNavigation.js +1 -1
  114. package/lib/module/ui/components/signIn/InlineCommonsQr.js +157 -0
  115. package/lib/module/ui/components/signIn/InlineCommonsQr.js.map +1 -0
  116. package/lib/module/ui/components/signIn/OxyAccountPicker.js +106 -0
  117. package/lib/module/ui/components/signIn/OxyAccountPicker.js.map +1 -0
  118. package/lib/module/ui/components/signIn/OxyAuthScreen.js +151 -0
  119. package/lib/module/ui/components/signIn/OxyAuthScreen.js.map +1 -0
  120. package/lib/module/ui/components/signIn/OxySignInPanel.js +366 -0
  121. package/lib/module/ui/components/signIn/OxySignInPanel.js.map +1 -0
  122. package/lib/module/ui/components/signIn/OxySignUpPanel.js +75 -0
  123. package/lib/module/ui/components/signIn/OxySignUpPanel.js.map +1 -0
  124. package/lib/module/ui/components/signIn/artwork.js +16 -0
  125. package/lib/module/ui/components/signIn/artwork.js.map +1 -0
  126. package/lib/module/ui/components/signIn/passkeyError.js +40 -0
  127. package/lib/module/ui/components/signIn/passkeyError.js.map +1 -0
  128. package/lib/module/ui/components/signIn/signInMethods.js +42 -0
  129. package/lib/module/ui/components/signIn/signInMethods.js.map +1 -0
  130. package/lib/module/ui/context/OxyContext.js +17 -17
  131. package/lib/module/ui/context/OxyContext.js.map +1 -1
  132. package/lib/module/ui/context/commitSessionFlow.js +0 -42
  133. package/lib/module/ui/context/commitSessionFlow.js.map +1 -1
  134. package/lib/module/ui/hooks/accountDialogSnapshot.js +14 -1
  135. package/lib/module/ui/hooks/accountDialogSnapshot.js.map +1 -1
  136. package/lib/module/ui/hooks/useDeviceSwitcher.js +3 -5
  137. package/lib/module/ui/hooks/useDeviceSwitcher.js.map +1 -1
  138. package/lib/module/ui/oauth/browserAuthTransport.js +11 -4
  139. package/lib/module/ui/oauth/browserAuthTransport.js.map +1 -1
  140. package/lib/module/ui/oauth/oauthHandshake.js +3 -0
  141. package/lib/module/ui/oauth/oauthHandshake.js.map +1 -1
  142. package/lib/module/ui/oauth/oauthPopup.js +2 -3
  143. package/lib/module/ui/oauth/oauthPopup.js.map +1 -1
  144. package/lib/module/ui/screens/ManageAccountScreen.js +3 -4
  145. package/lib/module/ui/screens/ManageAccountScreen.js.map +1 -1
  146. package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js +1 -1
  147. package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
  148. package/lib/module/ui/session/authStore.js +1 -22
  149. package/lib/module/ui/session/authStore.js.map +1 -1
  150. package/lib/module/ui/utils/accountDeletionHandoff.js +2 -2
  151. package/lib/module/ui/utils/accountDeletionHandoff.js.map +1 -1
  152. package/lib/typescript/assets/signIn/slide-1.jpg.d.ts +3 -0
  153. package/lib/typescript/assets/signIn/slide-2.jpg.d.ts +3 -0
  154. package/lib/typescript/assets/signIn/slide-3.jpg.d.ts +3 -0
  155. package/lib/typescript/assets/signIn/slide-4.jpg.d.ts +3 -0
  156. package/lib/typescript/commonjs/index.d.ts +8 -2
  157. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  158. package/lib/typescript/commonjs/ui/components/FollowButton.d.ts +6 -0
  159. package/lib/typescript/commonjs/ui/components/FollowButton.d.ts.map +1 -1
  160. package/lib/typescript/commonjs/ui/components/FollowTargetButton.d.ts.map +1 -1
  161. package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
  162. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts +5 -12
  163. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts.map +1 -1
  164. package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts.map +1 -1
  165. package/lib/typescript/commonjs/ui/components/ProfileButton.d.ts +1 -1
  166. package/lib/typescript/commonjs/ui/components/ProfileButton.d.ts.map +1 -1
  167. package/lib/typescript/commonjs/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -1
  168. package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts +0 -19
  169. package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts.map +1 -1
  170. package/lib/typescript/commonjs/ui/components/authChooser/signInFailureMessage.d.ts +1 -5
  171. package/lib/typescript/commonjs/ui/components/authChooser/signInFailureMessage.d.ts.map +1 -1
  172. package/lib/typescript/commonjs/ui/components/authChooser/styles.d.ts +0 -31
  173. package/lib/typescript/commonjs/ui/components/authChooser/styles.d.ts.map +1 -1
  174. package/lib/typescript/commonjs/ui/components/authChooser/types.d.ts +3 -3
  175. package/lib/typescript/commonjs/ui/components/followButtonAccessibility.d.ts +48 -0
  176. package/lib/typescript/commonjs/ui/components/followButtonAccessibility.d.ts.map +1 -0
  177. package/lib/typescript/commonjs/ui/components/oauthNavigation.d.ts +1 -1
  178. package/lib/typescript/commonjs/ui/components/signIn/InlineCommonsQr.d.ts +20 -0
  179. package/lib/typescript/commonjs/ui/components/signIn/InlineCommonsQr.d.ts.map +1 -0
  180. package/lib/typescript/commonjs/ui/components/signIn/OxyAccountPicker.d.ts +34 -0
  181. package/lib/typescript/commonjs/ui/components/signIn/OxyAccountPicker.d.ts.map +1 -0
  182. package/lib/typescript/commonjs/ui/components/signIn/OxyAuthScreen.d.ts +43 -0
  183. package/lib/typescript/commonjs/ui/components/signIn/OxyAuthScreen.d.ts.map +1 -0
  184. package/lib/typescript/commonjs/ui/components/signIn/OxySignInPanel.d.ts +43 -0
  185. package/lib/typescript/commonjs/ui/components/signIn/OxySignInPanel.d.ts.map +1 -0
  186. package/lib/typescript/commonjs/ui/components/signIn/OxySignUpPanel.d.ts +17 -0
  187. package/lib/typescript/commonjs/ui/components/signIn/OxySignUpPanel.d.ts.map +1 -0
  188. package/lib/typescript/commonjs/ui/components/signIn/artwork.d.ts +8 -0
  189. package/lib/typescript/commonjs/ui/components/signIn/artwork.d.ts.map +1 -0
  190. package/lib/typescript/commonjs/ui/components/signIn/passkeyError.d.ts +16 -0
  191. package/lib/typescript/commonjs/ui/components/signIn/passkeyError.d.ts.map +1 -0
  192. package/lib/typescript/commonjs/ui/components/signIn/signInMethods.d.ts +39 -0
  193. package/lib/typescript/commonjs/ui/components/signIn/signInMethods.d.ts.map +1 -0
  194. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
  195. package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts +0 -40
  196. package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts.map +1 -1
  197. package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts +8 -9
  198. package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts.map +1 -1
  199. package/lib/typescript/commonjs/ui/hooks/accountDialogSnapshot.d.ts +7 -1
  200. package/lib/typescript/commonjs/ui/hooks/accountDialogSnapshot.d.ts.map +1 -1
  201. package/lib/typescript/commonjs/ui/hooks/useDeviceSwitcher.d.ts.map +1 -1
  202. package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts +9 -0
  203. package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts.map +1 -1
  204. package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts +3 -0
  205. package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts.map +1 -1
  206. package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts +2 -3
  207. package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts.map +1 -1
  208. package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  209. package/lib/typescript/commonjs/ui/session/authStore.d.ts +0 -30
  210. package/lib/typescript/commonjs/ui/session/authStore.d.ts.map +1 -1
  211. package/lib/typescript/commonjs/ui/types/navigation.d.ts +0 -26
  212. package/lib/typescript/commonjs/ui/types/navigation.d.ts.map +1 -1
  213. package/lib/typescript/module/index.d.ts +8 -2
  214. package/lib/typescript/module/index.d.ts.map +1 -1
  215. package/lib/typescript/module/ui/components/FollowButton.d.ts +6 -0
  216. package/lib/typescript/module/ui/components/FollowButton.d.ts.map +1 -1
  217. package/lib/typescript/module/ui/components/FollowTargetButton.d.ts.map +1 -1
  218. package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
  219. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts +5 -12
  220. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts.map +1 -1
  221. package/lib/typescript/module/ui/components/OxyProvider.d.ts.map +1 -1
  222. package/lib/typescript/module/ui/components/ProfileButton.d.ts +1 -1
  223. package/lib/typescript/module/ui/components/ProfileButton.d.ts.map +1 -1
  224. package/lib/typescript/module/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -1
  225. package/lib/typescript/module/ui/components/authChooser/primitives.d.ts +0 -19
  226. package/lib/typescript/module/ui/components/authChooser/primitives.d.ts.map +1 -1
  227. package/lib/typescript/module/ui/components/authChooser/signInFailureMessage.d.ts +1 -5
  228. package/lib/typescript/module/ui/components/authChooser/signInFailureMessage.d.ts.map +1 -1
  229. package/lib/typescript/module/ui/components/authChooser/styles.d.ts +0 -31
  230. package/lib/typescript/module/ui/components/authChooser/styles.d.ts.map +1 -1
  231. package/lib/typescript/module/ui/components/authChooser/types.d.ts +3 -3
  232. package/lib/typescript/module/ui/components/followButtonAccessibility.d.ts +48 -0
  233. package/lib/typescript/module/ui/components/followButtonAccessibility.d.ts.map +1 -0
  234. package/lib/typescript/module/ui/components/oauthNavigation.d.ts +1 -1
  235. package/lib/typescript/module/ui/components/signIn/InlineCommonsQr.d.ts +20 -0
  236. package/lib/typescript/module/ui/components/signIn/InlineCommonsQr.d.ts.map +1 -0
  237. package/lib/typescript/module/ui/components/signIn/OxyAccountPicker.d.ts +34 -0
  238. package/lib/typescript/module/ui/components/signIn/OxyAccountPicker.d.ts.map +1 -0
  239. package/lib/typescript/module/ui/components/signIn/OxyAuthScreen.d.ts +43 -0
  240. package/lib/typescript/module/ui/components/signIn/OxyAuthScreen.d.ts.map +1 -0
  241. package/lib/typescript/module/ui/components/signIn/OxySignInPanel.d.ts +43 -0
  242. package/lib/typescript/module/ui/components/signIn/OxySignInPanel.d.ts.map +1 -0
  243. package/lib/typescript/module/ui/components/signIn/OxySignUpPanel.d.ts +17 -0
  244. package/lib/typescript/module/ui/components/signIn/OxySignUpPanel.d.ts.map +1 -0
  245. package/lib/typescript/module/ui/components/signIn/artwork.d.ts +8 -0
  246. package/lib/typescript/module/ui/components/signIn/artwork.d.ts.map +1 -0
  247. package/lib/typescript/module/ui/components/signIn/passkeyError.d.ts +16 -0
  248. package/lib/typescript/module/ui/components/signIn/passkeyError.d.ts.map +1 -0
  249. package/lib/typescript/module/ui/components/signIn/signInMethods.d.ts +39 -0
  250. package/lib/typescript/module/ui/components/signIn/signInMethods.d.ts.map +1 -0
  251. package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
  252. package/lib/typescript/module/ui/context/commitSessionFlow.d.ts +0 -40
  253. package/lib/typescript/module/ui/context/commitSessionFlow.d.ts.map +1 -1
  254. package/lib/typescript/module/ui/context/oxyContextTypes.d.ts +8 -9
  255. package/lib/typescript/module/ui/context/oxyContextTypes.d.ts.map +1 -1
  256. package/lib/typescript/module/ui/hooks/accountDialogSnapshot.d.ts +7 -1
  257. package/lib/typescript/module/ui/hooks/accountDialogSnapshot.d.ts.map +1 -1
  258. package/lib/typescript/module/ui/hooks/useDeviceSwitcher.d.ts.map +1 -1
  259. package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts +9 -0
  260. package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts.map +1 -1
  261. package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts +3 -0
  262. package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts.map +1 -1
  263. package/lib/typescript/module/ui/oauth/oauthPopup.d.ts +2 -3
  264. package/lib/typescript/module/ui/oauth/oauthPopup.d.ts.map +1 -1
  265. package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  266. package/lib/typescript/module/ui/session/authStore.d.ts +0 -30
  267. package/lib/typescript/module/ui/session/authStore.d.ts.map +1 -1
  268. package/lib/typescript/module/ui/types/navigation.d.ts +0 -26
  269. package/lib/typescript/module/ui/types/navigation.d.ts.map +1 -1
  270. package/package.json +6 -9
  271. package/src/assets/signIn/slide-1.jpg +0 -0
  272. package/src/assets/signIn/slide-1.jpg.d.ts +3 -0
  273. package/src/assets/signIn/slide-2.jpg +0 -0
  274. package/src/assets/signIn/slide-2.jpg.d.ts +3 -0
  275. package/src/assets/signIn/slide-3.jpg +0 -0
  276. package/src/assets/signIn/slide-3.jpg.d.ts +3 -0
  277. package/src/assets/signIn/slide-4.jpg +0 -0
  278. package/src/assets/signIn/slide-4.jpg.d.ts +3 -0
  279. package/src/index.ts +16 -7
  280. package/src/ui/components/FollowButton.tsx +25 -0
  281. package/src/ui/components/FollowTargetButton.tsx +4 -0
  282. package/src/ui/components/OxyAccountDialogScreen.tsx +11 -72
  283. package/src/ui/components/OxyAuthChooser.tsx +37 -53
  284. package/src/ui/components/OxyProvider.tsx +0 -2
  285. package/src/ui/components/ProfileButton.tsx +1 -4
  286. package/src/ui/components/__tests__/followButtonAccessibility.test.tsx +191 -0
  287. package/src/ui/components/authChooser/AccountsMenuView.tsx +28 -1
  288. package/src/ui/components/authChooser/primitives.tsx +1 -39
  289. package/src/ui/components/authChooser/signInFailureMessage.ts +1 -7
  290. package/src/ui/components/authChooser/styles.ts +0 -31
  291. package/src/ui/components/authChooser/types.ts +3 -3
  292. package/src/ui/components/followButtonAccessibility.ts +83 -0
  293. package/src/ui/components/oauthNavigation.ts +1 -1
  294. package/src/ui/components/signIn/InlineCommonsQr.tsx +135 -0
  295. package/src/ui/components/signIn/OxyAccountPicker.tsx +129 -0
  296. package/src/ui/components/signIn/OxyAuthScreen.tsx +123 -0
  297. package/src/ui/components/signIn/OxySignInPanel.tsx +392 -0
  298. package/src/ui/components/signIn/OxySignUpPanel.tsx +86 -0
  299. package/src/ui/components/signIn/artwork.ts +13 -0
  300. package/src/ui/components/signIn/passkeyError.ts +44 -0
  301. package/src/ui/components/signIn/signInMethods.ts +51 -0
  302. package/src/ui/context/OxyContext.tsx +21 -18
  303. package/src/ui/context/__tests__/commitSessionFlow.test.ts +0 -89
  304. package/src/ui/context/commitSessionFlow.ts +0 -61
  305. package/src/ui/context/oxyContextTypes.ts +9 -9
  306. package/src/ui/hooks/accountDialogSnapshot.ts +20 -1
  307. package/src/ui/hooks/useDeviceSwitcher.ts +3 -11
  308. package/src/ui/oauth/__tests__/browserAuthTransport.test.ts +21 -0
  309. package/src/ui/oauth/browserAuthTransport.ts +14 -4
  310. package/src/ui/oauth/oauthHandshake.ts +4 -1
  311. package/src/ui/oauth/oauthPopup.ts +2 -3
  312. package/src/ui/screens/ManageAccountScreen.tsx +3 -4
  313. package/src/ui/screens/trust/TrustLeaderboardScreen.tsx +1 -1
  314. package/src/ui/session/authStore.ts +0 -37
  315. package/src/ui/types/navigation.ts +0 -26
  316. package/src/ui/utils/accountDeletionHandoff.ts +2 -2
  317. package/lib/commonjs/ui/components/authChooser/SignInEntryView.js +0 -132
  318. package/lib/commonjs/ui/components/authChooser/SignInEntryView.js.map +0 -1
  319. package/lib/commonjs/ui/components/authChooser/SignUpView.js +0 -77
  320. package/lib/commonjs/ui/components/authChooser/SignUpView.js.map +0 -1
  321. package/lib/commonjs/ui/components/passkeyHubPopup.js +0 -33
  322. package/lib/commonjs/ui/components/passkeyHubPopup.js.map +0 -1
  323. package/lib/commonjs/ui/oauth/legacyRedirectLanes.js +0 -48
  324. package/lib/commonjs/ui/oauth/legacyRedirectLanes.js.map +0 -1
  325. package/lib/module/ui/components/authChooser/SignInEntryView.js +0 -127
  326. package/lib/module/ui/components/authChooser/SignInEntryView.js.map +0 -1
  327. package/lib/module/ui/components/authChooser/SignUpView.js +0 -73
  328. package/lib/module/ui/components/authChooser/SignUpView.js.map +0 -1
  329. package/lib/module/ui/components/passkeyHubPopup.js +0 -29
  330. package/lib/module/ui/components/passkeyHubPopup.js.map +0 -1
  331. package/lib/module/ui/oauth/legacyRedirectLanes.js +0 -44
  332. package/lib/module/ui/oauth/legacyRedirectLanes.js.map +0 -1
  333. package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts +0 -39
  334. package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts.map +0 -1
  335. package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts +0 -31
  336. package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts.map +0 -1
  337. package/lib/typescript/commonjs/ui/components/passkeyHubPopup.d.ts +0 -23
  338. package/lib/typescript/commonjs/ui/components/passkeyHubPopup.d.ts.map +0 -1
  339. package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts +0 -40
  340. package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts.map +0 -1
  341. package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts +0 -39
  342. package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts.map +0 -1
  343. package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts +0 -31
  344. package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts.map +0 -1
  345. package/lib/typescript/module/ui/components/passkeyHubPopup.d.ts +0 -23
  346. package/lib/typescript/module/ui/components/passkeyHubPopup.d.ts.map +0 -1
  347. package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts +0 -40
  348. package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts.map +0 -1
  349. package/src/ui/components/authChooser/SignInEntryView.tsx +0 -157
  350. package/src/ui/components/authChooser/SignUpView.tsx +0 -76
  351. package/src/ui/components/passkeyHubPopup.ts +0 -28
  352. package/src/ui/oauth/legacyRedirectLanes.ts +0 -43
@@ -0,0 +1,106 @@
1
+ "use strict";
2
+
3
+ /**
4
+ * "Choose an account" — every `principal acting as account` pair on this
5
+ * device, then "Use another account".
6
+ *
7
+ * The front screen of sign-in on a returning device, in the account dialog and
8
+ * on every auth.oxy.so page that asks WHO (sign-in, OAuth authorize, device
9
+ * approval, MCP linking). Presentational: the host decides what choosing a row
10
+ * means — a switch, a "Continue as" sign-in, or activating the pair before an
11
+ * OAuth consent — and passes the pair back, never an account id, which cannot
12
+ * say whose route was chosen.
13
+ */
14
+
15
+ import { Pressable, StyleSheet, View } from 'react-native';
16
+ import { RiArrowRightSLine } from '@oxy.so/bloom/icons/RiArrowRightSLine';
17
+ import { RiUserAddLine } from '@oxy.so/bloom/icons/RiUserAddLine';
18
+ import { useTheme } from '@oxy.so/bloom/theme';
19
+ import { Text } from '@oxy.so/bloom/typography';
20
+ import { showsPrincipalHeaders } from '@oxy.so/core';
21
+ import { useI18n } from "../../hooks/useI18n.js";
22
+ import { AccountRow } from "../authChooser/primitives.js";
23
+ import { authChooserStyles } from "../authChooser/styles.js";
24
+ import { OxyAuthScreen, OxyAuthScreenHeader, OxyAuthTerms } from "./OxyAuthScreen.js";
25
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
26
+ export const OxyAccountPicker = ({
27
+ principals,
28
+ appName,
29
+ onSelectContext,
30
+ onUseAnother,
31
+ pendingContextId = null,
32
+ isLoading = false,
33
+ signedOut = false
34
+ }) => {
35
+ const theme = useTheme();
36
+ const {
37
+ t
38
+ } = useI18n();
39
+ // Whose route a row is only needs naming once someone holds more than one
40
+ // account here — the same rule the account menu's group headers follow.
41
+ const namesTheOperator = showsPrincipalHeaders(principals);
42
+ return /*#__PURE__*/_jsxs(OxyAuthScreen, {
43
+ children: [/*#__PURE__*/_jsx(OxyAuthScreenHeader, {
44
+ title: t('signin.chooser.title'),
45
+ description: appName ? t('signin.chooser.subtitleToApp', {
46
+ app: appName
47
+ }) : t('signin.chooser.subtitle')
48
+ }), /*#__PURE__*/_jsxs(View, {
49
+ style: authChooserStyles.rows,
50
+ children: [principals.flatMap(principal => principal.contexts.map(context => /*#__PURE__*/_jsx(AccountRow, {
51
+ context: context,
52
+ operatedBy: namesTheOperator && context.isDelegated ? t('accountSwitcher.context.operatedBy', {
53
+ name: principal.displayName
54
+ }) : null,
55
+ continueAsLabel: signedOut ? t('signin.chooser.continueAs', {
56
+ name: context.handle ? `@${context.handle}` : context.displayName
57
+ }) : null,
58
+ theme: theme,
59
+ activating: pendingContextId === context.contextId,
60
+ disabled: isLoading,
61
+ onPress: () => onSelectContext(context)
62
+ }, context.contextId))), /*#__PURE__*/_jsxs(Pressable, {
63
+ onPress: onUseAnother,
64
+ disabled: isLoading,
65
+ accessibilityRole: "button",
66
+ accessibilityLabel: t('signin.chooser.useAnother'),
67
+ style: [authChooserStyles.accountRow, {
68
+ borderColor: theme.colors.border,
69
+ backgroundColor: theme.colors.card
70
+ }, isLoading ? authChooserStyles.rowDisabled : null],
71
+ testID: "use-another-account",
72
+ children: [/*#__PURE__*/_jsx(View, {
73
+ style: [styles.addGlyph, {
74
+ backgroundColor: theme.colors.backgroundSecondary
75
+ }],
76
+ children: /*#__PURE__*/_jsx(RiUserAddLine, {
77
+ size: "md",
78
+ fill: theme.colors.textSecondary
79
+ })
80
+ }), /*#__PURE__*/_jsx(Text, {
81
+ style: [authChooserStyles.rowName, styles.addLabel, {
82
+ color: theme.colors.text
83
+ }],
84
+ children: t('signin.chooser.useAnother')
85
+ }), /*#__PURE__*/_jsx(RiArrowRightSLine, {
86
+ size: "md",
87
+ fill: theme.colors.textSecondary
88
+ })]
89
+ })]
90
+ }), /*#__PURE__*/_jsx(OxyAuthTerms, {})]
91
+ });
92
+ };
93
+ const styles = StyleSheet.create({
94
+ // Matches `AccountRow`'s 40px avatar plus its 2px ring and 1px gap.
95
+ addGlyph: {
96
+ width: 46,
97
+ height: 46,
98
+ borderRadius: 23,
99
+ alignItems: 'center',
100
+ justifyContent: 'center'
101
+ },
102
+ addLabel: {
103
+ flex: 1
104
+ }
105
+ });
106
+ //# sourceMappingURL=OxyAccountPicker.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Pressable","StyleSheet","View","RiArrowRightSLine","RiUserAddLine","useTheme","Text","showsPrincipalHeaders","useI18n","AccountRow","authChooserStyles","OxyAuthScreen","OxyAuthScreenHeader","OxyAuthTerms","jsx","_jsx","jsxs","_jsxs","OxyAccountPicker","principals","appName","onSelectContext","onUseAnother","pendingContextId","isLoading","signedOut","theme","t","namesTheOperator","children","title","description","app","style","rows","flatMap","principal","contexts","map","context","operatedBy","isDelegated","name","displayName","continueAsLabel","handle","activating","contextId","disabled","onPress","accessibilityRole","accessibilityLabel","accountRow","borderColor","colors","border","backgroundColor","card","rowDisabled","testID","styles","addGlyph","backgroundSecondary","size","fill","textSecondary","rowName","addLabel","color","text","create","width","height","borderRadius","alignItems","justifyContent","flex"],"sourceRoot":"../../../../../src","sources":["ui/components/signIn/OxyAccountPicker.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAASA,SAAS,EAAEC,UAAU,EAAEC,IAAI,QAAQ,cAAc;AAC1D,SAASC,iBAAiB,QAAQ,uCAAuC;AACzE,SAASC,aAAa,QAAQ,mCAAmC;AACjE,SAASC,QAAQ,QAAQ,qBAAqB;AAC9C,SAASC,IAAI,QAAQ,0BAA0B;AAC/C,SAASC,qBAAqB,QAA4D,cAAc;AACxG,SAASC,OAAO,QAAQ,wBAAqB;AAC7C,SAASC,UAAU,QAAQ,8BAA2B;AACtD,SAASC,iBAAiB,QAAQ,0BAAuB;AACzD,SAASC,aAAa,EAAEC,mBAAmB,EAAEC,YAAY,QAAQ,oBAAiB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAsBnF,OAAO,MAAMC,gBAAiD,GAAGA,CAAC;EAChEC,UAAU;EACVC,OAAO;EACPC,eAAe;EACfC,YAAY;EACZC,gBAAgB,GAAG,IAAI;EACvBC,SAAS,GAAG,KAAK;EACjBC,SAAS,GAAG;AACd,CAAC,KAAK;EACJ,MAAMC,KAAK,GAAGrB,QAAQ,CAAC,CAAC;EACxB,MAAM;IAAEsB;EAAE,CAAC,GAAGnB,OAAO,CAAC,CAAC;EACvB;EACA;EACA,MAAMoB,gBAAgB,GAAGrB,qBAAqB,CAACY,UAAU,CAAC;EAE1D,oBACEF,KAAA,CAACN,aAAa;IAAAkB,QAAA,gBACZd,IAAA,CAACH,mBAAmB;MAClBkB,KAAK,EAAEH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/**
4
+ * The shell every Oxy sign-in screen shares — the in-app account dialog and
5
+ * every page of the auth.oxy.so IdP render these, so the two cannot drift:
6
+ *
7
+ * header the Oxy mark (56), then the title (48/800, tight) and a 18px
8
+ * description, 8 apart
9
+ * screen blocks 24 apart, at most 448 wide
10
+ * split from `md`, Bloom `AuthCard`'s split base — max 880, radius 24,
11
+ * 1px border, two equal columns, the right one on the secondary
12
+ * surface; below `md` the right column is dropped, not stacked
13
+ * loading an indeterminate spinner holding the screen's height
14
+ * terms one centred caption linking the Terms of Service and Privacy Policy
15
+ *
16
+ * Layout is NativeWind `className` (breakpoints included). Type stays on
17
+ * Bloom `Text`'s own ramp through `style` — a `className` there drops its
18
+ * default family — and colours come from the Bloom theme.
19
+ */
20
+
21
+ import { ActivityIndicator, Linking, Text as RNText } from 'react-native';
22
+ import { View } from 'react-native-css/components';
23
+ import { useTheme } from '@oxy.so/bloom/theme';
24
+ import { Text } from '@oxy.so/bloom/typography';
25
+ import { useI18n } from "../../hooks/useI18n.js";
26
+ import { LogoIcon } from "../logo/LogoIcon.js";
27
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
28
+ const LOGO_HEIGHT = 56;
29
+ const TERMS_URL = 'https://oxy.so/company/transparency/policies/terms-of-service';
30
+ const PRIVACY_URL = 'https://oxy.so/company/transparency/policies/privacy';
31
+ const TITLE = {
32
+ fontSize: 48,
33
+ lineHeight: 48,
34
+ fontWeight: '800',
35
+ letterSpacing: -1.2
36
+ };
37
+ const DESCRIPTION = {
38
+ fontSize: 18,
39
+ lineHeight: 28
40
+ };
41
+ const TERMS = {
42
+ fontSize: 14,
43
+ lineHeight: 20,
44
+ textAlign: 'center',
45
+ paddingHorizontal: 24
46
+ };
47
+ /** The Oxy mark over the screen's title and description. */
48
+ export const OxyAuthScreenHeader = ({
49
+ title,
50
+ description
51
+ }) => {
52
+ const theme = useTheme();
53
+ return /*#__PURE__*/_jsxs(View, {
54
+ className: "gap-6",
55
+ children: [/*#__PURE__*/_jsx(LogoIcon, {
56
+ height: LOGO_HEIGHT
57
+ }), /*#__PURE__*/_jsxs(View, {
58
+ className: "max-w-[90%] gap-2",
59
+ children: [/*#__PURE__*/_jsx(Text, {
60
+ accessibilityRole: "header",
61
+ style: [TITLE, {
62
+ color: theme.colors.text
63
+ }],
64
+ children: title
65
+ }), description != null && description !== '' ? typeof description === 'string' ? /*#__PURE__*/_jsx(Text, {
66
+ style: [DESCRIPTION, {
67
+ color: theme.colors.textSecondary
68
+ }],
69
+ children: description
70
+ }) : description : null]
71
+ })]
72
+ });
73
+ };
74
+
75
+ /** A sign-in screen's column: its blocks 24 apart. `className` extends it (the split's form column). */
76
+ export const OxyAuthScreen = ({
77
+ children,
78
+ className
79
+ }) => /*#__PURE__*/_jsx(View, {
80
+ className: `w-full max-w-[448px] self-center gap-6 ${className ?? ''}`,
81
+ children: children
82
+ });
83
+
84
+ /** The split card: `children` on the left and, from `md`, `aside` on the right. */
85
+ export const OxyAuthSplit = ({
86
+ children,
87
+ aside
88
+ }) => {
89
+ const theme = useTheme();
90
+ return /*#__PURE__*/_jsxs(View, {
91
+ className: "w-full self-center md:max-w-[880px] md:flex-row md:rounded-3xl md:border md:border-border md:bg-card md:overflow-hidden",
92
+ children: [/*#__PURE__*/_jsx(View, {
93
+ className: "md:flex-1 md:basis-0 md:min-w-0",
94
+ children: /*#__PURE__*/_jsx(View, {
95
+ className: "md:p-8",
96
+ children: children
97
+ })
98
+ }), /*#__PURE__*/_jsx(View, {
99
+ className: "hidden md:flex md:flex-1 md:basis-0 md:min-w-0 items-center justify-center overflow-hidden p-8",
100
+ style: {
101
+ backgroundColor: theme.colors.backgroundSecondary
102
+ },
103
+ children: aside
104
+ })]
105
+ });
106
+ };
107
+
108
+ /**
109
+ * The screen while there is nothing to show yet. React Native's own indicator:
110
+ * `@oxy.so/bloom/loading` can tree-shake to `undefined` in a rolldown-vite
111
+ * production bundle when co-imported with `@oxy.so/bloom/button`.
112
+ */
113
+ export const OxyAuthLoading = () => {
114
+ const theme = useTheme();
115
+ return /*#__PURE__*/_jsx(View, {
116
+ className: "min-h-[300px] items-center justify-center",
117
+ children: /*#__PURE__*/_jsx(ActivityIndicator, {
118
+ size: "large",
119
+ color: theme.colors.primary
120
+ })
121
+ });
122
+ };
123
+
124
+ /** "By continuing, you agree to our Terms of Service and Privacy Policy." */
125
+ export const OxyAuthTerms = () => {
126
+ const theme = useTheme();
127
+ const {
128
+ t
129
+ } = useI18n();
130
+ const link = {
131
+ color: theme.colors.text,
132
+ textDecorationLine: 'underline'
133
+ };
134
+ return /*#__PURE__*/_jsxs(Text, {
135
+ style: [TERMS, {
136
+ color: theme.colors.textSecondary
137
+ }],
138
+ children: [t('signin.terms.before'), ' ', /*#__PURE__*/_jsx(RNText, {
139
+ accessibilityRole: "link",
140
+ style: link,
141
+ onPress: () => void Linking.openURL(TERMS_URL),
142
+ children: t('signin.terms.termsLink')
143
+ }), ' ', t('signin.terms.and'), ' ', /*#__PURE__*/_jsx(RNText, {
144
+ accessibilityRole: "link",
145
+ style: link,
146
+ onPress: () => void Linking.openURL(PRIVACY_URL),
147
+ children: t('signin.terms.privacyLink')
148
+ }), "."]
149
+ });
150
+ };
151
+ //# sourceMappingURL=OxyAuthScreen.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["ActivityIndicator","Linking","Text","RNText","View","useTheme","useI18n","LogoIcon","jsx","_jsx","jsxs","_jsxs","LOGO_HEIGHT","TERMS_URL","PRIVACY_URL","TITLE","fontSize","lineHeight","fontWeight","letterSpacing","DESCRIPTION","TERMS","textAlign","paddingHorizontal","OxyAuthScreenHeader","title","description","theme","className","children","height","accessibilityRole","style","color","colors","text","textSecondary","OxyAuthScreen","OxyAuthSplit","aside","backgroundColor","backgroundSecondary","OxyAuthLoading","size","primary","OxyAuthTerms","t","link","textDecorationLine","onPress","openURL"],"sourceRoot":"../../../../../src","sources":["ui/components/signIn/OxyAuthScreen.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;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Ae,QAAA,EAC5FiB,CAAC,CAAC,0BAA0B;IAAC,CACxB,CAAC,KAEX;EAAA,CAAM,CAAC;AAEX,CAAC","ignoreList":[]}
@@ -0,0 +1,366 @@
1
+ "use strict";
2
+
3
+ /**
4
+ * THE Oxy sign-in screen. The account dialog every Oxy app opens and the
5
+ * auth.oxy.so page render this one component; only where it is mounted
6
+ * differs (`host`).
7
+ *
8
+ * picker a returning device: "Choose an account", then "Use another account"
9
+ * entry the header, the Commons way in, and the way in for someone with no
10
+ * account. On auth.oxy.so (`page`) also the username with its
11
+ * Continue — a username-first passkey sign-in, which takes a
12
+ * platform passkey AND a hardware security key with no resident
13
+ * credential (a U2F key such as a Titan) — and "or continue with" the
14
+ * discoverable passkey. From `md` that page is Bloom `AuthCard`'s
15
+ * split card, with the embedded QR over its photo carousel in the
16
+ * right column; below `md` it is "Continue with Oxy" at the top.
17
+ * In an app's dialog on the web, "Continue with Oxy" opens that page
18
+ * in a window over the app, like "Sign in with Google": the browser's
19
+ * session lives on auth.oxy.so, so every Oxy app shares it. On
20
+ * native it is "Continue with Oxy" ("Get Commons" without Commons).
21
+ *
22
+ * `signInMethods.ts` owns which blocks a platform gets.
23
+ */
24
+
25
+ import { useCallback, useEffect, useState } from 'react';
26
+ import { Linking, Platform, Text as RNText, StyleSheet, View } from 'react-native';
27
+ import { View as CssView } from 'react-native-css/components';
28
+ import { AuthMediaCarousel } from '@oxy.so/bloom/auth-card';
29
+ import { Button } from '@oxy.so/bloom/button';
30
+ import { Divider } from '@oxy.so/bloom/divider';
31
+ import { RiKey2Line } from '@oxy.so/bloom/icons/RiKey2Line';
32
+ import { RiQrCodeLine } from '@oxy.so/bloom/icons/RiQrCodeLine';
33
+ import { useTheme } from '@oxy.so/bloom/theme';
34
+ import { TextField, TextFieldHint, TextFieldInput, TextFieldLabel } from '@oxy.so/bloom/text-field';
35
+ import { toast } from '@oxy.so/bloom/toast';
36
+ import { Text } from '@oxy.so/bloom/typography';
37
+ import { useQueryClient } from '@tanstack/react-query';
38
+ import { useOxy } from "../../context/OxyContext.js";
39
+ import { useAccountDialogSnapshot } from "../../hooks/accountDialogSnapshot.js";
40
+ import { useDeviceSwitcher } from "../../hooks/useDeviceSwitcher.js";
41
+ import { useI18n } from "../../hooks/useI18n.js";
42
+ import { getCommonsAcquisitionUrl } from "../../utils/commonsStoreLinks.js";
43
+ import { isWebBrowser } from "../../utils/isWebBrowser.js";
44
+ import { SubtleLink } from "../authChooser/primitives.js";
45
+ import { SIGN_IN_SLIDES } from "./artwork.js";
46
+ import { InlineCommonsQr } from "./InlineCommonsQr.js";
47
+ import { OxyAccountPicker } from "./OxyAccountPicker.js";
48
+ import { OxyAuthScreen, OxyAuthScreenHeader, OxyAuthSplit, OxyAuthTerms } from "./OxyAuthScreen.js";
49
+ import { RATE_LIMIT_SECONDS, describePasskeyError, isRateLimited } from "./passkeyError.js";
50
+ import { resolveSignInMethods } from "./signInMethods.js";
51
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
52
+ export const OxySignInPanel = ({
53
+ onSignedIn,
54
+ onCreateAccount,
55
+ onRecover,
56
+ loginHint,
57
+ appName = null,
58
+ host = 'page'
59
+ }) => {
60
+ const theme = useTheme();
61
+ const {
62
+ t
63
+ } = useI18n();
64
+ const queryClient = useQueryClient();
65
+ const {
66
+ accountDialogController: controller,
67
+ openAccountDialog,
68
+ signInWithPasskey,
69
+ continueOnAuth
70
+ } = useOxy();
71
+ const snapshot = useAccountDialogSnapshot(controller);
72
+ const {
73
+ principals,
74
+ activeContext
75
+ } = useDeviceSwitcher();
76
+ const methods = resolveSignInMethods({
77
+ web: isWebBrowser(),
78
+ host,
79
+ commonsAvailability: snapshot.commonsAvailability
80
+ });
81
+ const [showForm, setShowForm] = useState(Boolean(loginHint));
82
+ const [identifier, setIdentifier] = useState(loginHint ?? '');
83
+ const [pending, setPending] = useState(false);
84
+ const [error, setError] = useState(null);
85
+ const [rateLimitSeconds, setRateLimitSeconds] = useState(0);
86
+ const blocked = pending || rateLimitSeconds > 0;
87
+
88
+ // The countdown after a 429: one tick a second until the person may retry.
89
+ useEffect(() => {
90
+ if (rateLimitSeconds <= 0) return;
91
+ const timer = setTimeout(() => setRateLimitSeconds(seconds => Math.max(0, seconds - 1)), 1000);
92
+ return () => clearTimeout(timer);
93
+ }, [rateLimitSeconds]);
94
+
95
+ // On a page, a request the controller runs (the embedded QR, or one shown in
96
+ // the dialog opened over it) finishes the page's sign-in too. Only one that
97
+ // STARTED here: a completion already on the controller is somebody else's.
98
+ const [mountedAttempt] = useState(snapshot.signIn.attempt);
99
+ const completedHere = snapshot.signIn.phase === 'completed' && snapshot.signIn.attempt !== mountedAttempt;
100
+ useEffect(() => {
101
+ if (host === 'page' && completedHere) onSignedIn();
102
+ }, [host, completedHere, onSignedIn]);
103
+
104
+ /** Show the request a controller call just started — the dialog is where it lives. */
105
+ const showRequest = useCallback(() => {
106
+ if (host === 'page') openAccountDialog('qr');
107
+ }, [host, openAccountDialog]);
108
+
109
+ // These open a window or leave the page, so they run straight from the
110
+ // press, before any await.
111
+ const continueWithOxy = () => {
112
+ void controller?.signInWithOxy();
113
+ showRequest();
114
+ };
115
+ const signInOnOxy = () => {
116
+ void continueOnAuth('signin').then(result => {
117
+ if (result.status === 'signed-in') onSignedIn();else if (result.status === 'failed') toast.error(t('signin.errors.failed'));
118
+ });
119
+ };
120
+ const useAnotherDevice = () => {
121
+ void controller?.showQr();
122
+ showRequest();
123
+ };
124
+ const getCommons = () => {
125
+ Promise.resolve().then(() => Linking.openURL(getCommonsAcquisitionUrl(Platform.OS))).catch(() => toast.error(t('accountSwitcher.linkOpenFailed')));
126
+ };
127
+ const runPasskey = async (username, failToast) => {
128
+ if (blocked) return;
129
+ setError(null);
130
+ setPending(true);
131
+ try {
132
+ await signInWithPasskey({
133
+ username
134
+ });
135
+ onSignedIn();
136
+ } catch (err) {
137
+ if (isRateLimited(err)) {
138
+ setRateLimitSeconds(RATE_LIMIT_SECONDS);
139
+ } else {
140
+ const message = describePasskeyError(err, t);
141
+ setError(message);
142
+ toast.error(failToast, {
143
+ description: message
144
+ });
145
+ }
146
+ } finally {
147
+ setPending(false);
148
+ }
149
+ };
150
+ const submitUsername = () => {
151
+ const username = identifier.trim();
152
+ if (username) void runPasskey(username, t('signin.errors.failed'));else setError(t('signin.username.required'));
153
+ };
154
+
155
+ // A returning device starts at WHO. Not while adding an account from inside
156
+ // a signed-in app: the rows are the accounts it would add.
157
+ const pickerAllowed = host === 'dialog' ? !snapshot.hasSession : activeContext !== null;
158
+ const reauthenticate = context => {
159
+ setIdentifier(context.handle ?? '');
160
+ setShowForm(true);
161
+ };
162
+ const selectContext = async context => {
163
+ const outcome = await controller?.chooseContext(context.contextId).catch(() => 'failed');
164
+ switch (outcome) {
165
+ case 'switched':
166
+ // Every account-scoped query now describes somebody else.
167
+ void queryClient.invalidateQueries();
168
+ onSignedIn();
169
+ return;
170
+ case 'current':
171
+ onSignedIn();
172
+ return;
173
+ case 'signing-in':
174
+ // The request for that account is running; it shows where requests do.
175
+ showRequest();
176
+ return;
177
+ case 'failed':
178
+ // The pair could not be activated as it stands: sign in as it explicitly.
179
+ if (methods.passkey && context.handle) reauthenticate(context);else toast.error(t('accountSwitcher.toasts.activateFailed'));
180
+ return;
181
+ default:
182
+ return;
183
+ }
184
+ };
185
+ const showsPicker = pickerAllowed && !showForm && principals.length > 0;
186
+ // auth.oxy.so's page is the split card from `md`.
187
+ const splits = methods.commons === 'qr';
188
+ if (showsPicker) {
189
+ return /*#__PURE__*/_jsx(OxyAccountPicker, {
190
+ principals: principals,
191
+ appName: appName,
192
+ signedOut: !snapshot.hasSession,
193
+ pendingContextId: snapshot.activatingContextId,
194
+ isLoading: snapshot.activatingContextId !== null,
195
+ onSelectContext: context => void selectContext(context),
196
+ onUseAnother: () => {
197
+ setIdentifier('');
198
+ setShowForm(true);
199
+ }
200
+ });
201
+ }
202
+ const shownError = rateLimitSeconds > 0 ? t('signin.errors.rateLimited', {
203
+ seconds: rateLimitSeconds
204
+ }) : error;
205
+ const adding = host === 'dialog' && snapshot.hasSession;
206
+ const title = adding ? t('signin.addAccountTitle') : t('signin.title');
207
+ const description = adding ? t('signin.addAccountSubtitle') : appName ? t('signin.subtitleToApp', {
208
+ app: appName
209
+ }) : t('signin.subtitle');
210
+ const noAccount = /*#__PURE__*/_jsxs(Text, {
211
+ style: [styles.note, styles.noAccount, {
212
+ color: theme.colors.textSecondary
213
+ }],
214
+ children: [t('signin.noAccount'), ' ', /*#__PURE__*/_jsx(RNText, {
215
+ accessibilityRole: "link",
216
+ onPress: onCreateAccount,
217
+ style: [styles.noAccountLink, {
218
+ color: theme.colors.text
219
+ }],
220
+ testID: "create-account-link",
221
+ children: t('signin.createAccount')
222
+ })]
223
+ });
224
+ // One solid action per screen: the username's Continue when there is one.
225
+ const commonsAppearance = methods.passkey ? 'outline' : 'solid';
226
+ const continueWithOxyButton = /*#__PURE__*/_jsx(Button, {
227
+ appearance: commonsAppearance,
228
+ tone: commonsAppearance === 'solid' ? 'action' : 'neutral',
229
+ size: "lg",
230
+ fullWidth: true,
231
+ onPress: methods.commons === 'window' ? signInOnOxy : continueWithOxy,
232
+ testID: "continue-with-oxy",
233
+ children: t('accountSwitcher.continueWithOxy')
234
+ });
235
+ const form = /*#__PURE__*/_jsxs(OxyAuthScreen, {
236
+ className: splits ? 'md:max-w-none' : undefined,
237
+ children: [/*#__PURE__*/_jsx(OxyAuthScreenHeader, {
238
+ title: title,
239
+ description: description
240
+ }), splits ? /*#__PURE__*/_jsx(CssView, {
241
+ className: "md:hidden",
242
+ children: continueWithOxyButton
243
+ }) : null, methods.commons === 'continue' || methods.commons === 'window' ? continueWithOxyButton : null, methods.commons === 'get-commons' ? /*#__PURE__*/_jsxs(View, {
244
+ style: styles.stack,
245
+ children: [/*#__PURE__*/_jsx(Text, {
246
+ style: [styles.note, {
247
+ color: theme.colors.textSecondary
248
+ }],
249
+ children: t('accountSwitcher.commonsNotInstalled')
250
+ }), /*#__PURE__*/_jsx(Button, {
251
+ appearance: "solid",
252
+ tone: "action",
253
+ size: "lg",
254
+ fullWidth: true,
255
+ onPress: getCommons,
256
+ testID: "get-commons-button",
257
+ children: t('accountSwitcher.getCommons')
258
+ })]
259
+ }) : null, methods.passkey ? /*#__PURE__*/_jsxs(View, {
260
+ style: styles.stack,
261
+ children: [/*#__PURE__*/_jsxs(View, {
262
+ style: styles.field,
263
+ children: [/*#__PURE__*/_jsx(TextFieldLabel, {
264
+ nativeID: "username-label",
265
+ children: t('signin.username.label')
266
+ }), /*#__PURE__*/_jsx(TextField, {
267
+ invalid: shownError !== null,
268
+ disabled: blocked,
269
+ radius: 999,
270
+ style: styles.input,
271
+ children: /*#__PURE__*/_jsx(TextFieldInput, {
272
+ testID: "username",
273
+ label: t('signin.username.label'),
274
+ value: identifier,
275
+ onValueChange: value => {
276
+ setIdentifier(value);
277
+ if (error) setError(null);
278
+ },
279
+ placeholder: t('signin.username.placeholder'),
280
+ autoComplete: "username",
281
+ autoCapitalize: "none",
282
+ autoCorrect: false,
283
+ autoFocus: Platform.OS === 'web',
284
+ returnKeyType: "go",
285
+ onSubmitEditing: submitUsername,
286
+ "aria-required": true
287
+ })
288
+ }), shownError ? /*#__PURE__*/_jsx(TextFieldHint, {
289
+ invalid: true,
290
+ children: shownError
291
+ }) : null]
292
+ }), noAccount, /*#__PURE__*/_jsx(Button, {
293
+ appearance: "solid",
294
+ tone: "action",
295
+ size: "lg",
296
+ fullWidth: true,
297
+ loading: pending,
298
+ disabled: blocked,
299
+ onPress: submitUsername,
300
+ testID: "username-continue",
301
+ children: t('signin.actions.continue')
302
+ })]
303
+ }) : null, methods.commons === 'window' ? null : /*#__PURE__*/_jsx(Divider, {
304
+ children: t('signin.orContinueWith')
305
+ }), methods.passkey ? /*#__PURE__*/_jsx(Button, {
306
+ appearance: "outline",
307
+ tone: "neutral",
308
+ size: "lg",
309
+ fullWidth: true,
310
+ leadingIcon: RiKey2Line,
311
+ disabled: blocked,
312
+ onPress: () => void runPasskey(undefined, t('signin.errors.failed')),
313
+ testID: "passkey-sign-in",
314
+ children: t('signin.methods.passkey')
315
+ }) : methods.commons === 'window' ? null : /*#__PURE__*/_jsx(Button, {
316
+ appearance: "outline",
317
+ tone: "neutral",
318
+ size: "lg",
319
+ fullWidth: true,
320
+ leadingIcon: RiQrCodeLine,
321
+ onPress: useAnotherDevice,
322
+ testID: "scan-qr",
323
+ children: t('accountSwitcher.scanQr')
324
+ }), methods.passkey ? null : noAccount, onRecover ? /*#__PURE__*/_jsx(SubtleLink, {
325
+ label: t('signin.recoverLink'),
326
+ theme: theme,
327
+ onPress: onRecover,
328
+ testID: "recover-link"
329
+ }) : null, /*#__PURE__*/_jsx(OxyAuthTerms, {})]
330
+ });
331
+ if (!splits) return form;
332
+ return /*#__PURE__*/_jsx(OxyAuthSplit, {
333
+ aside: /*#__PURE__*/_jsxs(_Fragment, {
334
+ children: [/*#__PURE__*/_jsx(AuthMediaCarousel, {
335
+ slides: SIGN_IN_SLIDES,
336
+ style: StyleSheet.absoluteFill
337
+ }), /*#__PURE__*/_jsx(InlineCommonsQr, {
338
+ controller: controller
339
+ })]
340
+ }),
341
+ children: form
342
+ });
343
+ };
344
+ const styles = StyleSheet.create({
345
+ stack: {
346
+ gap: 12
347
+ },
348
+ field: {
349
+ gap: 6
350
+ },
351
+ note: {
352
+ fontSize: 14,
353
+ lineHeight: 20,
354
+ textAlign: 'center'
355
+ },
356
+ noAccount: {
357
+ textAlign: 'left'
358
+ },
359
+ noAccountLink: {
360
+ textDecorationLine: 'underline'
361
+ },
362
+ input: {
363
+ height: 40
364
+ }
365
+ });
366
+ //# sourceMappingURL=OxySignInPanel.js.map