@thunderid/nextjs 1.12.0 → 1.14.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 (283) hide show
  1. package/dist/ThunderIDNextClient.d.ts +8 -1
  2. package/dist/ThunderIDNextClient.d.ts.map +1 -1
  3. package/dist/ThunderIDNextClient.js +10 -0
  4. package/dist/ThunderIDNextClient.js.map +1 -1
  5. package/dist/cjs/ThunderIDNextClient.cjs +10 -0
  6. package/dist/cjs/ThunderIDNextClient.cjs.map +1 -1
  7. package/dist/cjs/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.cjs +116 -0
  8. package/dist/cjs/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.cjs.map +1 -0
  9. package/dist/cjs/client/components/account/UserProfile/UserProfile.cjs +11 -1
  10. package/dist/cjs/client/components/account/UserProfile/UserProfile.cjs.map +1 -1
  11. package/dist/cjs/client/components/account/VerifyAttribute/VerifyAttribute.cjs +80 -0
  12. package/dist/cjs/client/components/account/VerifyAttribute/VerifyAttribute.cjs.map +1 -0
  13. package/dist/cjs/client/components/auth/SignIn/SignIn.cjs +3 -2
  14. package/dist/cjs/client/components/auth/SignIn/SignIn.cjs.map +1 -1
  15. package/dist/cjs/client/components/{admin → management}/AgentCreate/AgentCreate.cjs +1 -1
  16. package/dist/cjs/client/components/management/AgentCreate/AgentCreate.cjs.map +1 -0
  17. package/dist/cjs/client/components/{admin → management}/AgentDetails/AgentDetails.cjs +1 -1
  18. package/dist/cjs/client/components/management/AgentDetails/AgentDetails.cjs.map +1 -0
  19. package/dist/cjs/client/components/{admin → management}/AgentList/AgentList.cjs +1 -1
  20. package/dist/cjs/client/components/management/AgentList/AgentList.cjs.map +1 -0
  21. package/dist/cjs/client/components/{admin → management}/ApplicationCreate/ApplicationCreate.cjs +1 -1
  22. package/dist/cjs/client/components/management/ApplicationCreate/ApplicationCreate.cjs.map +1 -0
  23. package/dist/cjs/client/components/{admin → management}/ApplicationDetails/ApplicationDetails.cjs +1 -1
  24. package/dist/cjs/client/components/management/ApplicationDetails/ApplicationDetails.cjs.map +1 -0
  25. package/dist/cjs/client/components/{admin → management}/ApplicationList/ApplicationList.cjs +1 -1
  26. package/dist/cjs/client/components/management/ApplicationList/ApplicationList.cjs.map +1 -0
  27. package/dist/cjs/client/components/{admin → management}/GroupCreate/GroupCreate.cjs +1 -1
  28. package/dist/cjs/client/components/management/GroupCreate/GroupCreate.cjs.map +1 -0
  29. package/dist/cjs/client/components/management/GroupDetails/GroupDetails.cjs +28 -0
  30. package/dist/cjs/client/components/management/GroupDetails/GroupDetails.cjs.map +1 -0
  31. package/dist/cjs/client/components/{admin → management}/GroupList/GroupList.cjs +1 -1
  32. package/dist/cjs/client/components/management/GroupList/GroupList.cjs.map +1 -0
  33. package/dist/cjs/client/components/{admin → management}/GroupMembers/GroupMembers.cjs +1 -1
  34. package/dist/cjs/client/components/management/GroupMembers/GroupMembers.cjs.map +1 -0
  35. package/dist/cjs/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.cjs +28 -0
  36. package/dist/cjs/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.cjs.map +1 -0
  37. package/dist/cjs/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.cjs +28 -0
  38. package/dist/cjs/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.cjs.map +1 -0
  39. package/dist/cjs/client/components/management/OrganizationUnitList/OrganizationUnitList.cjs +28 -0
  40. package/dist/cjs/client/components/management/OrganizationUnitList/OrganizationUnitList.cjs.map +1 -0
  41. package/dist/cjs/client/components/management/ProjectCreate/ProjectCreate.cjs +28 -0
  42. package/dist/cjs/client/components/management/ProjectCreate/ProjectCreate.cjs.map +1 -0
  43. package/dist/cjs/client/components/management/ProjectDetails/ProjectDetails.cjs +28 -0
  44. package/dist/cjs/client/components/management/ProjectDetails/ProjectDetails.cjs.map +1 -0
  45. package/dist/cjs/client/components/management/ProjectList/ProjectList.cjs +28 -0
  46. package/dist/cjs/client/components/management/ProjectList/ProjectList.cjs.map +1 -0
  47. package/dist/cjs/client/components/management/ProjectSwitcher/ProjectSwitcher.cjs +30 -0
  48. package/dist/cjs/client/components/management/ProjectSwitcher/ProjectSwitcher.cjs.map +1 -0
  49. package/dist/cjs/client/components/{admin → management}/RoleAssignments/RoleAssignments.cjs +1 -1
  50. package/dist/cjs/client/components/management/RoleAssignments/RoleAssignments.cjs.map +1 -0
  51. package/dist/cjs/client/components/{admin → management}/RoleCreate/RoleCreate.cjs +1 -1
  52. package/dist/cjs/client/components/management/RoleCreate/RoleCreate.cjs.map +1 -0
  53. package/dist/cjs/client/components/management/RoleDetails/RoleDetails.cjs +28 -0
  54. package/dist/cjs/client/components/management/RoleDetails/RoleDetails.cjs.map +1 -0
  55. package/dist/cjs/client/components/{admin → management}/RoleList/RoleList.cjs +1 -1
  56. package/dist/cjs/client/components/management/RoleList/RoleList.cjs.map +1 -0
  57. package/dist/cjs/client/components/{admin → management}/RolePermissions/RolePermissions.cjs +1 -1
  58. package/dist/cjs/client/components/management/RolePermissions/RolePermissions.cjs.map +1 -0
  59. package/dist/cjs/client/components/management/SharingPolicies/SharingPolicies.cjs +28 -0
  60. package/dist/cjs/client/components/management/SharingPolicies/SharingPolicies.cjs.map +1 -0
  61. package/dist/cjs/client/components/{admin → management}/UserCreate/UserCreate.cjs +1 -1
  62. package/dist/cjs/client/components/management/UserCreate/UserCreate.cjs.map +1 -0
  63. package/dist/cjs/client/components/{admin → management}/UserDetails/UserDetails.cjs +1 -1
  64. package/dist/cjs/client/components/management/UserDetails/UserDetails.cjs.map +1 -0
  65. package/dist/cjs/client/components/{admin → management}/UserList/UserList.cjs +1 -1
  66. package/dist/cjs/client/components/management/UserList/UserList.cjs.map +1 -0
  67. package/dist/cjs/client/contexts/ThunderID/ThunderIDProvider.cjs +65 -2
  68. package/dist/cjs/client/contexts/ThunderID/ThunderIDProvider.cjs.map +1 -1
  69. package/dist/cjs/client/index.cjs +29 -17
  70. package/dist/cjs/index.cjs +100 -16
  71. package/dist/cjs/server/actions/account/getAccessibleOrganizationUnitsAction.cjs +53 -0
  72. package/dist/cjs/server/actions/account/getAccessibleOrganizationUnitsAction.cjs.map +1 -0
  73. package/dist/cjs/server/actions/account/getCurrentOrganizationUnitAction.cjs +31 -0
  74. package/dist/cjs/server/actions/account/getCurrentOrganizationUnitAction.cjs.map +1 -0
  75. package/dist/cjs/server/actions/auth/executeSelfFlowAction.cjs +47 -0
  76. package/dist/cjs/server/actions/auth/executeSelfFlowAction.cjs.map +1 -0
  77. package/dist/cjs/server/actions/auth/switchOrganizationUnitAction.cjs +85 -0
  78. package/dist/cjs/server/actions/auth/switchOrganizationUnitAction.cjs.map +1 -0
  79. package/dist/cjs/server/thunderid.cjs +16 -0
  80. package/dist/cjs/server/thunderid.cjs.map +1 -1
  81. package/dist/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.d.ts +24 -0
  82. package/dist/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.d.ts.map +1 -0
  83. package/dist/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.js +112 -0
  84. package/dist/client/components/account/OrganizationUnitSwitcher/OrganizationUnitSwitcher.js.map +1 -0
  85. package/dist/client/components/account/UserProfile/UserProfile.d.ts +7 -1
  86. package/dist/client/components/account/UserProfile/UserProfile.d.ts.map +1 -1
  87. package/dist/client/components/account/UserProfile/UserProfile.js +12 -2
  88. package/dist/client/components/account/UserProfile/UserProfile.js.map +1 -1
  89. package/dist/client/components/account/VerifyAttribute/VerifyAttribute.d.ts +41 -0
  90. package/dist/client/components/account/VerifyAttribute/VerifyAttribute.d.ts.map +1 -0
  91. package/dist/client/components/account/VerifyAttribute/VerifyAttribute.js +75 -0
  92. package/dist/client/components/account/VerifyAttribute/VerifyAttribute.js.map +1 -0
  93. package/dist/client/components/auth/SignIn/SignIn.d.ts +7 -1
  94. package/dist/client/components/auth/SignIn/SignIn.d.ts.map +1 -1
  95. package/dist/client/components/auth/SignIn/SignIn.js +3 -2
  96. package/dist/client/components/auth/SignIn/SignIn.js.map +1 -1
  97. package/dist/client/components/management/AgentCreate/AgentCreate.d.ts.map +1 -0
  98. package/dist/client/components/{admin → management}/AgentCreate/AgentCreate.js +1 -1
  99. package/dist/client/components/management/AgentCreate/AgentCreate.js.map +1 -0
  100. package/dist/client/components/management/AgentDetails/AgentDetails.d.ts.map +1 -0
  101. package/dist/client/components/{admin → management}/AgentDetails/AgentDetails.js +1 -1
  102. package/dist/client/components/management/AgentDetails/AgentDetails.js.map +1 -0
  103. package/dist/client/components/management/AgentList/AgentList.d.ts.map +1 -0
  104. package/dist/client/components/{admin → management}/AgentList/AgentList.js +1 -1
  105. package/dist/client/components/management/AgentList/AgentList.js.map +1 -0
  106. package/dist/client/components/management/ApplicationCreate/ApplicationCreate.d.ts.map +1 -0
  107. package/dist/client/components/{admin → management}/ApplicationCreate/ApplicationCreate.js +1 -1
  108. package/dist/client/components/management/ApplicationCreate/ApplicationCreate.js.map +1 -0
  109. package/dist/client/components/management/ApplicationDetails/ApplicationDetails.d.ts.map +1 -0
  110. package/dist/client/components/{admin → management}/ApplicationDetails/ApplicationDetails.js +1 -1
  111. package/dist/client/components/management/ApplicationDetails/ApplicationDetails.js.map +1 -0
  112. package/dist/client/components/management/ApplicationList/ApplicationList.d.ts.map +1 -0
  113. package/dist/client/components/{admin → management}/ApplicationList/ApplicationList.js +1 -1
  114. package/dist/client/components/management/ApplicationList/ApplicationList.js.map +1 -0
  115. package/dist/client/components/management/GroupCreate/GroupCreate.d.ts.map +1 -0
  116. package/dist/client/components/{admin → management}/GroupCreate/GroupCreate.js +1 -1
  117. package/dist/client/components/management/GroupCreate/GroupCreate.js.map +1 -0
  118. package/dist/client/components/management/GroupDetails/GroupDetails.d.ts +17 -0
  119. package/dist/client/components/management/GroupDetails/GroupDetails.d.ts.map +1 -0
  120. package/dist/client/components/management/GroupDetails/GroupDetails.js +25 -0
  121. package/dist/client/components/management/GroupDetails/GroupDetails.js.map +1 -0
  122. package/dist/client/components/management/GroupList/GroupList.d.ts.map +1 -0
  123. package/dist/client/components/{admin → management}/GroupList/GroupList.js +1 -1
  124. package/dist/client/components/management/GroupList/GroupList.js.map +1 -0
  125. package/dist/client/components/management/GroupMembers/GroupMembers.d.ts.map +1 -0
  126. package/dist/client/components/{admin → management}/GroupMembers/GroupMembers.js +1 -1
  127. package/dist/client/components/management/GroupMembers/GroupMembers.js.map +1 -0
  128. package/dist/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.d.ts +17 -0
  129. package/dist/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.d.ts.map +1 -0
  130. package/dist/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.js +25 -0
  131. package/dist/client/components/management/OrganizationUnitCreate/OrganizationUnitCreate.js.map +1 -0
  132. package/dist/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.d.ts +17 -0
  133. package/dist/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.d.ts.map +1 -0
  134. package/dist/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.js +25 -0
  135. package/dist/client/components/management/OrganizationUnitDetails/OrganizationUnitDetails.js.map +1 -0
  136. package/dist/client/components/management/OrganizationUnitList/OrganizationUnitList.d.ts +17 -0
  137. package/dist/client/components/management/OrganizationUnitList/OrganizationUnitList.d.ts.map +1 -0
  138. package/dist/client/components/management/OrganizationUnitList/OrganizationUnitList.js +25 -0
  139. package/dist/client/components/management/OrganizationUnitList/OrganizationUnitList.js.map +1 -0
  140. package/dist/client/components/management/ProjectCreate/ProjectCreate.d.ts +17 -0
  141. package/dist/client/components/management/ProjectCreate/ProjectCreate.d.ts.map +1 -0
  142. package/dist/client/components/management/ProjectCreate/ProjectCreate.js +25 -0
  143. package/dist/client/components/management/ProjectCreate/ProjectCreate.js.map +1 -0
  144. package/dist/client/components/management/ProjectDetails/ProjectDetails.d.ts +17 -0
  145. package/dist/client/components/management/ProjectDetails/ProjectDetails.d.ts.map +1 -0
  146. package/dist/client/components/management/ProjectDetails/ProjectDetails.js +25 -0
  147. package/dist/client/components/management/ProjectDetails/ProjectDetails.js.map +1 -0
  148. package/dist/client/components/management/ProjectList/ProjectList.d.ts +17 -0
  149. package/dist/client/components/management/ProjectList/ProjectList.d.ts.map +1 -0
  150. package/dist/client/components/management/ProjectList/ProjectList.js +25 -0
  151. package/dist/client/components/management/ProjectList/ProjectList.js.map +1 -0
  152. package/dist/client/components/management/ProjectSwitcher/ProjectSwitcher.d.ts +19 -0
  153. package/dist/client/components/management/ProjectSwitcher/ProjectSwitcher.d.ts.map +1 -0
  154. package/dist/client/components/management/ProjectSwitcher/ProjectSwitcher.js +27 -0
  155. package/dist/client/components/management/ProjectSwitcher/ProjectSwitcher.js.map +1 -0
  156. package/dist/client/components/management/RoleAssignments/RoleAssignments.d.ts.map +1 -0
  157. package/dist/client/components/{admin → management}/RoleAssignments/RoleAssignments.js +1 -1
  158. package/dist/client/components/management/RoleAssignments/RoleAssignments.js.map +1 -0
  159. package/dist/client/components/management/RoleCreate/RoleCreate.d.ts.map +1 -0
  160. package/dist/client/components/{admin → management}/RoleCreate/RoleCreate.js +1 -1
  161. package/dist/client/components/management/RoleCreate/RoleCreate.js.map +1 -0
  162. package/dist/client/components/management/RoleDetails/RoleDetails.d.ts +17 -0
  163. package/dist/client/components/management/RoleDetails/RoleDetails.d.ts.map +1 -0
  164. package/dist/client/components/management/RoleDetails/RoleDetails.js +25 -0
  165. package/dist/client/components/management/RoleDetails/RoleDetails.js.map +1 -0
  166. package/dist/client/components/management/RoleList/RoleList.d.ts.map +1 -0
  167. package/dist/client/components/{admin → management}/RoleList/RoleList.js +1 -1
  168. package/dist/client/components/management/RoleList/RoleList.js.map +1 -0
  169. package/dist/client/components/management/RolePermissions/RolePermissions.d.ts.map +1 -0
  170. package/dist/client/components/{admin → management}/RolePermissions/RolePermissions.js +1 -1
  171. package/dist/client/components/management/RolePermissions/RolePermissions.js.map +1 -0
  172. package/dist/client/components/management/SharingPolicies/SharingPolicies.d.ts +17 -0
  173. package/dist/client/components/management/SharingPolicies/SharingPolicies.d.ts.map +1 -0
  174. package/dist/client/components/management/SharingPolicies/SharingPolicies.js +25 -0
  175. package/dist/client/components/management/SharingPolicies/SharingPolicies.js.map +1 -0
  176. package/dist/client/components/management/UserCreate/UserCreate.d.ts.map +1 -0
  177. package/dist/client/components/{admin → management}/UserCreate/UserCreate.js +1 -1
  178. package/dist/client/components/management/UserCreate/UserCreate.js.map +1 -0
  179. package/dist/client/components/management/UserDetails/UserDetails.d.ts.map +1 -0
  180. package/dist/client/components/{admin → management}/UserDetails/UserDetails.js +1 -1
  181. package/dist/client/components/management/UserDetails/UserDetails.js.map +1 -0
  182. package/dist/client/components/management/UserList/UserList.d.ts.map +1 -0
  183. package/dist/client/components/{admin → management}/UserList/UserList.js +1 -1
  184. package/dist/client/components/management/UserList/UserList.js.map +1 -0
  185. package/dist/client/contexts/ThunderID/ThunderIDProvider.d.ts.map +1 -1
  186. package/dist/client/contexts/ThunderID/ThunderIDProvider.js +67 -4
  187. package/dist/client/contexts/ThunderID/ThunderIDProvider.js.map +1 -1
  188. package/dist/client/index.d.ts +57 -33
  189. package/dist/client/index.d.ts.map +1 -1
  190. package/dist/client/index.js +29 -17
  191. package/dist/client/management.d.ts +3 -0
  192. package/dist/client/management.d.ts.map +1 -0
  193. package/dist/client/management.js +6 -0
  194. package/dist/index.js +30 -18
  195. package/dist/server/actions/account/getAccessibleOrganizationUnitsAction.d.ts +20 -0
  196. package/dist/server/actions/account/getAccessibleOrganizationUnitsAction.d.ts.map +1 -0
  197. package/dist/server/actions/account/getAccessibleOrganizationUnitsAction.js +51 -0
  198. package/dist/server/actions/account/getAccessibleOrganizationUnitsAction.js.map +1 -0
  199. package/dist/server/actions/account/getCurrentOrganizationUnitAction.d.ts +10 -0
  200. package/dist/server/actions/account/getCurrentOrganizationUnitAction.d.ts.map +1 -0
  201. package/dist/server/actions/account/getCurrentOrganizationUnitAction.js +28 -0
  202. package/dist/server/actions/account/getCurrentOrganizationUnitAction.js.map +1 -0
  203. package/dist/server/actions/auth/executeSelfFlowAction.d.ts +20 -0
  204. package/dist/server/actions/auth/executeSelfFlowAction.d.ts.map +1 -0
  205. package/dist/server/actions/auth/executeSelfFlowAction.js +45 -0
  206. package/dist/server/actions/auth/executeSelfFlowAction.js.map +1 -0
  207. package/dist/server/actions/auth/switchOrganizationUnitAction.d.ts +30 -0
  208. package/dist/server/actions/auth/switchOrganizationUnitAction.d.ts.map +1 -0
  209. package/dist/server/actions/auth/switchOrganizationUnitAction.js +82 -0
  210. package/dist/server/actions/auth/switchOrganizationUnitAction.js.map +1 -0
  211. package/dist/server/thunderid.d.ts +2 -1
  212. package/dist/server/thunderid.d.ts.map +1 -1
  213. package/dist/server/thunderid.js +14 -0
  214. package/dist/server/thunderid.js.map +1 -1
  215. package/package.json +3 -3
  216. package/dist/cjs/client/components/admin/AgentCreate/AgentCreate.cjs.map +0 -1
  217. package/dist/cjs/client/components/admin/AgentDetails/AgentDetails.cjs.map +0 -1
  218. package/dist/cjs/client/components/admin/AgentList/AgentList.cjs.map +0 -1
  219. package/dist/cjs/client/components/admin/ApplicationCreate/ApplicationCreate.cjs.map +0 -1
  220. package/dist/cjs/client/components/admin/ApplicationDetails/ApplicationDetails.cjs.map +0 -1
  221. package/dist/cjs/client/components/admin/ApplicationList/ApplicationList.cjs.map +0 -1
  222. package/dist/cjs/client/components/admin/GroupCreate/GroupCreate.cjs.map +0 -1
  223. package/dist/cjs/client/components/admin/GroupList/GroupList.cjs.map +0 -1
  224. package/dist/cjs/client/components/admin/GroupMembers/GroupMembers.cjs.map +0 -1
  225. package/dist/cjs/client/components/admin/RoleAssignments/RoleAssignments.cjs.map +0 -1
  226. package/dist/cjs/client/components/admin/RoleCreate/RoleCreate.cjs.map +0 -1
  227. package/dist/cjs/client/components/admin/RoleList/RoleList.cjs.map +0 -1
  228. package/dist/cjs/client/components/admin/RolePermissions/RolePermissions.cjs.map +0 -1
  229. package/dist/cjs/client/components/admin/UserCreate/UserCreate.cjs.map +0 -1
  230. package/dist/cjs/client/components/admin/UserDetails/UserDetails.cjs.map +0 -1
  231. package/dist/cjs/client/components/admin/UserList/UserList.cjs.map +0 -1
  232. package/dist/client/admin.d.ts +0 -3
  233. package/dist/client/admin.d.ts.map +0 -1
  234. package/dist/client/admin.js +0 -6
  235. package/dist/client/components/admin/AgentCreate/AgentCreate.d.ts.map +0 -1
  236. package/dist/client/components/admin/AgentCreate/AgentCreate.js.map +0 -1
  237. package/dist/client/components/admin/AgentDetails/AgentDetails.d.ts.map +0 -1
  238. package/dist/client/components/admin/AgentDetails/AgentDetails.js.map +0 -1
  239. package/dist/client/components/admin/AgentList/AgentList.d.ts.map +0 -1
  240. package/dist/client/components/admin/AgentList/AgentList.js.map +0 -1
  241. package/dist/client/components/admin/ApplicationCreate/ApplicationCreate.d.ts.map +0 -1
  242. package/dist/client/components/admin/ApplicationCreate/ApplicationCreate.js.map +0 -1
  243. package/dist/client/components/admin/ApplicationDetails/ApplicationDetails.d.ts.map +0 -1
  244. package/dist/client/components/admin/ApplicationDetails/ApplicationDetails.js.map +0 -1
  245. package/dist/client/components/admin/ApplicationList/ApplicationList.d.ts.map +0 -1
  246. package/dist/client/components/admin/ApplicationList/ApplicationList.js.map +0 -1
  247. package/dist/client/components/admin/GroupCreate/GroupCreate.d.ts.map +0 -1
  248. package/dist/client/components/admin/GroupCreate/GroupCreate.js.map +0 -1
  249. package/dist/client/components/admin/GroupList/GroupList.d.ts.map +0 -1
  250. package/dist/client/components/admin/GroupList/GroupList.js.map +0 -1
  251. package/dist/client/components/admin/GroupMembers/GroupMembers.d.ts.map +0 -1
  252. package/dist/client/components/admin/GroupMembers/GroupMembers.js.map +0 -1
  253. package/dist/client/components/admin/RoleAssignments/RoleAssignments.d.ts.map +0 -1
  254. package/dist/client/components/admin/RoleAssignments/RoleAssignments.js.map +0 -1
  255. package/dist/client/components/admin/RoleCreate/RoleCreate.d.ts.map +0 -1
  256. package/dist/client/components/admin/RoleCreate/RoleCreate.js.map +0 -1
  257. package/dist/client/components/admin/RoleList/RoleList.d.ts.map +0 -1
  258. package/dist/client/components/admin/RoleList/RoleList.js.map +0 -1
  259. package/dist/client/components/admin/RolePermissions/RolePermissions.d.ts.map +0 -1
  260. package/dist/client/components/admin/RolePermissions/RolePermissions.js.map +0 -1
  261. package/dist/client/components/admin/UserCreate/UserCreate.d.ts.map +0 -1
  262. package/dist/client/components/admin/UserCreate/UserCreate.js.map +0 -1
  263. package/dist/client/components/admin/UserDetails/UserDetails.d.ts.map +0 -1
  264. package/dist/client/components/admin/UserDetails/UserDetails.js.map +0 -1
  265. package/dist/client/components/admin/UserList/UserList.d.ts.map +0 -1
  266. package/dist/client/components/admin/UserList/UserList.js.map +0 -1
  267. /package/dist/cjs/client/{admin.cjs → management.cjs} +0 -0
  268. /package/dist/client/components/{admin → management}/AgentCreate/AgentCreate.d.ts +0 -0
  269. /package/dist/client/components/{admin → management}/AgentDetails/AgentDetails.d.ts +0 -0
  270. /package/dist/client/components/{admin → management}/AgentList/AgentList.d.ts +0 -0
  271. /package/dist/client/components/{admin → management}/ApplicationCreate/ApplicationCreate.d.ts +0 -0
  272. /package/dist/client/components/{admin → management}/ApplicationDetails/ApplicationDetails.d.ts +0 -0
  273. /package/dist/client/components/{admin → management}/ApplicationList/ApplicationList.d.ts +0 -0
  274. /package/dist/client/components/{admin → management}/GroupCreate/GroupCreate.d.ts +0 -0
  275. /package/dist/client/components/{admin → management}/GroupList/GroupList.d.ts +0 -0
  276. /package/dist/client/components/{admin → management}/GroupMembers/GroupMembers.d.ts +0 -0
  277. /package/dist/client/components/{admin → management}/RoleAssignments/RoleAssignments.d.ts +0 -0
  278. /package/dist/client/components/{admin → management}/RoleCreate/RoleCreate.d.ts +0 -0
  279. /package/dist/client/components/{admin → management}/RoleList/RoleList.d.ts +0 -0
  280. /package/dist/client/components/{admin → management}/RolePermissions/RolePermissions.d.ts +0 -0
  281. /package/dist/client/components/{admin → management}/UserCreate/UserCreate.d.ts +0 -0
  282. /package/dist/client/components/{admin → management}/UserDetails/UserDetails.d.ts +0 -0
  283. /package/dist/client/components/{admin → management}/UserList/UserList.d.ts +0 -0
