@wildo-ai/saas-frontend-lib 1.1.5 → 1.1.6

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 (777) hide show
  1. package/dist/esm/components/actions/action-bar.d.ts +15 -0
  2. package/dist/esm/components/actions/action-bar.d.ts.map +1 -1
  3. package/dist/esm/components/actions/action-bar.js +15 -0
  4. package/dist/esm/components/actions/action-bar.js.map +1 -1
  5. package/dist/esm/components/ai-elements/decision/approval.d.ts +97 -7
  6. package/dist/esm/components/ai-elements/decision/approval.d.ts.map +1 -1
  7. package/dist/esm/components/ai-elements/decision/approval.js.map +1 -1
  8. package/dist/esm/components/app/AppLayout_AuthenticatedRoute.d.ts.map +1 -1
  9. package/dist/esm/components/app/AppLayout_AuthenticatedRoute.js +8 -3
  10. package/dist/esm/components/app/AppLayout_AuthenticatedRoute.js.map +1 -1
  11. package/dist/esm/components/auth/Auth_EnrollmentRequired.d.ts.map +1 -1
  12. package/dist/esm/components/auth/Auth_EnrollmentRequired.js +5 -1
  13. package/dist/esm/components/auth/Auth_EnrollmentRequired.js.map +1 -1
  14. package/dist/esm/components/auth/Auth_Main.d.ts.map +1 -1
  15. package/dist/esm/components/auth/Auth_Main.js +1 -4
  16. package/dist/esm/components/auth/Auth_Main.js.map +1 -1
  17. package/dist/esm/components/auth/Auth_Register.d.ts.map +1 -1
  18. package/dist/esm/components/auth/Auth_Register.js +1 -3
  19. package/dist/esm/components/auth/Auth_Register.js.map +1 -1
  20. package/dist/esm/components/auth/StepUpAuthDialog.d.ts +7 -0
  21. package/dist/esm/components/auth/StepUpAuthDialog.d.ts.map +1 -1
  22. package/dist/esm/components/auth/StepUpAuthDialog.js +13 -7
  23. package/dist/esm/components/auth/StepUpAuthDialog.js.map +1 -1
  24. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.d.ts.map +1 -1
  25. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.js +32 -33
  26. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.js.map +1 -1
  27. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.labels.d.ts.map +1 -1
  28. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.labels.js +18 -20
  29. package/dist/esm/components/auth/admin-config/AppPage_SecuritySettings.labels.js.map +1 -1
  30. package/dist/esm/components/auth/methods/ExternalOAuth2AuthMethod.d.ts.map +1 -1
  31. package/dist/esm/components/auth/methods/ExternalOAuth2AuthMethod.js +2 -3
  32. package/dist/esm/components/auth/methods/ExternalOAuth2AuthMethod.js.map +1 -1
  33. package/dist/esm/components/auth/utils/oauth-provider-display-label.frontend.utils.d.ts +13 -16
  34. package/dist/esm/components/auth/utils/oauth-provider-display-label.frontend.utils.d.ts.map +1 -1
  35. package/dist/esm/components/auth/utils/oauth-provider-display-label.frontend.utils.js +18 -15
  36. package/dist/esm/components/auth/utils/oauth-provider-display-label.frontend.utils.js.map +1 -1
  37. package/dist/esm/components/billing/billing-invoice-history.js +2 -2
  38. package/dist/esm/components/billing/billing-invoice-history.js.map +1 -1
  39. package/dist/esm/components/billing/billing-portal-link.js +2 -2
  40. package/dist/esm/components/billing/billing-portal-link.js.map +1 -1
  41. package/dist/esm/components/billing/billing-pricing-table.d.ts +33 -1
  42. package/dist/esm/components/billing/billing-pricing-table.d.ts.map +1 -1
  43. package/dist/esm/components/billing/billing-pricing-table.js +34 -5
  44. package/dist/esm/components/billing/billing-pricing-table.js.map +1 -1
  45. package/dist/esm/components/billing/billing-subscription-status.js +2 -2
  46. package/dist/esm/components/billing/billing-subscription-status.js.map +1 -1
  47. package/dist/esm/components/billing/billing-usage-dashboard.d.ts +2 -0
  48. package/dist/esm/components/billing/billing-usage-dashboard.d.ts.map +1 -1
  49. package/dist/esm/components/billing/billing-usage-dashboard.js +1 -0
  50. package/dist/esm/components/billing/billing-usage-dashboard.js.map +1 -1
  51. package/dist/esm/components/data-display/DisplayField.d.ts.map +1 -1
  52. package/dist/esm/components/data-display/DisplayField.js +15 -1
  53. package/dist/esm/components/data-display/DisplayField.js.map +1 -1
  54. package/dist/esm/components/data-display/DisplayFieldArray.d.ts.map +1 -1
  55. package/dist/esm/components/data-display/DisplayFieldArray.js +11 -0
  56. package/dist/esm/components/data-display/DisplayFieldArray.js.map +1 -1
  57. package/dist/esm/components/data-display/DisplayFieldEditable.d.ts.map +1 -1
  58. package/dist/esm/components/data-display/DisplayFieldEditable.js +2 -2
  59. package/dist/esm/components/data-display/DisplayFieldEditable.js.map +1 -1
  60. package/dist/esm/components/data-display/DisplayFieldEditableArray.d.ts +12 -2
  61. package/dist/esm/components/data-display/DisplayFieldEditableArray.d.ts.map +1 -1
  62. package/dist/esm/components/data-display/DisplayFieldEditableArray.js +3 -2
  63. package/dist/esm/components/data-display/DisplayFieldEditableArray.js.map +1 -1
  64. package/dist/esm/components/data-display/DisplayFieldReadOnly.d.ts.map +1 -1
  65. package/dist/esm/components/data-display/DisplayFieldReadOnly.js +2 -2
  66. package/dist/esm/components/data-display/DisplayFieldReadOnly.js.map +1 -1
  67. package/dist/esm/components/data-display/DisplayFieldReadOnlyArraySection.d.ts.map +1 -1
  68. package/dist/esm/components/data-display/DisplayFieldReadOnlyArraySection.js +8 -2
  69. package/dist/esm/components/data-display/DisplayFieldReadOnlyArraySection.js.map +1 -1
  70. package/dist/esm/components/data-display/DisplayValueDispatcher.d.ts.map +1 -1
  71. package/dist/esm/components/data-display/DisplayValueDispatcher.js +18 -4
  72. package/dist/esm/components/data-display/DisplayValueDispatcher.js.map +1 -1
  73. package/dist/esm/components/data-display/ResourceAutomaticDisplayer.d.ts.map +1 -1
  74. package/dist/esm/components/data-display/ResourceAutomaticDisplayer.js +61 -3
  75. package/dist/esm/components/data-display/ResourceAutomaticDisplayer.js.map +1 -1
  76. package/dist/esm/components/data-display/ResourceSummaryDisplayer.d.ts +7 -5
  77. package/dist/esm/components/data-display/ResourceSummaryDisplayer.d.ts.map +1 -1
  78. package/dist/esm/components/data-display/ResourceSummaryDisplayer.js.map +1 -1
  79. package/dist/esm/components/data-display/chromes/DisplayFieldChrome.d.ts +11 -1
  80. package/dist/esm/components/data-display/chromes/DisplayFieldChrome.d.ts.map +1 -1
  81. package/dist/esm/components/data-display/chromes/DisplayFieldChrome.js +36 -11
  82. package/dist/esm/components/data-display/chromes/DisplayFieldChrome.js.map +1 -1
  83. package/dist/esm/components/data-display/display-field-resolved-props.d.ts +6 -0
  84. package/dist/esm/components/data-display/display-field-resolved-props.d.ts.map +1 -1
  85. package/dist/esm/components/data-display/display-field-resolved-props.js.map +1 -1
  86. package/dist/esm/components/data-display/external-data-provenance/DisplayFieldProvenanceNote.d.ts +23 -0
  87. package/dist/esm/components/data-display/external-data-provenance/DisplayFieldProvenanceNote.d.ts.map +1 -0
  88. package/dist/esm/components/data-display/external-data-provenance/DisplayFieldProvenanceNote.js +35 -0
  89. package/dist/esm/components/data-display/external-data-provenance/DisplayFieldProvenanceNote.js.map +1 -0
  90. package/dist/esm/components/data-display/external-data-provenance/external-data-provenance.frontend.d.ts +47 -0
  91. package/dist/esm/components/data-display/external-data-provenance/external-data-provenance.frontend.d.ts.map +1 -0
  92. package/dist/esm/components/data-display/external-data-provenance/external-data-provenance.frontend.js +124 -0
  93. package/dist/esm/components/data-display/external-data-provenance/external-data-provenance.frontend.js.map +1 -0
  94. package/dist/esm/components/data-display/external-data-provenance/useExternalDataFieldProvenance.d.ts +8 -0
  95. package/dist/esm/components/data-display/external-data-provenance/useExternalDataFieldProvenance.d.ts.map +1 -0
  96. package/dist/esm/components/data-display/external-data-provenance/useExternalDataFieldProvenance.js +46 -0
  97. package/dist/esm/components/data-display/external-data-provenance/useExternalDataFieldProvenance.js.map +1 -0
  98. package/dist/esm/components/feedback/resource-empty-state.d.ts +21 -8
  99. package/dist/esm/components/feedback/resource-empty-state.d.ts.map +1 -1
  100. package/dist/esm/components/feedback/resource-empty-state.js +56 -26
  101. package/dist/esm/components/feedback/resource-empty-state.js.map +1 -1
  102. package/dist/esm/components/flows-actors/approval.d.ts +29 -7
  103. package/dist/esm/components/flows-actors/approval.d.ts.map +1 -1
  104. package/dist/esm/components/flows-actors/approval.js +231 -101
  105. package/dist/esm/components/flows-actors/approval.js.map +1 -1
  106. package/dist/esm/components/flows-actors/approval.labels.d.ts.map +1 -1
  107. package/dist/esm/components/flows-actors/approval.labels.js +57 -0
  108. package/dist/esm/components/flows-actors/approval.labels.js.map +1 -1
  109. package/dist/esm/components/flows-actors/system-catalog.d.ts.map +1 -1
  110. package/dist/esm/components/flows-actors/system-catalog.js +4 -4
  111. package/dist/esm/components/flows-actors/system-catalog.js.map +1 -1
  112. package/dist/esm/components/flows-actors/system-catalog.labels.d.ts.map +1 -1
  113. package/dist/esm/components/flows-actors/system-catalog.labels.js +0 -5
  114. package/dist/esm/components/flows-actors/system-catalog.labels.js.map +1 -1
  115. package/dist/esm/components/form/Form.d.ts +2 -2
  116. package/dist/esm/components/form/Form.js +2 -2
  117. package/dist/esm/components/form/Form.js.map +1 -1
  118. package/dist/esm/components/form/automated/AutomatedArrayField.d.ts +28 -3
  119. package/dist/esm/components/form/automated/AutomatedArrayField.d.ts.map +1 -1
  120. package/dist/esm/components/form/automated/AutomatedArrayField.js +43 -14
  121. package/dist/esm/components/form/automated/AutomatedArrayField.js.map +1 -1
  122. package/dist/esm/components/form/automated/FormField.d.ts +3 -0
  123. package/dist/esm/components/form/automated/FormField.d.ts.map +1 -1
  124. package/dist/esm/components/form/automated/FormField.js +60 -21
  125. package/dist/esm/components/form/automated/FormField.js.map +1 -1
  126. package/dist/esm/components/form/automated/FormFieldArray.d.ts +6 -3
  127. package/dist/esm/components/form/automated/FormFieldArray.d.ts.map +1 -1
  128. package/dist/esm/components/form/automated/FormFieldArray.js +3 -2
  129. package/dist/esm/components/form/automated/FormFieldArray.js.map +1 -1
  130. package/dist/esm/components/form/automated/ResourceAutomatedForm.d.ts +5 -4
  131. package/dist/esm/components/form/automated/ResourceAutomatedForm.d.ts.map +1 -1
  132. package/dist/esm/components/form/automated/ResourceAutomatedForm.js +148 -55
  133. package/dist/esm/components/form/automated/ResourceAutomatedForm.js.map +1 -1
  134. package/dist/esm/components/form/automated/ResourceFormActionsContext.d.ts +30 -0
  135. package/dist/esm/components/form/automated/ResourceFormActionsContext.d.ts.map +1 -1
  136. package/dist/esm/components/form/automated/ResourceFormActionsContext.js +30 -1
  137. package/dist/esm/components/form/automated/ResourceFormActionsContext.js.map +1 -1
  138. package/dist/esm/components/form/automated/TemplatePlacedFieldsContext.d.ts +79 -0
  139. package/dist/esm/components/form/automated/TemplatePlacedFieldsContext.d.ts.map +1 -0
  140. package/dist/esm/components/form/automated/TemplatePlacedFieldsContext.js +203 -0
  141. package/dist/esm/components/form/automated/TemplatePlacedFieldsContext.js.map +1 -0
  142. package/dist/esm/components/form/automated/automated-form-submit.utils.d.ts +12 -0
  143. package/dist/esm/components/form/automated/automated-form-submit.utils.d.ts.map +1 -1
  144. package/dist/esm/components/form/automated/automated-form-submit.utils.js +11 -0
  145. package/dist/esm/components/form/automated/automated-form-submit.utils.js.map +1 -1
  146. package/dist/esm/components/form/chromes/FormFieldChrome.d.ts.map +1 -1
  147. package/dist/esm/components/form/chromes/FormFieldChrome.js +2 -2
  148. package/dist/esm/components/form/chromes/FormFieldChrome.js.map +1 -1
  149. package/dist/esm/components/form/combobox.d.ts +7 -0
  150. package/dist/esm/components/form/combobox.d.ts.map +1 -1
  151. package/dist/esm/components/form/combobox.js.map +1 -1
  152. package/dist/esm/components/form/controls/form-field-checkbox-group.d.ts.map +1 -1
  153. package/dist/esm/components/form/controls/form-field-checkbox-group.js +13 -0
  154. package/dist/esm/components/form/controls/form-field-checkbox-group.js.map +1 -1
  155. package/dist/esm/components/form/fields/form-field-address.d.ts +58 -0
  156. package/dist/esm/components/form/fields/form-field-address.d.ts.map +1 -1
  157. package/dist/esm/components/form/fields/form-field-address.js +34 -6
  158. package/dist/esm/components/form/fields/form-field-address.js.map +1 -1
  159. package/dist/esm/components/form/fields/form-field-address.labels.d.ts.map +1 -1
  160. package/dist/esm/components/form/fields/form-field-address.labels.js +60 -1
  161. package/dist/esm/components/form/fields/form-field-address.labels.js.map +1 -1
  162. package/dist/esm/components/form/fields/form-field-file.d.ts +0 -12
  163. package/dist/esm/components/form/fields/form-field-file.d.ts.map +1 -1
  164. package/dist/esm/components/form/fields/form-field-file.js +34 -13
  165. package/dist/esm/components/form/fields/form-field-file.js.map +1 -1
  166. package/dist/esm/components/form/fields/form-field-file.labels.d.ts.map +1 -1
  167. package/dist/esm/components/form/fields/form-field-file.labels.js +46 -0
  168. package/dist/esm/components/form/fields/form-field-file.labels.js.map +1 -1
  169. package/dist/esm/components/form/fields/form-field-string-organization-role.d.ts +73 -0
  170. package/dist/esm/components/form/fields/form-field-string-organization-role.d.ts.map +1 -0
  171. package/dist/esm/components/form/fields/form-field-string-organization-role.js +64 -0
  172. package/dist/esm/components/form/fields/form-field-string-organization-role.js.map +1 -0
  173. package/dist/esm/components/form/fields/form-field-string.d.ts.map +1 -1
  174. package/dist/esm/components/form/fields/form-field-string.js +8 -1
  175. package/dist/esm/components/form/fields/form-field-string.js.map +1 -1
  176. package/dist/esm/components/form/fields/form-field-string.labels.d.ts.map +1 -1
  177. package/dist/esm/components/form/fields/form-field-string.labels.js +4 -0
  178. package/dist/esm/components/form/fields/form-field-string.labels.js.map +1 -1
  179. package/dist/esm/components/form/validation-errors/FormErrorSummary.js +1 -1
  180. package/dist/esm/components/form/validation-errors/FormErrorSummary.js.map +1 -1
  181. package/dist/esm/components/form/validation-errors/resolver-error-nesting.d.ts +31 -0
  182. package/dist/esm/components/form/validation-errors/resolver-error-nesting.d.ts.map +1 -0
  183. package/dist/esm/components/form/validation-errors/resolver-error-nesting.js +81 -0
  184. package/dist/esm/components/form/validation-errors/resolver-error-nesting.js.map +1 -0
  185. package/dist/esm/components/form/validation-errors/resource-error-notification-context.utils.d.ts +14 -1
  186. package/dist/esm/components/form/validation-errors/resource-error-notification-context.utils.d.ts.map +1 -1
  187. package/dist/esm/components/form/validation-errors/resource-error-notification-context.utils.js +14 -0
  188. package/dist/esm/components/form/validation-errors/resource-error-notification-context.utils.js.map +1 -1
  189. package/dist/esm/components/form/validation-errors/zod-issue-resolver.d.ts +22 -0
  190. package/dist/esm/components/form/validation-errors/zod-issue-resolver.d.ts.map +1 -1
  191. package/dist/esm/components/form/validation-errors/zod-issue-resolver.js +1 -22
  192. package/dist/esm/components/form/validation-errors/zod-issue-resolver.js.map +1 -1
  193. package/dist/esm/components/layout/resizable.d.ts +11 -0
  194. package/dist/esm/components/layout/resizable.d.ts.map +1 -1
  195. package/dist/esm/components/layout/resizable.js.map +1 -1
  196. package/dist/esm/components/navigation/app-level/ApplicationLevel_NavigationBack.d.ts +11 -1
  197. package/dist/esm/components/navigation/app-level/ApplicationLevel_NavigationBack.d.ts.map +1 -1
  198. package/dist/esm/components/navigation/app-level/ApplicationLevel_NavigationBack.js +15 -3
  199. package/dist/esm/components/navigation/app-level/ApplicationLevel_NavigationBack.js.map +1 -1
  200. package/dist/esm/components/navigation/app-level/ApplicationLevel_StatusBar.d.ts +2 -2
  201. package/dist/esm/components/navigation/app-level/ApplicationLevel_StatusBar.d.ts.map +1 -1
  202. package/dist/esm/components/navigation/app-level/ApplicationLevel_StatusBar.js.map +1 -1
  203. package/dist/esm/components/navigation/app-level/HostedComponentInteractionsProvider.d.ts +2 -2
  204. package/dist/esm/components/navigation/app-level/HostedComponentInteractionsProvider.js +2 -2
  205. package/dist/esm/components/navigation/app-level/HostedComponentInteractionsProvider.js.map +1 -1
  206. package/dist/esm/components/navigation/app-level/SidebarResourceBrowser.js +18 -20
  207. package/dist/esm/components/navigation/app-level/SidebarResourceBrowser.js.map +1 -1
  208. package/dist/esm/components/navigation/app-level/useCommandMenuBehavior.d.ts.map +1 -1
  209. package/dist/esm/components/navigation/app-level/useCommandMenuBehavior.js +7 -1
  210. package/dist/esm/components/navigation/app-level/useCommandMenuBehavior.js.map +1 -1
  211. package/dist/esm/components/navigation/app-level/useMenuBarBehavior.d.ts.map +1 -1
  212. package/dist/esm/components/navigation/app-level/useMenuBarBehavior.js +4 -1
  213. package/dist/esm/components/navigation/app-level/useMenuBarBehavior.js.map +1 -1
  214. package/dist/esm/components/navigation/app-level/useMenuUserOrgBehavior.d.ts.map +1 -1
  215. package/dist/esm/components/navigation/app-level/useMenuUserOrgBehavior.js +18 -2
  216. package/dist/esm/components/navigation/app-level/useMenuUserOrgBehavior.js.map +1 -1
  217. package/dist/esm/components/navigation/app-level/useSidebarBehavior.d.ts.map +1 -1
  218. package/dist/esm/components/navigation/app-level/useSidebarBehavior.js +82 -10
  219. package/dist/esm/components/navigation/app-level/useSidebarBehavior.js.map +1 -1
  220. package/dist/esm/components/navigation/app-level/useStatusBarBehavior.d.ts +2 -2
  221. package/dist/esm/components/navigation/app-level/useStatusBarBehavior.d.ts.map +1 -1
  222. package/dist/esm/components/navigation/app-level/useStatusBarBehavior.js.map +1 -1
  223. package/dist/esm/components/resources/ResourceCollectionQuickFilterTabs.d.ts.map +1 -1
  224. package/dist/esm/components/resources/ResourceCollectionQuickFilterTabs.js +8 -1
  225. package/dist/esm/components/resources/ResourceCollectionQuickFilterTabs.js.map +1 -1
  226. package/dist/esm/components/resources/ResourceCollectionToolbar.d.ts +8 -2
  227. package/dist/esm/components/resources/ResourceCollectionToolbar.d.ts.map +1 -1
  228. package/dist/esm/components/resources/ResourceCollectionToolbar.js +6 -2
  229. package/dist/esm/components/resources/ResourceCollectionToolbar.js.map +1 -1
  230. package/dist/esm/components/resources/ResourceLayout_Breadcrumb.d.ts.map +1 -1
  231. package/dist/esm/components/resources/ResourceLayout_Breadcrumb.js +31 -16
  232. package/dist/esm/components/resources/ResourceLayout_Breadcrumb.js.map +1 -1
  233. package/dist/esm/components/resources/ResourceLayout_ContainerDialogs.d.ts.map +1 -1
  234. package/dist/esm/components/resources/ResourceLayout_ContainerDialogs.js +23 -8
  235. package/dist/esm/components/resources/ResourceLayout_ContainerDialogs.js.map +1 -1
  236. package/dist/esm/components/resources/ResourceLayout_ContainerNested.js +2 -2
  237. package/dist/esm/components/resources/ResourceLayout_ContainerNested.js.map +1 -1
  238. package/dist/esm/components/resources/ResourceLayout_Header.d.ts +13 -0
  239. package/dist/esm/components/resources/ResourceLayout_Header.d.ts.map +1 -1
  240. package/dist/esm/components/resources/ResourceLayout_Header.js +55 -28
  241. package/dist/esm/components/resources/ResourceLayout_Header.js.map +1 -1
  242. package/dist/esm/components/resources/ResourceLayout_List.d.ts.map +1 -1
  243. package/dist/esm/components/resources/ResourceLayout_List.js +41 -20
  244. package/dist/esm/components/resources/ResourceLayout_List.js.map +1 -1
  245. package/dist/esm/components/resources/ResourceLayout_List.labels.d.ts.map +1 -1
  246. package/dist/esm/components/resources/ResourceLayout_List.labels.js +1 -2
  247. package/dist/esm/components/resources/ResourceLayout_List.labels.js.map +1 -1
  248. package/dist/esm/components/resources/ResourceLayout_Read.d.ts +9 -4
  249. package/dist/esm/components/resources/ResourceLayout_Read.d.ts.map +1 -1
  250. package/dist/esm/components/resources/ResourceLayout_Read.js +30 -11
  251. package/dist/esm/components/resources/ResourceLayout_Read.js.map +1 -1
  252. package/dist/esm/components/resources/ResourceLayout_ReadSummary.d.ts.map +1 -1
  253. package/dist/esm/components/resources/ResourceLayout_ReadSummary.js +4 -2
  254. package/dist/esm/components/resources/ResourceLayout_ReadSummary.js.map +1 -1
  255. package/dist/esm/components/resources/ResourceLayout_ReadSummary_TableRow.d.ts.map +1 -1
  256. package/dist/esm/components/resources/ResourceLayout_ReadSummary_TableRow.js +6 -2
  257. package/dist/esm/components/resources/ResourceLayout_ReadSummary_TableRow.js.map +1 -1
  258. package/dist/esm/components/resources/ResourceLayout_Search.d.ts.map +1 -1
  259. package/dist/esm/components/resources/ResourceLayout_Search.js +30 -14
  260. package/dist/esm/components/resources/ResourceLayout_Search.js.map +1 -1
  261. package/dist/esm/components/resources/ResourceLayout_SemanticOperationFallback.d.ts.map +1 -1
  262. package/dist/esm/components/resources/ResourceLayout_SemanticOperationFallback.js +14 -198
  263. package/dist/esm/components/resources/ResourceLayout_SemanticOperationFallback.js.map +1 -1
  264. package/dist/esm/components/resources/ResourceLayout_Update.d.ts +2 -2
  265. package/dist/esm/components/resources/ResourceLayout_Update.js +2 -2
  266. package/dist/esm/components/resources/ResourceLayout_Update.js.map +1 -1
  267. package/dist/esm/components/resources/ResourceListItemRenderer.d.ts.map +1 -1
  268. package/dist/esm/components/resources/ResourceListItemRenderer.js +69 -39
  269. package/dist/esm/components/resources/ResourceListItemRenderer.js.map +1 -1
  270. package/dist/esm/components/resources/ResourceOperationActionDropdown.d.ts +32 -0
  271. package/dist/esm/components/resources/ResourceOperationActionDropdown.d.ts.map +1 -0
  272. package/dist/esm/components/resources/ResourceOperationActionDropdown.js +130 -0
  273. package/dist/esm/components/resources/ResourceOperationActionDropdown.js.map +1 -0
  274. package/dist/esm/components/resources/collection-create-placement.utils.d.ts +32 -0
  275. package/dist/esm/components/resources/collection-create-placement.utils.d.ts.map +1 -0
  276. package/dist/esm/components/resources/collection-create-placement.utils.js +37 -0
  277. package/dist/esm/components/resources/collection-create-placement.utils.js.map +1 -0
  278. package/dist/esm/components/resources/embeds/RelatedResourcePreview.d.ts.map +1 -1
  279. package/dist/esm/components/resources/embeds/RelatedResourcePreview.js +5 -1
  280. package/dist/esm/components/resources/embeds/RelatedResourcePreview.js.map +1 -1
  281. package/dist/esm/components/resources/embeds/RelatedResourceSections.d.ts +8 -1
  282. package/dist/esm/components/resources/embeds/RelatedResourceSections.d.ts.map +1 -1
  283. package/dist/esm/components/resources/embeds/RelatedResourceSections.js +49 -2
  284. package/dist/esm/components/resources/embeds/RelatedResourceSections.js.map +1 -1
  285. package/dist/esm/components/resources/embeds/ResourceEmbeds.d.ts +22 -0
  286. package/dist/esm/components/resources/embeds/ResourceEmbeds.d.ts.map +1 -1
  287. package/dist/esm/components/resources/embeds/ResourceEmbeds.js +85 -2
  288. package/dist/esm/components/resources/embeds/ResourceEmbeds.js.map +1 -1
  289. package/dist/esm/components/resources/resourceLayout.utils.d.ts +14 -0
  290. package/dist/esm/components/resources/resourceLayout.utils.d.ts.map +1 -1
  291. package/dist/esm/components/resources/resourceLayout.utils.js +22 -0
  292. package/dist/esm/components/resources/resourceLayout.utils.js.map +1 -1
  293. package/dist/esm/components/resources/skeleton/ArrayField.d.ts.map +1 -1
  294. package/dist/esm/components/resources/skeleton/ArrayField.js +3 -0
  295. package/dist/esm/components/resources/skeleton/ArrayField.js.map +1 -1
  296. package/dist/esm/components/resources/skeleton/FormLayout.d.ts.map +1 -1
  297. package/dist/esm/components/resources/skeleton/FormLayout.js +33 -1
  298. package/dist/esm/components/resources/skeleton/FormLayout.js.map +1 -1
  299. package/dist/esm/components/resources/skeleton/ObjectScope.d.ts.map +1 -1
  300. package/dist/esm/components/resources/skeleton/ObjectScope.js +3 -0
  301. package/dist/esm/components/resources/skeleton/ObjectScope.js.map +1 -1
  302. package/dist/esm/components/resources/skeleton/Section.d.ts +12 -0
  303. package/dist/esm/components/resources/skeleton/Section.d.ts.map +1 -1
  304. package/dist/esm/components/resources/skeleton/Section.js +28 -2
  305. package/dist/esm/components/resources/skeleton/Section.js.map +1 -1
  306. package/dist/esm/components/resources/skeleton/SectionFieldsContext.d.ts +70 -0
  307. package/dist/esm/components/resources/skeleton/SectionFieldsContext.d.ts.map +1 -1
  308. package/dist/esm/components/resources/skeleton/SectionFieldsContext.js +157 -1
  309. package/dist/esm/components/resources/skeleton/SectionFieldsContext.js.map +1 -1
  310. package/dist/esm/components/resources/skeleton/WizardLayout.d.ts +6 -0
  311. package/dist/esm/components/resources/skeleton/WizardLayout.d.ts.map +1 -1
  312. package/dist/esm/components/resources/skeleton/WizardLayout.js +13 -2
  313. package/dist/esm/components/resources/skeleton/WizardLayout.js.map +1 -1
  314. package/dist/esm/components/resources/skeleton/WizardStep.d.ts.map +1 -1
  315. package/dist/esm/components/resources/skeleton/WizardStep.js +2 -1
  316. package/dist/esm/components/resources/skeleton/WizardStep.js.map +1 -1
  317. package/dist/esm/components/resources-fields/_presets/resource-reference/ResourceFieldDisplayPreset_ResourceReference_Default.d.ts.map +1 -1
  318. package/dist/esm/components/resources-fields/_presets/resource-reference/ResourceFieldDisplayPreset_ResourceReference_Default.js +61 -15
  319. package/dist/esm/components/resources-fields/_presets/resource-reference/ResourceFieldDisplayPreset_ResourceReference_Default.js.map +1 -1
  320. package/dist/esm/components/resources-fields/resource-reference/resource-reference.shared.utils.d.ts +24 -2
  321. package/dist/esm/components/resources-fields/resource-reference/resource-reference.shared.utils.d.ts.map +1 -1
  322. package/dist/esm/components/resources-fields/resource-reference/resource-reference.shared.utils.js +69 -1
  323. package/dist/esm/components/resources-fields/resource-reference/resource-reference.shared.utils.js.map +1 -1
  324. package/dist/esm/components/resources-fields/resource-reference/useResourceSearch.d.ts.map +1 -1
  325. package/dist/esm/components/resources-fields/resource-reference/useResourceSearch.js +18 -19
  326. package/dist/esm/components/resources-fields/resource-reference/useResourceSearch.js.map +1 -1
  327. package/dist/esm/components/sections/ContentSectionContainer.d.ts.map +1 -1
  328. package/dist/esm/components/sections/ContentSectionContainer.js +5 -4
  329. package/dist/esm/components/sections/ContentSectionContainer.js.map +1 -1
  330. package/dist/esm/components/sections/stepper.d.ts +5 -0
  331. package/dist/esm/components/sections/stepper.d.ts.map +1 -1
  332. package/dist/esm/components/sections/stepper.js.map +1 -1
  333. package/dist/esm/components/sections/surface.d.ts.map +1 -1
  334. package/dist/esm/components/sections/surface.js +12 -3
  335. package/dist/esm/components/sections/surface.js.map +1 -1
  336. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.d.ts +43 -0
  337. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.d.ts.map +1 -0
  338. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.js +129 -0
  339. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.js.map +1 -0
  340. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.labels.d.ts +3 -0
  341. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.labels.d.ts.map +1 -0
  342. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.labels.js +34 -0
  343. package/dist/esm/components/settings/AppPage_AgentWorkOverrideRateSettings.labels.js.map +1 -0
  344. package/dist/esm/components/settings/AppPage_AppearanceSettings.d.ts.map +1 -1
  345. package/dist/esm/components/settings/AppPage_AppearanceSettings.js +9 -11
  346. package/dist/esm/components/settings/AppPage_AppearanceSettings.js.map +1 -1
  347. package/dist/esm/components/settings/AppPage_AppearanceSettings.labels.d.ts.map +1 -1
  348. package/dist/esm/components/settings/AppPage_AppearanceSettings.labels.js +3 -2
  349. package/dist/esm/components/settings/AppPage_AppearanceSettings.labels.js.map +1 -1
  350. package/dist/esm/components/settings/AppPage_BillingSettings.d.ts +4 -2
  351. package/dist/esm/components/settings/AppPage_BillingSettings.d.ts.map +1 -1
  352. package/dist/esm/components/settings/AppPage_BillingSettings.js +21 -3
  353. package/dist/esm/components/settings/AppPage_BillingSettings.js.map +1 -1
  354. package/dist/esm/components/settings/AppPage_BillingSettings.labels.d.ts.map +1 -1
  355. package/dist/esm/components/settings/AppPage_BillingSettings.labels.js +5 -10
  356. package/dist/esm/components/settings/AppPage_BillingSettings.labels.js.map +1 -1
  357. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.d.ts +58 -0
  358. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.d.ts.map +1 -1
  359. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.js +243 -40
  360. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.js.map +1 -1
  361. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.labels.d.ts.map +1 -1
  362. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.labels.js +67 -6
  363. package/dist/esm/components/settings/AppPage_ConnectedAccountsSettings.labels.js.map +1 -1
  364. package/dist/esm/components/settings/AppPage_InvitationsSettings.d.ts.map +1 -1
  365. package/dist/esm/components/settings/AppPage_InvitationsSettings.js +19 -11
  366. package/dist/esm/components/settings/AppPage_InvitationsSettings.js.map +1 -1
  367. package/dist/esm/components/settings/AppPage_InvitationsSettings.labels.d.ts.map +1 -1
  368. package/dist/esm/components/settings/AppPage_InvitationsSettings.labels.js +4 -2
  369. package/dist/esm/components/settings/AppPage_InvitationsSettings.labels.js.map +1 -1
  370. package/dist/esm/components/settings/SettingsHub.d.ts.map +1 -1
  371. package/dist/esm/components/settings/SettingsHub.js +3 -0
  372. package/dist/esm/components/settings/SettingsHub.js.map +1 -1
  373. package/dist/esm/components/settings/SettingsResourceOperationPanel.d.ts.map +1 -1
  374. package/dist/esm/components/settings/SettingsResourceOperationPanel.js +16 -1
  375. package/dist/esm/components/settings/SettingsResourceOperationPanel.js.map +1 -1
  376. package/dist/esm/components/settings/useOwnerProviderConnections.d.ts +59 -0
  377. package/dist/esm/components/settings/useOwnerProviderConnections.d.ts.map +1 -0
  378. package/dist/esm/components/settings/useOwnerProviderConnections.js +136 -0
  379. package/dist/esm/components/settings/useOwnerProviderConnections.js.map +1 -0
  380. package/dist/esm/components/views/chart-view/chart-view.utils.d.ts +5 -0
  381. package/dist/esm/components/views/chart-view/chart-view.utils.d.ts.map +1 -1
  382. package/dist/esm/components/views/chart-view/chart-view.utils.js +5 -0
  383. package/dist/esm/components/views/chart-view/chart-view.utils.js.map +1 -1
  384. package/dist/esm/components/views/chart-view/useResourceChartData.d.ts +50 -0
  385. package/dist/esm/components/views/chart-view/useResourceChartData.d.ts.map +1 -0
  386. package/dist/esm/components/views/chart-view/useResourceChartData.js +72 -0
  387. package/dist/esm/components/views/chart-view/useResourceChartData.js.map +1 -0
  388. package/dist/esm/components/views/composite-view/CompositeLayout.d.ts.map +1 -1
  389. package/dist/esm/components/views/composite-view/CompositeLayout.js +2 -1
  390. package/dist/esm/components/views/composite-view/CompositeLayout.js.map +1 -1
  391. package/dist/esm/core/app-shell/AppShellBuildingBlocks.d.ts +86 -0
  392. package/dist/esm/core/app-shell/AppShellBuildingBlocks.d.ts.map +1 -0
  393. package/dist/esm/core/app-shell/AppShellBuildingBlocks.js +187 -0
  394. package/dist/esm/core/app-shell/AppShellBuildingBlocks.js.map +1 -0
  395. package/dist/esm/core/app-shell/PortalContainerContext.d.ts +5 -2
  396. package/dist/esm/core/app-shell/PortalContainerContext.d.ts.map +1 -1
  397. package/dist/esm/core/app-shell/PortalContainerContext.js +5 -2
  398. package/dist/esm/core/app-shell/PortalContainerContext.js.map +1 -1
  399. package/dist/esm/core/app-shell/app-shell.schemas.d.ts +18 -9
  400. package/dist/esm/core/app-shell/app-shell.schemas.d.ts.map +1 -1
  401. package/dist/esm/core/app-shell/app-shell.schemas.js +1 -0
  402. package/dist/esm/core/app-shell/app-shell.schemas.js.map +1 -1
  403. package/dist/esm/core/app-shell/useAppShellLayout.d.ts +10 -0
  404. package/dist/esm/core/app-shell/useAppShellLayout.d.ts.map +1 -1
  405. package/dist/esm/core/app-shell/useAppShellLayout.js +28 -5
  406. package/dist/esm/core/app-shell/useAppShellLayout.js.map +1 -1
  407. package/dist/esm/core/app-shell/usePublicShellLayout.d.ts.map +1 -1
  408. package/dist/esm/core/app-shell/usePublicShellLayout.js +38 -0
  409. package/dist/esm/core/app-shell/usePublicShellLayout.js.map +1 -1
  410. package/dist/esm/core/automated-layout/automated-layout.frontend.utils.d.ts +15 -1
  411. package/dist/esm/core/automated-layout/automated-layout.frontend.utils.d.ts.map +1 -1
  412. package/dist/esm/core/automated-layout/automated-layout.frontend.utils.js +47 -13
  413. package/dist/esm/core/automated-layout/automated-layout.frontend.utils.js.map +1 -1
  414. package/dist/esm/core/billing/BillingContext.d.ts +25 -2
  415. package/dist/esm/core/billing/BillingContext.d.ts.map +1 -1
  416. package/dist/esm/core/billing/BillingContext.js +16 -25
  417. package/dist/esm/core/billing/BillingContext.js.map +1 -1
  418. package/dist/esm/core/billing/billing-provider-display.frontend.utils.d.ts +11 -3
  419. package/dist/esm/core/billing/billing-provider-display.frontend.utils.d.ts.map +1 -1
  420. package/dist/esm/core/billing/billing-provider-display.frontend.utils.js +14 -8
  421. package/dist/esm/core/billing/billing-provider-display.frontend.utils.js.map +1 -1
  422. package/dist/esm/core/billing/useBillingPlanChange.d.ts.map +1 -1
  423. package/dist/esm/core/billing/useBillingPlanChange.js +2 -0
  424. package/dist/esm/core/billing/useBillingPlanChange.js.map +1 -1
  425. package/dist/esm/core/components-registry/assert-registry-completeness.frontend.helper.d.ts.map +1 -1
  426. package/dist/esm/core/components-registry/assert-registry-completeness.frontend.helper.js +1 -0
  427. package/dist/esm/core/components-registry/assert-registry-completeness.frontend.helper.js.map +1 -1
  428. package/dist/esm/core/components-registry/provider-component-registry.frontend.service.d.ts +29 -229
  429. package/dist/esm/core/components-registry/provider-component-registry.frontend.service.d.ts.map +1 -1
  430. package/dist/esm/core/components-registry/provider-component-registry.frontend.service.js +29 -327
  431. package/dist/esm/core/components-registry/provider-component-registry.frontend.service.js.map +1 -1
  432. package/dist/esm/core/components-registry/useProviderComponent.frontend.hooks.d.ts +17 -27
  433. package/dist/esm/core/components-registry/useProviderComponent.frontend.hooks.d.ts.map +1 -1
  434. package/dist/esm/core/components-registry/useProviderComponent.frontend.hooks.js +28 -48
  435. package/dist/esm/core/components-registry/useProviderComponent.frontend.hooks.js.map +1 -1
  436. package/dist/esm/core/config/app-configuration-frontend.schemas.d.ts +21 -11
  437. package/dist/esm/core/config/app-configuration-frontend.schemas.d.ts.map +1 -1
  438. package/dist/esm/core/config/app-configuration-frontend.schemas.js +4 -4
  439. package/dist/esm/core/config/app-configuration-frontend.schemas.js.map +1 -1
  440. package/dist/esm/core/config/app-level-components.frontend.schemas.d.ts +17 -0
  441. package/dist/esm/core/config/app-level-components.frontend.schemas.d.ts.map +1 -1
  442. package/dist/esm/core/config/app-level-components.frontend.schemas.js +17 -0
  443. package/dist/esm/core/config/app-level-components.frontend.schemas.js.map +1 -1
  444. package/dist/esm/core/config/chart-view.frontend.schemas.d.ts +10 -10
  445. package/dist/esm/core/config/engine-settings-destinations.d.ts.map +1 -1
  446. package/dist/esm/core/config/engine-settings-destinations.js +221 -6
  447. package/dist/esm/core/config/engine-settings-destinations.js.map +1 -1
  448. package/dist/esm/core/config/launcher-items.frontend.schemas.d.ts +8 -0
  449. package/dist/esm/core/config/launcher-items.frontend.schemas.d.ts.map +1 -1
  450. package/dist/esm/core/config/launcher-items.frontend.schemas.js +1 -0
  451. package/dist/esm/core/config/launcher-items.frontend.schemas.js.map +1 -1
  452. package/dist/esm/core/config/settings-hub.frontend.schemas.d.ts +10 -1
  453. package/dist/esm/core/config/settings-hub.frontend.schemas.d.ts.map +1 -1
  454. package/dist/esm/core/config/settings-hub.frontend.schemas.js +9 -0
  455. package/dist/esm/core/config/settings-hub.frontend.schemas.js.map +1 -1
  456. package/dist/esm/core/config/verify-launcher-content.d.ts.map +1 -1
  457. package/dist/esm/core/config/verify-launcher-content.js +30 -19
  458. package/dist/esm/core/config/verify-launcher-content.js.map +1 -1
  459. package/dist/esm/core/errors/ErrorContext.d.ts.map +1 -1
  460. package/dist/esm/core/errors/ErrorContext.js +9 -1
  461. package/dist/esm/core/errors/ErrorContext.js.map +1 -1
  462. package/dist/esm/core/errors/GlobalErrorHandler.d.ts.map +1 -1
  463. package/dist/esm/core/errors/GlobalErrorHandler.js +5 -4
  464. package/dist/esm/core/errors/GlobalErrorHandler.js.map +1 -1
  465. package/dist/esm/core/errors/RouterErrorBoundary.js +1 -1
  466. package/dist/esm/core/errors/RouterErrorBoundary.js.map +1 -1
  467. package/dist/esm/core/errors/errors-builder.frontend.services.d.ts +2 -2
  468. package/dist/esm/core/errors/errors-builder.frontend.services.d.ts.map +1 -1
  469. package/dist/esm/core/errors/errors-builder.frontend.services.js +4 -4
  470. package/dist/esm/core/errors/errors-builder.frontend.services.js.map +1 -1
  471. package/dist/esm/core/errors/user-facing-error-message.frontend.utils.js +1 -1
  472. package/dist/esm/core/errors/user-facing-error-message.frontend.utils.js.map +1 -1
  473. package/dist/esm/core/events/NotificationContext.d.ts.map +1 -1
  474. package/dist/esm/core/events/NotificationContext.js +23 -5
  475. package/dist/esm/core/events/NotificationContext.js.map +1 -1
  476. package/dist/esm/core/events/events.frontend.schemas.d.ts +110 -43
  477. package/dist/esm/core/events/events.frontend.schemas.d.ts.map +1 -1
  478. package/dist/esm/core/events/events.frontend.schemas.js +89 -15
  479. package/dist/esm/core/events/events.frontend.schemas.js.map +1 -1
  480. package/dist/esm/core/execution/useExecutionParticipationRMM.d.ts +2 -0
  481. package/dist/esm/core/execution/useExecutionParticipationRMM.d.ts.map +1 -1
  482. package/dist/esm/core/execution/useExecutionParticipationRMM.js +2 -1
  483. package/dist/esm/core/execution/useExecutionParticipationRMM.js.map +1 -1
  484. package/dist/esm/core/execution/useExecutionResourceOperationSurface.d.ts +1 -1
  485. package/dist/esm/core/execution/useExecutionResourceOperationSurface.d.ts.map +1 -1
  486. package/dist/esm/core/execution/useExecutionResourceOperationSurface.js +5 -2
  487. package/dist/esm/core/execution/useExecutionResourceOperationSurface.js.map +1 -1
  488. package/dist/esm/core/external-providers/ConsentBasedProviderSdks.d.ts +63 -0
  489. package/dist/esm/core/external-providers/ConsentBasedProviderSdks.d.ts.map +1 -0
  490. package/dist/esm/core/external-providers/ConsentBasedProviderSdks.js +131 -0
  491. package/dist/esm/core/external-providers/ConsentBasedProviderSdks.js.map +1 -0
  492. package/dist/esm/core/external-providers/ProviderAddressLookupCombobox.d.ts +61 -0
  493. package/dist/esm/core/external-providers/ProviderAddressLookupCombobox.d.ts.map +1 -0
  494. package/dist/esm/core/external-providers/ProviderAddressLookupCombobox.js +178 -0
  495. package/dist/esm/core/external-providers/ProviderAddressLookupCombobox.js.map +1 -0
  496. package/dist/esm/core/external-providers/ProviderAddressLookupHost.d.ts +52 -0
  497. package/dist/esm/core/external-providers/ProviderAddressLookupHost.d.ts.map +1 -0
  498. package/dist/esm/core/external-providers/ProviderAddressLookupHost.js +144 -0
  499. package/dist/esm/core/external-providers/ProviderAddressLookupHost.js.map +1 -0
  500. package/dist/esm/core/external-providers/ProviderFilePickerHost.d.ts +22 -1
  501. package/dist/esm/core/external-providers/ProviderFilePickerHost.d.ts.map +1 -1
  502. package/dist/esm/core/external-providers/ProviderFilePickerHost.js +23 -3
  503. package/dist/esm/core/external-providers/ProviderFilePickerHost.js.map +1 -1
  504. package/dist/esm/core/external-providers/provider-address-lookup-selection.frontend.utils.d.ts +55 -0
  505. package/dist/esm/core/external-providers/provider-address-lookup-selection.frontend.utils.d.ts.map +1 -0
  506. package/dist/esm/core/external-providers/provider-address-lookup-selection.frontend.utils.js +65 -0
  507. package/dist/esm/core/external-providers/provider-address-lookup-selection.frontend.utils.js.map +1 -0
  508. package/dist/esm/core/external-providers/provider-scope-reauthorization-offers.frontend.d.ts +63 -0
  509. package/dist/esm/core/external-providers/provider-scope-reauthorization-offers.frontend.d.ts.map +1 -0
  510. package/dist/esm/core/external-providers/provider-scope-reauthorization-offers.frontend.js +100 -0
  511. package/dist/esm/core/external-providers/provider-scope-reauthorization-offers.frontend.js.map +1 -0
  512. package/dist/esm/core/flows-actors/FlowsActorsContext.d.ts +45 -7
  513. package/dist/esm/core/flows-actors/FlowsActorsContext.d.ts.map +1 -1
  514. package/dist/esm/core/flows-actors/FlowsActorsContext.js +112 -28
  515. package/dist/esm/core/flows-actors/FlowsActorsContext.js.map +1 -1
  516. package/dist/esm/core/flows-actors/usePendingDecisions.d.ts +32 -0
  517. package/dist/esm/core/flows-actors/usePendingDecisions.d.ts.map +1 -0
  518. package/dist/esm/core/flows-actors/usePendingDecisions.js +91 -0
  519. package/dist/esm/core/flows-actors/usePendingDecisions.js.map +1 -0
  520. package/dist/esm/core/guidance/GuidanceRenderer.d.ts.map +1 -1
  521. package/dist/esm/core/guidance/GuidanceRenderer.js +3 -2
  522. package/dist/esm/core/guidance/GuidanceRenderer.js.map +1 -1
  523. package/dist/esm/core/i18n/I18nContext.d.ts +22 -8
  524. package/dist/esm/core/i18n/I18nContext.d.ts.map +1 -1
  525. package/dist/esm/core/i18n/I18nContext.js +21 -9
  526. package/dist/esm/core/i18n/I18nContext.js.map +1 -1
  527. package/dist/esm/core/i18n/component-label-resolution.utils.d.ts +5 -3
  528. package/dist/esm/core/i18n/component-label-resolution.utils.d.ts.map +1 -1
  529. package/dist/esm/core/i18n/component-label-resolution.utils.js +5 -3
  530. package/dist/esm/core/i18n/component-label-resolution.utils.js.map +1 -1
  531. package/dist/esm/core/i18n/useI18n.d.ts +2 -1
  532. package/dist/esm/core/i18n/useI18n.d.ts.map +1 -1
  533. package/dist/esm/core/i18n/useI18n.js +2 -1
  534. package/dist/esm/core/i18n/useI18n.js.map +1 -1
  535. package/dist/esm/core/loading/LoadingContext.d.ts.map +1 -1
  536. package/dist/esm/core/loading/LoadingContext.js +7 -1
  537. package/dist/esm/core/loading/LoadingContext.js.map +1 -1
  538. package/dist/esm/core/loading/LoadingGate.d.ts.map +1 -1
  539. package/dist/esm/core/loading/LoadingGate.js +19 -1
  540. package/dist/esm/core/loading/LoadingGate.js.map +1 -1
  541. package/dist/esm/core/monitoring/analytics/AnalyticsContext.d.ts +15 -2
  542. package/dist/esm/core/monitoring/analytics/AnalyticsContext.d.ts.map +1 -1
  543. package/dist/esm/core/monitoring/analytics/AnalyticsContext.js +183 -20
  544. package/dist/esm/core/monitoring/analytics/AnalyticsContext.js.map +1 -1
  545. package/dist/esm/core/monitoring/analytics/AnalyticsEventBridge.js +2 -2
  546. package/dist/esm/core/monitoring/analytics/AnalyticsEventBridge.js.map +1 -1
  547. package/dist/esm/core/monitoring/analytics/analytics-provider-registry.frontend.service.d.ts +7 -15
  548. package/dist/esm/core/monitoring/analytics/analytics-provider-registry.frontend.service.d.ts.map +1 -1
  549. package/dist/esm/core/monitoring/analytics/analytics-provider-registry.frontend.service.js +8 -26
  550. package/dist/esm/core/monitoring/analytics/analytics-provider-registry.frontend.service.js.map +1 -1
  551. package/dist/esm/core/monitoring/analytics/analytics-provider.frontend.interface.d.ts +12 -3
  552. package/dist/esm/core/monitoring/analytics/analytics-provider.frontend.interface.d.ts.map +1 -1
  553. package/dist/esm/core/monitoring/analytics/analytics-provider.frontend.interface.js +3 -2
  554. package/dist/esm/core/monitoring/analytics/analytics-provider.frontend.interface.js.map +1 -1
  555. package/dist/esm/core/monitoring/analytics/providers/backend-proxy-analytics.provider.d.ts +42 -0
  556. package/dist/esm/core/monitoring/analytics/providers/backend-proxy-analytics.provider.d.ts.map +1 -1
  557. package/dist/esm/core/monitoring/analytics/providers/backend-proxy-analytics.provider.js +89 -5
  558. package/dist/esm/core/monitoring/analytics/providers/backend-proxy-analytics.provider.js.map +1 -1
  559. package/dist/esm/core/monitoring/analytics/providers/console-analytics.provider.d.ts +2 -0
  560. package/dist/esm/core/monitoring/analytics/providers/console-analytics.provider.d.ts.map +1 -1
  561. package/dist/esm/core/monitoring/analytics/providers/console-analytics.provider.js +2 -0
  562. package/dist/esm/core/monitoring/analytics/providers/console-analytics.provider.js.map +1 -1
  563. package/dist/esm/core/navigation/NavigationContentAreas.d.ts +78 -0
  564. package/dist/esm/core/navigation/NavigationContentAreas.d.ts.map +1 -1
  565. package/dist/esm/core/navigation/NavigationContentAreas.js +264 -16
  566. package/dist/esm/core/navigation/NavigationContentAreas.js.map +1 -1
  567. package/dist/esm/core/navigation/NavigationContext.d.ts +8 -0
  568. package/dist/esm/core/navigation/NavigationContext.d.ts.map +1 -1
  569. package/dist/esm/core/navigation/NavigationContext.js +137 -30
  570. package/dist/esm/core/navigation/NavigationContext.js.map +1 -1
  571. package/dist/esm/core/navigation/launcher-resolution.d.ts +2 -0
  572. package/dist/esm/core/navigation/launcher-resolution.d.ts.map +1 -1
  573. package/dist/esm/core/navigation/launcher-resolution.js +1 -0
  574. package/dist/esm/core/navigation/launcher-resolution.js.map +1 -1
  575. package/dist/esm/core/navigation/navigation-cascade.d.ts +46 -0
  576. package/dist/esm/core/navigation/navigation-cascade.d.ts.map +1 -0
  577. package/dist/esm/core/navigation/navigation-cascade.js +222 -0
  578. package/dist/esm/core/navigation/navigation-cascade.js.map +1 -0
  579. package/dist/esm/core/navigation/navigation-clean-break.frontend.utils.d.ts.map +1 -1
  580. package/dist/esm/core/navigation/navigation-clean-break.frontend.utils.js +21 -2
  581. package/dist/esm/core/navigation/navigation-clean-break.frontend.utils.js.map +1 -1
  582. package/dist/esm/core/navigation/navigation-controller-internals.d.ts +71 -0
  583. package/dist/esm/core/navigation/navigation-controller-internals.d.ts.map +1 -0
  584. package/dist/esm/core/navigation/navigation-controller-internals.js +84 -0
  585. package/dist/esm/core/navigation/navigation-controller-internals.js.map +1 -0
  586. package/dist/esm/core/navigation/navigation-policy-resolver.service.d.ts +86 -2
  587. package/dist/esm/core/navigation/navigation-policy-resolver.service.d.ts.map +1 -1
  588. package/dist/esm/core/navigation/navigation-policy-resolver.service.js +242 -124
  589. package/dist/esm/core/navigation/navigation-policy-resolver.service.js.map +1 -1
  590. package/dist/esm/core/navigation/navigation.schemas.d.ts +170 -8
  591. package/dist/esm/core/navigation/navigation.schemas.d.ts.map +1 -1
  592. package/dist/esm/core/navigation/navigation.schemas.js +121 -2
  593. package/dist/esm/core/navigation/navigation.schemas.js.map +1 -1
  594. package/dist/esm/core/navigation/navigation.utils.d.ts +102 -6
  595. package/dist/esm/core/navigation/navigation.utils.d.ts.map +1 -1
  596. package/dist/esm/core/navigation/navigation.utils.js +283 -34
  597. package/dist/esm/core/navigation/navigation.utils.js.map +1 -1
  598. package/dist/esm/core/navigation/useIsStackEntryActive.d.ts +0 -10
  599. package/dist/esm/core/navigation/useIsStackEntryActive.d.ts.map +0 -1
  600. package/dist/esm/core/navigation/useIsStackEntryActive.js.map +0 -1
  601. package/dist/esm/core/navigation/useNavigationController.d.ts +28 -157
  602. package/dist/esm/core/navigation/useNavigationController.d.ts.map +1 -1
  603. package/dist/esm/core/navigation/useNavigationController.js +211 -1189
  604. package/dist/esm/core/navigation/useNavigationController.js.map +1 -1
  605. package/dist/esm/core/navigation/useNavigationRouterSync.d.ts +174 -0
  606. package/dist/esm/core/navigation/useNavigationRouterSync.d.ts.map +1 -0
  607. package/dist/esm/core/navigation/useNavigationRouterSync.js +977 -0
  608. package/dist/esm/core/navigation/useNavigationRouterSync.js.map +1 -0
  609. package/dist/esm/core/navigation/useOverlayTitle.d.ts +13 -1
  610. package/dist/esm/core/navigation/useOverlayTitle.d.ts.map +1 -1
  611. package/dist/esm/core/navigation/useOverlayTitle.js +15 -10
  612. package/dist/esm/core/navigation/useOverlayTitle.js.map +1 -1
  613. package/dist/esm/core/navigation/useResponsiveZoneMigration.d.ts +43 -0
  614. package/dist/esm/core/navigation/useResponsiveZoneMigration.d.ts.map +1 -0
  615. package/dist/esm/core/navigation/useResponsiveZoneMigration.js +44 -0
  616. package/dist/esm/core/navigation/useResponsiveZoneMigration.js.map +1 -0
  617. package/dist/esm/core/navigation/zone-collapse-migration.d.ts +83 -0
  618. package/dist/esm/core/navigation/zone-collapse-migration.d.ts.map +1 -0
  619. package/dist/esm/core/navigation/zone-collapse-migration.js +116 -0
  620. package/dist/esm/core/navigation/zone-collapse-migration.js.map +1 -0
  621. package/dist/esm/core/navigation/zone-collapse.d.ts +51 -0
  622. package/dist/esm/core/navigation/zone-collapse.d.ts.map +1 -0
  623. package/dist/esm/core/navigation/zone-collapse.js +59 -0
  624. package/dist/esm/core/navigation/zone-collapse.js.map +1 -0
  625. package/dist/esm/core/navigation/zone-emphasis.d.ts +3 -0
  626. package/dist/esm/core/navigation/zone-emphasis.d.ts.map +1 -1
  627. package/dist/esm/core/navigation/zone-emphasis.js +26 -4
  628. package/dist/esm/core/navigation/zone-emphasis.js.map +1 -1
  629. package/dist/esm/core/navigation/zone-visible-entry.d.ts +22 -0
  630. package/dist/esm/core/navigation/zone-visible-entry.d.ts.map +1 -1
  631. package/dist/esm/core/navigation/zone-visible-entry.js +25 -0
  632. package/dist/esm/core/navigation/zone-visible-entry.js.map +1 -1
  633. package/dist/esm/core/requests/websockets/WebSocketContext.d.ts.map +1 -1
  634. package/dist/esm/core/requests/websockets/WebSocketContext.js +53 -18
  635. package/dist/esm/core/requests/websockets/WebSocketContext.js.map +1 -1
  636. package/dist/esm/core/requests/websockets/WebSocketEventBridge.d.ts.map +1 -1
  637. package/dist/esm/core/requests/websockets/WebSocketEventBridge.js +3 -1
  638. package/dist/esm/core/requests/websockets/WebSocketEventBridge.js.map +1 -1
  639. package/dist/esm/core/requests/websockets/useNotificationBadges.d.ts +22 -0
  640. package/dist/esm/core/requests/websockets/useNotificationBadges.d.ts.map +1 -1
  641. package/dist/esm/core/requests/websockets/useNotificationBadges.js +72 -3
  642. package/dist/esm/core/requests/websockets/useNotificationBadges.js.map +1 -1
  643. package/dist/esm/core/requests/websockets/usePublishNotificationBadgeCount.d.ts +28 -0
  644. package/dist/esm/core/requests/websockets/usePublishNotificationBadgeCount.d.ts.map +1 -0
  645. package/dist/esm/core/requests/websockets/usePublishNotificationBadgeCount.js +86 -0
  646. package/dist/esm/core/requests/websockets/usePublishNotificationBadgeCount.js.map +1 -0
  647. package/dist/esm/core/requests/wildo-http-client-manual-calls.frontend.service.d.ts +38 -3
  648. package/dist/esm/core/requests/wildo-http-client-manual-calls.frontend.service.d.ts.map +1 -1
  649. package/dist/esm/core/requests/wildo-http-client-manual-calls.frontend.service.js +57 -2
  650. package/dist/esm/core/requests/wildo-http-client-manual-calls.frontend.service.js.map +1 -1
  651. package/dist/esm/core/requests/wildo-http-client-resources.frontend.service.d.ts.map +1 -1
  652. package/dist/esm/core/requests/wildo-http-client-resources.frontend.service.js +4 -2
  653. package/dist/esm/core/requests/wildo-http-client-resources.frontend.service.js.map +1 -1
  654. package/dist/esm/core/requests/wildo-http-client.frontend.service.d.ts +30 -1
  655. package/dist/esm/core/requests/wildo-http-client.frontend.service.d.ts.map +1 -1
  656. package/dist/esm/core/requests/wildo-http-client.frontend.service.js +47 -4
  657. package/dist/esm/core/requests/wildo-http-client.frontend.service.js.map +1 -1
  658. package/dist/esm/core/resources/ResourceRegistryContext.d.ts.map +1 -1
  659. package/dist/esm/core/resources/ResourceRegistryContext.js +22 -1
  660. package/dist/esm/core/resources/ResourceRegistryContext.js.map +1 -1
  661. package/dist/esm/core/resources/context-resource-identifiers.frontend.utils.js +1 -1
  662. package/dist/esm/core/resources/context-resource-identifiers.frontend.utils.js.map +1 -1
  663. package/dist/esm/core/resources/frontend-resource.utils.d.ts +22 -1
  664. package/dist/esm/core/resources/frontend-resource.utils.d.ts.map +1 -1
  665. package/dist/esm/core/resources/frontend-resource.utils.js +25 -2
  666. package/dist/esm/core/resources/frontend-resource.utils.js.map +1 -1
  667. package/dist/esm/core/resources/operation-semantics.frontend.utils.d.ts +113 -13
  668. package/dist/esm/core/resources/operation-semantics.frontend.utils.d.ts.map +1 -1
  669. package/dist/esm/core/resources/operation-semantics.frontend.utils.js +173 -20
  670. package/dist/esm/core/resources/operation-semantics.frontend.utils.js.map +1 -1
  671. package/dist/esm/core/resources/relationship-surface-runtime.frontend.utils.d.ts +11 -0
  672. package/dist/esm/core/resources/relationship-surface-runtime.frontend.utils.d.ts.map +1 -1
  673. package/dist/esm/core/resources/relationship-surface-runtime.frontend.utils.js +7 -0
  674. package/dist/esm/core/resources/relationship-surface-runtime.frontend.utils.js.map +1 -1
  675. package/dist/esm/core/resources/resource-label-field-paths.frontend.utils.d.ts +3 -2
  676. package/dist/esm/core/resources/resource-label-field-paths.frontend.utils.d.ts.map +1 -1
  677. package/dist/esm/core/resources/resource-label-field-paths.frontend.utils.js +13 -5
  678. package/dist/esm/core/resources/resource-label-field-paths.frontend.utils.js.map +1 -1
  679. package/dist/esm/core/resources/resources-repository.frontend.service.d.ts +6 -0
  680. package/dist/esm/core/resources/resources-repository.frontend.service.d.ts.map +1 -1
  681. package/dist/esm/core/resources/resources-repository.frontend.service.js +90 -1
  682. package/dist/esm/core/resources/resources-repository.frontend.service.js.map +1 -1
  683. package/dist/esm/core/resources/resources.frontend.schemas.d.ts +139 -16
  684. package/dist/esm/core/resources/resources.frontend.schemas.d.ts.map +1 -1
  685. package/dist/esm/core/resources/resources.frontend.schemas.js +110 -11
  686. package/dist/esm/core/resources/resources.frontend.schemas.js.map +1 -1
  687. package/dist/esm/core/resources/rmm/ResourceMutationManager.d.ts.map +1 -1
  688. package/dist/esm/core/resources/rmm/ResourceMutationManager.js +3 -1
  689. package/dist/esm/core/resources/rmm/ResourceMutationManager.js.map +1 -1
  690. package/dist/esm/core/resources/rmm/update-like-mutation-fallback.frontend.d.ts +10 -0
  691. package/dist/esm/core/resources/rmm/update-like-mutation-fallback.frontend.d.ts.map +1 -1
  692. package/dist/esm/core/resources/rmm/update-like-mutation-fallback.frontend.js +8 -0
  693. package/dist/esm/core/resources/rmm/update-like-mutation-fallback.frontend.js.map +1 -1
  694. package/dist/esm/core/resources/rmm/useResourceRMM.d.ts +7 -0
  695. package/dist/esm/core/resources/rmm/useResourceRMM.d.ts.map +1 -1
  696. package/dist/esm/core/resources/rmm/useResourceRMM.js +9 -2
  697. package/dist/esm/core/resources/rmm/useResourceRMM.js.map +1 -1
  698. package/dist/esm/core/resources/useOperationDirectExecution.d.ts +59 -0
  699. package/dist/esm/core/resources/useOperationDirectExecution.d.ts.map +1 -0
  700. package/dist/esm/core/resources/useOperationDirectExecution.js +278 -0
  701. package/dist/esm/core/resources/useOperationDirectExecution.js.map +1 -0
  702. package/dist/esm/core/resources/useResourceOperationActions.d.ts +1 -1
  703. package/dist/esm/core/resources/useResourceOperationActions.d.ts.map +1 -1
  704. package/dist/esm/core/resources/useResourceOperationActions.js +69 -22
  705. package/dist/esm/core/resources/useResourceOperationActions.js.map +1 -1
  706. package/dist/esm/core/resources/useResourceOperationSurface.d.ts +8 -6
  707. package/dist/esm/core/resources/useResourceOperationSurface.d.ts.map +1 -1
  708. package/dist/esm/core/resources/useResourceOperationSurface.js +3 -2
  709. package/dist/esm/core/resources/useResourceOperationSurface.js.map +1 -1
  710. package/dist/esm/core/runtime/AppRouter.d.ts.map +1 -1
  711. package/dist/esm/core/runtime/AppRouter.js +23 -2
  712. package/dist/esm/core/runtime/AppRouter.js.map +1 -1
  713. package/dist/esm/core/runtime/ApplicationContext.shared.d.ts +4 -2
  714. package/dist/esm/core/runtime/ApplicationContext.shared.d.ts.map +1 -1
  715. package/dist/esm/core/runtime/ApplicationContext.shared.js.map +1 -1
  716. package/dist/esm/core/runtime/ApplicationMainContext.d.ts +12 -2
  717. package/dist/esm/core/runtime/ApplicationMainContext.d.ts.map +1 -1
  718. package/dist/esm/core/runtime/ApplicationMainContext.js +5 -2
  719. package/dist/esm/core/runtime/ApplicationMainContext.js.map +1 -1
  720. package/dist/esm/core/runtime/domain-module.frontend.definitions.d.ts +25 -1
  721. package/dist/esm/core/runtime/domain-module.frontend.definitions.d.ts.map +1 -1
  722. package/dist/esm/core/runtime/domain-module.frontend.definitions.js +37 -1
  723. package/dist/esm/core/runtime/domain-module.frontend.definitions.js.map +1 -1
  724. package/dist/esm/core/runtime/start-application.frontend.service.d.ts +21 -2
  725. package/dist/esm/core/runtime/start-application.frontend.service.d.ts.map +1 -1
  726. package/dist/esm/core/runtime/start-application.frontend.service.js +51 -4
  727. package/dist/esm/core/runtime/start-application.frontend.service.js.map +1 -1
  728. package/dist/esm/core/security/AuthSessionContext.d.ts +11 -0
  729. package/dist/esm/core/security/AuthSessionContext.d.ts.map +1 -1
  730. package/dist/esm/core/security/AuthSessionContext.js +70 -22
  731. package/dist/esm/core/security/AuthSessionContext.js.map +1 -1
  732. package/dist/esm/core/security/StepUpAuthContext.d.ts.map +1 -1
  733. package/dist/esm/core/security/StepUpAuthContext.js +10 -2
  734. package/dist/esm/core/security/StepUpAuthContext.js.map +1 -1
  735. package/dist/esm/core/security/UserOrgsContext.d.ts.map +1 -1
  736. package/dist/esm/core/security/UserOrgsContext.js +72 -8
  737. package/dist/esm/core/security/UserOrgsContext.js.map +1 -1
  738. package/dist/esm/core/security/route-organization-access.frontend.utils.d.ts +7 -0
  739. package/dist/esm/core/security/route-organization-access.frontend.utils.d.ts.map +1 -1
  740. package/dist/esm/core/security/route-organization-access.frontend.utils.js +8 -2
  741. package/dist/esm/core/security/route-organization-access.frontend.utils.js.map +1 -1
  742. package/dist/esm/core/security/useGrantedConsentPurposes.d.ts +30 -0
  743. package/dist/esm/core/security/useGrantedConsentPurposes.d.ts.map +1 -0
  744. package/dist/esm/core/security/useGrantedConsentPurposes.js +38 -0
  745. package/dist/esm/core/security/useGrantedConsentPurposes.js.map +1 -0
  746. package/dist/esm/core/ui/UIContext.d.ts.map +1 -1
  747. package/dist/esm/core/ui/UIContext.js +10 -6
  748. package/dist/esm/core/ui/UIContext.js.map +1 -1
  749. package/dist/esm/core/ui/color-conversion.utils.d.ts +20 -0
  750. package/dist/esm/core/ui/color-conversion.utils.d.ts.map +1 -1
  751. package/dist/esm/core/ui/color-conversion.utils.js +39 -5
  752. package/dist/esm/core/ui/color-conversion.utils.js.map +1 -1
  753. package/dist/esm/core/ui/themes/default.theme.d.ts.map +1 -1
  754. package/dist/esm/core/ui/themes/default.theme.js +22 -2
  755. package/dist/esm/core/ui/themes/default.theme.js.map +1 -1
  756. package/dist/esm/core/ui/ui.frontend.schemas.d.ts +6 -6
  757. package/dist/esm/core/ui/ui.frontend.schemas.d.ts.map +1 -1
  758. package/dist/esm/core/ui/ui.frontend.schemas.js +3 -3
  759. package/dist/esm/core/ui/ui.frontend.schemas.js.map +1 -1
  760. package/dist/esm/index.d.ts +10 -1
  761. package/dist/esm/index.d.ts.map +1 -1
  762. package/dist/esm/index.js +19 -1
  763. package/dist/esm/index.js.map +1 -1
  764. package/dist/esm/testing/app-shell-placement-coverage.d.ts +43 -0
  765. package/dist/esm/testing/app-shell-placement-coverage.d.ts.map +1 -0
  766. package/dist/esm/testing/app-shell-placement-coverage.js +114 -0
  767. package/dist/esm/testing/app-shell-placement-coverage.js.map +1 -0
  768. package/dist/esm/testing/mock-builders.d.ts.map +1 -1
  769. package/dist/esm/testing/mock-builders.js +5 -0
  770. package/dist/esm/testing/mock-builders.js.map +1 -1
  771. package/dist/esm/testing.d.ts +1 -0
  772. package/dist/esm/testing.d.ts.map +1 -1
  773. package/dist/esm/testing.js +1 -0
  774. package/dist/esm/testing.js.map +1 -1
  775. package/package.json +9 -7
  776. package/dist/esm/core/navigation/useIsStackEntryActive.js +0 -15
  777. package/dist/tsconfig.build.tsbuildinfo +0 -1
