@jmruthers/pace-core 0.5.54 → 0.5.55

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 (396) hide show
  1. package/README.md +0 -4
  2. package/dist/{DataTable-7FMFXA7A.js → DataTable-4T627QFJ.js} +11 -11
  3. package/dist/{PublicLoadingSpinner-Bq_-BeK-.d.ts → PublicLoadingSpinner-SL8WaQN7.d.ts} +2 -21
  4. package/dist/{api-H5A3H4IR.js → api-LUNF5O6M.js} +3 -3
  5. package/dist/{appConfig-BVGyuvI7.d.ts → appConfig-DjpeG6P-.d.ts} +9 -1
  6. package/dist/{appNameResolver-7GHF5ED2.js → appNameResolver-UURKN7NF.js} +2 -2
  7. package/dist/{audit-BUW3LMJB.js → audit-6TOCAMKO.js} +2 -2
  8. package/dist/{chunk-MZBUOP4P.js → chunk-5BSLGBYI.js} +4 -3
  9. package/dist/chunk-5BSLGBYI.js.map +1 -0
  10. package/dist/{chunk-I5Z3QH5X.js → chunk-66C4BSAY.js} +2 -2
  11. package/dist/{chunk-I5Z3QH5X.js.map → chunk-66C4BSAY.js.map} +1 -1
  12. package/dist/{chunk-MYP2EGHX.js → chunk-AJ2KMES7.js} +21 -14
  13. package/dist/chunk-AJ2KMES7.js.map +1 -0
  14. package/dist/{chunk-EL2O4IUX.js → chunk-AQFRLC7K.js} +16 -24
  15. package/dist/{chunk-EL2O4IUX.js.map → chunk-AQFRLC7K.js.map} +1 -1
  16. package/dist/{chunk-7BNPOCLL.js → chunk-B2WTCLCV.js} +6 -2
  17. package/dist/chunk-B2WTCLCV.js.map +1 -0
  18. package/dist/{chunk-WJARTBCT.js → chunk-D7ARGIA3.js} +16 -7
  19. package/dist/chunk-D7ARGIA3.js.map +1 -0
  20. package/dist/{chunk-NRK4AIHQ.js → chunk-KBRACSJI.js} +3 -3
  21. package/dist/{chunk-NYUJ4FJR.js → chunk-KJDPSM64.js} +7 -7
  22. package/dist/chunk-KJDPSM64.js.map +1 -0
  23. package/dist/{chunk-GWSBHC4J.js → chunk-KLPVOPRI.js} +261 -38
  24. package/dist/chunk-KLPVOPRI.js.map +1 -0
  25. package/dist/{chunk-TRIZ7IB7.js → chunk-MPQDF75X.js} +148 -288
  26. package/dist/chunk-MPQDF75X.js.map +1 -0
  27. package/dist/{chunk-MSFACPQQ.js → chunk-PAEM3OWN.js} +11 -11
  28. package/dist/{chunk-MSFACPQQ.js.map → chunk-PAEM3OWN.js.map} +1 -1
  29. package/dist/{chunk-GIO7BFE7.js → chunk-RQD3D2CO.js} +66 -169
  30. package/dist/{chunk-GIO7BFE7.js.map → chunk-RQD3D2CO.js.map} +1 -1
  31. package/dist/{chunk-YDJW5XTN.js → chunk-STT7INZR.js} +25 -1
  32. package/dist/chunk-STT7INZR.js.map +1 -0
  33. package/dist/{chunk-6MTY77WU.js → chunk-TNMXZLDR.js} +3 -3
  34. package/dist/{chunk-BC3S53OZ.js → chunk-UQE2Y64H.js} +30 -14
  35. package/dist/chunk-UQE2Y64H.js.map +1 -0
  36. package/dist/{chunk-22KLBHPS.js → chunk-W66AZIOH.js} +2 -2
  37. package/dist/chunk-W66AZIOH.js.map +1 -0
  38. package/dist/{chunk-SS3E6QLB.js → chunk-YNUBMSMV.js} +2 -2
  39. package/dist/chunk-YNUBMSMV.js.map +1 -0
  40. package/dist/{chunk-NZ655MWE.js → chunk-ZOD2ZY6X.js} +5 -4
  41. package/dist/chunk-ZOD2ZY6X.js.map +1 -0
  42. package/dist/{chunk-74C6SNEC.js → chunk-ZPK5656W.js} +3 -3
  43. package/dist/{chunk-74C6SNEC.js.map → chunk-ZPK5656W.js.map} +1 -1
  44. package/dist/components.d.ts +22 -899
  45. package/dist/components.js +436 -3118
  46. package/dist/components.js.map +1 -1
  47. package/dist/file-reference-9xUOnwyt.d.ts +70 -0
  48. package/dist/hooks.d.ts +2 -2
  49. package/dist/hooks.js +10 -10
  50. package/dist/hooks.js.map +1 -1
  51. package/dist/index.d.ts +49 -9
  52. package/dist/index.js +190 -25
  53. package/dist/index.js.map +1 -1
  54. package/dist/{organisation-CO3Sh3_D.d.ts → organisation-t-vvQC3g.d.ts} +1 -8
  55. package/dist/providers.d.ts +2 -2
  56. package/dist/providers.js +5 -5
  57. package/dist/rbac/index.d.ts +65 -46
  58. package/dist/rbac/index.js +10 -12
  59. package/dist/styles/core.css +0 -125
  60. package/dist/types.d.ts +2 -1
  61. package/dist/types.js +3 -1
  62. package/dist/types.js.map +1 -1
  63. package/dist/{usePublicRouteParams-B2OcAsur.d.ts → usePublicRouteParams-CdoFxnJK.d.ts} +1 -1
  64. package/dist/utils.d.ts +3 -4
  65. package/dist/utils.js +44 -13
  66. package/dist/utils.js.map +1 -1
  67. package/docs/FILE_REFERENCE_SYSTEM.md +440 -0
  68. package/docs/INDEX.md +7 -5
  69. package/docs/README.md +0 -1
  70. package/docs/api/README.md +0 -4
  71. package/docs/api/classes/ErrorBoundary.md +1 -1
  72. package/docs/api/classes/InvalidScopeError.md +1 -1
  73. package/docs/api/classes/MissingUserContextError.md +1 -1
  74. package/docs/api/classes/OrganisationContextRequiredError.md +1 -1
  75. package/docs/api/classes/PermissionDeniedError.md +2 -2
  76. package/docs/api/classes/PublicErrorBoundary.md +1 -1
  77. package/docs/api/classes/RBACAuditManager.md +12 -12
  78. package/docs/api/classes/RBACCache.md +1 -1
  79. package/docs/api/classes/RBACEngine.md +6 -6
  80. package/docs/api/classes/RBACError.md +1 -1
  81. package/docs/api/classes/RBACNotInitializedError.md +1 -1
  82. package/docs/api/classes/SecureSupabaseClient.md +1 -1
  83. package/docs/api/classes/StorageUtils.md +281 -0
  84. package/docs/api/interfaces/AggregateConfig.md +1 -1
  85. package/docs/api/interfaces/ButtonProps.md +1 -1
  86. package/docs/api/interfaces/CardProps.md +1 -1
  87. package/docs/api/interfaces/ColorPalette.md +1 -1
  88. package/docs/api/interfaces/ColorShade.md +1 -1
  89. package/docs/api/interfaces/DataAccessRecord.md +1 -1
  90. package/docs/api/interfaces/DataTableAction.md +1 -1
  91. package/docs/api/interfaces/DataTableColumn.md +1 -1
  92. package/docs/api/interfaces/DataTableProps.md +1 -1
  93. package/docs/api/interfaces/DataTableToolbarButton.md +1 -1
  94. package/docs/api/interfaces/EmptyStateConfig.md +1 -1
  95. package/docs/api/interfaces/EnhancedNavigationMenuProps.md +1 -1
  96. package/docs/api/interfaces/EventContextType.md +1 -1
  97. package/docs/api/interfaces/EventLogoProps.md +1 -1
  98. package/docs/api/interfaces/EventProviderProps.md +1 -1
  99. package/docs/api/interfaces/FileSizeLimits.md +1 -1
  100. package/docs/api/interfaces/FileUploadProps.md +1 -1
  101. package/docs/api/interfaces/FooterProps.md +1 -1
  102. package/docs/api/interfaces/InactivityWarningModalProps.md +1 -1
  103. package/docs/api/interfaces/InputProps.md +1 -1
  104. package/docs/api/interfaces/LabelProps.md +1 -1
  105. package/docs/api/interfaces/LoginFormProps.md +1 -1
  106. package/docs/api/interfaces/NavigationAccessRecord.md +2 -2
  107. package/docs/api/interfaces/NavigationContextType.md +1 -1
  108. package/docs/api/interfaces/NavigationGuardProps.md +1 -1
  109. package/docs/api/interfaces/NavigationItem.md +1 -1
  110. package/docs/api/interfaces/NavigationMenuProps.md +1 -1
  111. package/docs/api/interfaces/NavigationProviderProps.md +1 -1
  112. package/docs/api/interfaces/Organisation.md +1 -1
  113. package/docs/api/interfaces/OrganisationContextType.md +1 -1
  114. package/docs/api/interfaces/OrganisationMembership.md +1 -1
  115. package/docs/api/interfaces/OrganisationProviderProps.md +1 -1
  116. package/docs/api/interfaces/OrganisationSecurityError.md +1 -1
  117. package/docs/api/interfaces/PaceAppLayoutProps.md +1 -1
  118. package/docs/api/interfaces/PaceLoginPageProps.md +1 -1
  119. package/docs/api/interfaces/PageAccessRecord.md +1 -1
  120. package/docs/api/interfaces/PagePermissionContextType.md +1 -1
  121. package/docs/api/interfaces/PagePermissionGuardProps.md +1 -1
  122. package/docs/api/interfaces/PagePermissionProviderProps.md +1 -1
  123. package/docs/api/interfaces/PaletteData.md +1 -1
  124. package/docs/api/interfaces/PermissionEnforcerProps.md +4 -4
  125. package/docs/api/interfaces/PublicErrorBoundaryProps.md +1 -1
  126. package/docs/api/interfaces/PublicErrorBoundaryState.md +1 -1
  127. package/docs/api/interfaces/PublicLoadingSpinnerProps.md +1 -1
  128. package/docs/api/interfaces/PublicPageFooterProps.md +1 -1
  129. package/docs/api/interfaces/PublicPageHeaderProps.md +1 -1
  130. package/docs/api/interfaces/PublicPageLayoutProps.md +1 -1
  131. package/docs/api/interfaces/RBACConfig.md +1 -1
  132. package/docs/api/interfaces/RBACContextType.md +1 -1
  133. package/docs/api/interfaces/RBACLogger.md +1 -1
  134. package/docs/api/interfaces/RBACProviderProps.md +1 -1
  135. package/docs/api/interfaces/RoleBasedRouterContextType.md +1 -1
  136. package/docs/api/interfaces/RoleBasedRouterProps.md +1 -1
  137. package/docs/api/interfaces/RouteAccessRecord.md +2 -2
  138. package/docs/api/interfaces/RouteConfig.md +2 -2
  139. package/docs/api/interfaces/SecureDataContextType.md +1 -1
  140. package/docs/api/interfaces/SecureDataProviderProps.md +1 -1
  141. package/docs/api/interfaces/StorageConfig.md +1 -1
  142. package/docs/api/interfaces/StorageFileInfo.md +1 -1
  143. package/docs/api/interfaces/StorageFileMetadata.md +1 -1
  144. package/docs/api/interfaces/StorageListOptions.md +1 -1
  145. package/docs/api/interfaces/StorageListResult.md +1 -1
  146. package/docs/api/interfaces/StorageUploadOptions.md +1 -1
  147. package/docs/api/interfaces/StorageUploadResult.md +1 -1
  148. package/docs/api/interfaces/StorageUrlOptions.md +1 -1
  149. package/docs/api/interfaces/StyleImport.md +1 -1
  150. package/docs/api/interfaces/ToastActionElement.md +1 -1
  151. package/docs/api/interfaces/ToastProps.md +1 -1
  152. package/docs/api/interfaces/UnifiedAuthContextType.md +1 -1
  153. package/docs/api/interfaces/UnifiedAuthProviderProps.md +1 -1
  154. package/docs/api/interfaces/UseInactivityTrackerOptions.md +1 -1
  155. package/docs/api/interfaces/UseInactivityTrackerReturn.md +1 -1
  156. package/docs/api/interfaces/UsePublicEventLogoOptions.md +1 -1
  157. package/docs/api/interfaces/UsePublicEventLogoReturn.md +1 -1
  158. package/docs/api/interfaces/UsePublicEventOptions.md +1 -1
  159. package/docs/api/interfaces/UsePublicEventReturn.md +1 -1
  160. package/docs/api/interfaces/UsePublicRouteParamsReturn.md +1 -1
  161. package/docs/api/interfaces/UserEventAccess.md +1 -1
  162. package/docs/api/interfaces/UserMenuProps.md +1 -1
  163. package/docs/api/interfaces/UserProfile.md +1 -1
  164. package/docs/api/modules.md +204 -200
  165. package/docs/api-reference/components.md +141 -163
  166. package/docs/api-reference/hooks.md +347 -0
  167. package/docs/core-concepts/rbac-system.md +69 -16
  168. package/docs/getting-started/examples/basic-auth-app.md +0 -1
  169. package/docs/implementation-guides/datatable-rbac-usage.md +12 -11
  170. package/docs/implementation-guides/file-upload-storage.md +733 -0
  171. package/docs/implementation-guides/inactivity-tracking.md +779 -0
  172. package/docs/implementation-guides/organisation-security.md +748 -0
  173. package/docs/implementation-guides/public-pages-advanced.md +1022 -0
  174. package/docs/migration/MIGRATION_GUIDE.md +684 -0
  175. package/docs/migration/README.md +13 -2
  176. package/docs/migration/rbac-migration.md +73 -0
  177. package/docs/rbac/examples/rbac-rls-integration-example.md +11 -13
  178. package/docs/style-guide.md +269 -1
  179. package/package.json +1 -1
  180. package/src/__tests__/TESTING_GUIDELINES.md +331 -18
  181. package/src/__tests__/helpers/supabaseMock.ts +99 -0
  182. package/src/__tests__/rbac/PagePermissionGuard.test.tsx +10 -7
  183. package/src/__tests__/shared.ts +6 -0
  184. package/src/components/DataTable/components/ActionButtons.tsx +2 -2
  185. package/src/components/DataTable/components/DataTableCore.tsx +2 -2
  186. package/src/components/DataTable/components/UnifiedTableBody.tsx +1 -1
  187. package/src/components/DataTable/utils/debugTools.ts +2 -2
  188. package/src/components/Dialog/Dialog.test.tsx +12 -2
  189. package/src/components/ErrorBoundary/ErrorBoundary.test.tsx +6 -6
  190. package/src/components/ErrorBoundary/ErrorBoundary.tsx +2 -2
  191. package/src/components/FileDisplay.tsx +233 -0
  192. package/src/components/FileUpload.tsx +176 -0
  193. package/src/components/Footer/Footer.test.tsx +7 -7
  194. package/src/components/NavigationMenu/NavigationMenu.test.tsx +13 -6
  195. package/src/components/OrganisationSelector/OrganisationSelector.test.tsx +30 -3
  196. package/src/components/OrganisationSelector/OrganisationSelector.tsx +1 -1
  197. package/src/components/PaceAppLayout/__tests__/PaceAppLayout.rbac.test.tsx +558 -0
  198. package/src/components/PublicLayout/PublicErrorBoundary.tsx +1 -1
  199. package/src/components/PublicLayout/PublicPageDebugger.tsx +2 -2
  200. package/src/components/PublicLayout/PublicPageDiagnostic.tsx +2 -2
  201. package/src/components/PublicLayout/PublicPageProvider.tsx +2 -2
  202. package/src/components/Select/Select.test.tsx +50 -15
  203. package/src/components/SuperAdminGuard.tsx +2 -2
  204. package/src/components/__tests__/SuperAdminGuard.test.tsx +559 -0
  205. package/src/components/index.ts +0 -183
  206. package/src/hooks/__tests__/useOrganisationPermissions.unit.test.tsx +2 -2
  207. package/src/hooks/__tests__/usePermissionCache.unit.test.ts +1 -1
  208. package/src/hooks/__tests__/useRBAC.unit.test.ts +191 -138
  209. package/src/hooks/public/usePublicEvent.ts +2 -2
  210. package/src/hooks/useAppConfig.ts +3 -3
  211. package/src/hooks/useComponentPerformance.ts +1 -1
  212. package/src/hooks/useDataTablePerformance.ts +1 -1
  213. package/src/hooks/useFileReference.ts +232 -0
  214. package/src/hooks/useOrganisationPermissions.test.ts +254 -344
  215. package/src/hooks/useOrganisationPermissions.ts +15 -7
  216. package/src/hooks/useOrganisationSecurity.test.ts +390 -402
  217. package/src/hooks/usePerformanceMonitor.ts +1 -1
  218. package/src/hooks/usePermissionCache.test.ts +264 -395
  219. package/src/hooks/usePermissionCache.ts +34 -4
  220. package/src/hooks/useSecureDataAccess.test.ts +486 -0
  221. package/src/hooks/useSecureDataAccess.ts +4 -1
  222. package/src/providers/InactivityProvider.tsx +2 -2
  223. package/src/providers/OrganisationProvider.test.simple.tsx +168 -0
  224. package/src/providers/OrganisationProvider.test.tsx +168 -0
  225. package/src/providers/OrganisationProvider.tsx +18 -31
  226. package/src/providers/UnifiedAuthProvider.test.simple.tsx +205 -0
  227. package/src/providers/UnifiedAuthProvider.test.tsx +128 -0
  228. package/src/providers/__tests__/InactivityProvider.test.tsx +3 -4
  229. package/src/providers/__tests__/OrganisationProvider.test.tsx +19 -14
  230. package/src/rbac/__tests__/integration.authflow.test.tsx +123 -0
  231. package/src/rbac/__tests__/integration.navigation.test.tsx +72 -0
  232. package/src/rbac/__tests__/integration.securedata.test.tsx +92 -0
  233. package/src/rbac/__tests__/integration.smoke.test.tsx +73 -0
  234. package/src/rbac/__tests__/rbac-core.test.tsx +26 -22
  235. package/src/rbac/__tests__/rbac-engine-core-logic.test.ts +411 -0
  236. package/src/rbac/__tests__/rbac-engine-simplified.test.ts +285 -0
  237. package/src/rbac/__tests__/rbac-functions.test.ts +655 -0
  238. package/src/rbac/__tests__/rbac-integration.test.ts +532 -0
  239. package/src/rbac/__tests__/scenarios.user-role.test.tsx +196 -0
  240. package/src/rbac/api.test.ts +6 -6
  241. package/src/rbac/api.ts +2 -2
  242. package/src/rbac/audit.test.ts +485 -0
  243. package/src/rbac/audit.ts +7 -1
  244. package/src/rbac/cache-invalidation.ts +318 -0
  245. package/src/rbac/cache.test.ts +286 -0
  246. package/src/rbac/components/EnhancedNavigationMenu.test.tsx +559 -0
  247. package/src/rbac/components/EnhancedNavigationMenu.tsx +29 -23
  248. package/src/rbac/components/NavigationProvider.test.tsx +449 -0
  249. package/src/rbac/components/PagePermissionGuard.tsx +4 -4
  250. package/src/rbac/components/PagePermissionProvider.test.tsx +479 -0
  251. package/src/rbac/components/SecureDataProvider.test.tsx +511 -0
  252. package/src/rbac/components/__tests__/PagePermissionGuard.race-condition.test.tsx +159 -430
  253. package/src/rbac/components/__tests__/PagePermissionGuard.test.tsx +4 -5
  254. package/src/rbac/components/__tests__/PagePermissionGuard.verification.test.tsx +112 -118
  255. package/src/rbac/config.test.ts +410 -0
  256. package/src/rbac/engine.test.simple.ts +237 -0
  257. package/src/rbac/engine.test.ts +233 -0
  258. package/src/rbac/engine.ts +37 -41
  259. package/src/rbac/examples/CompleteRBACExample.tsx +3 -3
  260. package/src/rbac/examples/EventBasedApp.tsx +4 -4
  261. package/src/rbac/hooks/useRBAC.simple.test.ts +16 -0
  262. package/src/rbac/hooks/useRBAC.test.ts +207 -455
  263. package/src/rbac/hooks/useRBAC.ts +30 -22
  264. package/src/rbac/permissions.test.ts +128 -0
  265. package/src/rbac/permissions.ts +56 -141
  266. package/src/rbac/providers/RBACProvider.tsx +1 -1
  267. package/src/rbac/secureClient.test.ts +444 -0
  268. package/src/rbac/security.test.ts +390 -0
  269. package/src/rbac/security.ts +1 -1
  270. package/src/rbac/types.test.ts +382 -0
  271. package/src/rbac/types.ts +2 -2
  272. package/src/styles/core.css +0 -125
  273. package/src/types/file-reference.ts +77 -0
  274. package/src/types/rbac-functions.ts +290 -0
  275. package/src/types/supabase.ts +10 -28
  276. package/src/types/unified.ts +4 -1
  277. package/src/utils/__tests__/bundleAnalysis.unit.test.ts +81 -55
  278. package/src/utils/__tests__/lazyLoad.unit.test.tsx +21 -12
  279. package/src/utils/__tests__/organisationContext.unit.test.ts +13 -7
  280. package/src/utils/__tests__/performanceBudgets.unit.test.ts +3 -3
  281. package/src/utils/__tests__/sessionTracking.unit.test.ts +32 -12
  282. package/src/utils/appConfig.ts +1 -1
  283. package/src/utils/appIdResolver.test.ts +503 -0
  284. package/src/utils/appIdResolver.ts +1 -1
  285. package/src/utils/appNameResolver.test.ts +494 -0
  286. package/src/utils/appNameResolver.ts +3 -2
  287. package/src/utils/bundleAnalysis.ts +3 -3
  288. package/src/utils/debugLogger.ts +1 -1
  289. package/src/utils/file-reference.ts +263 -0
  290. package/src/utils/formatDate.test.ts +2 -2
  291. package/src/utils/organisationContext.test.ts +340 -0
  292. package/src/utils/organisationContext.ts +19 -6
  293. package/src/utils/performanceBudgets.ts +2 -2
  294. package/src/utils/permissionUtils.test.ts +393 -0
  295. package/src/utils/permissionUtils.ts +5 -2
  296. package/src/utils/secureDataAccess.test.ts +715 -0
  297. package/src/utils/secureDataAccess.ts +21 -5
  298. package/src/utils/sessionTracking.ts +34 -4
  299. package/src/utils/storage/__tests__/helpers.unit.test.ts +328 -0
  300. package/src/utils/storage/__tests__/index.unit.test.ts +16 -0
  301. package/src/utils/storage/helpers.ts +20 -25
  302. package/src/utils/storage/index.ts +29 -1
  303. package/src/vite-env.d.ts +17 -0
  304. package/dist/chunk-22KLBHPS.js.map +0 -1
  305. package/dist/chunk-7BNPOCLL.js.map +0 -1
  306. package/dist/chunk-BC3S53OZ.js.map +0 -1
  307. package/dist/chunk-GWSBHC4J.js.map +0 -1
  308. package/dist/chunk-MYP2EGHX.js.map +0 -1
  309. package/dist/chunk-MZBUOP4P.js.map +0 -1
  310. package/dist/chunk-NYUJ4FJR.js.map +0 -1
  311. package/dist/chunk-NZ655MWE.js.map +0 -1
  312. package/dist/chunk-SS3E6QLB.js.map +0 -1
  313. package/dist/chunk-TRIZ7IB7.js.map +0 -1
  314. package/dist/chunk-WJARTBCT.js.map +0 -1
  315. package/dist/chunk-YDJW5XTN.js.map +0 -1
  316. package/docs/print-components/README.md +0 -258
  317. package/docs/print-components/api-reference.md +0 -636
  318. package/docs/print-components/examples/README.md +0 -204
  319. package/docs/print-components/examples/basic-report.tsx +0 -92
  320. package/docs/print-components/examples/card-catalog.tsx +0 -149
  321. package/docs/print-components/examples/cover-page-report.tsx +0 -163
  322. package/docs/print-components/quick-start.md +0 -363
  323. package/src/components/PrintButton/PrintButton.tsx +0 -321
  324. package/src/components/PrintButton/PrintButtonGroup.tsx +0 -84
  325. package/src/components/PrintButton/PrintToolbar.tsx +0 -94
  326. package/src/components/PrintButton/__tests__/PrintButton.test.tsx +0 -271
  327. package/src/components/PrintButton/examples/PrintButtonShowcase.tsx +0 -438
  328. package/src/components/PrintButton/index.ts +0 -33
  329. package/src/components/PrintButton/types.ts +0 -173
  330. package/src/components/PrintCard/PrintCard.tsx +0 -154
  331. package/src/components/PrintCard/PrintCardContent.tsx +0 -57
  332. package/src/components/PrintCard/PrintCardFooter.tsx +0 -60
  333. package/src/components/PrintCard/PrintCardGrid.tsx +0 -91
  334. package/src/components/PrintCard/PrintCardHeader.tsx +0 -78
  335. package/src/components/PrintCard/PrintCardImage.tsx +0 -81
  336. package/src/components/PrintCard/examples/PrintCardShowcase.tsx +0 -239
  337. package/src/components/PrintCard/index.ts +0 -34
  338. package/src/components/PrintCard/types.ts +0 -171
  339. package/src/components/PrintDataTable/PrintDataTable.tsx +0 -215
  340. package/src/components/PrintDataTable/PrintTableGroup.tsx +0 -90
  341. package/src/components/PrintDataTable/PrintTableRow.tsx +0 -76
  342. package/src/components/PrintDataTable/index.ts +0 -25
  343. package/src/components/PrintDataTable/types.ts +0 -67
  344. package/src/components/PrintFooter/PrintFooter.tsx +0 -183
  345. package/src/components/PrintFooter/PrintFooterContent.tsx +0 -71
  346. package/src/components/PrintFooter/PrintFooterInfo.tsx +0 -86
  347. package/src/components/PrintFooter/PrintPageNumber.tsx +0 -90
  348. package/src/components/PrintFooter/examples/PrintFooterShowcase.tsx +0 -390
  349. package/src/components/PrintFooter/index.ts +0 -30
  350. package/src/components/PrintFooter/types.ts +0 -149
  351. package/src/components/PrintGrid/PrintGrid.tsx +0 -180
  352. package/src/components/PrintGrid/PrintGridBreakpoint.tsx +0 -109
  353. package/src/components/PrintGrid/PrintGridContainer.tsx +0 -128
  354. package/src/components/PrintGrid/PrintGridItem.tsx +0 -220
  355. package/src/components/PrintGrid/examples/PrintGridShowcase.tsx +0 -359
  356. package/src/components/PrintGrid/index.ts +0 -31
  357. package/src/components/PrintGrid/types.ts +0 -159
  358. package/src/components/PrintHeader/PrintCoverHeader.tsx +0 -230
  359. package/src/components/PrintHeader/PrintHeader.tsx +0 -150
  360. package/src/components/PrintHeader/index.ts +0 -17
  361. package/src/components/PrintHeader/types.ts +0 -42
  362. package/src/components/PrintLayout/PrintLayout.tsx +0 -122
  363. package/src/components/PrintLayout/PrintLayoutContext.tsx +0 -66
  364. package/src/components/PrintLayout/PrintPageBreak.tsx +0 -52
  365. package/src/components/PrintLayout/examples/PrintShowcase.tsx +0 -230
  366. package/src/components/PrintLayout/index.ts +0 -19
  367. package/src/components/PrintLayout/types.ts +0 -37
  368. package/src/components/PrintPageBreak/PrintPageBreak.tsx +0 -120
  369. package/src/components/PrintPageBreak/PrintPageBreakGroup.tsx +0 -90
  370. package/src/components/PrintPageBreak/PrintPageBreakIndicator.tsx +0 -112
  371. package/src/components/PrintPageBreak/examples/PrintPageBreakShowcase.tsx +0 -279
  372. package/src/components/PrintPageBreak/index.ts +0 -23
  373. package/src/components/PrintPageBreak/types.ts +0 -94
  374. package/src/components/PrintSection/PrintColumn.tsx +0 -104
  375. package/src/components/PrintSection/PrintDivider.tsx +0 -101
  376. package/src/components/PrintSection/PrintSection.tsx +0 -129
  377. package/src/components/PrintSection/PrintSectionContent.tsx +0 -75
  378. package/src/components/PrintSection/PrintSectionHeader.tsx +0 -97
  379. package/src/components/PrintSection/examples/PrintSectionShowcase.tsx +0 -258
  380. package/src/components/PrintSection/index.ts +0 -33
  381. package/src/components/PrintSection/types.ts +0 -155
  382. package/src/components/PrintText/PrintText.tsx +0 -116
  383. package/src/components/PrintText/index.ts +0 -16
  384. package/src/components/PrintText/types.ts +0 -24
  385. package/src/rbac/__tests__/integration.test.tsx +0 -218
  386. package/src/utils/print/PrintDataProcessor.ts +0 -390
  387. package/src/utils/print/examples/PrintUtilitiesShowcase.tsx +0 -397
  388. package/src/utils/print/index.ts +0 -29
  389. package/src/utils/print/types.ts +0 -196
  390. package/src/utils/print/usePrintOptimization.ts +0 -272
  391. /package/dist/{DataTable-7FMFXA7A.js.map → DataTable-4T627QFJ.js.map} +0 -0
  392. /package/dist/{api-H5A3H4IR.js.map → api-LUNF5O6M.js.map} +0 -0
  393. /package/dist/{appNameResolver-7GHF5ED2.js.map → appNameResolver-UURKN7NF.js.map} +0 -0
  394. /package/dist/{audit-BUW3LMJB.js.map → audit-6TOCAMKO.js.map} +0 -0
  395. /package/dist/{chunk-NRK4AIHQ.js.map → chunk-KBRACSJI.js.map} +0 -0
  396. /package/dist/{chunk-6MTY77WU.js.map → chunk-TNMXZLDR.js.map} +0 -0