@@ -0,0 +1,17 @@
1
+ import { ProjectListProps as ReactProjectListProps } from '@thunderid/react';
2
+ import { FC } from 'react';
3
+ export type ProjectListProps = ReactProjectListProps;
4
+ /**
5
+ * Lists the projects, a page at a time. Projects are served by the control plane only.
6
+ *
7
+ * Management requests go through a server action with the signed-in user's server-held session, so
8
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
9
+ *
10
+ * @example
11
+ * ```tsx
12
+ * <ProjectList onSelect={(project) => router.push(`/admin/projects/${project.id}`)} />
13
+ * ```
14
+ */
15
+ declare const ProjectList: FC<ProjectListProps>;
16
+ export default ProjectList;
17
+ //# sourceMappingURL=ProjectList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProjectList.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/ProjectList/ProjectList.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAkC,gBAAgB,IAAI,qBAAqB,EAAC,MAAM,kBAAkB,CAAC;AAC5G,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAErD;;;;;;;;;;GAUG;AACH,QAAA,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CAA8E,CAAC;AAIrH,eAAe,WAAW,CAAC"}
@@ -0,0 +1,25 @@
1
+ 'use client';
2
+
3
+
4
+ import { ProjectList } from "@thunderid/react";
5
+ import { jsx } from "react/jsx-runtime";
6
+
7
+ //#region src/client/components/management/ProjectList/ProjectList.tsx
8
+ /**
9
+ * Lists the projects, a page at a time. Projects are served by the control plane only.
10
+ *
11
+ * Management requests go through a server action with the signed-in user's server-held session, so
12
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
13
+ *
14
+ * @example
15
+ * ```tsx
16
+ * <ProjectList onSelect={(project) => router.push(`/admin/projects/${project.id}`)} />
17
+ * ```
18
+ */
19
+ const ProjectList$1 = (props) => /* @__PURE__ */ jsx(ProjectList, { ...props });
20
+ ProjectList$1.displayName = "ProjectList";
21
+ var ProjectList_default = ProjectList$1;
22
+
23
+ //#endregion
24
+ export { ProjectList_default as default };
25
+ //# sourceMappingURL=ProjectList.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProjectList.js","names":["ProjectList: FC<ProjectListProps>","ReactProjectList","ProjectList"],"sources":["../../../../../src/client/components/management/ProjectList/ProjectList.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {ProjectList as ReactProjectList, ProjectListProps as ReactProjectListProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type ProjectListProps = ReactProjectListProps;\n\n/**\n * Lists the projects, a page at a time. Projects are served by the control plane only.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <ProjectList onSelect={(project) => router.push(`/admin/projects/${project.id}`)} />\n * ```\n */\nconst ProjectList: FC<ProjectListProps> = (props: ProjectListProps): ReactElement => <ReactProjectList {...props} />;\n\nProjectList.displayName = 'ProjectList';\n\nexport default ProjectList;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,iBAAqC,UAA0C,oBAACC,eAAiB,GAAI,QAAS;AAEpH,cAAY,cAAc;AAE1B,0BAAeC"}
@@ -0,0 +1,19 @@
1
+ import { ProjectSwitcherProps as ReactProjectSwitcherProps } from '@thunderid/react';
2
+ import { FC } from 'react';
3
+ export type ProjectSwitcherProps = ReactProjectSwitcherProps;
4
+ /**
5
+ * Lets the user choose the current project. The choice is client-side context kept in the browser, not a sign-in: `useThunderID()` exposes it as `currentProject`.
6
+ * `ApplicationList` and `AgentList` list the current project, and `ApplicationCreate` and `AgentCreate` place new
7
+ * resources in it when no organization unit is given.
8
+ *
9
+ * Management requests go through a server action with the signed-in user's server-held session, so
10
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
11
+ *
12
+ * @example
13
+ * ```tsx
14
+ * <ProjectSwitcher onSelect={(project) => router.refresh()} />
15
+ * ```
16
+ */
17
+ declare const ProjectSwitcher: FC<ProjectSwitcherProps>;
18
+ export default ProjectSwitcher;
19
+ //# sourceMappingURL=ProjectSwitcher.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProjectSwitcher.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/ProjectSwitcher/ProjectSwitcher.tsx"],"names":[],"mappings":"AAKA,OAAO,EAEL,oBAAoB,IAAI,yBAAyB,EAClD,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,oBAAoB,GAAG,yBAAyB,CAAC;AAE7D;;;;;;;;;;;;GAYG;AACH,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAE7C,CAAC;AAIF,eAAe,eAAe,CAAC"}
@@ -0,0 +1,27 @@
1
+ 'use client';
2
+
3
+
4
+ import { ProjectSwitcher } from "@thunderid/react";
5
+ import { jsx } from "react/jsx-runtime";
6
+
7
+ //#region src/client/components/management/ProjectSwitcher/ProjectSwitcher.tsx
8
+ /**
9
+ * Lets the user choose the current project. The choice is client-side context kept in the browser, not a sign-in: `useThunderID()` exposes it as `currentProject`.
10
+ * `ApplicationList` and `AgentList` list the current project, and `ApplicationCreate` and `AgentCreate` place new
11
+ * resources in it when no organization unit is given.
12
+ *
13
+ * Management requests go through a server action with the signed-in user's server-held session, so
14
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
15
+ *
16
+ * @example
17
+ * ```tsx
18
+ * <ProjectSwitcher onSelect={(project) => router.refresh()} />
19
+ * ```
20
+ */
21
+ const ProjectSwitcher$1 = (props) => /* @__PURE__ */ jsx(ProjectSwitcher, { ...props });
22
+ ProjectSwitcher$1.displayName = "ProjectSwitcher";
23
+ var ProjectSwitcher_default = ProjectSwitcher$1;
24
+
25
+ //#endregion
26
+ export { ProjectSwitcher_default as default };
27
+ //# sourceMappingURL=ProjectSwitcher.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProjectSwitcher.js","names":["ProjectSwitcher: FC<ProjectSwitcherProps>","ReactProjectSwitcher","ProjectSwitcher"],"sources":["../../../../../src/client/components/management/ProjectSwitcher/ProjectSwitcher.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {\n ProjectSwitcher as ReactProjectSwitcher,\n ProjectSwitcherProps as ReactProjectSwitcherProps,\n} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type ProjectSwitcherProps = ReactProjectSwitcherProps;\n\n/**\n * Lets the user choose the current project. The choice is client-side context kept in the browser, not a sign-in: `useThunderID()` exposes it as `currentProject`.\n * `ApplicationList` and `AgentList` list the current project, and `ApplicationCreate` and `AgentCreate` place new\n * resources in it when no organization unit is given.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <ProjectSwitcher onSelect={(project) => router.refresh()} />\n * ```\n */\nconst ProjectSwitcher: FC<ProjectSwitcherProps> = (props: ProjectSwitcherProps): ReactElement => (\n <ReactProjectSwitcher {...props} />\n);\n\nProjectSwitcher.displayName = 'ProjectSwitcher';\n\nexport default ProjectSwitcher;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AA0BA,MAAMA,qBAA6C,UACjD,oBAACC,mBAAqB,GAAI,QAAS;AAGrC,kBAAgB,cAAc;AAE9B,8BAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleAssignments.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/RoleAssignments/RoleAssignments.tsx"],"names":[],"mappings":"AAKA,OAAO,EAEL,oBAAoB,IAAI,yBAAyB,EAClD,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,oBAAoB,GAAG,yBAAyB,CAAC;AAE7D;;;;;;;;;;GAUG;AACH,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAE7C,CAAC;AAIF,eAAe,eAAe,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { RoleAssignments } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/RoleAssignments/RoleAssignments.tsx
7
+ //#region src/client/components/management/RoleAssignments/RoleAssignments.tsx
8
8
  /**
9
9
  * Lists a role's assignments and assigns or unassigns users, groups and agents.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleAssignments.js","names":["RoleAssignments: FC<RoleAssignmentsProps>","ReactRoleAssignments","RoleAssignments"],"sources":["../../../../../src/client/components/management/RoleAssignments/RoleAssignments.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {\n RoleAssignments as ReactRoleAssignments,\n RoleAssignmentsProps as ReactRoleAssignmentsProps,\n} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type RoleAssignmentsProps = ReactRoleAssignmentsProps;\n\n/**\n * Lists a role's assignments and assigns or unassigns users, groups and agents.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <RoleAssignments roleId={id} />\n * ```\n */\nconst RoleAssignments: FC<RoleAssignmentsProps> = (props: RoleAssignmentsProps): ReactElement => (\n <ReactRoleAssignments {...props} />\n);\n\nRoleAssignments.displayName = 'RoleAssignments';\n\nexport default RoleAssignments;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAwBA,MAAMA,qBAA6C,UACjD,oBAACC,mBAAqB,GAAI,QAAS;AAGrC,kBAAgB,cAAc;AAE9B,8BAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleCreate.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/RoleCreate/RoleCreate.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAgC,eAAe,IAAI,oBAAoB,EAAC,MAAM,kBAAkB,CAAC;AACxG,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,eAAe,GAAG,oBAAoB,CAAC;AAEnD;;;;;;;;;;GAUG;AACH,QAAA,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAA4E,CAAC;AAIjH,eAAe,UAAU,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { RoleCreate } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/RoleCreate/RoleCreate.tsx