@@ -5,6 +5,19 @@ import { type ButtonVariants_Variant } from './button';
5
5
  import { type ActionButtonSize } from './action-button';
6
6
  import type { ResourceOperationRiskLevel } from '@wildo-ai/saas-models';
7
7
  import type { DisplayDirection } from '@wildo-ai/zod-decorators';
8
+ /**
9
+ * What an anchored panel's BODY is, which decides the panel's own chrome.
10
+ *
11
+ * A form wants the panel's padding around it; a list of options wants none — a menu runs its rows
12
+ * edge to edge, and padding around a command list draws a second frame inside the first. The body
13
+ * knows which it is, so it says so rather than each renderer guessing from the content.
14
+ */
15
+ export declare enum ActionBarPopoverChrome {
16
+ /** A padded panel for a form or other free content. The default. */
17
+ PANEL = "panel",
18
+ /** An unpadded, menu-width panel for a list of options (a DROPDOWN action). */
19
+ LIST = "list"
20
+ }
8
21
  /**
9
22
  * An anchored panel this action opens instead of firing `onClick`.
10
23
  *
@@ -24,6 +37,8 @@ export interface ActionBarButtonPopover {
24
37
  content: React.ReactNode;
25
38
  /** Accessible name for the panel. Falls back to the action's own label. */