@@ -0,0 +1,440 @@
1
+ # File Reference System
2
+
3
+ A centralized file management system for PACE Core that provides consistent file storage, metadata tracking, and access control across all applications.
4
+
5
+ ## Overview
6
+
7
+ The File Reference System replaces scattered file URL columns with a centralized `file_references` table that provides:
8
+
9
+ - **Consistent Storage**: All files stored in organization-first structure
10
+ - **Metadata Tracking**: Rich file metadata including size, type, dimensions, etc.
11
+ - **Access Control**: Row Level Security (RLS) based on organization membership
12
+ - **Audit Trail**: Track who uploaded files and when
13
+ - **Easy Cleanup**: Identify and manage orphaned files
14
+
15
+ ## Architecture
16
+
17
+ ### Database Schema
18
+
19
+ ```sql
20
+ CREATE TABLE file_references (
21
+ id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
22
+ table_name TEXT NOT NULL, -- Source table (e.g., 'pace_person')
23
+ record_id TEXT NOT NULL, -- Source record ID
24
+ file_path TEXT NOT NULL, -- Storage path
25
+ file_metadata JSONB DEFAULT '{}', -- File metadata
26
+ organisation_id UUID NOT NULL, -- For RLS
27
+ app_id UUID NOT NULL, -- Application context
28
+ is_public BOOLEAN DEFAULT false, -- Public vs private
29
+ created_at TIMESTAMP WITH TIME ZONE DEFAULT NOW(),
30
+ updated_at TIMESTAMP WITH TIME ZONE DEFAULT NOW()
31
+ );
32
+ ```
33
+
34
+ ### Storage Structure
35
+
36
+ **Organization-First Structure:**
37
+ ```
38
+ {bucket}/{orgId}/{category}/{filename}
39
+
40
+ Examples:
41
+ - files/org-123/profile_photos/timestamp-uuid-photo.jpg
42
+ - files/org-123/id_documents/timestamp-uuid-passport.pdf
43
+ - public-files/org-123/event_logos/timestamp-uuid-logo.png
44
+ ```
45
+
46
+ ### File Categories
47
+
48
+ ```typescript
49
+ enum FileCategory {
50
+ PROFILE_PHOTOS = 'profile_photos',
51
+ ID_DOCUMENTS = 'id_documents',
52
+ QUALIFICATIONS = 'qualifications',
53
+ MEDICAL_DOCUMENTS = 'medical_documents',
54
+ DISH_IMAGES = 'dish_images',
55
+ EVENT_LOGOS = 'event_logos',
56
+ GENERAL_DOCUMENTS = 'general_documents',
57
+ IMAGES = 'images',
58
+ AUDIO = 'audio',
59
+ VIDEO = 'video',
60
+ ARCHIVES = 'archives'
61
+ }
62
+ ```
63
+
64
+ ## Usage
65
+
66
+ ### React Components
67
+
68
+ #### FileUpload Component
69
+
70
+ ```tsx
71
+ import { FileUpload, FileCategory } from '@jmruthers/pace-core';
72
+
73
+ <FileUpload
74
+ supabase={supabase}
75
+ table_name="pace_person"
76
+ record_id={personId}
77
+ organisation_id={orgId}
78
+ app_id="your-app-id"
79
+ category={FileCategory.PROFILE_PHOTOS}
80
+ accept="image/*"
81
+ maxSize={5 * 1024 * 1024}
82
+ onUploadSuccess={(result) => console.log('Uploaded:', result.file_path)}
83
+ onUploadError={(error) => console.error('Upload failed:', error)}
84
+ >
85
+ <div className="custom-upload-ui">
86
+ <p>Click to upload profile photo</p>
87
+ </div>
88
+ </FileUpload>
89
+ ```
90
+
91
+ #### FileDisplay Component
92
+
93
+ ```tsx
94
+ import { FileDisplay, FileCategory } from '@jmruthers/pace-core';
95
+
96
+ <FileDisplay
97
+ supabase={supabase}
98
+ table_name="pace_person"
99
+ record_id={personId}
100
+ organisation_id={orgId}
101
+ category={FileCategory.PROFILE_PHOTOS}
102
+ showDelete={true}
103
+ >
104
+ <FileUpload
105
+ supabase={supabase}
106
+ table_name="pace_person"
107
+ record_id={personId}
108
+ organisation_id={orgId}
109
+ app_id="your-app-id"
110
+ category={FileCategory.PROFILE_PHOTOS}
111
+ />
112
+ </FileDisplay>
113
+ ```
114
+
115
+ ### React Hooks
116
+
117
+ #### useFileReference Hook
118
+
119
+ ```tsx
120
+ import { useFileReference } from '@jmruthers/pace-core';
121
+
122
+ const { uploadFile, getFileUrl, deleteFile, isLoading, error } = useFileReference(supabase);
123
+
124
+ // Upload a file
125
+ const result = await uploadFile({
126
+ table_name: 'pace_person',
127
+ record_id: personId,
128
+ organisation_id: orgId,
129
+ app_id: 'your-app-id',
130
+ category: FileCategory.PROFILE_PHOTOS,
131
+ is_public: false
132
+ }, file);
133
+
134
+ // Get file URL
135
+ const fileUrl = await getFileUrl('pace_person', personId, orgId);
136
+
137
+ // Delete file
138
+ const success = await deleteFile('pace_person', personId, orgId, true);
139
+ ```
140
+
141
+ #### useFileReferenceForRecord Hook
142
+
143
+ ```tsx
144
+ import { useFileReferenceForRecord } from '@jmruthers/pace-core';
145
+
146
+ const { fileUrl, uploadFile, deleteFile, isLoading } = useFileReferenceForRecord(
147
+ supabase,
148
+ 'pace_person',
149
+ personId,
150
+ orgId
151
+ );
152
+
153
+ // Automatically loads file data for the record
154
+ // Provides convenient methods for common operations
155
+ ```
156
+
157
+ ### TypeScript Service
158
+
159
+ ```typescript
160
+ import { createFileReferenceService } from '@jmruthers/pace-core';
161
+
162
+ const service = createFileReferenceService(supabase);
163
+
164
+ // Create file reference
165
+ const fileRef = await service.createFileReference({
166
+ table_name: 'pace_person',
167
+ record_id: personId,
168
+ organisation_id: orgId,
169
+ app_id: 'your-app-id',
170
+ category: FileCategory.PROFILE_PHOTOS
171
+ }, file);
172
+
173
+ // Get file URL
174
+ const fileUrl = await service.getFileUrl('pace_person', personId, orgId);
175
+
176
+ // List all files for a record
177
+ const files = await service.listFileReferences('pace_person', personId, orgId);
178
+ ```
179
+
180
+ ## Database Functions
181
+
182
+ ### Helper Functions
183
+
184
+ ```sql
185
+ -- Insert file reference
186
+ SELECT insert_file_reference(
187
+ 'pace_person', -- table_name
188
+ 'person-uuid', -- record_id
189
+ 'org-123/profile_photos/file.jpg', -- file_path
190
+ 'org-uuid', -- organisation_id
191
+ 'app-uuid', -- app_id
192
+ '{"fileName": "photo.jpg"}'::jsonb, -- file_metadata
193
+ false -- is_public
194
+ );
195
+
196
+ -- Get file URL
197
+ SELECT get_file_url('pace_person', 'person-uuid', 'org-uuid');
198
+
199
+ -- Get signed URL for private files
200
+ SELECT get_file_signed_url('pace_person', 'person-uuid', 'org-uuid', 3600);
201
+
202
+ -- Delete file reference
203
+ SELECT delete_file_reference('pace_person', 'person-uuid', 'org-uuid', true);
204
+
205
+ -- List files for a record
206
+ SELECT * FROM get_record_files('pace_person', 'person-uuid', 'org-uuid');
207
+
208
+ -- Get file count for a record
209
+ SELECT get_record_file_count('pace_person', 'person-uuid', 'org-uuid');
210
+ ```
211
+
212
+ ## Migration from Old System
213
+
214
+ ### Before (Old Pattern)
215
+ ```typescript
216
+ // Direct URL storage
217
+ interface Person {
218
+ id: string;
219
+ name: string;
220
+ profile_photo_url: string; // Direct URL
221
+ }
222
+
223
+ // Manual file management
224
+ const uploadFile = async (file: File) => {
225
+ const { data } = await supabase.storage
226
+ .from('files')
227
+ .upload(`org-123/profile_photos/${file.name}`, file);
228
+
229
+ await supabase
230
+ .from('pace_person')
231
+ .update({ profile_photo_url: data.path })
232
+ .eq('id', personId);
233
+ };
234
+ ```
235
+
236
+ ### After (New Pattern)
237
+ ```typescript
238
+ // File reference system
239
+ interface Person {
240
+ id: string;
241
+ name: string;
242
+ // profile_photo_url removed - use file_references table
243
+ }
244
+
245
+ // Centralized file management
246
+ const { uploadFile } = useFileReference(supabase);
247
+
248
+ const handleUpload = async (file: File) => {
249
+ await uploadFile({
250
+ table_name: 'pace_person',
251
+ record_id: personId,
252
+ organisation_id: orgId,
253
+ app_id: 'your-app-id',
254
+ category: FileCategory.PROFILE_PHOTOS
255
+ }, file);
256
+ };
257
+ ```
258
+
259
+ ## Storage Management
260
+
261
+ ### Audit Orphaned Files
262
+
263
+ ```bash
264
+ # Run audit to identify orphaned files
265
+ node scripts/audit-storage-files.js
266
+
267
+ # Archive orphaned files (dry run first)
268
+ node scripts/archive-orphaned-files.js storage-audit-report.json --dry-run
269
+
270
+ # Actually archive orphaned files
271
+ node scripts/archive-orphaned-files.js storage-audit-report.json
272
+ ```
273
+
274
+ ### File Cleanup
275
+
276
+ The system provides automated cleanup capabilities:
277
+
278
+ 1. **Audit Script**: Identifies files not referenced in `file_references` table
279
+ 2. **Archive Script**: Moves orphaned files to `archived/` directory
280
+ 3. **Manual Review**: Review archived files before permanent deletion
281
+
282
+ ## Security
283
+
284
+ ### Row Level Security (RLS)
285
+
286
+ All file references are protected by RLS policies:
287
+
288
+ - Users can only access files from their organization
289
+ - Service role has full access for administrative operations
290
+ - File paths are validated to prevent directory traversal
291
+
292
+ ### Access Control
293
+
294
+ ```typescript
295
+ // Public files - accessible via public URL
296
+ const publicUrl = getPublicUrl(filePath);
297
+
298
+ // Private files - require signed URL
299
+ const signedUrl = await getSignedUrl(supabase, filePath, { expiresIn: 3600 });
300
+ ```
301
+
302
+ ## Best Practices
303
+
304
+ ### 1. Use Appropriate Categories
305
+ ```typescript
306
+ // Good - specific category
307
+ category: FileCategory.PROFILE_PHOTOS
308
+
309
+ // Avoid - generic category
310
+ category: FileCategory.GENERAL_DOCUMENTS
311
+ ```
312
+
313
+ ### 2. Handle Errors Gracefully
314
+ ```typescript
315
+ const { uploadFile, error } = useFileReference(supabase);
316
+
317
+ const handleUpload = async (file: File) => {
318
+ try {
319
+ const result = await uploadFile(options, file);
320
+ if (!result) {
321
+ console.error('Upload failed:', error);
322
+ }
323
+ } catch (err) {
324
+ console.error('Upload error:', err);
325
+ }
326
+ };
327
+ ```
328
+
329
+ ### 3. Clean Up on Component Unmount
330
+ ```typescript
331
+ useEffect(() => {
332
+ return () => {
333
+ // Clear any pending uploads or signed URLs
334
+ clearError();
335
+ };
336
+ }, []);
337
+ ```
338
+
339
+ ### 4. Validate File Types and Sizes
340
+ ```typescript
341
+ <FileUpload
342
+ accept="image/*"
343
+ maxSize={5 * 1024 * 1024} // 5MB
344
+ onUploadError={(error) => showError(error)}
345
+ />
346
+ ```
347
+
348
+ ## Troubleshooting
349
+
350
+ ### Common Issues
351
+
352
+ 1. **File not found**: Check if file reference exists in database
353
+ 2. **Access denied**: Verify user has access to organization
354
+ 3. **Upload fails**: Check file size limits and storage permissions
355
+ 4. **Signed URL expired**: Refresh signed URL for private files
356
+
357
+ ### Debug Mode
358
+
359
+ Enable debug logging to troubleshoot issues:
360
+
361
+ ```typescript
362
+ // Set debug mode in your app
363
+ localStorage.setItem('pace-core-debug', 'true');
364
+ ```
365
+
366
+ ## API Reference
367
+
368
+ ### FileReference Interface
369
+
370
+ ```typescript
371
+ interface FileReference {
372
+ id: string;
373
+ table_name: string;
374
+ record_id: string;
375
+ file_path: string;
376
+ file_metadata: FileMetadata;
377
+ organisation_id: string;
378
+ app_id: string;
379
+ is_public: boolean;
380
+ created_at: string;
381
+ updated_at: string;
382
+ }
383
+ ```
384
+
385
+ ### FileMetadata Interface
386
+
387
+ ```typescript
388
+ interface FileMetadata {
389
+ fileName: string;
390
+ fileType: string;
391
+ fileSize?: number;
392
+ width?: number;
393
+ height?: number;
394
+ category: FileCategory;
395
+ hash?: string;
396
+ uploadedBy?: string;
397
+ uploadedAt?: string;
398
+ tags?: string[];
399
+ customMetadata?: Record<string, any>;
400
+ }
401
+ ```
402
+
403
+ ## Migration Guide
404
+
405
+ ### Step 1: Database Migration
406
+ Run the migration scripts in order:
407
+ 1. `20250202030001_add_file_references_indexes_and_functions.sql`
408
+ 2. `20250202030002_migrate_file_columns_to_file_references.sql`
409
+ 3. `20250202030003_drop_old_file_columns.sql`
410
+ 4. `20250202030004_drop_old_file_columns_final.sql`
411
+
412
+ ### Step 2: Update Application Code
413
+ Replace direct file URL usage with file reference system:
414
+
415
+ ```typescript
416
+ // Old
417
+ const profilePhoto = person.profile_photo_url;
418
+
419
+ // New
420
+ const { fileUrl } = useFileReferenceForRecord(supabase, 'pace_person', personId, orgId);
421
+ ```
422
+
423
+ ### Step 3: Test and Verify
424
+ 1. Test file uploads and downloads
425
+ 2. Verify RLS policies work correctly
426
+ 3. Run audit script to check for orphaned files
427
+ 4. Clean up any issues found
428
+
429
+ ### Step 4: Cleanup
430
+ Run the cleanup migration:
431
+ - `20250202040001_cleanup_migration_tables.sql`
432
+
433
+ ## Support
434
+
435
+ For issues or questions about the File Reference System:
436
+
437
+ 1. Check this documentation first
438
+ 2. Review the audit reports for storage issues
439
+ 3. Check the database logs for RLS policy violations
440
+ 4. Contact the development team with specific error messages
package/docs/INDEX.md CHANGED
@@ -27,15 +27,16 @@ Complete index of all PACE Core documentation organized by topic and use case.
27
27
  ### Data Management