7
+ //#region src/client/components/management/RoleCreate/RoleCreate.tsx
8
8
  /**
9
9
  * Creates a role.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleCreate.js","names":["RoleCreate: FC<RoleCreateProps>","ReactRoleCreate","RoleCreate"],"sources":["../../../../../src/client/components/management/RoleCreate/RoleCreate.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {RoleCreate as ReactRoleCreate, RoleCreateProps as ReactRoleCreateProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type RoleCreateProps = ReactRoleCreateProps;\n\n/**\n * Creates a role.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <RoleCreate onCreated={(role) => router.push(`/admin/roles/${role.id}`)} />\n * ```\n */\nconst RoleCreate: FC<RoleCreateProps> = (props: RoleCreateProps): ReactElement => <ReactRoleCreate {...props} />;\n\nRoleCreate.displayName = 'RoleCreate';\n\nexport default RoleCreate;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,gBAAmC,UAAyC,oBAACC,cAAgB,GAAI,QAAS;AAEhH,aAAW,cAAc;AAEzB,yBAAeC"}
@@ -0,0 +1,17 @@
1
+ import { RoleDetailsProps as ReactRoleDetailsProps } from '@thunderid/react';
2
+ import { FC } from 'react';
3
+ export type RoleDetailsProps = ReactRoleDetailsProps;
4
+ /**
5
+ * Shows a role with its permissions and assignments, and optionally manages the assignments and deletes the role.
6
+ *
7
+ * Management requests go through a server action with the signed-in user's server-held session, so
8
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
9
+ *
10
+ * @example
11
+ * ```tsx
12
+ * <RoleDetails roleId={id} editable deletable onDeleted={() => router.push('/admin/roles')} />
13
+ * ```
14
+ */
15
+ declare const RoleDetails: FC<RoleDetailsProps>;
16
+ export default RoleDetails;
17
+ //# sourceMappingURL=RoleDetails.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleDetails.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/RoleDetails/RoleDetails.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAkC,gBAAgB,IAAI,qBAAqB,EAAC,MAAM,kBAAkB,CAAC;AAC5G,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAErD;;;;;;;;;;GAUG;AACH,QAAA,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CAA8E,CAAC;AAIrH,eAAe,WAAW,CAAC"}
@@ -0,0 +1,25 @@
1
+ 'use client';
2
+
3
+
4
+ import { RoleDetails } from "@thunderid/react";
5
+ import { jsx } from "react/jsx-runtime";
6
+
7
+ //#region src/client/components/management/RoleDetails/RoleDetails.tsx
8
+ /**
9
+ * Shows a role with its permissions and assignments, and optionally manages the assignments and deletes the role.
10
+ *
11
+ * Management requests go through a server action with the signed-in user's server-held session, so
12
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
13
+ *
14
+ * @example
15
+ * ```tsx
16
+ * <RoleDetails roleId={id} editable deletable onDeleted={() => router.push('/admin/roles')} />
17
+ * ```
18
+ */
19
+ const RoleDetails$1 = (props) => /* @__PURE__ */ jsx(RoleDetails, { ...props });
20
+ RoleDetails$1.displayName = "RoleDetails";
21
+ var RoleDetails_default = RoleDetails$1;
22
+
23
+ //#endregion
24
+ export { RoleDetails_default as default };
25
+ //# sourceMappingURL=RoleDetails.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleDetails.js","names":["RoleDetails: FC<RoleDetailsProps>","ReactRoleDetails","RoleDetails"],"sources":["../../../../../src/client/components/management/RoleDetails/RoleDetails.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {RoleDetails as ReactRoleDetails, RoleDetailsProps as ReactRoleDetailsProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type RoleDetailsProps = ReactRoleDetailsProps;\n\n/**\n * Shows a role with its permissions and assignments, and optionally manages the assignments and deletes the role.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <RoleDetails roleId={id} editable deletable onDeleted={() => router.push('/admin/roles')} />\n * ```\n */\nconst RoleDetails: FC<RoleDetailsProps> = (props: RoleDetailsProps): ReactElement => <ReactRoleDetails {...props} />;\n\nRoleDetails.displayName = 'RoleDetails';\n\nexport default RoleDetails;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,iBAAqC,UAA0C,oBAACC,eAAiB,GAAI,QAAS;AAEpH,cAAY,cAAc;AAE1B,0BAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleList.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/RoleList/RoleList.tsx"],"names":[],"mappings":"AAKA,OAAO,EAA4B,aAAa,IAAI,kBAAkB,EAAC,MAAM,kBAAkB,CAAC;AAChG,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,aAAa,GAAG,kBAAkB,CAAC;AAE/C;;;;;;;;;;GAUG;AACH,QAAA,MAAM,QAAQ,EAAE,EAAE,CAAC,aAAa,CAAwE,CAAC;AAIzG,eAAe,QAAQ,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { RoleList } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/RoleList/RoleList.tsx
7
+ //#region src/client/components/management/RoleList/RoleList.tsx
8
8
  /**
9
9
  * Lists roles, a page at a time.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RoleList.js","names":["RoleList: FC<RoleListProps>","ReactRoleList","RoleList"],"sources":["../../../../../src/client/components/management/RoleList/RoleList.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {RoleList as ReactRoleList, RoleListProps as ReactRoleListProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type RoleListProps = ReactRoleListProps;\n\n/**\n * Lists roles, a page at a time.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <RoleList onSelect={(role) => router.push(`/admin/roles/${role.id}`)} />\n * ```\n */\nconst RoleList: FC<RoleListProps> = (props: RoleListProps): ReactElement => <ReactRoleList {...props} />;\n\nRoleList.displayName = 'RoleList';\n\nexport default RoleList;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,cAA+B,UAAuC,oBAACC,YAAc,GAAI,QAAS;AAExG,WAAS,cAAc;AAEvB,uBAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RolePermissions.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/RolePermissions/RolePermissions.tsx"],"names":[],"mappings":"AAKA,OAAO,EAEL,oBAAoB,IAAI,yBAAyB,EAClD,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,oBAAoB,GAAG,yBAAyB,CAAC;AAE7D;;;;;;;;;;GAUG;AACH,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAE7C,CAAC;AAIF,eAAe,eAAe,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { RolePermissions } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/RolePermissions/RolePermissions.tsx