26
39
  title?: string;
40
+ /** What the body is — see {@link ActionBarPopoverChrome}. Omitted means PANEL. */
41
+ chrome?: ActionBarPopoverChrome;
27
42
  }
28
43
  /**
29
44
  * Why an action cannot run right now, and — when there is one — the single step that makes it
@@ -1 +1 @@
1
- {"version":3,"file":"action-bar.d.ts","sourceRoot":"","sources":["../../../../../src/components/actions/action-bar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAA0C,sBAAsB,EAAE,MAAM,qCAAqC,CAAA;AACpH,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAA;AACvH,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,UAAU,CAAA;AACtD,OAAO,EAAE,KAAK,gBAAg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time";
2
2
  import { createComponentResolver } from '../../core/components-registry/component-resolver.frontend.helper.js';
3
3
  import { FrontendComponentType, CorePresetNames } from '@wildo-ai/presets-components-models';
4
+ // --- Contract ---
5
+ /**
6
+ * What an anchored panel's BODY is, which decides the panel's own chrome.
7
+ *
8
+ * A form wants the panel's padding around it; a list of options wants none — a menu runs its rows
9
+ * edge to edge, and padding around a command list draws a second frame inside the first. The body
10
+ * knows which it is, so it says so rather than each renderer guessing from the content.
11
+ */
12
+ export var ActionBarPopoverChrome;
13
+ (function (ActionBarPopoverChrome) {
14
+ /** A padded panel for a form or other free content. The default. */
15
+ ActionBarPopoverChrome["PANEL"] = "panel";
16
+ /** An unpadded, menu-width panel for a list of options (a DROPDOWN action). */
17
+ ActionBarPopoverChrome["LIST"] = "list";
18
+ })(ActionBarPopoverChrome || (ActionBarPopoverChrome = {}));
4
19
  // --- Wrapper ---