28
28
  - **[Data Tables](./implementation-guides/data-tables.md)** - Interactive data management
29
29
  - **[Forms](./implementation-guides/forms.md)** - Form handling and validation
30
+ - **[File Upload & Storage](./implementation-guides/file-upload-storage.md)** - **NEW** Complete file management system
30
31
  - **[Event Management](./core-concepts/event-management.md)** - Event selection and context
31
32
  - **[Organisation Management](./core-concepts/organisation-management.md)** - Multi-tenant support
32
- - **[Public Pages](./implementation-guides/public-pages.md)** - **NEW** Public pages without authentication
33
+ - **[Public Pages](./implementation-guides/public-pages.md)** - Public pages without authentication
34
+ - **[Public Pages Advanced](./implementation-guides/public-pages-advanced.md)** - **NEW** Advanced public page patterns
33
35
 
34
36
  ### UI & Layout
35
37
  - **[Components API](./api-reference/components.md)** - Complete component reference
36
38
  - **[App Layout](./implementation-guides/app-layout.md)** - Application structure
37
39
  - **[Navigation](./implementation-guides/navigation.md)** - Navigation patterns
38
- - **[Print Components](./print-components/README.md)** - Print-optimized layouts
39
40
 
40
41
  ## 🎨 Styling & Theming