7
+ //#region src/client/components/management/RolePermissions/RolePermissions.tsx
8
8
  /**
9
9
  * Shows the permissions a role grants.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RolePermissions.js","names":["RolePermissions: FC<RolePermissionsProps>","ReactRolePermissions","RolePermissions"],"sources":["../../../../../src/client/components/management/RolePermissions/RolePermissions.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {\n RolePermissions as ReactRolePermissions,\n RolePermissionsProps as ReactRolePermissionsProps,\n} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type RolePermissionsProps = ReactRolePermissionsProps;\n\n/**\n * Shows the permissions a role grants.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <RolePermissions roleId={id} />\n * ```\n */\nconst RolePermissions: FC<RolePermissionsProps> = (props: RolePermissionsProps): ReactElement => (\n <ReactRolePermissions {...props} />\n);\n\nRolePermissions.displayName = 'RolePermissions';\n\nexport default RolePermissions;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAwBA,MAAMA,qBAA6C,UACjD,oBAACC,mBAAqB,GAAI,QAAS;AAGrC,kBAAgB,cAAc;AAE9B,8BAAeC"}
@@ -0,0 +1,17 @@
1
+ import { SharingPoliciesProps as ReactSharingPoliciesProps } from '@thunderid/react';
2
+ import { FC } from 'react';
3
+ export type SharingPoliciesProps = ReactSharingPoliciesProps;
4
+ /**
5
+ * Lists the sharing policies of a user, an application, a role or a flow, and lets the signed-in user manage them when `editable`.
6
+ *
7
+ * Management requests go through a server action with the signed-in user's server-held session, so
8
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
9
+ *
10
+ * @example
11
+ * ```tsx
12
+ * <SharingPolicies resourceType="role" resourceId={roleId} editable />
13
+ * ```
14
+ */
15
+ declare const SharingPolicies: FC<SharingPoliciesProps>;
16
+ export default SharingPolicies;
17
+ //# sourceMappingURL=SharingPolicies.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SharingPolicies.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/SharingPolicies/SharingPolicies.tsx"],"names":[],"mappings":"AAKA,OAAO,EAEL,oBAAoB,IAAI,yBAAyB,EAClD,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,oBAAoB,GAAG,yBAAyB,CAAC;AAE7D;;;;;;;;;;GAUG;AACH,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAE7C,CAAC;AAIF,eAAe,eAAe,CAAC"}
@@ -0,0 +1,25 @@
1
+ 'use client';
2
+
3
+
4
+ import { SharingPolicies } from "@thunderid/react";
5
+ import { jsx } from "react/jsx-runtime";
6
+
7
+ //#region src/client/components/management/SharingPolicies/SharingPolicies.tsx
8
+ /**
9
+ * Lists the sharing policies of a user, an application, a role or a flow, and lets the signed-in user manage them when `editable`.
10
+ *
11
+ * Management requests go through a server action with the signed-in user's server-held session, so
12
+ * the access token never reaches the browser. Whether a request succeeds is the server's decision.
13
+ *
14
+ * @example
15
+ * ```tsx
16
+ * <SharingPolicies resourceType="role" resourceId={roleId} editable />
17
+ * ```
18
+ */
19
+ const SharingPolicies$1 = (props) => /* @__PURE__ */ jsx(SharingPolicies, { ...props });
20
+ SharingPolicies$1.displayName = "SharingPolicies";
21
+ var SharingPolicies_default = SharingPolicies$1;
22
+
23
+ //#endregion
24
+ export { SharingPolicies_default as default };
25
+ //# sourceMappingURL=SharingPolicies.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SharingPolicies.js","names":["SharingPolicies: FC<SharingPoliciesProps>","ReactSharingPolicies","SharingPolicies"],"sources":["../../../../../src/client/components/management/SharingPolicies/SharingPolicies.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {\n SharingPolicies as ReactSharingPolicies,\n SharingPoliciesProps as ReactSharingPoliciesProps,\n} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type SharingPoliciesProps = ReactSharingPoliciesProps;\n\n/**\n * Lists the sharing policies of a user, an application, a role or a flow, and lets the signed-in user manage them when `editable`.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <SharingPolicies resourceType=\"role\" resourceId={roleId} editable />\n * ```\n */\nconst SharingPolicies: FC<SharingPoliciesProps> = (props: SharingPoliciesProps): ReactElement => (\n <ReactSharingPolicies {...props} />\n);\n\nSharingPolicies.displayName = 'SharingPolicies';\n\nexport default SharingPolicies;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAwBA,MAAMA,qBAA6C,UACjD,oBAACC,mBAAqB,GAAI,QAAS;AAGrC,kBAAgB,cAAc;AAE9B,8BAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserCreate.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/UserCreate/UserCreate.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAgC,eAAe,IAAI,oBAAoB,EAAC,MAAM,kBAAkB,CAAC;AACxG,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,eAAe,GAAG,oBAAoB,CAAC;AAEnD;;;;;;;;;;GAUG;AACH,QAAA,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAA4E,CAAC;AAIjH,eAAe,UAAU,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { UserCreate } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/UserCreate/UserCreate.tsx
7
+ //#region src/client/components/management/UserCreate/UserCreate.tsx
8
8
  /**
9
9
  * Creates a user, or invites one with `mode="invite"`.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserCreate.js","names":["UserCreate: FC<UserCreateProps>","ReactUserCreate","UserCreate"],"sources":["../../../../../src/client/components/management/UserCreate/UserCreate.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {UserCreate as ReactUserCreate, UserCreateProps as ReactUserCreateProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type UserCreateProps = ReactUserCreateProps;\n\n/**\n * Creates a user, or invites one with `mode=\"invite\"`.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <UserCreate onCreated={(user) => router.push(`/admin/users/${user.id}`)} />\n * ```\n */\nconst UserCreate: FC<UserCreateProps> = (props: UserCreateProps): ReactElement => <ReactUserCreate {...props} />;\n\nUserCreate.displayName = 'UserCreate';\n\nexport default UserCreate;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,gBAAmC,UAAyC,oBAACC,cAAgB,GAAI,QAAS;AAEhH,aAAW,cAAc;AAEzB,yBAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserDetails.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/UserDetails/UserDetails.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAkC,gBAAgB,IAAI,qBAAqB,EAAC,MAAM,kBAAkB,CAAC;AAC5G,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAErD;;;;;;;;;;GAUG;AACH,QAAA,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CAA8E,CAAC;AAIrH,eAAe,WAAW,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { UserDetails } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/UserDetails/UserDetails.tsx