5
20
  export function ActionBar({ preset = CorePresetNames.DEFAULT, ...props }) {
6
21
  const Component = createComponentResolver(FrontendComponentType.LOW_LEVEL_ACTION_BAR, 'ActionBar')(preset);
@@ -1 +1 @@
1
- {"version":3,"file":"action-bar.js","sourceRoot":"","sources":["../../../../../src/components/actions/action-bar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,uBAAuB,EAAE,MAAM,iFAAiF,CAAA;AACzH,OAAO,EAAE,qBAAqB,EAAE,eAAe,EAA0B,MAAM,qCAAqC,CAAA;AA0HpH,kBAAkB;AAClB,MAAM,UAAU,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAyC;IAC7G,MAAM,SAAS,GAAG,uBAAuB,CAAiB,qBAAqB,CAAC,oBAAoB,EAAE,WAAW,CAAC,CAAC,MAAM,CAAC,CAAA;IAC1H,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC","sourcesContent":["import React from 'react'\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper'\nimport { FrontendComponentType, CorePresetNames, ActionLabelDisplayMode } from '@wildo-ai/presets-components-models'\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas'\nimport { type ButtonVariants_Variant } from './button'\nimport { type ActionButtonSize } from './action-button'\nimport type { ResourceOperationRiskLevel } from '@wildo-ai/saas-models'\nimport type { DisplayDirection } from '@wildo-ai/zod-decorators'\n\n// --- Contract ---\n\n/**\n * An anchored panel this action opens instead of firing `onClick`.\n *\n * The bar owns the ANCHORING and nothing else: what goes in the panel is the caller's, which keeps\n * the bar free of any knowledge of resources, forms or operations.\n *\n * **A host that cannot anchor must fall back to `onClick`.** An item collapsed into the `…` overflow\n * menu or nested in a subgroup is already inside an open dropdown, and anchoring a second floating\n * layer to a row of the first is a nested-overlay problem with no good answer — the panel traps\n * focus the dropdown is still holding, and dismissing either one is ambiguous. Both are therefore\n * rendered as ordinary items, and `onClick` is expected to reach a host that CAN present the same\n * input (an overlay). An item carrying `popover` must always carry `onClick` too.\n */\nexport interface ActionBarButtonPopover {\n open: boolean\n onOpenChange: (open: boolean) => void\n content: React.ReactNode\n /** Accessible name for the panel. Falls back to the action's own label. */\n title?: string\n}\n\n/**\n * Why an action cannot run right now, and — when there is one — the single step that makes it\n * runnable.\n *\n * An unavailable action stays FOCUSABLE (`aria-disabled`, not the native `disabled`, which removes it\n * from the tab order and swallows the click), and activating it opens a panel that says why. A greyed\n * button that explains nothing is the pattern this replaces: the person cannot tell \"not allowed\"\n * from \"not applicable to these rows\" from \"broken\", and a keyboard or screen-reader user cannot even\n * reach it to wonder.\n *\n * `resolve` exists for the case where the fix is one click away — a bulk action that 2 of 5 selected\n * rows do not qualify for offers \"Keep only the 3 eligible\". It never runs the action itself: the\n * person narrows, looks, and then acts.\n */\nexport interface ActionBarUnavailability {\n /** Localized, specific reason — never a generic \"not available\". */\n reason: string\n resolve?: { label: string; onSelect: () => void }\n}\n\nexport interface ActionBarButton {\n type?: \"button\"\n icon: React.ReactNode\n label: string\n onClick?: () => void\n variant?: ButtonVariants_Variant\n disabled?: boolean\n /**\n * Set instead of `disabled` when the host can say WHY — see {@link ActionBarUnavailability}.\n * `disabled` without a reason remains for states that genuinely have none to give (an action\n * already running).\n */\n unavailability?: ActionBarUnavailability\n /** This action is RUNNING — shown in progress and not pressable again until it ends. */\n busy?: boolean\n className?: string\n featureLocked?: boolean\n featureAvailability?: Record<string, unknown>\n /** Backend risk classification of the operation; lets a host (e.g. the danger\n * zone) pick risk-specific copy. Carried through, never rendered by ActionBar. */\n riskLevel?: ResourceOperationRiskLevel\n /** Operation identifier — lets a host resolve per-operation i18n, e.g.\n * `tResourceOperation(resourceType, operationIdentifier, 'description')`. */\n operationIdentifier?: string\n /**\n * Render this action as an anchored panel rather than a plain button — see\n * {@link ActionBarButtonPopover}, including when a host must ignore it.\n */\n popover?: ActionBarButtonPopover\n}\n\nexport interface ActionBarSeparator {\n type: \"separator\"\n}\n\nexport interface ActionBarSubGroup {\n type: \"subgroup\"\n icon: React.ReactNode\n label: string\n items: ActionBarItem[]\n variant?: ButtonVariants_Variant\n disabled?: boolean\n className?: string\n riskLevel?: ResourceOperationRiskLevel\n operationIdentifier?: string\n}\n\nexport type ActionBarItem = ActionBarButton | ActionBarSeparator | ActionBarSubGroup\n\nexport interface ActionBarProps {\n items: ActionBarItem[]\n maxDisplayed?: number\n size?: ActionButtonSize\n /**\n * How the bar's actions render their labels. When omitted, the bar falls\n * back to the app-wide default (`ComponentStyleTheme.actionLabelDisplayMode`\n * via `useUI()`). `INLINE` renders label text inside each button; `TOOLTIP`\n * keeps buttons icon-only with tooltip labels; `DROPDOWN` collapses every\n * action into the `…` overflow menu (icon + label per row).\n */\n labelDisplayMode?: ActionLabelDisplayMode\n /**\n * Lay the buttons out as a horizontal row (default) or a vertical stack.\n * Drives the toolbar's flex direction, `aria-orientation`, the inter-item\n * separator axis, and the arrow-key navigation axis. Used e.g. by a card whose\n * `cardActionPlacement.orientation` is `VERTICAL`.\n */\n orientation?: DisplayDirection\n 'aria-label'?: string\n className?: string\n}\n\n// --- Wrapper ---\nexport function ActionBar({ preset = CorePresetNames.DEFAULT, ...props }: ActionBarProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<ActionBarProps>(FrontendComponentType.LOW_LEVEL_ACTION_BAR, 'ActionBar')(preset)\n return <Component {...props} />\n}\n"]}
1
+ {"version":3,"file":"action-bar.js","sourceRoot":"","sources":["../../../../../src/components/actions/action-bar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,uBAAuB,EAAE,MAAM,iFAAiF,CAAA;AACzH,OAAO,EAAE,qBAAqB,EAAE,eAAe,EAA0B,MAAM,qCAAqC,CAAA;AAOpH,mBAAmB;AAEnB;;;;;;GAMG;AACH,MAAM,CAAN,IAAY,sBAKX;AALD,WAAY,sBAAsB;IAChC,oEAAoE;IACpE,yCAAe,CAAA;IACf,+EAA+E;IAC/E,uCAAa,CAAA;AACf,CAAC,EALW,sBAAsB,KAAtB,sBAAsB,QAKjC;AAqHD,kBAAkB;AAClB,MAAM,UAAU,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAyC;IAC7G,MAAM,SAAS,GAAG,uBAAuB,CAAiB,qBAAqB,CAAC,oBAAoB,EAAE,WAAW,CAAC,CAAC,MAAM,CAAC,CAAA;IAC1H,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC","sourcesContent":["import React from 'react'\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper'\nimport { FrontendComponentType, CorePresetNames, ActionLabelDisplayMode } from '@wildo-ai/presets-components-models'\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas'\nimport { type ButtonVariants_Variant } from './button'\nimport { type ActionButtonSize } from './action-button'\nimport type { ResourceOperationRiskLevel } from '@wildo-ai/saas-models'\nimport type { DisplayDirection } from '@wildo-ai/zod-decorators'\n\n// --- Contract ---\n\n/**\n * What an anchored panel's BODY is, which decides the panel's own chrome.\n *\n * A form wants the panel's padding around it; a list of options wants none — a menu runs its rows\n * edge to edge, and padding around a command list draws a second frame inside the first. The body\n * knows which it is, so it says so rather than each renderer guessing from the content.\n */\nexport enum ActionBarPopoverChrome {\n /** A padded panel for a form or other free content. The default. */\n PANEL = 'panel',\n /** An unpadded, menu-width panel for a list of options (a DROPDOWN action). */\n LIST = 'list',\n}\n\n/**\n * An anchored panel this action opens instead of firing `onClick`.\n *\n * The bar owns the ANCHORING and nothing else: what goes in the panel is the caller's, which keeps\n * the bar free of any knowledge of resources, forms or operations.\n *\n * **A host that cannot anchor must fall back to `onClick`.** An item collapsed into the `…` overflow\n * menu or nested in a subgroup is already inside an open dropdown, and anchoring a second floating\n * layer to a row of the first is a nested-overlay problem with no good answer — the panel traps\n * focus the dropdown is still holding, and dismissing either one is ambiguous. Both are therefore\n * rendered as ordinary items, and `onClick` is expected to reach a host that CAN present the same\n * input (an overlay). An item carrying `popover` must always carry `onClick` too.\n */\nexport interface ActionBarButtonPopover {\n open: boolean\n onOpenChange: (open: boolean) => void\n content: React.ReactNode\n /** Accessible name for the panel. Falls back to the action's own label. */\n title?: string\n /** What the body is — see {@link ActionBarPopoverChrome}. Omitted means PANEL. */\n chrome?: ActionBarPopoverChrome\n}\n\n/**\n * Why an action cannot run right now, and — when there is one — the single step that makes it\n * runnable.\n *\n * An unavailable action stays FOCUSABLE (`aria-disabled`, not the native `disabled`, which removes it\n * from the tab order and swallows the click), and activating it opens a panel that says why. A greyed\n * button that explains nothing is the pattern this replaces: the person cannot tell \"not allowed\"\n * from \"not applicable to these rows\" from \"broken\", and a keyboard or screen-reader user cannot even\n * reach it to wonder.\n *\n * `resolve` exists for the case where the fix is one click away — a bulk action that 2 of 5 selected\n * rows do not qualify for offers \"Keep only the 3 eligible\". It never runs the action itself: the\n * person narrows, looks, and then acts.\n */\nexport interface ActionBarUnavailability {\n /** Localized, specific reason — never a generic \"not available\". */\n reason: string\n resolve?: { label: string; onSelect: () => void }\n}\n\nexport interface ActionBarButton {\n type?: \"button\"\n icon: React.ReactNode\n label: string\n onClick?: () => void\n variant?: ButtonVariants_Variant\n disabled?: boolean\n /**\n * Set instead of `disabled` when the host can say WHY — see {@link ActionBarUnavailability}.\n * `disabled` without a reason remains for states that genuinely have none to give (an action\n * already running).\n */\n unavailability?: ActionBarUnavailability\n /** This action is RUNNING — shown in progress and not pressable again until it ends. */\n busy?: boolean\n className?: string\n featureLocked?: boolean\n featureAvailability?: Record<string, unknown>\n /** Backend risk classification of the operation; lets a host (e.g. the danger\n * zone) pick risk-specific copy. Carried through, never rendered by ActionBar. */\n riskLevel?: ResourceOperationRiskLevel\n /** Operation identifier — lets a host resolve per-operation i18n, e.g.\n * `tResourceOperation(resourceType, operationIdentifier, 'description')`. */\n operationIdentifier?: string\n /**\n * Render this action as an anchored panel rather than a plain button — see\n * {@link ActionBarButtonPopover}, including when a host must ignore it.\n */\n popover?: ActionBarButtonPopover\n}\n\nexport interface ActionBarSeparator {\n type: \"separator\"\n}\n\nexport interface ActionBarSubGroup {\n type: \"subgroup\"\n icon: React.ReactNode\n label: string\n items: ActionBarItem[]\n variant?: ButtonVariants_Variant\n disabled?: boolean\n className?: string\n riskLevel?: ResourceOperationRiskLevel\n operationIdentifier?: string\n}\n\nexport type ActionBarItem = ActionBarButton | ActionBarSeparator | ActionBarSubGroup\n\nexport interface ActionBarProps {\n items: ActionBarItem[]\n maxDisplayed?: number\n size?: ActionButtonSize\n /**\n * How the bar's actions render their labels. When omitted, the bar falls\n * back to the app-wide default (`ComponentStyleTheme.actionLabelDisplayMode`\n * via `useUI()`). `INLINE` renders label text inside each button; `TOOLTIP`\n * keeps buttons icon-only with tooltip labels; `DROPDOWN` collapses every\n * action into the `…` overflow menu (icon + label per row).\n */\n labelDisplayMode?: ActionLabelDisplayMode\n /**\n * Lay the buttons out as a horizontal row (default) or a vertical stack.\n * Drives the toolbar's flex direction, `aria-orientation`, the inter-item\n * separator axis, and the arrow-key navigation axis. Used e.g. by a card whose\n * `cardActionPlacement.orientation` is `VERTICAL`.\n */\n orientation?: DisplayDirection\n 'aria-label'?: string\n className?: string\n}\n\n// --- Wrapper ---\nexport function ActionBar({ preset = CorePresetNames.DEFAULT, ...props }: ActionBarProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<ActionBarProps>(FrontendComponentType.LOW_LEVEL_ACTION_BAR, 'ActionBar')(preset)\n return <Component {...props} />\n}\n"]}
@@ -2,7 +2,62 @@ import React from 'react';
2
2
  import type { SerializableZodSchema } from '@wildo-ai/zod-decorators';
3
3
  import { ComponentPresetProps } from '../../../core/components-registry/component-registry.frontend.schemas';
4
4
  import type { ComponentProps } from 'react';
5
- export type AI_ApprovalRequestProps = ComponentProps<"div"> & {
5
+ /** One person a decision may be moved to, as the surface shows them. `value` is their id. */
6
+ export type AI_ApprovalReassignCandidate = {
7
+ value: string;
8
+ label: string;
9
+ };
10
+ /** One reason a decision's clocks may be paused for (#1628). `value` is the gate's pause-state identifier. */
11
+ export type AI_ApprovalPauseStateOption = {
12
+ value: string;
13
+ label: string;
14
+ };
15
+ /**
16
+ * One reason an approver may give for changing or rejecting an agent's proposal (#1921). `value` is a code of the
17
+ * application's declared vocabulary (`agentWorkReview.reasonCodes`); `label` is its word, as LOCALIZED text the
18
+ * surface's owner resolved from `system_enums.AgentWorkReasonCode.<code>` — the code itself when no word is authored.
19
+ */
20
+ export type AI_ApprovalReasonCodeOption = {
21
+ value: string;
22
+ label: string;
23
+ };
24
+ /**
25
+ * What else a person may do with a decision besides answering it (#1594 D12). Each is offered only when its
26
+ * callback is supplied, so a surface shows exactly the acts its owner can carry out — never a button that
27
+ * submits into nothing. Declared here as well as on the preset: this module is the contract consumers import.
28
+ */
29
+ export type AI_ApprovalRoutingProps = {
30
+ /** Take a decision routed to a role you hold for yourself. */
31
+ onClaim?: (approvalId: string) => void;
32
+ /** Give a decision you claimed back to its role. */
33
+ onUnclaim?: (approvalId: string) => void;
34
+ /** The reassign picker opened: load who it may go to, and pass them back as `reassignCandidates`. */
35
+ onReassignOpen?: (approvalId: string) => void;
36
+ /** Only people who could answer it. Absent while loading; empty when nobody else can. */
37
+ reassignCandidates?: readonly AI_ApprovalReassignCandidate[];
38
+ onReassign?: (approvalId: string, targetUserId: string, comment?: string) => void;
39
+ /** What the last act came to, as LOCALIZED text the surface's owner resolved. Absent when there is nothing to say. */
40
+ actionNotice?: string;
41
+ /**
42
+ * Stop the decision's CLAIM and DECISION deadlines, naming one of `pauseStateOptions` (#1628). Offered only
43
+ * with at least one option. Pausing never stops the decision from expiring.
44
+ */
45
+ onPauseClock?: (approvalId: string, pauseStateRef: string) => void;
46
+ /** Restart paused deadlines; the paused time is added to them. */
47
+ onResumeClock?: (approvalId: string) => void;
48
+ /** The reasons the gate allows its deadlines to be paused for. */
49
+ pauseStateOptions?: readonly AI_ApprovalPauseStateOption[];
50
+ /** The next deadline ahead of the decision, as LOCALIZED text the surface's owner resolved. */
51
+ deadlineNotice?: string;
52
+ /** Set while its deadlines are paused: why, as LOCALIZED text the surface's owner resolved. */
53
+ clockPausedNotice?: string;
54
+ };
55
+ export type AI_ApprovalRequestProps = ComponentProps<"div"> & AI_ApprovalRoutingProps & {
56
+ /**
57
+ * Whether THIS viewer may answer it (#1594). `false` renders the request with no actions and shows
58
+ * `actionNotice` instead — a question a reviewer answers. Default `true`.
59
+ */
60
+ answerable?: boolean;
6
61
  approvalId: string;
7
62
  actionDescription: string;
8
63
  /**
@@ -50,9 +105,19 @@ export type AI_ApprovalRequestProps = ComponentProps<"div"> & {
50
105
  * from their edit rather than from the model's proposal.
51
106
  */
52
107
  rejectedArguments?: Record<string, unknown>;
53
- /** `modifiedToolArgs` is present only when the approver EDITED the arguments (#566). */
54
- onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>) => void;
55
- onDeny?: (approvalId: string, comment?: string) => void;
108
+ /**
109
+ * The reasons an approver may give when they CHANGE or REJECT the proposal (#1921). Offered only then — approving
110
+ * the call as proposed is not a correction and needs no reason — and never required: a reason is optional evidence
111
+ * for the override rate's breakdown, not a gate on answering. Absent or empty: no picker.
112
+ */
113
+ reasonCodeOptions?: readonly AI_ApprovalReasonCodeOption[];
114
+ /**
115
+ * `modifiedToolArgs` is present only when the approver EDITED the arguments (#566); `reasonCode` only when they gave a
116
+ * reason for that edit (#1921).
117
+ */
118
+ onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>, reasonCode?: string) => void;
119
+ /** `reasonCode` is present only when the approver gave a reason for the rejection (#1921). */
120
+ onDeny?: (approvalId: string, comment?: string, reasonCode?: string) => void;
56
121
  onEscalate?: (approvalId: string, comment?: string) => void;
57
122
  isProcessing?: boolean;
58
123
  createdAt?: Date;
@@ -68,11 +133,36 @@ export type AI_ApprovalQueueItem = {
68
133
  requiredRoles?: string[];
69
134
  executionContext?: Record<string, unknown>;
70
135
  createdAt?: Date;
136
+ /** The gated tool, rendered as authored (#455). */
137
+ toolName?: string;
138
+ /** Which routing acts THIS item offers (#1594). Unset means none. */
139
+ canEscalate?: boolean;
140
+ canClaim?: boolean;
141
+ canUnclaim?: boolean;
142
+ canReassign?: boolean;
143
+ reassignCandidates?: readonly AI_ApprovalReassignCandidate[];
144
+ actionNotice?: string;
145
+ /** #1628: whether this item offers Pause / Resume, the reasons it may be paused for, and its deadline lines. */
146
+ canPauseClock?: boolean;
147
+ canResumeClock?: boolean;
148
+ pauseStateOptions?: readonly AI_ApprovalPauseStateOption[];
149
+ deadlineNotice?: string;
150
+ clockPausedNotice?: string;
151
+ /** #1921: the reasons a reviewer may give when changing or rejecting this item's proposal. */
152
+ reasonCodeOptions?: readonly AI_ApprovalReasonCodeOption[];
153
+ /**
154
+ * #1921: offer the argument editor on this item — a reviewer may CHANGE the proposed call, not only approve or reject
155
+ * it. Only for an item whose answer door carries `modifiedToolArgs`; see `AI_ApprovalRequestProps`.
156
+ */
157
+ allowArgumentModification?: boolean;
158
+ /** The gated tool's input-schema descriptor, so the editor offers the tool's fields (#587). */
159
+ argumentsSchema?: SerializableZodSchema;
71
160
  };
72
- export type AI_ApprovalQueueProps = ComponentProps<"div"> & {
161
+ export type AI_ApprovalQueueProps = ComponentProps<"div"> & Omit<AI_ApprovalRoutingProps, 'reassignCandidates' | 'actionNotice' | 'pauseStateOptions' | 'deadlineNotice' | 'clockPausedNotice'> & {
73
162
  items: AI_ApprovalQueueItem[];
74
- onApprove?: (approvalId: string, comment?: string) => void;
75
- onDeny?: (approvalId: string, comment?: string) => void;
163
+ /** `modifiedToolArgs` only when the reviewer edited the call; `reasonCode` only when they gave a reason (#1921). */
164
+ onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>, reasonCode?: string) => void;
165
+ onDeny?: (approvalId: string, comment?: string, reasonCode?: string) => void;
76
166
  onEscalate?: (approvalId: string, comment?: string) => void;
77
167
  processingIds?: Set<string>;
78
168
  filter?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"approval.d.ts","sourceRoot":"","sources":["../../../../../../src/components/ai-elements/decision/approval.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAA;AAErE,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAA;AACvH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAI3C,MAAM,MAAM,uBAAuB,GAAG,cAAc,CAAC,KAAK,CAAC,GAAG;IAC5D,UAAU,EAAE,MAAM,CAAA;IAClB,iBAAiB,EAAE,MAAM,CAAA;IACzB;;;OAGG;IACH,SAAS,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,GAAG,UAAU,CAAA;IAClD,WAAW,EAAE,MAAM,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,IAAI,CAAA;IAChB,aAAa,CAAC,EAAE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qBAAqB,CAAC,gCAAgC,EAAE,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAA;IAC5J,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC","sourcesContent":["import React from 'react'\nimport { FrontendComponentType, CorePresetNames } from '@wildo-ai/presets-components-models'\nimport type { SerializableZodSchema } from '@wildo-ai/zod-decorators'\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper'\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas'\nimport type { ComponentProps } from 'react'\n\n// --- Contracts ---\n\nexport type AI_ApprovalRequestProps = ComponentProps<\"div\"> & {\n approvalId: string\n actionDescription: string\n /**\n * OPTIONAL, because nothing populates it — see the preset implementation's note. Absent means no\n * risk badge; a default would assert a severity nobody declared (#528).\n */\n riskLevel?: \"low\" | \"medium\" | \"high\" | \"critical\"\n executionId: string\n systemRef?: string\n expiresAt?: Date\n requiredRoles?: string[]\n /**\n * The gated tool call, and the arguments proposed for it.\n *\n * `toolName` is an IDENTIFIER, rendered as authored — it is the thing the agent asked to run,\n * and humanizing it here would invent display text no i18n tree owns.\n * `executionContext` carries the arguments (#455).\n */\n toolName?: string\n executionContext?: Record<string, unknown>\n /**\n * Offer the approver an EDITOR over the proposed arguments (#566) — see the preset implementation\n * for why this is opt-in per surface: turning it on changes what an approval MEANS, from assenting\n * to the agent's call to authoring one.\n *\n * Declared HERE as well as on the preset because this module is the CONTRACT every consumer\n * imports; the preset behind it is reached through the registry. A prop added only to the preset\n * is invisible to callers and rejected by this type — which is exactly what happened while adding\n * it, and is the resolver hop `positive-evidence-must-name-its-target.md` records.\n */\n allowArgumentModification?: boolean\n /**\n * The gated tool's input schema as a `SerializableZodSchema` descriptor (#587). When present and\n * renderable, the argument editor offers the tool's fields instead of raw JSON; the raw editor stays\n * reachable, and is the fallback for any shape the fields cannot express.\n */\n argumentsSchema?: SerializableZodSchema\n /**\n * The server's refusal of the last submitted edit (#587). The approval is still pending, so the\n * editor stays open and shows why.\n */\n argumentModificationError?: string\n /**\n * The arguments the approver submitted when that edit was refused (#587), so the reopened editor starts\n * from their edit rather than from the model's proposal.\n */\n rejectedArguments?: Record<string, unknown>\n /** `modifiedToolArgs` is present only when the approver EDITED the arguments (#566). */\n onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>) => void\n onDeny?: (approvalId: string, comment?: string) => void\n onEscalate?: (approvalId: string, comment?: string) => void\n isProcessing?: boolean\n createdAt?: Date\n}\n\nexport type AI_ApprovalQueueItem = {\n approvalId: string\n executionId: string\n systemRef: string\n actionDescription: string\n /** OPTIONAL for the same reason as on a single request — nothing populates it (#528). */\n riskLevel?: \"low\" | \"medium\" | \"high\" | \"critical\"\n expiresAt?: Date\n requiredRoles?: string[]\n executionContext?: Record<string, unknown>\n createdAt?: Date\n}\n\nexport type AI_ApprovalQueueProps = ComponentProps<\"div\"> & {\n items: AI_ApprovalQueueItem[]\n onApprove?: (approvalId: string, comment?: string) => void\n onDeny?: (approvalId: string, comment?: string) => void\n onEscalate?: (approvalId: string, comment?: string) => void\n processingIds?: Set<string>\n filter?: string\n onFilterChange?: (filter: string) => void\n}\n\nexport type AI_DecisionOption = {\n id: string\n label: string\n description?: string\n variant?: \"default\" | \"destructive\" | \"outline\"\n}\n\nexport type AI_DecisionRequestProps = Omit<ComponentProps<\"div\">, \"onSelect\"> & {\n decisionId: string\n title: string\n description: string\n options: AI_DecisionOption[]\n riskLevel?: string\n deadline?: string\n undoGracePeriodMs?: number\n onSelect?: (decisionId: string, optionId: string) => void\n}\n\nexport type AI_HumanInputRequestProps = Omit<ComponentProps<\"div\">, \"onSubmit\"> & {\n requestId: string\n prompt: string\n inputType?: \"text\" | \"textarea\"\n placeholder?: string\n maxLength?: number\n deadline?: string\n onSubmit?: (requestId: string, value: string) => void\n}\n\n// --- Wrappers ---\n\nexport function AI_ApprovalRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_ApprovalRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_ApprovalRequestProps>(FrontendComponentType.LOW_LEVEL_AI_APPROVAL_REQUEST, 'AI_ApprovalRequest')(preset)\n return <Component {...props} />\n}\n\nexport function AI_ApprovalQueue({ preset = CorePresetNames.DEFAULT, ...props }: AI_ApprovalQueueProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_ApprovalQueueProps>(FrontendComponentType.LOW_LEVEL_AI_APPROVAL_QUEUE, 'AI_ApprovalQueue')(preset)\n return <Component {...props} />\n}\n\nexport function AI_DecisionRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_DecisionRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_DecisionRequestProps>(FrontendComponentType.LOW_LEVEL_AI_DECISION_REQUEST, 'AI_DecisionRequest')(preset)\n return <Component {...props} />\n}\n\nexport function AI_HumanInputRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_HumanInputRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_HumanInputRequestProps>(FrontendComponentType.LOW_LEVEL_AI_HUMAN_INPUT_REQUEST, 'AI_HumanInputRequest')(preset)\n return <Component {...props} />\n}\n"]}
1
+ {"version":3,"file":"approval.js","sourceRoot":"","sources":["../../../../../../src/components/ai-elements/decision/approval.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,qBAAqB,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAA;AAE5F,OAAO,EAAE,uBAAuB,EAAE,MAAM,iFAAiF,CAAA;AAsMzH,mBAAmB;AAEnB,MAAM,UAAU,kBAAkB,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAkD;IAC/H,MAAM,SAAS,GAAG,uBAAuB,CAA0B,qBAAqB,CAAC,6BAA6B,EAAE,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAA;IACrJ,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAgD;IAC3H,MAAM,SAAS,GAAG,uBAAuB,CAAwB,qBAAqB,CAAC,2BAA2B,EAAE,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAA;IAC/I,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAkD;IAC/H,MAAM,SAAS,GAAG,uBAAuB,CAA0B,qBAAqB,CAAC,6BAA6B,EAAE,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAA;IACrJ,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAAoD;IACnI,MAAM,SAAS,GAAG,uBAAuB,CAA4B,qBAAqB,CAAC,gCAAgC,EAAE,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAA;IAC5J,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAA;AACjC,CAAC","sourcesContent":["import React from 'react'\nimport { FrontendComponentType, CorePresetNames } from '@wildo-ai/presets-components-models'\nimport type { SerializableZodSchema } from '@wildo-ai/zod-decorators'\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper'\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas'\nimport type { ComponentProps } from 'react'\n\n// --- Contracts ---\n\n/** One person a decision may be moved to, as the surface shows them. `value` is their id. */\nexport type AI_ApprovalReassignCandidate = { value: string; label: string }\n\n/** One reason a decision's clocks may be paused for (#1628). `value` is the gate's pause-state identifier. */\nexport type AI_ApprovalPauseStateOption = { value: string; label: string }\n\n/**\n * One reason an approver may give for changing or rejecting an agent's proposal (#1921). `value` is a code of the\n * application's declared vocabulary (`agentWorkReview.reasonCodes`); `label` is its word, as LOCALIZED text the\n * surface's owner resolved from `system_enums.AgentWorkReasonCode.<code>` — the code itself when no word is authored.\n */\nexport type AI_ApprovalReasonCodeOption = { value: string; label: string }\n\n/**\n * What else a person may do with a decision besides answering it (#1594 D12). Each is offered only when its\n * callback is supplied, so a surface shows exactly the acts its owner can carry out — never a button that\n * submits into nothing. Declared here as well as on the preset: this module is the contract consumers import.\n */\nexport type AI_ApprovalRoutingProps = {\n /** Take a decision routed to a role you hold for yourself. */\n onClaim?: (approvalId: string) => void\n /** Give a decision you claimed back to its role. */\n onUnclaim?: (approvalId: string) => void\n /** The reassign picker opened: load who it may go to, and pass them back as `reassignCandidates`. */\n onReassignOpen?: (approvalId: string) => void\n /** Only people who could answer it. Absent while loading; empty when nobody else can. */\n reassignCandidates?: readonly AI_ApprovalReassignCandidate[]\n onReassign?: (approvalId: string, targetUserId: string, comment?: string) => void\n /** What the last act came to, as LOCALIZED text the surface's owner resolved. Absent when there is nothing to say. */\n actionNotice?: string\n /**\n * Stop the decision's CLAIM and DECISION deadlines, naming one of `pauseStateOptions` (#1628). Offered only\n * with at least one option. Pausing never stops the decision from expiring.\n */\n onPauseClock?: (approvalId: string, pauseStateRef: string) => void\n /** Restart paused deadlines; the paused time is added to them. */\n onResumeClock?: (approvalId: string) => void\n /** The reasons the gate allows its deadlines to be paused for. */\n pauseStateOptions?: readonly AI_ApprovalPauseStateOption[]\n /** The next deadline ahead of the decision, as LOCALIZED text the surface's owner resolved. */\n deadlineNotice?: string\n /** Set while its deadlines are paused: why, as LOCALIZED text the surface's owner resolved. */\n clockPausedNotice?: string\n}\n\nexport type AI_ApprovalRequestProps = ComponentProps<\"div\"> & AI_ApprovalRoutingProps & {\n /**\n * Whether THIS viewer may answer it (#1594). `false` renders the request with no actions and shows\n * `actionNotice` instead — a question a reviewer answers. Default `true`.\n */\n answerable?: boolean\n approvalId: string\n actionDescription: string\n /**\n * OPTIONAL, because nothing populates it — see the preset implementation's note. Absent means no\n * risk badge; a default would assert a severity nobody declared (#528).\n */\n riskLevel?: \"low\" | \"medium\" | \"high\" | \"critical\"\n executionId: string\n systemRef?: string\n expiresAt?: Date\n requiredRoles?: string[]\n /**\n * The gated tool call, and the arguments proposed for it.\n *\n * `toolName` is an IDENTIFIER, rendered as authored — it is the thing the agent asked to run,\n * and humanizing it here would invent display text no i18n tree owns.\n * `executionContext` carries the arguments (#455).\n */\n toolName?: string\n executionContext?: Record<string, unknown>\n /**\n * Offer the approver an EDITOR over the proposed arguments (#566) — see the preset implementation\n * for why this is opt-in per surface: turning it on changes what an approval MEANS, from assenting\n * to the agent's call to authoring one.\n *\n * Declared HERE as well as on the preset because this module is the CONTRACT every consumer\n * imports; the preset behind it is reached through the registry. A prop added only to the preset\n * is invisible to callers and rejected by this type — which is exactly what happened while adding\n * it, and is the resolver hop `positive-evidence-must-name-its-target.md` records.\n */\n allowArgumentModification?: boolean\n /**\n * The gated tool's input schema as a `SerializableZodSchema` descriptor (#587). When present and\n * renderable, the argument editor offers the tool's fields instead of raw JSON; the raw editor stays\n * reachable, and is the fallback for any shape the fields cannot express.\n */\n argumentsSchema?: SerializableZodSchema\n /**\n * The server's refusal of the last submitted edit (#587). The approval is still pending, so the\n * editor stays open and shows why.\n */\n argumentModificationError?: string\n /**\n * The arguments the approver submitted when that edit was refused (#587), so the reopened editor starts\n * from their edit rather than from the model's proposal.\n */\n rejectedArguments?: Record<string, unknown>\n /**\n * The reasons an approver may give when they CHANGE or REJECT the proposal (#1921). Offered only then — approving\n * the call as proposed is not a correction and needs no reason — and never required: a reason is optional evidence\n * for the override rate's breakdown, not a gate on answering. Absent or empty: no picker.\n */\n reasonCodeOptions?: readonly AI_ApprovalReasonCodeOption[]\n /**\n * `modifiedToolArgs` is present only when the approver EDITED the arguments (#566); `reasonCode` only when they gave a\n * reason for that edit (#1921).\n */\n onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>, reasonCode?: string) => void\n /** `reasonCode` is present only when the approver gave a reason for the rejection (#1921). */\n onDeny?: (approvalId: string, comment?: string, reasonCode?: string) => void\n onEscalate?: (approvalId: string, comment?: string) => void\n isProcessing?: boolean\n createdAt?: Date\n}\n\nexport type AI_ApprovalQueueItem = {\n approvalId: string\n executionId: string\n systemRef: string\n actionDescription: string\n /** OPTIONAL for the same reason as on a single request — nothing populates it (#528). */\n riskLevel?: \"low\" | \"medium\" | \"high\" | \"critical\"\n expiresAt?: Date\n requiredRoles?: string[]\n executionContext?: Record<string, unknown>\n createdAt?: Date\n /** The gated tool, rendered as authored (#455). */\n toolName?: string\n /** Which routing acts THIS item offers (#1594). Unset means none. */\n canEscalate?: boolean\n canClaim?: boolean\n canUnclaim?: boolean\n canReassign?: boolean\n reassignCandidates?: readonly AI_ApprovalReassignCandidate[]\n actionNotice?: string\n /** #1628: whether this item offers Pause / Resume, the reasons it may be paused for, and its deadline lines. */\n canPauseClock?: boolean\n canResumeClock?: boolean\n pauseStateOptions?: readonly AI_ApprovalPauseStateOption[]\n deadlineNotice?: string\n clockPausedNotice?: string\n /** #1921: the reasons a reviewer may give when changing or rejecting this item's proposal. */\n reasonCodeOptions?: readonly AI_ApprovalReasonCodeOption[]\n /**\n * #1921: offer the argument editor on this item — a reviewer may CHANGE the proposed call, not only approve or reject\n * it. Only for an item whose answer door carries `modifiedToolArgs`; see `AI_ApprovalRequestProps`.\n */\n allowArgumentModification?: boolean\n /** The gated tool's input-schema descriptor, so the editor offers the tool's fields (#587). */\n argumentsSchema?: SerializableZodSchema\n}\n\nexport type AI_ApprovalQueueProps = ComponentProps<\"div\"> & Omit<AI_ApprovalRoutingProps, 'reassignCandidates' | 'actionNotice' | 'pauseStateOptions' | 'deadlineNotice' | 'clockPausedNotice'> & {\n items: AI_ApprovalQueueItem[]\n /** `modifiedToolArgs` only when the reviewer edited the call; `reasonCode` only when they gave a reason (#1921). */\n onApprove?: (approvalId: string, comment?: string, modifiedToolArgs?: Record<string, unknown>, reasonCode?: string) => void\n onDeny?: (approvalId: string, comment?: string, reasonCode?: string) => void\n onEscalate?: (approvalId: string, comment?: string) => void\n processingIds?: Set<string>\n filter?: string\n onFilterChange?: (filter: string) => void\n}\n\nexport type AI_DecisionOption = {\n id: string\n label: string\n description?: string\n variant?: \"default\" | \"destructive\" | \"outline\"\n}\n\nexport type AI_DecisionRequestProps = Omit<ComponentProps<\"div\">, \"onSelect\"> & {\n decisionId: string\n title: string\n description: string\n options: AI_DecisionOption[]\n riskLevel?: string\n deadline?: string\n undoGracePeriodMs?: number\n onSelect?: (decisionId: string, optionId: string) => void\n}\n\nexport type AI_HumanInputRequestProps = Omit<ComponentProps<\"div\">, \"onSubmit\"> & {\n requestId: string\n prompt: string\n inputType?: \"text\" | \"textarea\"\n placeholder?: string\n maxLength?: number\n deadline?: string\n onSubmit?: (requestId: string, value: string) => void\n}\n\n// --- Wrappers ---\n\nexport function AI_ApprovalRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_ApprovalRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_ApprovalRequestProps>(FrontendComponentType.LOW_LEVEL_AI_APPROVAL_REQUEST, 'AI_ApprovalRequest')(preset)\n return <Component {...props} />\n}\n\nexport function AI_ApprovalQueue({ preset = CorePresetNames.DEFAULT, ...props }: AI_ApprovalQueueProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_ApprovalQueueProps>(FrontendComponentType.LOW_LEVEL_AI_APPROVAL_QUEUE, 'AI_ApprovalQueue')(preset)\n return <Component {...props} />\n}\n\nexport function AI_DecisionRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_DecisionRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_DecisionRequestProps>(FrontendComponentType.LOW_LEVEL_AI_DECISION_REQUEST, 'AI_DecisionRequest')(preset)\n return <Component {...props} />\n}\n\nexport function AI_HumanInputRequest({ preset = CorePresetNames.DEFAULT, ...props }: AI_HumanInputRequestProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<AI_HumanInputRequestProps>(FrontendComponentType.LOW_LEVEL_AI_HUMAN_INPUT_REQUEST, 'AI_HumanInputRequest')(preset)\n return <Component {...props} />\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"AppLayout_AuthenticatedRoute.d.ts","sourceRoot":"","sources":["../../../../../src/components/app/AppLayout_AuthenticatedRoute.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAA4B,MAAM,OAAO,CAAC;AAoBjD,UAAU,iCAAiC;IACzC,8CAA8C;IAC9C,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AA+CD;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,4BAA4B,EAAE,KAAK,CAAC,EAAE,CAAC,iCAAiC,CA2DpF,CAAC"}
1
+ {"version":3,"file":"AppLayout_AuthenticatedRoute.d.ts","sourceRoot":"","sources":["../../../../../src/components/app/AppLayout_AuthenticatedRoute.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAwC,MAAM,OAAO,CAAC;AAqB7D,UAAU,iCAAiC;IACzC,8CAA8C;IAC9C,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AA+CD;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,4BAA4B,EAAE,KAAK,CAAC,EAAE,CAAC,iCAAiC,CAgEpF,CAAC"}
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  /**
3
3
  * AppLayout_AuthenticatedRoute
4
4
  *
@@ -8,7 +8,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
8
8
  * This ensures that ALL authenticated routes (resource pages, home, etc.)
9
9
  * are wrapped with the application shell (sidebar, menubar, etc.)
10
10
  */
11
- import { useEffect, useRef } from 'react';
11
+ import { useContext, useEffect, useRef } from 'react';
12
12
  import { Outlet, Navigate, useLocation, useNavigate } from 'react-router-dom';
13
13
  import { ErrorCustomMessageReference, ErrorType } from '@wildo-ai/saas-models';
14
14
  import { useUserOrgs } from '../../core/security/useUserOrgs.js';
@@ -24,6 +24,7 @@ import { LoadingSpinner } from '../../components/feedback/loading-spinner.js';
24
24
  import { AppLayout_MainContainer } from './AppLayout_MainContainer.js';
25
25
  import { AppLayout_ConsentGate } from './AppLayout_ConsentGate.js';
26
26
  import { AppLayout_DocumentAcceptanceGate } from './AppLayout_DocumentAcceptanceGate.js';
27
+ import { ApplicationContext } from '../../core/runtime/ApplicationContext.shared.js';
27
28
  /**
28
29
  * A spinner in place of page content.
29
30
  *
@@ -73,6 +74,7 @@ const AppLayout_OrganizationAccessRefused = () => {
73
74
  */
74
75
  export const AppLayout_AuthenticatedRoute = ({ redirectTo = CommonRoutePaths.login, }) => {
75
76
  const { auth } = useUserOrgs();
77
+ const shellCompanions = useContext(ApplicationContext)?.shellCompanions ?? [];
76
78
  const appScope = useAppScopeSafe();
77
79
  const location = useLocation();
78
80
  const routeOrganizationAccess = useRouteOrganizationAccess();
@@ -112,6 +114,9 @@ export const AppLayout_AuthenticatedRoute = ({ redirectTo = CommonRoutePaths.log
112
114
  // being asked about processing: while an acceptance is owed the consent gate is not rendered at all,
113
115
  // and its non-blocking prompt cannot float over the acceptance panel. Both wrap the whole shell, for the
114
116
  // reason above. See `AppLayout_DocumentAcceptanceGate`.
115
- return (_jsx(AppLayout_DocumentAcceptanceGate, { children: _jsx(AppLayout_ConsentGate, { children: _jsx(AppLayout_MainContainer, { children: routeContent }) }) }));
117
+ // Shell companions (`ApplicationMainProviderOptions.shellCompanions`) sit beside the shell, inside both
118
+ // gates and only once the session is restored: they live exactly as long as the signed-in shell does,
119
+ // on every page, and never read before a person has agreed to what the application does.
120
+ return (_jsx(AppLayout_DocumentAcceptanceGate, { children: _jsxs(AppLayout_ConsentGate, { children: [shellCompanions.map((Companion, index) => _jsx(Companion, {}, index)), _jsx(AppLayout_MainContainer, { children: routeContent })] }) }));
116
121
  };
117
122
  //# sourceMappingURL=AppLayout_AuthenticatedRoute.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppLayout_AuthenticatedRoute.js","sourceRoot":"","sources":["../../../../../src/components/app/AppLayout_AuthenticatedRoute.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AAEH,OAAc,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC9E,OAAO,EAAE,2BAA2B,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAC/E,OAAO,EAAE,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAC5E,OAAO,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAChG,OAAO,EACL,wBAAwB,EACxB,uBAAuB,GACxB,MAAM,gEAAgE,CAAC;AACxE,OAAO,EAAE,0BAA0B,EAAE,MAAM,8DAA8D,CAAC;AAC1G,OAAO,EAAE,uBAAuB,EAAE,MAAM,4EAA4E,CAAC;AACrH,OAAO,EAAE,eAAe,EAAE,MAAM,iDAAiD,CAAC;AAClF,OAAO,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAChE,OAAO,EAAE,6BAA6B,EAAE,MAAM,0EAA0E,CAAC;AACzH,OAAO,EAAE,cAAc,EAAE,MAAM,yDAAyD,CAAC;AACzF,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gCAAgC,EAAE,MAAM,oCAAoC,CAAC;AAOtF;;;;;;;GAOG;AACH,MAAM,wBAAwB,GAAa,GAAG,EAAE,CAAC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pC,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/**\n * AppLayout_AuthenticatedRoute\n *\n * Layout route component for authenticated pages.\n * Uses React Router's Outlet to render nested routes inside the MainContainer shell.\n *\n * This ensures that ALL authenticated routes (resource pages, home, etc.)\n * are wrapped with the application shell (sidebar, menubar, etc.)\n */\n\nimport React, { useEffect, useRef } from 'react';\nimport { Outlet, Navigate, useLocation, useNavigate } from 'react-router-dom';\nimport { ErrorCustomMessageReference, ErrorType } from '@wildo-ai/saas-models';\nimport { useUserOrgs } from '~wildo-frontend-lib/core/security/useUserOrgs';\nimport { useAppScopeSafe } from '~wildo-frontend-lib/core/scope/useAppScope';\nimport { CommonRoutePaths } from '~wildo-frontend-lib/core/runtime/routes.frontend.definitions';\nimport {\n appendAuthRedirectToPath,\n buildAuthRedirectTarget,\n} from '~wildo-frontend-lib/core/security/auth-redirect.frontend.utils';\nimport { useRouteOrganizationAccess } from '~wildo-frontend-lib/core/security/useRouteOrganizationAccess';\nimport { RouteOrganizationAccess } from '~wildo-frontend-lib/core/security/route-organization-access.frontend.utils';\nimport { useNotification } from '~wildo-frontend-lib/core/events/useNotification';\nimport { useI18n } from '~wildo-frontend-lib/core/i18n/useI18n';\nimport { resolveUserFacingErrorMessage } from '~wildo-frontend-lib/core/errors/user-facing-error-message.frontend.utils';\nimport { LoadingSpinner } from '~wildo-frontend-lib/components/feedback/loading-spinner';\nimport { AppLayout_MainContainer } from './AppLayout_MainContainer';\nimport { AppLayout_ConsentGate } from './AppLayout_ConsentGate';\nimport { AppLayout_DocumentAcceptanceGate } from './AppLayout_DocumentAcceptanceGate';\n\ninterface AppLayout_AuthenticatedRouteProps {\n /** Redirect path for unauthenticated users */\n redirectTo?: string;\n}\n\n/**\n * A spinner in place of page content.\n *\n * I-5: the registry-resolved `LoadingSpinner` exposes `role=\"status\"` + `aria-live=\"polite\"` for screen\n * readers; no text is rendered here intentionally — i18n is not guaranteed to be ready during the early\n * auth-restore phase, and a localized aria-label would couple this layout to a component-scope translation\n * key it has no natural home for.\n */\nconst AppLayout_ContentLoading: React.FC = () => (\n <div className=\"flex items-center justify-center w-full min-h-[200px]\">\n <LoadingSpinner />\n </div>\n);\n\n/**\n * Leaves a route whose organization the server refused to this account: sends it to the home page and says why.\n *\n * The words come from `errors_messages` / `errors_guidance` under\n * {@link ErrorCustomMessageReference.AUTHORIZATION_ORGANIZATION_NOT_ACCESSIBLE}, through the same resolver\n * the global error toast uses, so this notice is authored and translated like every other error.\n *\n * The ref guards a single notice per refusal: StrictMode runs the effect twice, and the translators change\n * identity on every i18n render.\n */\nconst AppLayout_OrganizationAccessRefused: React.FC = () => {\n const navigate = useNavigate();\n const { notifyWarning } = useNotification();\n const { tErrorMessage, tErrorGuidance } = useI18n();\n const handledRef = useRef(false);\n\n useEffect(() => {\n if (handledRef.current) {\n return;\n }\n handledRef.current = true;\n notifyWarning(resolveUserFacingErrorMessage(\n { type: ErrorType.AUTHORIZATION, customMessageReference: ErrorCustomMessageReference.AUTHORIZATION_ORGANIZATION_NOT_ACCESSIBLE },\n { translators: { tErrorMessage, tErrorGuidance } },\n ));\n navigate(CommonRoutePaths.home, { replace: true });\n }, [navigate, notifyWarning, tErrorMessage, tErrorGuidance]);\n\n return <AppLayout_ContentLoading />;\n};\n\n/**\n * Layout route that wraps authenticated content with MainContainer.\n * Redirects to login if user is not authenticated.\n * Waits while authenticated restore is still unresolved so the shell does not\n * render against prevalidated scope hints. After restore completes, a missing\n * AppScope organization remains a valid authenticated shell state.\n *\n * A route addressing an organization this account cannot open is left for the\n * home page with a notice, before any page content loads (see\n * {@link RouteOrganizationAccess}). This is the one layout every signed-in route\n * renders through, so resource, composite, chart, custom, flows and execution\n * routes are all covered, whatever path brought the person there.\n */\nexport const AppLayout_AuthenticatedRoute: React.FC<AppLayout_AuthenticatedRouteProps> = ({\n redirectTo = CommonRoutePaths.login,\n}) => {\n const { auth } = useUserOrgs();\n const appScope = useAppScopeSafe();\n const location = useLocation();\n const routeOrganizationAccess = useRouteOrganizationAccess();\n const currentOrganizationId = appScope?.currentOrganizationId;\n const isAuthenticated = !!auth.accessToken;\n const redirectTarget = buildAuthRedirectTarget(location);\n const loginRedirectPath = appendAuthRedirectToPath(redirectTo, redirectTarget);\n\n // Not authenticated - redirect to login\n if (!isAuthenticated) {\n return <Navigate to={loginRedirectPath} replace />;\n }\n\n // Wait while restore is unresolved so children do not render against\n // prevalidated organization hints. Once restore is complete, missing org is\n // still a valid authenticated shell state for org-optional flows.\n if (auth.isRestoringSession || (!auth.sessionRestored && !currentOrganizationId)) {\n return (\n <AppLayout_MainContainer>\n <AppLayout_ContentLoading />\n </AppLayout_MainContainer>\n );\n }\n\n // The page's own reads would carry the route's organization, so the route outlet (which syncs the route\n // into the navigation zones and starts those reads) is withheld until the server has answered. Only the\n // outlet is swapped: the shell below keeps the same element tree, so the sidebar, menubar and zone stacks\n // stay mounted while an organization is verified.\n let routeContent: React.ReactNode = <Outlet />;\n if (routeOrganizationAccess === RouteOrganizationAccess.VERIFYING) {\n routeContent = <AppLayout_ContentLoading />;\n } else if (routeOrganizationAccess === RouteOrganizationAccess.REFUSED) {\n routeContent = <AppLayout_OrganizationAccessRefused />;\n }\n\n // The consent gate wraps the SHELL, never the outlet. Signed-in page content is rendered from the\n // navigation zone stacks, and this outlet is only the PRIMARY zone's fallback while that stack is empty —\n // it is unmounted once the route has synced into the stack. A gate around it left the page after that sync\n // (a live browser never showed the prompt, #977), and the shell could navigate past it. Around the shell it\n // holds on every signed-in render: a missing REQUIRED purpose withholds the whole application (its panel\n // carries sign-out), and an undecided optional purpose prompts in a fixed panel over it. See\n // `AppLayout_ConsentGate`.\n // The document acceptance gate sits OUTSIDE the consent gate, so a person agrees to the terms before\n // being asked about processing: while an acceptance is owed the consent gate is not rendered at all,\n // and its non-blocking prompt cannot float over the acceptance panel. Both wrap the whole shell, for the\n // reason above. See `AppLayout_DocumentAcceptanceGate`.\n return (\n <AppLayout_DocumentAcceptanceGate>\n <AppLayout_ConsentGate>\n <AppLayout_MainContainer>\n {routeContent}\n </AppLayout_MainContainer>\n </AppLayout_ConsentGate>\n </AppLayout_DocumentAcceptanceGate>\n );\n};\n\n\n"]}
1
+ {"version":3,"file":"AppLayout_AuthenticatedRoute.js","sourceRoot":"","sources":["../../../../../src/components/app/AppLayout_AuthenticatedRoute.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AAEH,OAAc,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC7D,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC9E,OAAO,EAAE,2BAA2B,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAC/E,OAAO,EAAE,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAC5E,OAAO,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAChG,OAAO,EACL,wBAAwB,EACxB,uBAAuB,GACxB,MAAM,gEAAgE,CAAC;AACxE,OAAO,EAAE,0BAA0B,EAAE,MAAM,8DAA8D,CAAC;AAC1G,OAAO,EAAE,uBAAuB,EAAE,MAAM,4EAA4E,CAAC;AACrH,OAAO,EAAE,eAAe,EAAE,MAAM,iDAAiD,CAAC;AAClF,OAAO,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAChE,OAAO,EAAE,6BAA6B,EAAE,MAAM,0EAA0E,CAAC;AACzH,OAAO,EAAE,cAAc,EAAE,MAAM,yDAAyD,CAAC;AACzF,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gCAAgC,EAAE,MAAM,oCAAoC,CAAC;AACtF,OAAO,EAAE,kBAAkB,EAAE,MAAM,4DAA4D,CAAC;AAOhG;;;;;;;GAOG;AACH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G;IACzG,wDAAwD;IACxD,wGAAwG;IACxG,sGAAsG;IACtG,yFAAyF;IACzF,OAAO,CACL,KAAC,gCAAgC,cAC/B,MAAC,qBAAqB,eACnB,eAAe,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,KAAK,EAAE,EAAE,CAAC,KAAC,SAAS,MAAM,KAAK,CAAI,CAAC,EACrE,KAAC,uBAAuB,cACrB,YAAY,GACW,IACJ,GACS,CACpC,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/**\n * AppLayout_AuthenticatedRoute\n *\n * Layout route component for authenticated pages.\n * Uses React Router's Outlet to render nested routes inside the MainContainer shell.\n *\n * This ensures that ALL authenticated routes (resource pages, home, etc.)\n * are wrapped with the application shell (sidebar, menubar, etc.)\n */\n\nimport React, { useContext, useEffect, useRef } from 'react';\nimport { Outlet, Navigate, useLocation, useNavigate } from 'react-router-dom';\nimport { ErrorCustomMessageReference, ErrorType } from '@wildo-ai/saas-models';\nimport { useUserOrgs } from '~wildo-frontend-lib/core/security/useUserOrgs';\nimport { useAppScopeSafe } from '~wildo-frontend-lib/core/scope/useAppScope';\nimport { CommonRoutePaths } from '~wildo-frontend-lib/core/runtime/routes.frontend.definitions';\nimport {\n appendAuthRedirectToPath,\n buildAuthRedirectTarget,\n} from '~wildo-frontend-lib/core/security/auth-redirect.frontend.utils';\nimport { useRouteOrganizationAccess } from '~wildo-frontend-lib/core/security/useRouteOrganizationAccess';\nimport { RouteOrganizationAccess } from '~wildo-frontend-lib/core/security/route-organization-access.frontend.utils';\nimport { useNotification } from '~wildo-frontend-lib/core/events/useNotification';\nimport { useI18n } from '~wildo-frontend-lib/core/i18n/useI18n';\nimport { resolveUserFacingErrorMessage } from '~wildo-frontend-lib/core/errors/user-facing-error-message.frontend.utils';\nimport { LoadingSpinner } from '~wildo-frontend-lib/components/feedback/loading-spinner';\nimport { AppLayout_MainContainer } from './AppLayout_MainContainer';\nimport { AppLayout_ConsentGate } from './AppLayout_ConsentGate';\nimport { AppLayout_DocumentAcceptanceGate } from './AppLayout_DocumentAcceptanceGate';\nimport { ApplicationContext } from '~wildo-frontend-lib/core/runtime/ApplicationContext.shared';\n\ninterface AppLayout_AuthenticatedRouteProps {\n /** Redirect path for unauthenticated users */\n redirectTo?: string;\n}\n\n/**\n * A spinner in place of page content.\n *\n * I-5: the registry-resolved `LoadingSpinner` exposes `role=\"status\"` + `aria-live=\"polite\"` for screen\n * readers; no text is rendered here intentionally — i18n is not guaranteed to be ready during the early\n * auth-restore phase, and a localized aria-label would couple this layout to a component-scope translation\n * key it has no natural home for.\n */\nconst AppLayout_ContentLoading: React.FC = () => (\n <div className=\"flex items-center justify-center w-full min-h-[200px]\">\n <LoadingSpinner />\n </div>\n);\n\n/**\n * Leaves a route whose organization the server refused to this account: sends it to the home page and says why.\n *\n * The words come from `errors_messages` / `errors_guidance` under\n * {@link ErrorCustomMessageReference.AUTHORIZATION_ORGANIZATION_NOT_ACCESSIBLE}, through the same resolver\n * the global error toast uses, so this notice is authored and translated like every other error.\n *\n * The ref guards a single notice per refusal: StrictMode runs the effect twice, and the translators change\n * identity on every i18n render.\n */\nconst AppLayout_OrganizationAccessRefused: React.FC = () => {\n const navigate = useNavigate();\n const { notifyWarning } = useNotification();\n const { tErrorMessage, tErrorGuidance } = useI18n();\n const handledRef = useRef(false);\n\n useEffect(() => {\n if (handledRef.current) {\n return;\n }\n handledRef.current = true;\n notifyWarning(resolveUserFacingErrorMessage(\n { type: ErrorType.AUTHORIZATION, customMessageReference: ErrorCustomMessageReference.AUTHORIZATION_ORGANIZATION_NOT_ACCESSIBLE },\n { translators: { tErrorMessage, tErrorGuidance } },\n ));\n navigate(CommonRoutePaths.home, { replace: true });\n }, [navigate, notifyWarning, tErrorMessage, tErrorGuidance]);\n\n return <AppLayout_ContentLoading />;\n};\n\n/**\n * Layout route that wraps authenticated content with MainContainer.\n * Redirects to login if user is not authenticated.\n * Waits while authenticated restore is still unresolved so the shell does not\n * render against prevalidated scope hints. After restore completes, a missing\n * AppScope organization remains a valid authenticated shell state.\n *\n * A route addressing an organization this account cannot open is left for the\n * home page with a notice, before any page content loads (see\n * {@link RouteOrganizationAccess}). This is the one layout every signed-in route\n * renders through, so resource, composite, chart, custom, flows and execution\n * routes are all covered, whatever path brought the person there.\n */\nexport const AppLayout_AuthenticatedRoute: React.FC<AppLayout_AuthenticatedRouteProps> = ({\n redirectTo = CommonRoutePaths.login,\n}) => {\n const { auth } = useUserOrgs();\n const shellCompanions = useContext(ApplicationContext)?.shellCompanions ?? [];\n const appScope = useAppScopeSafe();\n const location = useLocation();\n const routeOrganizationAccess = useRouteOrganizationAccess();\n const currentOrganizationId = appScope?.currentOrganizationId;\n const isAuthenticated = !!auth.accessToken;\n const redirectTarget = buildAuthRedirectTarget(location);\n const loginRedirectPath = appendAuthRedirectToPath(redirectTo, redirectTarget);\n\n // Not authenticated - redirect to login\n if (!isAuthenticated) {\n return <Navigate to={loginRedirectPath} replace />;\n }\n\n // Wait while restore is unresolved so children do not render against\n // prevalidated organization hints. Once restore is complete, missing org is\n // still a valid authenticated shell state for org-optional flows.\n if (auth.isRestoringSession || (!auth.sessionRestored && !currentOrganizationId)) {\n return (\n <AppLayout_MainContainer>\n <AppLayout_ContentLoading />\n </AppLayout_MainContainer>\n );\n }\n\n // The page's own reads would carry the route's organization, so the route outlet (which syncs the route\n // into the navigation zones and starts those reads) is withheld until the server has answered. Only the\n // outlet is swapped: the shell below keeps the same element tree, so the sidebar, menubar and zone stacks\n // stay mounted while an organization is verified.\n let routeContent: React.ReactNode = <Outlet />;\n if (routeOrganizationAccess === RouteOrganizationAccess.VERIFYING) {\n routeContent = <AppLayout_ContentLoading />;\n } else if (routeOrganizationAccess === RouteOrganizationAccess.REFUSED) {\n routeContent = <AppLayout_OrganizationAccessRefused />;\n }\n\n // The consent gate wraps the SHELL, never the outlet. Signed-in page content is rendered from the\n // navigation zone stacks, and this outlet is only the PRIMARY zone's fallback while that stack is empty —\n // it is unmounted once the route has synced into the stack. A gate around it left the page after that sync\n // (a live browser never showed the prompt, #977), and the shell could navigate past it. Around the shell it\n // holds on every signed-in render: a missing REQUIRED purpose withholds the whole application (its panel\n // carries sign-out), and an undecided optional purpose prompts in a fixed panel over it. See\n // `AppLayout_ConsentGate`.\n // The document acceptance gate sits OUTSIDE the consent gate, so a person agrees to the terms before\n // being asked about processing: while an acceptance is owed the consent gate is not rendered at all,\n // and its non-blocking prompt cannot float over the acceptance panel. Both wrap the whole shell, for the\n // reason above. See `AppLayout_DocumentAcceptanceGate`.\n // Shell companions (`ApplicationMainProviderOptions.shellCompanions`) sit beside the shell, inside both\n // gates and only once the session is restored: they live exactly as long as the signed-in shell does,\n // on every page, and never read before a person has agreed to what the application does.\n return (\n <AppLayout_DocumentAcceptanceGate>\n <AppLayout_ConsentGate>\n {shellCompanions.map((Companion, index) => <Companion key={index} />)}\n <AppLayout_MainContainer>\n {routeContent}\n </AppLayout_MainContainer>\n </AppLayout_ConsentGate>\n </AppLayout_DocumentAcceptanceGate>\n );\n};\n\n\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"Auth_EnrollmentRequired.d.ts","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_EnrollmentRequired.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;AAsBjF,OAAO,qEAAqE,CAAC;AAC7E,OAAO,wEAAwE,CAAC;AAChF,OAAO,sEAAsE,CAAC;AAE9E,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAC;AAIxH,MAAM,WAAW,kDAAkD;CAAG;AAQtE;;;;;;;;GAQG;AACH,eAAO,MAAM,6CAA6C,GAAI,QAAQ,kDAAkD,KAAG,KAAK,CAAC,GAAG,CAAC,OAkQpI,CAAC;AAEF,wBAAgB,uBAAuB,CAAC,EAAE,MAAgC,EAAE,GAAG,KAAK,EAAE,EAAE,kDAAkD,GAAG,oBAAoB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAGpL"}
1
+ {"version":3,"file":"Auth_EnrollmentRequired.d.ts","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_EnrollmentRequired.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;AAuBjF,OAAO,qEAAqE,CAAC;AAC7E,OAAO,wEAAwE,CAAC;AAChF,OAAO,sEAAsE,CAAC;AAE9E,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAC;AAIxH,MAAM,WAAW,kDAAkD;CAAG;AAQtE;;;;;;;;GAQG;AACH,eAAO,MAAM,6CAA6C,GAAI,QAAQ,kDAAkD,KAAG,KAAK,CAAC,GAAG,CAAC,OAqQpI,CAAC;AAEF,wBAAgB,uBAAuB,CAAC,EAAE,MAAgC,EAAE,GAAG,KAAK,EAAE,EAAE,kDAAkD,GAAG,oBAAoB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAGpL"}
@@ -4,6 +4,7 @@ import { Navigate, useLocation, useNavigate } from 'react-router-dom';
4
4
  import { ButtonSize, CorePresetNames, EnrollmentRequiredLabel, FrontendComponentType } from '@wildo-ai/presets-components-models';
5
5
  import { AuthMethod } from '@wildo-ai/saas-models';
6
6
  import { useAuthSession } from '../../core/security/useAuthSession.js';
7
+ import { useUserOrgs } from '../../core/security/useUserOrgs.js';
7
8
  import { organizationOnboardingNavigationTarget } from '../../core/security/organization-onboarding.frontend.utils.js';
8
9
  import { useI18n } from '../../core/i18n/useI18n.js';
9
10
  import { CommonRoutePaths } from '../../core/runtime/routes.frontend.definitions.js';
@@ -34,7 +35,10 @@ const METHOD_DISPLAY_LABELS = {
34
35
  * All user-facing strings are i18n-driven via EnrollmentRequiredLabel.
35
36
  */
36
37
  export const PublicLayoutPreset_EnrollmentRequired_Default = (_props) => {
37
- const { auth, logout, completeEnrollmentSession, getSessionState, adoptPendingMfaSession } = useAuthSession();
38
+ const { auth, completeEnrollmentSession, getSessionState, adoptPendingMfaSession } = useAuthSession();
39
+ // Signing out goes through `UserOrgsProvider`, which announces the person's departure before their consent is
40
+ // cleared (#1977). The auth session's own `logout` skips that announcement.
41
+ const { logout } = useUserOrgs();
38
42
  const { tComponent, isReady } = useI18n({ component: FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED });
39
43
  const navigate = useNavigate();
40
44
  const location = useLocation();
@@ -1 +1 @@
1
- {"version":3,"file":"Auth_EnrollmentRequired.js","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_EnrollmentRequired.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjF,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAC;AAClI,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAClF,OAAO,EAAE,sCAAsC,EAAE,MAAM,0EAA0E,CAAC;AAClI,OAAO,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAChG,OAAO,EACL,wBAAwB,EACxB,6BAA6B,EAC7B,uBAAuB,GACxB,MAAM,gEAAgE,CAAC;AAExE,OAAO,EAAE,4BAA4B,EAAE,MAAM,6EAA6E,CAAC;AAC3H,OAAO,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,MAAM,gEAAgE,CAAC;AAC9H,OAAO,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,MAAM,8EAA8E,CAAC;AAC9I,OAAO,EAAE,MAAM,EAAE,sBAAsB,EAAE,MAAM,+CAA+C,CAAC;AAC/F,OAAO,EAAE,OAAO,EAAE,MAAM,mDAAmD,CAAC;AAC5E,OAAO,EAAE,IAA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kC,EAAE,yBAAyB,CAAC,CAAC,MAAM,CAAC,CAAC;IAC3L,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAC;AAClC,CAAC","sourcesContent":["import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { Navigate, useLocation, useNavigate } from 'react-router-dom';\nimport { ButtonSize, CorePresetNames, EnrollmentRequiredLabel, FrontendComponentType } from '@wildo-ai/presets-components-models';\nimport { AuthMethod } from '@wildo-ai/saas-models';\nimport { useAuthSession } from '~wildo-frontend-lib/core/security/useAuthSession';\nimport { organizationOnboardingNavigationTarget } from '~wildo-frontend-lib/core/security/organization-onboarding.frontend.utils';\nimport { useI18n } from '~wildo-frontend-lib/core/i18n/useI18n';\nimport { CommonRoutePaths } from '~wildo-frontend-lib/core/runtime/routes.frontend.definitions';\nimport {\n appendAuthRedirectToPath,\n extractAuthRedirectFromSearch,\n resolvePostAuthRedirect,\n} from '~wildo-frontend-lib/core/security/auth-redirect.frontend.utils';\nimport type { EnrollmentSessionSettlementResponse } from '~wildo-frontend-lib/core/requests/wildo-http-client-manual-calls.frontend.service';\nimport { ENROLLMENT_METHOD_COMPONENTS } from '~wildo-frontend-lib/components/auth/enrollment/enrollment-method-components';\nimport { AuthMethodChoiceLayout, AuthMethodChoiceList } from '~wildo-frontend-lib/components/auth/utils/AuthMethodChoiceList';\nimport { forgetPendingMfaSession, readPendingMfaSession } from '~wildo-frontend-lib/core/security/pending-mfa-session-storage.frontend.utils';\nimport { Button, ButtonVariants_Variant } from '~wildo-frontend-lib/components/actions/button';\nimport { Heading } from '~wildo-frontend-lib/components/typography/heading';\nimport { Text } from '~wildo-frontend-lib/components/typography/text';\nimport { Alert, AlertDescription } from '~wildo-frontend-lib/components/overlays/containers/alert';\n\nimport '~wildo-frontend-lib/components/auth/enrollment/TotpEnrollmentMethod';\nimport '~wildo-frontend-lib/components/auth/enrollment/PasskeyEnrollmentMethod';\nimport '~wildo-frontend-lib/components/auth/enrollment/PhoneEnrollmentMethod';\n\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas';\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper';\n\n// --- Contract ---\nexport interface PublicLayoutPreset_EnrollmentRequired_DefaultProps {}\n\nconst METHOD_DISPLAY_LABELS: Record<string, EnrollmentRequiredLabel> = {\n [AuthMethod.TOTP]: EnrollmentRequiredLabel.TOTP_TITLE,\n [AuthMethod.PASSKEY]: EnrollmentRequiredLabel.PASSKEY_TITLE,\n [AuthMethod.SMS_OTP]: EnrollmentRequiredLabel.PHONE_TITLE,\n};\n\n/**\n * MFA enrollment required default preset.\n *\n * Displayed when the user's organization requires MFA but the user has\n * not enrolled any second-factor method yet. Offers enrollment options\n * and redirects to MFA challenge upon completion.\n *\n * All user-facing strings are i18n-driven via EnrollmentRequiredLabel.\n */\nexport const PublicLayoutPreset_EnrollmentRequired_Default = (_props: PublicLayoutPreset_EnrollmentRequired_DefaultProps): React.JSX.Element => {\n const { auth, logout, completeEnrollmentSession, getSessionState, adoptPendingMfaSession } = useAuthSession();\n const { tComponent, isReady } = useI18n({ component: FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED });\n const navigate = useNavigate();\n const location = useLocation();\n\n const t = (key: string) => tComponent(FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED, key);\n const authRedirectTarget = useMemo(\n () => extractAuthRedirectFromSearch(location.search),\n [location.search],\n );\n const { urlSessionId, urlEmail } = useMemo(() => {\n const params = new URLSearchParams(location.search);\n return { urlSessionId: params.get('sessionId'), urlEmail: params.get('email') || '' };\n }, [location.search]);\n\n /*\n * Recover the session when this page was LOADED with an empty auth context rather than routed to.\n *\n * Every in-app arrival here finds the context already holding the session. A hard load does not, and this\n * screen used to read ONLY the context, so it sent a valid session to sign-in. Two routes lead here, and\n * each leaves the session somewhere a reload can find it:\n * - the MFA CHALLENGE, itself loaded from a URL carrying `sessionId`, passes `sessionId`/`email` on in the\n * gate URL — ids its own URL already showed (#1033);\n * - the in-app hand-off from sign-in, registration, email confirmation, invitation and magic link\n * (`useMfaContinuationNavigation`) carries NOTHING in the URL — a registration or invitation session\n * issues tokens and lives 24h — so a reload after it recovers from the tab-scoped copy the auth provider\n * keeps (`pending-mfa-session-storage.frontend.utils.ts`, #1068).\n *\n * The URL wins when both exist: it names the session this exact navigation was made for. Storage is read\n * ONCE, in the first render — before any effect runs — so the provider's own bookkeeping cannot race it.\n *\n * A session in a state the server no longer admits second-factor work on, or one the server no longer\n * knows, is not adopted, its stored copy is forgotten, and the sign-in bounce below proceeds as before.\n */\n const [storedPendingSession] = useState(() => readPendingMfaSession());\n const recoverySessionId = urlSessionId ?? storedPendingSession?.sessionId ?? null;\n const recoveryEmail = urlEmail || storedPendingSession?.email || '';\n const needsSessionRecovery = !auth.accessToken && !auth.mfaRequired && !!recoverySessionId;\n const [sessionRecoverySettled, setSessionRecoverySettled] = useState(false);\n const sessionRecoveryStartedRef = useRef(false);\n\n useEffect(() => {\n if (!needsSessionRecovery || !recoverySessionId || sessionRecoveryStartedRef.current) return;\n sessionRecoveryStartedRef.current = true;\n\n // Only a copy of THIS session is dropped: a URL-named session failing says nothing about a different one\n // the tab still remembers.\n const forgetIfRemembered = () => {\n if (storedPendingSession?.sessionId === recoverySessionId) forgetPendingMfaSession();\n };\n\n getSessionState(recoverySessionId)\n .then((sessionState) => {\n if (!adoptPendingMfaSession(recoverySessionId, sessionState)) forgetIfRemembered();\n })\n .catch((error: { response?: { status?: number } }) => {\n // Forget only what the server says is GONE. A transient failure leaves the copy for the next reload,\n // matching how the challenge screen tells an expired session from a generic error.\n const status = error?.response?.status;\n if (status === 404 || status === 410) forgetIfRemembered();\n })\n .finally(() => setSessionRecoverySettled(true));\n }, [needsSessionRecovery, recoverySessionId, storedPendingSession, getSessionState, adoptPendingMfaSession]);\n const loginPath = useMemo(\n () => appendAuthRedirectToPath(CommonRoutePaths.login, authRedirectTarget),\n [authRedirectTarget],\n );\n const postAuthRedirect = useMemo(\n () => resolvePostAuthRedirect(location.search),\n [location.search],\n );\n\n const [selectedMethod, setSelectedMethod] = useState<AuthMethod | null>(null);\n const [enrolledSuccessfully, setEnrolledSuccessfully] = useState(false);\n const [error, setError] = useState<string | null>(null);\n\n const enrollableOptions = useMemo(\n () => (auth.availableEnrollmentMethods as AuthMethod[]).filter(m => ENROLLMENT_METHOD_COMPONENTS[m]),\n [auth.availableEnrollmentMethods],\n );\n\n const mfaChallengePath = useMemo(() => {\n const sessionId = auth.mfaSessionId;\n if (!sessionId) {\n return appendAuthRedirectToPath(CommonRoutePaths.mfaChallenge, authRedirectTarget);\n }\n\n // A recovered session has no identification response behind it, so the recovered email is the fallback.\n const email = auth.identification?.email || recoveryEmail;\n return appendAuthRedirectToPath(\n `${CommonRoutePaths.mfaChallenge}?sessionId=${sessionId}&email=${encodeURIComponent(email)}`,\n authRedirectTarget,\n );\n }, [auth.mfaSessionId, auth.identification?.email, recoveryEmail, authRedirectTarget]);\n\n /*\n * Where enrollment leads depends on the session it was performed on, and the backend has already\n * decided it (`enrollmentSession` on the ceremony response):\n * - a REGISTRATION or INVITATION session is COMPLETED by the enrollment itself — the registrant has\n * just proven the factor, so there is nothing to challenge. The response carries the access\n * token; adopting it signs them in, and the `auth.accessToken` redirect below takes them into the\n * application. Sending them to the challenge instead is the dead end #603 records: the session is\n * consumed and no door would answer.\n * - a LOGIN session was moved to `MFA_REQUIRED`, and the enrolled factor is now presented as the\n * challenge it still owes.\n * - a registration settlement that stopped at `ONBOARDING_PENDING` (reachable since #1011) is adopted as a\n * parked onboarding session; the organization-onboarding guard below then takes the registrant to name\n * their organization, which signs them in (#1090).\n */\n const handleEnrollmentComplete = useCallback((settlement?: EnrollmentSessionSettlementResponse) => {\n setError(null);\n if (completeEnrollmentSession(settlement)) {\n return;\n }\n setEnrolledSuccessfully(true);\n setTimeout(() => {\n navigate(mfaChallengePath, { replace: true });\n }, 1200);\n }, [navigate, mfaChallengePath, completeEnrollmentSession]);\n\n const handleEnrollmentError = useCallback((msg: string) => {\n setError(msg);\n }, []);\n\n // Parked at organization onboarding (#1090): the organization is the only step left, whatever this screen was doing.\n const organizationOnboardingTarget = organizationOnboardingNavigationTarget(auth, authRedirectTarget);\n if (organizationOnboardingTarget) {\n return <Navigate to={organizationOnboardingTarget} replace />;\n }\n\n // Signed in — including by an enrollment that completed a registration session. Checked BEFORE the\n // `mfaRequired` bounce, which that completion clears and would otherwise read as \"go back to login\".\n if (auth.accessToken && !auth.isLoading) {\n return <Navigate to={postAuthRedirect} replace />;\n }\n\n if (!auth.mfaRequired) {\n // Not yet: the URL names a session and the recovery above has not answered. Bouncing now is the\n // defect #1033 records — the session is valid, only this page's memory of it is missing.\n if (needsSessionRecovery && !sessionRecoverySettled) {\n return <></>;\n }\n return <Navigate to={loginPath} replace />;\n }\n\n /*\n * Hand back to the challenge ONLY when a challenge can actually run.\n *\n * This bounce means \"you do not need to enroll anything, go and answer the challenge\" — a sentence\n * that is only true when something is usable. It used to fire on `enrollableOptions.length === 0`\n * alone, which made it the other half of a redirect loop: the challenge sends a user here when\n * nothing is usable, and this sent them straight back when there was nothing to enroll. Both\n * screens were individually reasonable and the PAIR never terminated.\n *\n * Requiring a usable factor breaks the cycle HERE, at the source, rather than relying on the two\n * screens agreeing about `availableEnrollmentMethods` — which they read from different places (this\n * one from the auth context, the challenge from its own session fetch), so any backend path that\n * populates one and not the other would reopen it.\n */\n const hasUsableSecondFactor = auth.usableSecondFactorMethods.length > 0;\n if (auth.mfaSessionId && enrollableOptions.length === 0 && hasUsableSecondFactor) {\n return <Navigate to={mfaChallengePath} replace />;\n }\n\n if (!isReady) return null;\n\n // Required, nothing usable, nothing enrollable: terminal, and it says so. Only an administrator can\n // resolve it, so the sole action left is to sign out.\n if (enrollableOptions.length === 0) {\n return (\n <div className=\"space-y-group py-section\">\n <div className=\"text-center space-y-item-xs\">\n <Heading>{t(EnrollmentRequiredLabel.TITLE)}</Heading>\n </div>\n <Alert>\n <AlertDescription>{t(EnrollmentRequiredLabel.NO_METHODS_AVAILABLE)}</AlertDescription>\n </Alert>\n <Button variant={ButtonVariants_Variant.OUTLINE} className=\"w-full\" onClick={() => logout()}>\n {t(EnrollmentRequiredLabel.LOGOUT_BUTTON)}\n </Button>\n </div>\n );\n }\n\n if (enrolledSuccessfully) {\n return (\n <div className=\"text-center space-y-group py-section\">\n <Alert>\n <AlertDescription>{t(EnrollmentRequiredLabel.ENROLL_SUCCESS)}</AlertDescription>\n </Alert>\n <Text className=\"text-sm text-muted-foreground\">{t(EnrollmentRequiredLabel.LOADING)}</Text>\n </div>\n );\n }\n\n const SelectedComponent = selectedMethod ? ENROLLMENT_METHOD_COMPONENTS[selectedMethod] : null;\n\n return (\n <div className=\"space-y-group py-section\">\n <div className=\"text-center space-y-item-xs\">\n <Heading>{t(EnrollmentRequiredLabel.TITLE)}</Heading>\n <Text className=\"text-muted-foreground max-w-sm mx-auto\">\n {t(EnrollmentRequiredLabel.DESCRIPTION)}\n </Text>\n </div>\n\n {error && (\n <Alert variant=\"destructive\">\n <AlertDescription>{error}</AlertDescription>\n </Alert>\n )}\n\n {!selectedMethod && (\n <div className=\"space-y-item\">\n <Text className=\"text-sm font-medium text-center\">\n {t(EnrollmentRequiredLabel.SELECT_METHOD)}\n </Text>\n <AuthMethodChoiceList\n layout={AuthMethodChoiceLayout.LIST}\n methods={enrollableOptions}\n labelFor={(method) => t(METHOD_DISPLAY_LABELS[method] || method)}\n onSelect={(method) => { setSelectedMethod(method); setError(null); }}\n />\n </div>\n )}\n\n {selectedMethod && SelectedComponent && (\n <div className=\"space-y-item\">\n <div className=\"flex items-center gap-2\">\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => { setSelectedMethod(null); setError(null); }}\n >\n ←\n </Button>\n <Text className=\"text-sm font-medium\">\n {t(METHOD_DISPLAY_LABELS[selectedMethod] || selectedMethod)}\n </Text>\n </div>\n <SelectedComponent\n sessionId={auth.mfaSessionId || undefined}\n onComplete={handleEnrollmentComplete}\n onError={handleEnrollmentError}\n isLoading={false}\n t={t}\n />\n </div>\n )}\n\n <div className=\"pt-2\">\n <Button variant={ButtonVariants_Variant.OUTLINE} className=\"w-full\" onClick={() => logout()}>\n {t(EnrollmentRequiredLabel.LOGOUT_BUTTON)}\n </Button>\n </div>\n </div>\n );\n};\n\nexport function Auth_EnrollmentRequired({ preset = CorePresetNames.DEFAULT, ...props }: PublicLayoutPreset_EnrollmentRequired_DefaultProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<PublicLayoutPreset_EnrollmentRequired_DefaultProps>(FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED, 'Auth_EnrollmentRequired')(preset);\n return <Component {...props} />;\n}\n"]}
1
+ {"version":3,"file":"Auth_EnrollmentRequired.js","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_EnrollmentRequired.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjF,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAC;AAClI,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAClF,OAAO,EAAE,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAC5E,OAAO,EAAE,sCAAsC,EAAE,MAAM,0EAA0E,CAAC;AAClI,OAAO,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAChG,OAAO,EACL,wBAAwB,EACxB,6BAA6B,EAC7B,uBAAuB,GACxB,MAAM,g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ACJ,IACE,CACP,EAED,cAAK,SAAS,EAAC,MAAM,YACnB,KAAC,MAAM,IAAC,OAAO,EAAE,sBAAsB,CAAC,OAAO,EAAE,SAAS,EAAC,QAAQ,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,MAAM,EAAE,YACxF,CAAC,CAAC,uBAAuB,CAAC,aAAa,CAAC,GAClC,GACL,IACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,UAAU,uBAAuB,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC,OAAO,EAAE,GAAG,KAAK,EAA6E;IAC/J,MAAM,SAAS,GAAG,uBAAuB,CAAqD,qBAAqB,CAAC,kCAAkC,EAAE,yBAAyB,CAAC,CAAC,MAAM,CAAC,CAAC;IAC3L,OAAO,KAAC,SAAS,OAAK,KAAK,GAAI,CAAC;AAClC,CAAC","sourcesContent":["import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { Navigate, useLocation, useNavigate } from 'react-router-dom';\nimport { ButtonSize, CorePresetNames, EnrollmentRequiredLabel, FrontendComponentType } from '@wildo-ai/presets-components-models';\nimport { AuthMethod } from '@wildo-ai/saas-models';\nimport { useAuthSession } from '~wildo-frontend-lib/core/security/useAuthSession';\nimport { useUserOrgs } from '~wildo-frontend-lib/core/security/useUserOrgs';\nimport { organizationOnboardingNavigationTarget } from '~wildo-frontend-lib/core/security/organization-onboarding.frontend.utils';\nimport { useI18n } from '~wildo-frontend-lib/core/i18n/useI18n';\nimport { CommonRoutePaths } from '~wildo-frontend-lib/core/runtime/routes.frontend.definitions';\nimport {\n appendAuthRedirectToPath,\n extractAuthRedirectFromSearch,\n resolvePostAuthRedirect,\n} from '~wildo-frontend-lib/core/security/auth-redirect.frontend.utils';\nimport type { EnrollmentSessionSettlementResponse } from '~wildo-frontend-lib/core/requests/wildo-http-client-manual-calls.frontend.service';\nimport { ENROLLMENT_METHOD_COMPONENTS } from '~wildo-frontend-lib/components/auth/enrollment/enrollment-method-components';\nimport { AuthMethodChoiceLayout, AuthMethodChoiceList } from '~wildo-frontend-lib/components/auth/utils/AuthMethodChoiceList';\nimport { forgetPendingMfaSession, readPendingMfaSession } from '~wildo-frontend-lib/core/security/pending-mfa-session-storage.frontend.utils';\nimport { Button, ButtonVariants_Variant } from '~wildo-frontend-lib/components/actions/button';\nimport { Heading } from '~wildo-frontend-lib/components/typography/heading';\nimport { Text } from '~wildo-frontend-lib/components/typography/text';\nimport { Alert, AlertDescription } from '~wildo-frontend-lib/components/overlays/containers/alert';\n\nimport '~wildo-frontend-lib/components/auth/enrollment/TotpEnrollmentMethod';\nimport '~wildo-frontend-lib/components/auth/enrollment/PasskeyEnrollmentMethod';\nimport '~wildo-frontend-lib/components/auth/enrollment/PhoneEnrollmentMethod';\n\nimport { ComponentPresetProps } from '~wildo-frontend-lib/core/components-registry/component-registry.frontend.schemas';\nimport { createComponentResolver } from '~wildo-frontend-lib/core/components-registry/component-resolver.frontend.helper';\n\n// --- Contract ---\nexport interface PublicLayoutPreset_EnrollmentRequired_DefaultProps {}\n\nconst METHOD_DISPLAY_LABELS: Record<string, EnrollmentRequiredLabel> = {\n [AuthMethod.TOTP]: EnrollmentRequiredLabel.TOTP_TITLE,\n [AuthMethod.PASSKEY]: EnrollmentRequiredLabel.PASSKEY_TITLE,\n [AuthMethod.SMS_OTP]: EnrollmentRequiredLabel.PHONE_TITLE,\n};\n\n/**\n * MFA enrollment required default preset.\n *\n * Displayed when the user's organization requires MFA but the user has\n * not enrolled any second-factor method yet. Offers enrollment options\n * and redirects to MFA challenge upon completion.\n *\n * All user-facing strings are i18n-driven via EnrollmentRequiredLabel.\n */\nexport const PublicLayoutPreset_EnrollmentRequired_Default = (_props: PublicLayoutPreset_EnrollmentRequired_DefaultProps): React.JSX.Element => {\n const { auth, completeEnrollmentSession, getSessionState, adoptPendingMfaSession } = useAuthSession();\n // Signing out goes through `UserOrgsProvider`, which announces the person's departure before their consent is\n // cleared (#1977). The auth session's own `logout` skips that announcement.\n const { logout } = useUserOrgs();\n const { tComponent, isReady } = useI18n({ component: FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED });\n const navigate = useNavigate();\n const location = useLocation();\n\n const t = (key: string) => tComponent(FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED, key);\n const authRedirectTarget = useMemo(\n () => extractAuthRedirectFromSearch(location.search),\n [location.search],\n );\n const { urlSessionId, urlEmail } = useMemo(() => {\n const params = new URLSearchParams(location.search);\n return { urlSessionId: params.get('sessionId'), urlEmail: params.get('email') || '' };\n }, [location.search]);\n\n /*\n * Recover the session when this page was LOADED with an empty auth context rather than routed to.\n *\n * Every in-app arrival here finds the context already holding the session. A hard load does not, and this\n * screen used to read ONLY the context, so it sent a valid session to sign-in. Two routes lead here, and\n * each leaves the session somewhere a reload can find it:\n * - the MFA CHALLENGE, itself loaded from a URL carrying `sessionId`, passes `sessionId`/`email` on in the\n * gate URL — ids its own URL already showed (#1033);\n * - the in-app hand-off from sign-in, registration, email confirmation, invitation and magic link\n * (`useMfaContinuationNavigation`) carries NOTHING in the URL — a registration or invitation session\n * issues tokens and lives 24h — so a reload after it recovers from the tab-scoped copy the auth provider\n * keeps (`pending-mfa-session-storage.frontend.utils.ts`, #1068).\n *\n * The URL wins when both exist: it names the session this exact navigation was made for. Storage is read\n * ONCE, in the first render — before any effect runs — so the provider's own bookkeeping cannot race it.\n *\n * A session in a state the server no longer admits second-factor work on, or one the server no longer\n * knows, is not adopted, its stored copy is forgotten, and the sign-in bounce below proceeds as before.\n */\n const [storedPendingSession] = useState(() => readPendingMfaSession());\n const recoverySessionId = urlSessionId ?? storedPendingSession?.sessionId ?? null;\n const recoveryEmail = urlEmail || storedPendingSession?.email || '';\n const needsSessionRecovery = !auth.accessToken && !auth.mfaRequired && !!recoverySessionId;\n const [sessionRecoverySettled, setSessionRecoverySettled] = useState(false);\n const sessionRecoveryStartedRef = useRef(false);\n\n useEffect(() => {\n if (!needsSessionRecovery || !recoverySessionId || sessionRecoveryStartedRef.current) return;\n sessionRecoveryStartedRef.current = true;\n\n // Only a copy of THIS session is dropped: a URL-named session failing says nothing about a different one\n // the tab still remembers.\n const forgetIfRemembered = () => {\n if (storedPendingSession?.sessionId === recoverySessionId) forgetPendingMfaSession();\n };\n\n getSessionState(recoverySessionId)\n .then((sessionState) => {\n if (!adoptPendingMfaSession(recoverySessionId, sessionState)) forgetIfRemembered();\n })\n .catch((error: { response?: { status?: number } }) => {\n // Forget only what the server says is GONE. A transient failure leaves the copy for the next reload,\n // matching how the challenge screen tells an expired session from a generic error.\n const status = error?.response?.status;\n if (status === 404 || status === 410) forgetIfRemembered();\n })\n .finally(() => setSessionRecoverySettled(true));\n }, [needsSessionRecovery, recoverySessionId, storedPendingSession, getSessionState, adoptPendingMfaSession]);\n const loginPath = useMemo(\n () => appendAuthRedirectToPath(CommonRoutePaths.login, authRedirectTarget),\n [authRedirectTarget],\n );\n const postAuthRedirect = useMemo(\n () => resolvePostAuthRedirect(location.search),\n [location.search],\n );\n\n const [selectedMethod, setSelectedMethod] = useState<AuthMethod | null>(null);\n const [enrolledSuccessfully, setEnrolledSuccessfully] = useState(false);\n const [error, setError] = useState<string | null>(null);\n\n const enrollableOptions = useMemo(\n () => (auth.availableEnrollmentMethods as AuthMethod[]).filter(m => ENROLLMENT_METHOD_COMPONENTS[m]),\n [auth.availableEnrollmentMethods],\n );\n\n const mfaChallengePath = useMemo(() => {\n const sessionId = auth.mfaSessionId;\n if (!sessionId) {\n return appendAuthRedirectToPath(CommonRoutePaths.mfaChallenge, authRedirectTarget);\n }\n\n // A recovered session has no identification response behind it, so the recovered email is the fallback.\n const email = auth.identification?.email || recoveryEmail;\n return appendAuthRedirectToPath(\n `${CommonRoutePaths.mfaChallenge}?sessionId=${sessionId}&email=${encodeURIComponent(email)}`,\n authRedirectTarget,\n );\n }, [auth.mfaSessionId, auth.identification?.email, recoveryEmail, authRedirectTarget]);\n\n /*\n * Where enrollment leads depends on the session it was performed on, and the backend has already\n * decided it (`enrollmentSession` on the ceremony response):\n * - a REGISTRATION or INVITATION session is COMPLETED by the enrollment itself — the registrant has\n * just proven the factor, so there is nothing to challenge. The response carries the access\n * token; adopting it signs them in, and the `auth.accessToken` redirect below takes them into the\n * application. Sending them to the challenge instead is the dead end #603 records: the session is\n * consumed and no door would answer.\n * - a LOGIN session was moved to `MFA_REQUIRED`, and the enrolled factor is now presented as the\n * challenge it still owes.\n * - a registration settlement that stopped at `ONBOARDING_PENDING` (reachable since #1011) is adopted as a\n * parked onboarding session; the organization-onboarding guard below then takes the registrant to name\n * their organization, which signs them in (#1090).\n */\n const handleEnrollmentComplete = useCallback((settlement?: EnrollmentSessionSettlementResponse) => {\n setError(null);\n if (completeEnrollmentSession(settlement)) {\n return;\n }\n setEnrolledSuccessfully(true);\n setTimeout(() => {\n navigate(mfaChallengePath, { replace: true });\n }, 1200);\n }, [navigate, mfaChallengePath, completeEnrollmentSession]);\n\n const handleEnrollmentError = useCallback((msg: string) => {\n setError(msg);\n }, []);\n\n // Parked at organization onboarding (#1090): the organization is the only step left, whatever this screen was doing.\n const organizationOnboardingTarget = organizationOnboardingNavigationTarget(auth, authRedirectTarget);\n if (organizationOnboardingTarget) {\n return <Navigate to={organizationOnboardingTarget} replace />;\n }\n\n // Signed in — including by an enrollment that completed a registration session. Checked BEFORE the\n // `mfaRequired` bounce, which that completion clears and would otherwise read as \"go back to login\".\n if (auth.accessToken && !auth.isLoading) {\n return <Navigate to={postAuthRedirect} replace />;\n }\n\n if (!auth.mfaRequired) {\n // Not yet: the URL names a session and the recovery above has not answered. Bouncing now is the\n // defect #1033 records — the session is valid, only this page's memory of it is missing.\n if (needsSessionRecovery && !sessionRecoverySettled) {\n return <></>;\n }\n return <Navigate to={loginPath} replace />;\n }\n\n /*\n * Hand back to the challenge ONLY when a challenge can actually run.\n *\n * This bounce means \"you do not need to enroll anything, go and answer the challenge\" — a sentence\n * that is only true when something is usable. It used to fire on `enrollableOptions.length === 0`\n * alone, which made it the other half of a redirect loop: the challenge sends a user here when\n * nothing is usable, and this sent them straight back when there was nothing to enroll. Both\n * screens were individually reasonable and the PAIR never terminated.\n *\n * Requiring a usable factor breaks the cycle HERE, at the source, rather than relying on the two\n * screens agreeing about `availableEnrollmentMethods` — which they read from different places (this\n * one from the auth context, the challenge from its own session fetch), so any backend path that\n * populates one and not the other would reopen it.\n */\n const hasUsableSecondFactor = auth.usableSecondFactorMethods.length > 0;\n if (auth.mfaSessionId && enrollableOptions.length === 0 && hasUsableSecondFactor) {\n return <Navigate to={mfaChallengePath} replace />;\n }\n\n if (!isReady) return null;\n\n // Required, nothing usable, nothing enrollable: terminal, and it says so. Only an administrator can\n // resolve it, so the sole action left is to sign out.\n if (enrollableOptions.length === 0) {\n return (\n <div className=\"space-y-group py-section\">\n <div className=\"text-center space-y-item-xs\">\n <Heading>{t(EnrollmentRequiredLabel.TITLE)}</Heading>\n </div>\n <Alert>\n <AlertDescription>{t(EnrollmentRequiredLabel.NO_METHODS_AVAILABLE)}</AlertDescription>\n </Alert>\n <Button variant={ButtonVariants_Variant.OUTLINE} className=\"w-full\" onClick={() => logout()}>\n {t(EnrollmentRequiredLabel.LOGOUT_BUTTON)}\n </Button>\n </div>\n );\n }\n\n if (enrolledSuccessfully) {\n return (\n <div className=\"text-center space-y-group py-section\">\n <Alert>\n <AlertDescription>{t(EnrollmentRequiredLabel.ENROLL_SUCCESS)}</AlertDescription>\n </Alert>\n <Text className=\"text-sm text-muted-foreground\">{t(EnrollmentRequiredLabel.LOADING)}</Text>\n </div>\n );\n }\n\n const SelectedComponent = selectedMethod ? ENROLLMENT_METHOD_COMPONENTS[selectedMethod] : null;\n\n return (\n <div className=\"space-y-group py-section\">\n <div className=\"text-center space-y-item-xs\">\n <Heading>{t(EnrollmentRequiredLabel.TITLE)}</Heading>\n <Text className=\"text-muted-foreground max-w-sm mx-auto\">\n {t(EnrollmentRequiredLabel.DESCRIPTION)}\n </Text>\n </div>\n\n {error && (\n <Alert variant=\"destructive\">\n <AlertDescription>{error}</AlertDescription>\n </Alert>\n )}\n\n {!selectedMethod && (\n <div className=\"space-y-item\">\n <Text className=\"text-sm font-medium text-center\">\n {t(EnrollmentRequiredLabel.SELECT_METHOD)}\n </Text>\n <AuthMethodChoiceList\n layout={AuthMethodChoiceLayout.LIST}\n methods={enrollableOptions}\n labelFor={(method) => t(METHOD_DISPLAY_LABELS[method] || method)}\n onSelect={(method) => { setSelectedMethod(method); setError(null); }}\n />\n </div>\n )}\n\n {selectedMethod && SelectedComponent && (\n <div className=\"space-y-item\">\n <div className=\"flex items-center gap-2\">\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => { setSelectedMethod(null); setError(null); }}\n >\n ←\n </Button>\n <Text className=\"text-sm font-medium\">\n {t(METHOD_DISPLAY_LABELS[selectedMethod] || selectedMethod)}\n </Text>\n </div>\n <SelectedComponent\n sessionId={auth.mfaSessionId || undefined}\n onComplete={handleEnrollmentComplete}\n onError={handleEnrollmentError}\n isLoading={false}\n t={t}\n />\n </div>\n )}\n\n <div className=\"pt-2\">\n <Button variant={ButtonVariants_Variant.OUTLINE} className=\"w-full\" onClick={() => logout()}>\n {t(EnrollmentRequiredLabel.LOGOUT_BUTTON)}\n </Button>\n </div>\n </div>\n );\n};\n\nexport function Auth_EnrollmentRequired({ preset = CorePresetNames.DEFAULT, ...props }: PublicLayoutPreset_EnrollmentRequired_DefaultProps & ComponentPresetProps): React.JSX.Element {\n const Component = createComponentResolver<PublicLayoutPreset_EnrollmentRequired_DefaultProps>(FrontendComponentType.PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED, 'Auth_EnrollmentRequired')(preset);\n return <Component {...props} />;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"Auth_Main.d.ts","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_Main.tsx"],"names":[],"mappings":"AACA,OAAO,KAA4D,MAAM,OAAO,CAAC;AAiDjF,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAA;AAoEvH,MAAM,WAAW,wCAAwC;CACxD;AAED,eAAO,MAAM,mCAAmC,GAAI,IAAI,wCAAwC,KAAG,KAAK,CAAC,GAAG,CAAC,OAkc5G,CAAC;AAEF,wBAAgB,SAAS,CAAC,EAAE,MAAgC,EAAE,GAAG,KAAK,EAAE,EAAE,wCAAwC,GAAG,oBAAoB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAI5J"}
1
+ {"version":3,"file":"Auth_Main.d.ts","sourceRoot":"","sources":["../../../../../src/components/auth/Auth_Main.tsx"],"names":[],"mappings":"AACA,OAAO,KAA4D,MAAM,OAAO,CAAC;AAgDjF,OAAO,EAAE,oBAAoB,EAAE,MAAM,kFAAkF,CAAA;AAoEvH,MAAM,WAAW,wCAAwC;CACxD;AAED,eAAO,MAAM,mCAAmC,GAAI,IAAI,wCAAwC,KAAG,KAAK,CAAC,GAAG,CAAC,OAgc5G,CAAC;AAEF,wBAAgB,SAAS,CAAC,EAAE,MAAgC,EAAE,GAAG,KAAK,EAAE,EAAE,wCAAwC,GAAG,oBAAoB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAI5J"}
@@ -23,7 +23,6 @@ import { Alert, AlertDescription } from '../../components/overlays/containers/al
23
23
  import { CommonRoutePaths } from '../../core/runtime/routes.frontend.definitions.js';
24
24
  import { LoggerFrontendService } from '../../core/monitoring/logger.frontend.service.js';
25
25
  import { appendAuthRedirectToPath, extractAuthRedirectFromSearch, resolvePostAuthRedirect, } from '../../core/security/auth-redirect.frontend.utils.js';
26
- import { useApplication } from '../../core/runtime/useApplication.js';
27
26
  import { collectFrontendProviderDisplayLabelKeys } from '../../core/external-providers/frontend-provider-display-label.frontend.utils.js';
28
27
  import { resolveOAuthProviderDisplayLabel, resolvePublicOAuthProviderEntries } from '../../components/auth/utils/oauth-provider-display-label.frontend.utils.js';
29
28
  import { OAuthProvidersSection, SSO_PROVIDER_BRAND_META } from '../../components/auth/utils/OAuthProvidersSection.js';
@@ -80,15 +79,13 @@ const PASSKEY_AUTOFILL_FIELD_WAIT_MS = 3000;
80
79
  export const PublicLayoutPreset_UserAuth_Default = ({}) => {
81
80
  const { auth, identifyByEmail, initiateOAuth2Login } = useUserOrgs();
82
81
  const { signInWithPasskey } = useAuthSession();
83
- const { frontendProviderRegistry } = useApplication();
84
82
  const resolvedAuth = useResolvedAuthConfig();
85
83
  const location = useLocation();
86
84
  const enabledSocialOAuth2Providers = useMemo(() => {
87
85
  return resolvePublicOAuthProviderEntries({
88
86
  publicProviders: resolvedAuth.globalAuth?.socialOAuth2Providers,
89
- frontendProviderRegistry,
90
87
  });
91
- }, [frontendProviderRegistry, resolvedAuth.globalAuth?.socialOAuth2Providers]);
88
+ }, [resolvedAuth.globalAuth?.socialOAuth2Providers]);
92
89
  const socialOAuth2ProviderLabelKeys = useMemo(() => {
93
90
  return collectFrontendProviderDisplayLabelKeys(enabledSocialOAuth2Providers.map((provider) => provider.displayNameLabelKey));
94
91
  }, [enabledSocialOAuth2Providers]);