41
42
 
@@ -56,7 +57,6 @@ Complete index of all PACE Core documentation organized by topic and use case.
56
57
  - **[UI Components](./api-reference/components.md)** - Button, Card, Input, etc.
57
58
  - **[Data Components](./api-reference/components.md#data-table)** - DataTable, Form, etc.
58
59
  - **[Layout Components](./api-reference/components.md#layout-components)** - PaceAppLayout, Header, etc.
59
- - **[Print Components](./api-reference/components.md#print-components)** - Print-optimized components
60
60
 
61
61
  ### Hooks & Utilities
62
62
  - **[React Hooks](./api-reference/hooks.md)** - useUnifiedAuth, useCan, etc.
@@ -92,7 +92,8 @@ Complete index of all PACE Core documentation organized by topic and use case.
92
92
  ## 🔄 Migration & Updates
93
93
 
94
94
  ### Version Updates
95
- - **[Migration Overview](./migration/README.md)** - Upgrade guides
95
+ - **[Unified Migration Guide](./migration/MIGRATION_GUIDE.md)** - **NEW** Complete migration reference
96
+ - **[Migration Overview](./migration/README.md)** - Individual migration guides
96
97
  - **[v0.4.17 Source Path Fix](./migration/v0.4.17-source-path-fix.md)** - **CRITICAL** Fix
97
98
  - **[v0.4.16 CSS-First Migration](./migration/v0.4.16-css-first-approach.md)** - Simplified config
98
99
  - **[v0.4.15 Tailwind Scanning](./migration/v0.4.15-tailwind-scanning.md)** - Legacy approach
@@ -132,9 +133,10 @@ Complete index of all PACE Core documentation organized by topic and use case.
132
133
 
133
134
  ### Advanced Features
134
135
  - **[Permission Enforcement](./implementation-guides/permission-enforcement.md)** - Security implementation
136
+ - **[Inactivity Tracking](./implementation-guides/inactivity-tracking.md)** - **NEW** User session management
137
+ - **[Organisation Security](./implementation-guides/organisation-security.md)** - **NEW** Advanced security patterns
135
138
  - **[Event Management](./implementation-guides/event-management.md)** - Event handling
136
139
  - **[Organisation Management](./implementation-guides/organisation-management.md)** - Multi-tenancy
137
- - **[Print Reports](./implementation-guides/print-reports.md)** - Report generation
138
140
 
139
141
  ## 🎨 Styling Guides
140
142
 
package/docs/README.md CHANGED
@@ -48,7 +48,6 @@ function App() {
48
48
  - **[Authentication](./core-concepts/authentication.md)** - User management and session handling
49
49
  - **[RBAC System](./rbac/README.md)** - Complete role-based access control
50
50
  - **[UI Components](./api-reference/components.md)** - Modern, accessible component library
51
- - **[Print Components](./print-components/README.md)** - **NEW** Print-optimized layout system
52
51
  - **[Styling](./styles/README.md)** - Design system and theming
53
52
 
54
53
  ### 🛠️ **Implementation**
@@ -284,7 +284,6 @@ import {
284
284
  - **Data Display**: DataTable (with hierarchical actions & expand/collapse all), Table
285
285
  - **Forms**: Form, LoginForm
286
286
  - **Layout**: PaceAppLayout, Header, Footer, NavigationMenu
287
- - **Print Components**: PrintLayout, PrintDataTable, PrintCard, PrintHeader, PrintText, PrintButton, PrintGrid, PrintSection, PrintFooter, PrintPageBreak
288
287
  - **Providers**: UnifiedAuthProvider, OrganisationProvider, EventProvider
289
288
  - **Hooks**: useUnifiedAuth, useOrganisations, useEvents
290
289
 
@@ -292,9 +291,6 @@ import {
292
291
 
293
292
  - **[DataTable Component](docs/implementation-guides/data-tables.md)** - Enterprise-grade data table with hierarchical rows, expand/collapse all, actions, sorting, filtering, and performance optimization
294
293
  - **[Hierarchical DataTable Guide](docs/implementation-guides/hierarchical-datatable.md)** - Complete guide for implementing parent/child rows with expand/collapse all and smart sorting
295
- - **[Print Components](docs/print-components/README.md)** - **NEW** Print-optimized layout system for reports, documents, and printable content
296
- - **[Print Quick Start](docs/print-components/quick-start.md)** - 5-minute setup guide
297
- - **[Print API Reference](docs/print-components/api-reference.md)** - Complete component documentation
298
294
  - **[Dialog Component](src/components/Dialog/README.md)** - Comprehensive dialog system with smart height management, scrolling, HTML content rendering, and accessibility features
299
295
  - **[Storage System](src/utils/storage/README.md)** - File storage utilities with organization-scoped access control
300
296
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / ErrorBoundary
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / ErrorBoundary
2
2
 
3
3
  # Class: ErrorBoundary
4
4
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / InvalidScopeError
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / InvalidScopeError
2
2
 
3
3
  # Class: InvalidScopeError
4
4
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / MissingUserContextError
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / MissingUserContextError
2
2
 
3
3
  # Class: MissingUserContextError
4
4
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / OrganisationContextRequiredError
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / OrganisationContextRequiredError
2
2
 
3
3
  # Class: OrganisationContextRequiredError
4
4
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / PermissionDeniedError
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / PermissionDeniedError
2
2
 
3
3
  # Class: PermissionDeniedError
4
4
 
@@ -29,7 +29,7 @@
29
29
 
30
30
  | Name | Type |
31
31
  | :------ | :------ |
32
- | `permission` | \`read:$\{string}\` \| \`create:$\{string}\` \| \`update:$\{string}\` \| \`delete:$\{string}\` \| \`manage:$\{string}\` |
32
+ | `permission` | \`read:$\{string}\` \| \`create:$\{string}\` \| \`update:$\{string}\` \| \`delete:$\{string}\` |
33
33
  | `context?` | `Record`\<`string`, `any`\> |
34
34
 
35
35
  #### Returns
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / PublicErrorBoundary
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / PublicErrorBoundary
2
2
 
3
3
  # Class: PublicErrorBoundary
4
4
 
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / RBACAuditManager
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / RBACAuditManager
2
2
 
3
3
  # Class: RBACAuditManager
4
4
 
@@ -43,7 +43,7 @@ Handles emission of structured audit events for all RBAC operations.
43
43
 
44
44
  #### Defined in
45
45
 
46
- [packages/core/src/rbac/audit.ts:110](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L110)
46
+ [packages/core/src/rbac/audit.ts:112](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L112)
47
47
 
48
48
  ## Methods
49
49
 
@@ -65,7 +65,7 @@ Enable or disable audit logging
65
65
 
66
66
  #### Defined in
67
67
 
68
- [packages/core/src/rbac/audit.ts:119](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L119)
68
+ [packages/core/src/rbac/audit.ts:121](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L121)
69
69
 
70
70
  ___
71
71
 
@@ -83,7 +83,7 @@ True if audit logging is enabled
83
83
 
84
84
  #### Defined in
85
85
 
86
- [packages/core/src/rbac/audit.ts:128](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L128)
86
+ [packages/core/src/rbac/audit.ts:130](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L130)
87
87
 
88
88
  ___
89
89
 
@@ -107,7 +107,7 @@ Promise that resolves when event is logged
107
107
 
108
108
  #### Defined in
109
109
 
110
- [packages/core/src/rbac/audit.ts:138](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L138)
110
+ [packages/core/src/rbac/audit.ts:140](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L140)
111
111
 
112
112
  ___
113
113
 
@@ -129,7 +129,7 @@ Emit a permission check audit event
129
129
 
130
130
  #### Defined in
131
131
 
132
- [packages/core/src/rbac/audit.ts:194](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L194)
132
+ [packages/core/src/rbac/audit.ts:200](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L200)
133
133
 
134
134
  ___
135
135
 
@@ -151,7 +151,7 @@ Emit a permission denied audit event
151
151
 
152
152
  #### Defined in
153
153
 
154
- [packages/core/src/rbac/audit.ts:206](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L206)
154
+ [packages/core/src/rbac/audit.ts:212](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L212)
155
155
 
156
156
  ___
157
157
 
@@ -173,7 +173,7 @@ Emit a role granted audit event
173
173
 
174
174
  #### Defined in
175
175
 
176
- [packages/core/src/rbac/audit.ts:218](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L218)
176
+ [packages/core/src/rbac/audit.ts:224](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L224)
177
177
 
178
178
  ___
179
179
 
@@ -195,7 +195,7 @@ Emit a role revoked audit event
195
195
 
196
196
  #### Defined in
197
197
 
198
- [packages/core/src/rbac/audit.ts:230](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L230)
198
+ [packages/core/src/rbac/audit.ts:236](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L236)
199
199
 
200
200
  ___
201
201
 
@@ -217,7 +217,7 @@ Emit an RLS denied audit event
217
217
 
218
218
  #### Defined in
219
219
 
220
- [packages/core/src/rbac/audit.ts:242](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L242)
220
+ [packages/core/src/rbac/audit.ts:248](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L248)
221
221
 
222
222
  ___
223
223
 
@@ -242,7 +242,7 @@ Promise resolving to audit events
242
242
 
243
243
  #### Defined in
244
244
 
245
- [packages/core/src/rbac/audit.ts:256](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L256)
245
+ [packages/core/src/rbac/audit.ts:262](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L262)
246
246
 
247
247
  ___
248
248
 
@@ -267,4 +267,4 @@ Promise resolving to audit events
267
267
 
268
268
  #### Defined in
269
269
 
270
- [packages/core/src/rbac/audit.ts:278](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L278)
270
+ [packages/core/src/rbac/audit.ts:284](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/rbac/audit.ts#L284)
@@ -1,4 +1,4 @@
1
- [@jmruthers/pace-core - v0.5.54](../README.md) / [Exports](../modules.md) / RBACCache
1
+ [@jmruthers/pace-core - v0.5.55](../README.md) / [Exports](../modules.md) / RBACCache
2
2
 
3
3
  # Class: RBACCache
4
4