7
+ //#region src/client/components/management/UserDetails/UserDetails.tsx
8
8
  /**
9
9
  * Shows a user's attributes and groups, and optionally edits or deletes the user.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserDetails.js","names":["UserDetails: FC<UserDetailsProps>","ReactUserDetails","UserDetails"],"sources":["../../../../../src/client/components/management/UserDetails/UserDetails.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {UserDetails as ReactUserDetails, UserDetailsProps as ReactUserDetailsProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type UserDetailsProps = ReactUserDetailsProps;\n\n/**\n * Shows a user's attributes and groups, and optionally edits or deletes the user.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <UserDetails userId={id} editable deletable onDeleted={() => router.push('/admin/users')} />\n * ```\n */\nconst UserDetails: FC<UserDetailsProps> = (props: UserDetailsProps): ReactElement => <ReactUserDetails {...props} />;\n\nUserDetails.displayName = 'UserDetails';\n\nexport default UserDetails;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,iBAAqC,UAA0C,oBAACC,eAAiB,GAAI,QAAS;AAEpH,cAAY,cAAc;AAE1B,0BAAeC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserList.d.ts","sourceRoot":"","sources":["../../../../../src/client/components/management/UserList/UserList.tsx"],"names":[],"mappings":"AAKA,OAAO,EAA4B,aAAa,IAAI,kBAAkB,EAAC,MAAM,kBAAkB,CAAC;AAChG,OAAO,EAAC,EAAE,EAAe,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,aAAa,GAAG,kBAAkB,CAAC;AAE/C;;;;;;;;;;GAUG;AACH,QAAA,MAAM,QAAQ,EAAE,EAAE,CAAC,aAAa,CAAwE,CAAC;AAIzG,eAAe,QAAQ,CAAC"}
