@jmruthers/pace-core 0.5.133 → 0.5.135
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.
- package/dist/{DataTable-O7VZ5UHT.js → DataTable-A36PJG6N.js} +2 -2
- package/dist/{chunk-ROXKK5IX.js → chunk-GVDR7WNV.js} +3 -1
- package/dist/chunk-GVDR7WNV.js.map +1 -0
- package/dist/{chunk-23C2SU3M.js → chunk-HMNOSGVA.js} +2 -2
- package/dist/components.js +2 -2
- package/dist/index.d.ts +120 -2
- package/dist/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/utils.js +1 -1
- package/docs/api/classes/ColumnFactory.md +1 -1
- package/docs/api/classes/ErrorBoundary.md +1 -1
- package/docs/api/classes/InvalidScopeError.md +1 -1
- package/docs/api/classes/MissingUserContextError.md +1 -1
- package/docs/api/classes/OrganisationContextRequiredError.md +1 -1
- package/docs/api/classes/PermissionDeniedError.md +1 -1
- package/docs/api/classes/PublicErrorBoundary.md +1 -1
- package/docs/api/classes/RBACAuditManager.md +1 -1
- package/docs/api/classes/RBACCache.md +1 -1
- package/docs/api/classes/RBACEngine.md +1 -1
- package/docs/api/classes/RBACError.md +1 -1
- package/docs/api/classes/RBACNotInitializedError.md +1 -1
- package/docs/api/classes/SecureSupabaseClient.md +1 -1
- package/docs/api/classes/StorageUtils.md +1 -1
- package/docs/api/enums/FileCategory.md +1 -1
- package/docs/api/interfaces/AggregateConfig.md +1 -1
- package/docs/api/interfaces/ButtonProps.md +1 -1
- package/docs/api/interfaces/CardProps.md +1 -1
- package/docs/api/interfaces/ColorPalette.md +1 -1
- package/docs/api/interfaces/ColorShade.md +1 -1
- package/docs/api/interfaces/DataAccessRecord.md +1 -1
- package/docs/api/interfaces/DataRecord.md +1 -1
- package/docs/api/interfaces/DataTableAction.md +1 -1
- package/docs/api/interfaces/DataTableColumn.md +1 -1
- package/docs/api/interfaces/DataTableProps.md +3 -3
- package/docs/api/interfaces/DataTableToolbarButton.md +1 -1
- package/docs/api/interfaces/EmptyStateConfig.md +1 -1
- package/docs/api/interfaces/EnhancedNavigationMenuProps.md +1 -1
- package/docs/api/interfaces/EventAppRoleData.md +1 -1
- package/docs/api/interfaces/ExportColumn.md +90 -0
- package/docs/api/interfaces/ExportOptions.md +126 -0
- package/docs/api/interfaces/FileDisplayProps.md +1 -1
- package/docs/api/interfaces/FileMetadata.md +1 -1
- package/docs/api/interfaces/FileReference.md +1 -1
- package/docs/api/interfaces/FileSizeLimits.md +1 -1
- package/docs/api/interfaces/FileUploadOptions.md +1 -1
- package/docs/api/interfaces/FileUploadProps.md +1 -1
- package/docs/api/interfaces/FooterProps.md +1 -1
- package/docs/api/interfaces/GrantEventAppRoleParams.md +1 -1
- package/docs/api/interfaces/InactivityWarningModalProps.md +1 -1
- package/docs/api/interfaces/InputProps.md +1 -1
- package/docs/api/interfaces/LabelProps.md +1 -1
- package/docs/api/interfaces/LoginFormProps.md +1 -1
- package/docs/api/interfaces/NavigationAccessRecord.md +1 -1
- package/docs/api/interfaces/NavigationContextType.md +1 -1
- package/docs/api/interfaces/NavigationGuardProps.md +1 -1
- package/docs/api/interfaces/NavigationItem.md +1 -1
- package/docs/api/interfaces/NavigationMenuProps.md +1 -1
- package/docs/api/interfaces/NavigationProviderProps.md +1 -1
- package/docs/api/interfaces/Organisation.md +1 -1
- package/docs/api/interfaces/OrganisationContextType.md +1 -1
- package/docs/api/interfaces/OrganisationMembership.md +1 -1
- package/docs/api/interfaces/OrganisationProviderProps.md +1 -1
- package/docs/api/interfaces/OrganisationSecurityError.md +1 -1
- package/docs/api/interfaces/PaceAppLayoutProps.md +1 -1
- package/docs/api/interfaces/PaceLoginPageProps.md +1 -1
- package/docs/api/interfaces/PageAccessRecord.md +1 -1
- package/docs/api/interfaces/PagePermissionContextType.md +1 -1
- package/docs/api/interfaces/PagePermissionGuardProps.md +1 -1
- package/docs/api/interfaces/PagePermissionProviderProps.md +1 -1
- package/docs/api/interfaces/PaletteData.md +1 -1
- package/docs/api/interfaces/PermissionEnforcerProps.md +1 -1
- package/docs/api/interfaces/ProtectedRouteProps.md +1 -1
- package/docs/api/interfaces/PublicErrorBoundaryProps.md +1 -1
- package/docs/api/interfaces/PublicErrorBoundaryState.md +1 -1
- package/docs/api/interfaces/PublicLoadingSpinnerProps.md +1 -1
- package/docs/api/interfaces/PublicPageFooterProps.md +1 -1
- package/docs/api/interfaces/PublicPageHeaderProps.md +1 -1
- package/docs/api/interfaces/PublicPageLayoutProps.md +1 -1
- package/docs/api/interfaces/RBACConfig.md +1 -1
- package/docs/api/interfaces/RBACLogger.md +1 -1
- package/docs/api/interfaces/RevokeEventAppRoleParams.md +1 -1
- package/docs/api/interfaces/RoleBasedRouterContextType.md +1 -1
- package/docs/api/interfaces/RoleBasedRouterProps.md +1 -1
- package/docs/api/interfaces/RoleManagementResult.md +1 -1
- package/docs/api/interfaces/RouteAccessRecord.md +1 -1
- package/docs/api/interfaces/RouteConfig.md +1 -1
- package/docs/api/interfaces/SecureDataContextType.md +1 -1
- package/docs/api/interfaces/SecureDataProviderProps.md +1 -1
- package/docs/api/interfaces/StorageConfig.md +1 -1
- package/docs/api/interfaces/StorageFileInfo.md +1 -1
- package/docs/api/interfaces/StorageFileMetadata.md +1 -1
- package/docs/api/interfaces/StorageListOptions.md +1 -1
- package/docs/api/interfaces/StorageListResult.md +1 -1
- package/docs/api/interfaces/StorageUploadOptions.md +1 -1
- package/docs/api/interfaces/StorageUploadResult.md +1 -1
- package/docs/api/interfaces/StorageUrlOptions.md +1 -1
- package/docs/api/interfaces/StyleImport.md +1 -1
- package/docs/api/interfaces/SwitchProps.md +1 -1
- package/docs/api/interfaces/ToastActionElement.md +1 -1
- package/docs/api/interfaces/ToastProps.md +1 -1
- package/docs/api/interfaces/UnifiedAuthContextType.md +1 -1
- package/docs/api/interfaces/UnifiedAuthProviderProps.md +1 -1
- package/docs/api/interfaces/UseInactivityTrackerOptions.md +1 -1
- package/docs/api/interfaces/UseInactivityTrackerReturn.md +1 -1
- package/docs/api/interfaces/UsePublicEventOptions.md +1 -1
- package/docs/api/interfaces/UsePublicEventReturn.md +1 -1
- package/docs/api/interfaces/UsePublicFileDisplayOptions.md +1 -1
- package/docs/api/interfaces/UsePublicFileDisplayReturn.md +1 -1
- package/docs/api/interfaces/UsePublicRouteParamsReturn.md +1 -1
- package/docs/api/interfaces/UseResolvedScopeOptions.md +1 -1
- package/docs/api/interfaces/UseResolvedScopeReturn.md +1 -1
- package/docs/api/interfaces/UserEventAccess.md +1 -1
- package/docs/api/interfaces/UserMenuProps.md +1 -1
- package/docs/api/interfaces/UserProfile.md +1 -1
- package/docs/api/modules.md +136 -2
- package/package.json +1 -1
- package/src/components/DataTable/DataTable.tsx +6 -0
- package/src/index.ts +9 -1
- package/dist/chunk-ROXKK5IX.js.map +0 -1
- /package/dist/{DataTable-O7VZ5UHT.js.map → DataTable-A36PJG6N.js.map} +0 -0
- /package/dist/{chunk-23C2SU3M.js.map → chunk-HMNOSGVA.js.map} +0 -0
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
[@jmruthers/pace-core - v0.5.135](../README.md) / [Exports](../modules.md) / ExportColumn
|
|
2
|
+
|
|
3
|
+
# Interface: ExportColumn
|
|
4
|
+
|
|
5
|
+
Column definition for export
|
|
6
|
+
|
|
7
|
+
## Table of contents
|
|
8
|
+
|
|
9
|
+
### Properties
|
|
10
|
+
|
|
11
|
+
- [header](ExportColumn.md#header)
|
|
12
|
+
- [id](ExportColumn.md#id)
|
|
13
|
+
- [accessorKey](ExportColumn.md#accessorkey)
|
|
14
|
+
- [accessorFn](ExportColumn.md#accessorfn)
|
|
15
|
+
- [editAccessorKey](ExportColumn.md#editaccessorkey)
|
|
16
|
+
- [isIdColumn](ExportColumn.md#isidcolumn)
|
|
17
|
+
|
|
18
|
+
## Properties
|
|
19
|
+
|
|
20
|
+
### header
|
|
21
|
+
|
|
22
|
+
• `Optional` **header**: `string`
|
|
23
|
+
|
|
24
|
+
#### Defined in
|
|
25
|
+
|
|
26
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:49](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L49)
|
|
27
|
+
|
|
28
|
+
___
|
|
29
|
+
|
|
30
|
+
### id
|
|
31
|
+
|
|
32
|
+
• `Optional` **id**: `string`
|
|
33
|
+
|
|
34
|
+
#### Defined in
|
|
35
|
+
|
|
36
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:50](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L50)
|
|
37
|
+
|
|
38
|
+
___
|
|
39
|
+
|
|
40
|
+
### accessorKey
|
|
41
|
+
|
|
42
|
+
• `Optional` **accessorKey**: `string`
|
|
43
|
+
|
|
44
|
+
#### Defined in
|
|
45
|
+
|
|
46
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:51](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L51)
|
|
47
|
+
|
|
48
|
+
___
|
|
49
|
+
|
|
50
|
+
### accessorFn
|
|
51
|
+
|
|
52
|
+
• `Optional` **accessorFn**: (`row`: `any`) => `any`
|
|
53
|
+
|
|
54
|
+
#### Type declaration
|
|
55
|
+
|
|
56
|
+
▸ (`row`): `any`
|
|
57
|
+
|
|
58
|
+
##### Parameters
|
|
59
|
+
|
|
60
|
+
| Name | Type |
|
|
61
|
+
| :------ | :------ |
|
|
62
|
+
| `row` | `any` |
|
|
63
|
+
|
|
64
|
+
##### Returns
|
|
65
|
+
|
|
66
|
+
`any`
|
|
67
|
+
|
|
68
|
+
#### Defined in
|
|
69
|
+
|
|
70
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:52](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L52)
|
|
71
|
+
|
|
72
|
+
___
|
|
73
|
+
|
|
74
|
+
### editAccessorKey
|
|
75
|
+
|
|
76
|
+
• `Optional` **editAccessorKey**: `string`
|
|
77
|
+
|
|
78
|
+
#### Defined in
|
|
79
|
+
|
|
80
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:53](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L53)
|
|
81
|
+
|
|
82
|
+
___
|
|
83
|
+
|
|
84
|
+
### isIdColumn
|
|
85
|
+
|
|
86
|
+
• `Optional` **isIdColumn**: `boolean`
|
|
87
|
+
|
|
88
|
+
#### Defined in
|
|
89
|
+
|
|
90
|
+
[packages/core/src/components/DataTable/utils/exportUtils.ts:54](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/utils/exportUtils.ts#L54)
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
[@jmruthers/pace-core - v0.5.135](../README.md) / [Exports](../modules.md) / ExportOptions
|
|
2
|
+
|
|
3
|
+
# Interface: ExportOptions\<TData\>
|
|
4
|
+
|
|
5
|
+
Options provided to the onExport handler for custom export functionality
|
|
6
|
+
|
|
7
|
+
**`Example`**
|
|
8
|
+
|
|
9
|
+
```tsx
|
|
10
|
+
<DataTable
|
|
11
|
+
onExport={async (options) => {
|
|
12
|
+
// Export only specific columns
|
|
13
|
+
const customColumns = options.allColumns.filter(col =>
|
|
14
|
+
['name', 'email', 'role'].includes(col.accessorKey || '')
|
|
15
|
+
);
|
|
16
|
+
await exportToCSVWithTableRows(
|
|
17
|
+
options.tableRows,
|
|
18
|
+
customColumns,
|
|
19
|
+
options.columnIdToTableColumn,
|
|
20
|
+
'custom-export.csv'
|
|
21
|
+
);
|
|
22
|
+
}}
|
|
23
|
+
/>
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Type parameters
|
|
27
|
+
|
|
28
|
+
| Name | Type |
|
|
29
|
+
| :------ | :------ |
|
|
30
|
+
| `TData` | extends [`DataRecord`](DataRecord.md) |
|
|
31
|
+
|
|
32
|
+
## Table of contents
|
|
33
|
+
|
|
34
|
+
### Properties
|
|
35
|
+
|
|
36
|
+
- [tableRows](ExportOptions.md#tablerows)
|
|
37
|
+
- [allColumns](ExportOptions.md#allcolumns)
|
|
38
|
+
- [visibleColumns](ExportOptions.md#visiblecolumns)
|
|
39
|
+
- [columnIdToTableColumn](ExportOptions.md#columnidtotablecolumn)
|
|
40
|
+
- [data](ExportOptions.md#data)
|
|
41
|
+
- [filename](ExportOptions.md#filename)
|
|
42
|
+
- [table](ExportOptions.md#table)
|
|
43
|
+
|
|
44
|
+
## Properties
|
|
45
|
+
|
|
46
|
+
### tableRows
|
|
47
|
+
|
|
48
|
+
• **tableRows**: \{ `original`: `TData` ; `getValue`: (`columnId`: `string`) => `any` ; `id`: `string` }[]
|
|
49
|
+
|
|
50
|
+
Filtered table rows with getValue() method for proper accessorFn evaluation
|
|
51
|
+
|
|
52
|
+
#### Defined in
|
|
53
|
+
|
|
54
|
+
[packages/core/src/components/DataTable/types.ts:634](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L634)
|
|
55
|
+
|
|
56
|
+
___
|
|
57
|
+
|
|
58
|
+
### allColumns
|
|
59
|
+
|
|
60
|
+
• **allColumns**: [`DataTableColumn`](DataTableColumn.md)\<`TData`\>[]
|
|
61
|
+
|
|
62
|
+
All column definitions passed to the DataTable
|
|
63
|
+
|
|
64
|
+
#### Defined in
|
|
65
|
+
|
|
66
|
+
[packages/core/src/components/DataTable/types.ts:640](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L640)
|
|
67
|
+
|
|
68
|
+
___
|
|
69
|
+
|
|
70
|
+
### visibleColumns
|
|
71
|
+
|
|
72
|
+
• **visibleColumns**: [`DataTableColumn`](DataTableColumn.md)\<`TData`\>[]
|
|
73
|
+
|
|
74
|
+
Currently visible columns in the table
|
|
75
|
+
|
|
76
|
+
#### Defined in
|
|
77
|
+
|
|
78
|
+
[packages/core/src/components/DataTable/types.ts:642](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L642)
|
|
79
|
+
|
|
80
|
+
___
|
|
81
|
+
|
|
82
|
+
### columnIdToTableColumn
|
|
83
|
+
|
|
84
|
+
• **columnIdToTableColumn**: `Map`\<`string`, `any`\>
|
|
85
|
+
|
|
86
|
+
Mapping of column IDs to TanStack table column instances (for getValue() calls)
|
|
87
|
+
|
|
88
|
+
#### Defined in
|
|
89
|
+
|
|
90
|
+
[packages/core/src/components/DataTable/types.ts:644](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L644)
|
|
91
|
+
|
|
92
|
+
___
|
|
93
|
+
|
|
94
|
+
### data
|
|
95
|
+
|
|
96
|
+
• **data**: `TData`[]
|
|
97
|
+
|
|
98
|
+
Raw data array (unfiltered)
|
|
99
|
+
|
|
100
|
+
#### Defined in
|
|
101
|
+
|
|
102
|
+
[packages/core/src/components/DataTable/types.ts:646](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L646)
|
|
103
|
+
|
|
104
|
+
___
|
|
105
|
+
|
|
106
|
+
### filename
|
|
107
|
+
|
|
108
|
+
• **filename**: `string`
|
|
109
|
+
|
|
110
|
+
Default filename generated from table title
|
|
111
|
+
|
|
112
|
+
#### Defined in
|
|
113
|
+
|
|
114
|
+
[packages/core/src/components/DataTable/types.ts:648](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L648)
|
|
115
|
+
|
|
116
|
+
___
|
|
117
|
+
|
|
118
|
+
### table
|
|
119
|
+
|
|
120
|
+
• **table**: `any`
|
|
121
|
+
|
|
122
|
+
TanStack table instance for advanced operations
|
|
123
|
+
|
|
124
|
+
#### Defined in
|
|
125
|
+
|
|
126
|
+
[packages/core/src/components/DataTable/types.ts:650](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L650)
|