@@ -4,7 +4,7 @@
4
4
  import { UserList } from "@thunderid/react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
 
7
- //#region src/client/components/admin/UserList/UserList.tsx
7
+ //#region src/client/components/management/UserList/UserList.tsx
8
8
  /**
9
9
  * Lists the users the signed-in user is allowed to see, a page at a time.
10
10
  *
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserList.js","names":["UserList: FC<UserListProps>","ReactUserList","UserList"],"sources":["../../../../../src/client/components/management/UserList/UserList.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\n'use client';\n\nimport {UserList as ReactUserList, UserListProps as ReactUserListProps} from '@thunderid/react';\nimport {FC, ReactElement} from 'react';\n\nexport type UserListProps = ReactUserListProps;\n\n/**\n * Lists the users the signed-in user is allowed to see, a page at a time.\n *\n * Management requests go through a server action with the signed-in user's server-held session, so\n * the access token never reaches the browser. Whether a request succeeds is the server's decision.\n *\n * @example\n * ```tsx\n * <UserList onSelect={(user) => router.push(`/admin/users/${user.id}`)} />\n * ```\n */\nconst UserList: FC<UserListProps> = (props: UserListProps): ReactElement => <ReactUserList {...props} />;\n\nUserList.displayName = 'UserList';\n\nexport default UserList;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqBA,MAAMA,cAA+B,UAAuC,oBAACC,YAAc,GAAI,QAAS;AAExG,WAAS,cAAc;AAEvB,uBAAeC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ThunderIDProvider.d.ts","sourceRoot":"","sources":["../../../../src/client/contexts/ThunderID/ThunderIDProvider.tsx"],"names":[],"mappings":"AAKA,OAAO,EACL,eAAe,EAEf,oBAAoB,EAEpB,qBAAqB,EACrB,IAAI,EACJ,WAAW,EAGZ,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAQL,sBAAsB,EACvB,MAAM,kBAAkB,CAAC;AAI1B,OAAO,EAAC,EAAE,EAAE,iBAAiB,EAAkD,MAAM,OAAO,CAAC;AAC7F,OAAyB,EAAC,qBAAqB,EAAC,MAAM,oBAAoB,CAAC;AAC3E,OAAO,EAAC,aAAa,EAAC,MAAM,sCAAsC,CAAC;AAKnE;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,OAAO,CAAC,IAAI,CAAC,sBAAsB,EAAE,SAAS,GAAG,UAAU,CAAC,CAAC,GACtG,IAAI,CAAC,sBAAsB,EAAE,SAAS,GAAG,UAAU,CAAC,GAAG;IACrD,aAAa,EAAE,qBAAqB,CAAC,eAAe,CAAC,CAAC;IACtD,YAAY,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,mBAAmB,EAAE,CACnB,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,KACV,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAC,CAAC,CAAC;IACvE;;;OAGG;IACH,WAAW,CAAC,EAAE,oBAAoB,GAAG,IAAI,CAAC;IAC1C,UAAU,EAAE,OAAO,CAAC;IACpB,kBAAkB,EAAE,qBAAqB,CAAC,oBAAoB,CAAC,CAAC;IAChE,YAAY,EAAE,MAAM,OAAO,CAAC,aAAa,CAAC,CAAC;IAC3C,MAAM,EAAE,qBAAqB,CAAC,QAAQ,CAAC,CAAC;IACxC,OAAO,EAAE,qBAAqB,CAAC,SAAS,CAAC,CAAC;IAC1C,MAAM,EAAE,qBAAqB,CAAC,QAAQ,CAAC,CAAC;IACxC,aAAa,EAAE,CACb,aAAa,EAAE,qBAAqB,EACpC,SAAS,CAAC,EAAE,MAAM,KACf,OAAO,CAAC;QAAC,IAAI,EAAE;YAAC,IAAI,EAAE,IAAI,CAAA;SAAC,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAC,CAAC,CAAC;IACpE,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,WAAW,EAAE,WAAW,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,GAAG,IAAI,CAAC;CACrD,CAAC;AAEJ,QAAA,MAAM,uBAAuB,EAAE,EAAE,CAAC,iBAAiB,CAAC,4BAA4B,CAAC,CAoWhF,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
1
+ {"version":3,"file":"ThunderIDProvider.d.ts","sourceRoot":"","sources":["../../../../src/client/contexts/ThunderID/ThunderIDProvider.tsx"],"names":[],"mappings":"AAKA,OAAO,EACL,eAAe,EAEf,oBAAoB,EAEpB,qBAAqB,EACrB,IAAI,EACJ,WAAW,EAMZ,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAQL,sBAAsB,EAEvB,MAAM,kBAAkB,CAAC;AAI1B,OAAO,EAAC,EAAE,EAAE,iBAAiB,EAAkD,MAAM,OAAO,CAAC;AAC7F,OAAyB,EAAC,qBAAqB,EAAC,MAAM,oBAAoB,CAAC;AAQ3E,OAAO,EAAC,aAAa,EAAC,MAAM,sCAAsC,CAAC;AAKnE;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,OAAO,CAAC,IAAI,CAAC,sBAAsB,EAAE,SAAS,GAAG,UAAU,CAAC,CAAC,GACtG,IAAI,CAAC,sBAAsB,EAAE,SAAS,GAAG,UAAU,CAAC,GAAG;IACrD,aAAa,EAAE,qBAAqB,CAAC,eAAe,CAAC,CAAC;IACtD,YAAY,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,mBAAmB,EAAE,CACnB,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,KACV,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAC,CAAC,CAAC;IACvE;;;OAGG;IACH,WAAW,CAAC,EAAE,oBAAoB,GAAG,IAAI,CAAC;IAC1C,UAAU,EAAE,OAAO,CAAC;IACpB,kBAAkB,EAAE,qBAAqB,CAAC,oBAAoB,CAAC,CAAC;IAChE,YAAY,EAAE,MAAM,OAAO,CAAC,aAAa,CAAC,CAAC;IAC3C,MAAM,EAAE,qBAAqB,CAAC,QAAQ,CAAC,CAAC;IACxC,OAAO,EAAE,qBAAqB,CAAC,SAAS,CAAC,CAAC;IAC1C,MAAM,EAAE,qBAAqB,CAAC,QAAQ,CAAC,CAAC;IACxC,aAAa,EAAE,CACb,aAAa,EAAE,qBAAqB,EACpC,SAAS,CAAC,EAAE,MAAM,KACf,OAAO,CAAC;QAAC,IAAI,EAAE;YAAC,IAAI,EAAE,IAAI,CAAA;SAAC,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAC,CAAC,CAAC;IACpE,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,WAAW,EAAE,WAAW,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,GAAG,IAAI,CAAC;CACrD,CAAC;AAEJ,QAAA,MAAM,uBAAuB,EAAE,EAAE,CAAC,iBAAiB,CAAC,4BAA4B,CAAC,CAochF,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
@@ -1,12 +1,17 @@
1
1
  'use client';
2
2
 
3
3
 
4
+ import getSessionId_default from "../../../server/actions/getSessionId.js";
5
+ import getUserAction_default from "../../../server/actions/account/getUserAction.js";
6
+ import getUserProfileAction_default from "../../../server/actions/account/getUserProfileAction.js";
4
7
  import logger_default from "../../../utils/logger.js";
5
8
  import ThunderIDContext_default from "./ThunderIDContext.js";
9
+ import getCurrentOrganizationUnitAction_default from "../../../server/actions/account/getCurrentOrganizationUnitAction.js";
10
+ import switchOrganizationUnitAction_default from "../../../server/actions/auth/switchOrganizationUnitAction.js";
6
11
  import fetchFlowMetaFromServer_default from "../../fetchFlowMetaFromServer.js";
7
12
  import fetchManagementFromServer_default from "../../fetchManagementFromServer.js";
8
- import { ThunderIDRuntimeError, generateFlattenedUserProfile, getVendorPrefix } from "@thunderid/node";
9
- import { FlowMetaProvider, FlowProvider, I18nProvider, ThemeProvider, ThunderIDContext, UserProvider } from "@thunderid/react";
13
+ import { ThunderIDAPIError, ThunderIDRuntimeError, generateFlattenedUserProfile, getVendorPrefix } from "@thunderid/node";
14
+ import { FlowMetaProvider, FlowProvider, I18nProvider, ThemeProvider, ThunderIDContext, UserProvider, useCurrentProjectState } from "@thunderid/react";
10
15
  import { useRouter, useSearchParams } from "next/navigation";
11
16
  import { useEffect, useMemo, useRef, useState } from "react";
12
17
  import { jsx } from "react/jsx-runtime";
@@ -56,6 +61,38 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
56
61
  useEffect(() => {
57
62
  setIsLoading(false);
58
63
  }, [isSignedIn, user]);
64
+ const [currentOrganizationUnit, setCurrentOrganizationUnit] = useState(null);
65
+ const { currentProject, setCurrentProject } = useCurrentProjectState(getVendorPrefix(vendor));
66
+ useEffect(() => {
67
+ if (!isSignedIn) {
68
+ setCurrentOrganizationUnit(null);
69
+ return;
70
+ }
71
+ getCurrentOrganizationUnitAction_default().then(setCurrentOrganizationUnit).catch(() => setCurrentOrganizationUnit(null));
72
+ }, [isSignedIn, user]);
73
+ /**
74
+ * Signs in again bounded to another organization unit through a server action. Redirect mode sends the
75
+ * browser to the unit's authorization endpoint and resolves with `undefined`; embedded mode replaces
76
+ * the session in place and resolves with the refreshed user. A failure keeps the previous session and
77
+ * rejects with an error whose code is one of `OrganizationUnitSwitchErrorCodes`.
78
+ */
79
+ const handleSwitchOrganizationUnit = async (organizationUnitId, options) => {
80
+ const result = await switchOrganizationUnitAction_default(organizationUnitId, { redirect: options?.redirect });
81
+ if (!result.success) throw new ThunderIDAPIError(JSON.stringify({
82
+ code: result.code,
83
+ message: { defaultValue: "Switching the organization unit failed" }
84
+ }), result.code, "nextjs", result.statusCode);
85
+ if (result.data.signInUrl) {
86
+ window.location.href = result.data.signInUrl;
87
+ return;
88
+ }
89
+ const sessionId = await getSessionId_default();
90
+ const refreshedUser = (sessionId ? await getUserAction_default(sessionId) : void 0)?.data?.user ?? null;
91
+ if (refreshedUser) setUser(refreshedUser);
92
+ setCurrentOrganizationUnit(await getCurrentOrganizationUnitAction_default());
93
+ router.refresh();
94
+ return refreshedUser ?? void 0;
95
+ };
59
96
  const handleSignIn = async (payload, request) => {
60
97
  if (!signIn) throw new ThunderIDRuntimeError("`signIn` function is not available.", "ThunderIDClientProvider-handleSignIn-RuntimeError-001", "nextjs");
61
98
  const result = await signIn(payload, request);
@@ -107,11 +144,16 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
107
144
  applicationId,
108
145
  baseUrl,
109
146
  clearSession,
147
+ currentOrganizationUnit,
148
+ currentProject,
149
+ getCurrentOrganizationUnit: getCurrentOrganizationUnitAction_default,
110
150
  isLoading,
111
151
  isSignedIn,
112
152
  organizationHandle,
113
153
  preferences,
114
154
  refreshToken,
155
+ setCurrentProject,
156
+ switchOrganizationUnit: handleSwitchOrganizationUnit,
115
157
  scopes,
116
158
  signIn: handleSignIn,
117
159
  signInUrl,
@@ -129,7 +171,10 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
129
171
  applicationId,
130
172
  organizationHandle,
131
173
  scopes,
132
- preferences
174
+ preferences,
175
+ currentOrganizationUnit,
176
+ currentProject,
177
+ setCurrentProject
133
178
  ]);
134
179
  const handleProfileUpdate = (payload) => {
135
180
  setUser(payload);
@@ -139,6 +184,15 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
139
184
  profile: payload
140
185
  }));
141
186
  };
187
+ /**
188
+ * Re-reads `/users/me` through the server-held session, so a change made outside the profile API,
189
+ * such as a recorded verification, shows.
190
+ */
191
+ const revalidateProfile = async () => {
192
+ if (preferences?.user?.fetchUserProfile === false) return;
193
+ const result = await getUserProfileAction_default(await getSessionId_default() ?? "");
194
+ if (result.success) handleProfileUpdate(result.data.userProfile.profile);
195
+ };
142
196
  const unsupported = (name) => {
143
197
  return () => Promise.reject(new ThunderIDRuntimeError(`\`${name}\` is not supported in @thunderid/nextjs.`, `ThunderIDClientProvider-${name}-NotSupportedError-001`, "nextjs"));
144
198
  };
@@ -148,10 +202,13 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
148
202
  baseUrl,
149
203
  clearSession,
150
204
  clientId: void 0,
205
+ currentOrganizationUnit,
206
+ currentProject,
151
207
  discovery: { wellKnown: null },
152
208
  endpoints,
153
209
  exchangeToken: unsupported("exchangeToken"),
154
210
  getAccessToken: unsupported("getAccessToken"),
211
+ getCurrentOrganizationUnit: getCurrentOrganizationUnitAction_default,
155
212
  getDecodedIdToken: unsupported("getDecodedIdToken"),
156
213
  getGrantedPermissions: unsupported("getGrantedPermissions"),
157
214
  getIdToken: unsupported("getIdToken"),
@@ -172,12 +229,14 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
172
229
  recover: unsupported("recover"),
173
230
  resolveFlowTemplateLiterals: (text) => text ?? "",
174
231
  scopes,
232
+ setCurrentProject,
175
233
  signIn: handleSignIn,
176
234
  signInSilently: unsupported("signInSilently"),
177
235
  signInUrl,
178
236
  signOut: handleSignOut,
179
237
  signUp: handleSignUp,
180
238
  signUpUrl,
239
+ switchOrganizationUnit: handleSwitchOrganizationUnit,
181
240
  user,
182
241
  userSchema,
183
242
  vendor: getVendorPrefix(vendor)
@@ -195,7 +254,10 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
195
254
  user,
196
255
  userSchema,
197
256
  initialMeta,
198
- vendor
257
+ vendor,
258
+ currentOrganizationUnit,
259
+ currentProject,
260
+ setCurrentProject
199
261
  ]);
200
262
  return /* @__PURE__ */ jsx(ThunderIDContext_default.Provider, {
201
263
  value: contextValue,
@@ -214,6 +276,7 @@ const ThunderIDClientProvider = ({ baseUrl, children, endpoints, signIn, clearSe
214
276
  profile: userProfile,
215
277
  userSchema,
216
278
  onUpdateProfile: handleProfileUpdate,
279
+ revalidateProfile,
217
280
  updateProfile,
218
281
  children
219
282
  }) })