@jmruthers/pace-core 0.6.6 → 0.6.7
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/{scripts/audit/audit-dependencies.cjs → audit-tool/00-dependencies.cjs} +12 -13
- package/audit-tool/audits/01-pace-core-compliance.cjs +556 -0
- package/audit-tool/audits/02-project-structure.cjs +255 -0
- package/audit-tool/audits/03-architecture.cjs +196 -0
- package/audit-tool/audits/04-code-quality.cjs +149 -0
- package/audit-tool/audits/05-styling.cjs +224 -0
- package/audit-tool/audits/06-security-rbac.cjs +544 -0
- package/audit-tool/audits/07-api-tech-stack.cjs +301 -0
- package/audit-tool/audits/08-testing-documentation.cjs +202 -0
- package/audit-tool/audits/09-operations.cjs +208 -0
- package/audit-tool/index.cjs +291 -0
- package/audit-tool/utils/code-utils.cjs +218 -0
- package/audit-tool/utils/file-utils.cjs +230 -0
- package/audit-tool/utils/report-utils.cjs +241 -0
- package/cursor-rules/00-standards-overview.mdc +156 -0
- package/cursor-rules/{00-pace-core-compliance.mdc → 01-pace-core-compliance.mdc} +187 -34
- package/cursor-rules/02-project-structure.mdc +37 -5
- package/cursor-rules/{03-solid-principles.mdc → 03-architecture.mdc} +125 -11
- package/cursor-rules/04-code-quality.mdc +419 -0
- package/cursor-rules/{08-markup-quality.mdc → 05-styling.mdc} +55 -10
- package/cursor-rules/{09-rbac-compliance.mdc → 06-security-rbac.mdc} +62 -6
- package/cursor-rules/07-api-tech-stack.mdc +377 -0
- package/cursor-rules/08-testing-documentation.mdc +324 -0
- package/cursor-rules/09-operations.mdc +365 -0
- package/dist/DataTable-7PMH7XN7.js +15 -0
- package/dist/{DataTable-2N_tqbfq.d.ts → DataTable-DRUIgtUH.d.ts} +1 -1
- package/dist/{PublicPageProvider-BBH6Vqg7.d.ts → PublicPageProvider-DlsCaR5v.d.ts} +26 -16
- package/dist/{chunk-FENMYN2U.js → chunk-5X4QLXRG.js} +1 -3
- package/dist/{chunk-4T7OBVTU.js → chunk-6F3IILHI.js} +1 -1
- package/dist/{chunk-SD6WQY43.js → chunk-7ILTDCL2.js} +9 -1
- package/dist/{chunk-3QC3KRHK.js → chunk-A3W6LW53.js} +16 -1
- package/dist/{chunk-7TYHROIV.js → chunk-BM4CQ5P3.js} +50 -8
- package/dist/{chunk-2HGJFNAH.js → chunk-FEJLJNWA.js} +1 -15
- package/dist/{chunk-OHIK3MIO.js → chunk-GHYHJTYV.js} +2 -2
- package/dist/{chunk-UIYSCEV7.js → chunk-IUBRCBSY.js} +1 -1
- package/dist/{chunk-LAZMKTTF.js → chunk-JGWDVX64.js} +281 -347
- package/dist/{chunk-MAGBIDNS.js → chunk-L4XMVJKY.js} +2 -2
- package/dist/{chunk-A55DK444.js → chunk-OJ4SKRSV.js} +1 -7
- package/dist/{chunk-ZS5VO5JB.js → chunk-Q7Q7V5NV.js} +406 -451
- package/dist/{chunk-3O3WHILE.js → chunk-VBCS3DUA.js} +236 -60
- package/dist/{chunk-BVP2BCJF.js → chunk-ZKAWKYT4.js} +8 -8
- package/dist/components.d.ts +5 -4
- package/dist/components.js +27 -32
- package/dist/eslint-rules/index.cjs +22 -9
- package/{src/eslint-rules/rules/compliance.cjs → dist/eslint-rules/rules/01-pace-core-compliance.cjs} +184 -23
- package/dist/eslint-rules/rules/04-code-quality.cjs +290 -0
- package/dist/eslint-rules/rules/05-styling.cjs +61 -0
- package/dist/eslint-rules/rules/{rbac.cjs → 06-security-rbac.cjs} +26 -10
- package/dist/eslint-rules/rules/07-api-tech-stack.cjs +263 -0
- package/dist/eslint-rules/rules/08-testing.cjs +94 -0
- package/dist/hooks.d.ts +5 -5
- package/dist/hooks.js +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +18 -17
- package/dist/rbac/index.js +6 -6
- package/dist/theming/runtime.d.ts +14 -1
- package/dist/theming/runtime.js +1 -1
- package/dist/{types-B-K_5VnO.d.ts → types-DXstZpNI.d.ts} +0 -17
- package/dist/{usePublicRouteParams-COZ28Mvq.d.ts → usePublicRouteParams-MamNgwqe.d.ts} +19 -19
- package/dist/utils.d.ts +2 -2
- package/dist/utils.js +8 -8
- package/docs/README.md +1 -1
- package/docs/api/modules.md +47 -31
- package/docs/api-reference/components.md +18 -20
- package/docs/api-reference/hooks.md +80 -80
- package/docs/api-reference/types.md +1 -1
- package/docs/api-reference/utilities.md +1 -1
- package/docs/architecture/README.md +1 -1
- package/docs/core-concepts/events.md +3 -3
- package/docs/core-concepts/organisations.md +6 -6
- package/docs/core-concepts/permissions.md +6 -6
- package/docs/documentation-index.md +12 -18
- package/docs/getting-started/documentation-index.md +1 -1
- package/docs/getting-started/examples/README.md +4 -4
- package/docs/getting-started/examples/full-featured-app.md +1 -1
- package/docs/getting-started/faq.md +2 -2
- package/docs/getting-started/quick-reference.md +4 -4
- package/docs/implementation-guides/authentication.md +15 -15
- package/docs/implementation-guides/component-styling.md +1 -1
- package/docs/implementation-guides/data-tables.md +126 -33
- package/docs/implementation-guides/datatable-rbac-usage.md +1 -1
- package/docs/implementation-guides/dynamic-colors.md +3 -3
- package/docs/implementation-guides/file-upload-storage.md +2 -2
- package/docs/implementation-guides/hierarchical-datatable.md +40 -60
- package/docs/implementation-guides/inactivity-tracking.md +3 -3
- package/docs/implementation-guides/large-datasets.md +3 -2
- package/docs/implementation-guides/organisation-security.md +2 -2
- package/docs/implementation-guides/performance.md +2 -2
- package/docs/implementation-guides/permission-enforcement.md +1 -1
- package/docs/migration/V0.3.44_organisation-context-timing-fix.md +1 -1
- package/docs/migration/V0.4.0_rbac-migration.md +6 -6
- package/docs/rbac/README.md +5 -5
- package/docs/rbac/advanced-patterns.md +6 -6
- package/docs/rbac/api-reference.md +20 -20
- package/docs/rbac/event-based-apps.md +3 -3
- package/docs/rbac/examples.md +41 -41
- package/docs/rbac/getting-started.md +37 -37
- package/docs/rbac/performance.md +1 -1
- package/docs/rbac/quick-start.md +52 -52
- package/docs/rbac/secure-client-protection.md +1 -1
- package/docs/rbac/troubleshooting.md +1 -1
- package/docs/security/README.md +5 -5
- package/docs/standards/0-standards-overview.md +220 -0
- package/docs/standards/{00-pace-core-compliance.md → 1-pace-core-compliance-standards.md} +204 -185
- package/docs/standards/{02-project-structure.md → 2-project-structure-standards.md} +11 -47
- package/docs/standards/3-architecture-standards.md +606 -0
- package/docs/standards/4-code-quality-standards.md +728 -0
- package/docs/standards/{08-markup-quality.md → 5-styling-standards.md} +12 -9
- package/docs/standards/{09-rbac-compliance.md → 6-security-rbac-standards.md} +126 -18
- package/docs/standards/7-api-tech-stack-standards.md +662 -0
- package/docs/standards/8-testing-documentation-standards.md +401 -0
- package/docs/standards/9-operations-standards.md +1102 -0
- package/docs/standards/README.md +203 -104
- package/docs/troubleshooting/README.md +4 -4
- package/docs/troubleshooting/common-issues.md +2 -2
- package/docs/troubleshooting/debugging.md +9 -9
- package/docs/troubleshooting/migration.md +4 -4
- package/eslint-config-pace-core.cjs +21 -10
- package/package.json +6 -5
- package/scripts/install-cursor-rules.cjs +11 -243
- package/scripts/install-eslint-config.cjs +284 -0
- package/src/__tests__/helpers/__tests__/component-test-utils.test.tsx +2 -2
- package/src/__tests__/helpers/__tests__/test-providers.test.tsx +2 -2
- package/src/__tests__/helpers/__tests__/test-utils.test.tsx +10 -10
- package/src/__tests__/integration/UserProfile.test.tsx +14 -14
- package/src/__tests__/rbac/PagePermissionGuard.test.tsx +6 -6
- package/src/__tests__/templates/accessibility.test.template.tsx +9 -9
- package/src/__tests__/templates/component.test.template.tsx +18 -15
- package/src/components/Calendar/Calendar.tsx +201 -47
- package/src/components/ContextSelector/ContextSelector.tsx +137 -153
- package/src/components/DataTable/AUDIT_REPORT.md +293 -0
- package/src/components/DataTable/__tests__/DataTableCore.test.tsx +10 -2
- package/src/components/DataTable/__tests__/a11y.basic.test.tsx +10 -4
- package/src/components/DataTable/__tests__/test-utils/sharedTestUtils.tsx +9 -9
- package/src/components/DataTable/components/ColumnFilter.tsx +63 -74
- package/src/components/DataTable/components/ColumnVisibilityDropdown.tsx +43 -41
- package/src/components/DataTable/components/DataTableErrorBoundary.tsx +9 -11
- package/src/components/DataTable/components/DataTableLayout.tsx +5 -16
- package/src/components/DataTable/components/EditableRow.tsx +5 -7
- package/src/components/DataTable/components/EmptyState.tsx +10 -9
- package/src/components/DataTable/components/FilterRow.tsx +2 -4
- package/src/components/DataTable/components/ImportModal.tsx +124 -126
- package/src/components/DataTable/components/LoadingState.tsx +5 -6
- package/src/components/DataTable/components/SortIndicator.tsx +50 -0
- package/src/components/DataTable/components/__tests__/COVERAGE_NOTE.md +4 -4
- package/src/components/DataTable/components/__tests__/ColumnFilter.test.tsx +23 -82
- package/src/components/DataTable/components/__tests__/DataTableErrorBoundary.test.tsx +37 -9
- package/src/components/DataTable/components/__tests__/EmptyState.test.tsx +7 -4
- package/src/components/DataTable/components/__tests__/FilterRow.test.tsx +12 -4
- package/src/components/DataTable/components/__tests__/LoadingState.test.tsx +41 -27
- package/src/components/DataTable/components/index.ts +2 -1
- package/src/components/DataTable/types.ts +0 -18
- package/src/components/DataTable/utils/a11yUtils.ts +17 -0
- package/src/components/DatePickerWithTimezone/DatePickerWithTimezone.test.tsx +2 -1
- package/src/components/DatePickerWithTimezone/DatePickerWithTimezone.tsx +11 -15
- package/src/components/DateTimeField/DateTimeField.tsx +7 -8
- package/src/components/Dialog/Dialog.test.tsx +1 -0
- package/src/components/Dialog/Dialog.tsx +25 -8
- package/src/components/ErrorBoundary/ErrorBoundary.tsx +77 -79
- package/src/components/FileUpload/FileUpload.test.tsx +52 -14
- package/src/components/FileUpload/FileUpload.tsx +112 -130
- package/src/components/Progress/Progress.tsx +2 -4
- package/src/components/ProtectedRoute/ProtectedRoute.tsx +8 -8
- package/src/components/Select/Select.tsx +86 -77
- package/src/components/Select/types.ts +3 -0
- package/src/hooks/__tests__/ServiceHooks.test.tsx +16 -16
- package/src/hooks/__tests__/hooks.integration.test.tsx +49 -49
- package/src/hooks/__tests__/useFocusTrap.unit.test.tsx +97 -97
- package/src/hooks/public/usePublicEvent.ts +5 -5
- package/src/hooks/public/usePublicEventLogo.ts +5 -5
- package/src/hooks/public/usePublicFileDisplay.ts +2 -2
- package/src/hooks/public/usePublicRouteParams.ts +5 -5
- package/src/hooks/useAppConfig.ts +2 -2
- package/src/hooks/useEventTheme.test.ts +7 -7
- package/src/hooks/useEventTheme.ts +1 -4
- package/src/hooks/useFileDisplay.ts +2 -2
- package/src/providers/UnifiedAuthProvider.smoke.test.tsx +21 -21
- package/src/providers/__tests__/AuthProvider.test.tsx +21 -21
- package/src/providers/__tests__/EventProvider.test.tsx +61 -61
- package/src/providers/__tests__/InactivityProvider.test.tsx +56 -56
- package/src/providers/__tests__/OrganisationProvider.test.tsx +75 -75
- package/src/providers/__tests__/ProviderLifecycle.test.tsx +37 -37
- package/src/providers/__tests__/UnifiedAuthProvider.test.tsx +103 -103
- package/src/providers/services/__tests__/AuthServiceProvider.integration.test.tsx +7 -7
- package/src/providers/services/__tests__/UnifiedAuthProvider.integration.test.tsx +10 -10
- package/src/styles/core.css +7 -0
- package/src/theming/__tests__/parseEventColours.test.ts +9 -3
- package/src/theming/parseEventColours.ts +22 -10
- package/src/utils/__tests__/lazyLoad.unit.test.tsx +42 -39
- package/src/utils/storage/README.md +1 -1
- package/cursor-rules/01-standards-compliance.mdc +0 -285
- package/cursor-rules/04-testing-standards.mdc +0 -270
- package/cursor-rules/05-bug-reports-and-features.mdc +0 -248
- package/cursor-rules/06-code-quality.mdc +0 -311
- package/cursor-rules/07-tech-stack-compliance.mdc +0 -216
- package/cursor-rules/10-error-handling-patterns.mdc +0 -179
- package/cursor-rules/11-performance-optimization.mdc +0 -169
- package/cursor-rules/12-ci-cd-integration.mdc +0 -150
- package/dist/DataTable-LRJL4IRV.js +0 -15
- package/dist/eslint-rules/rules/compliance.cjs +0 -348
- package/dist/eslint-rules/rules/components.cjs +0 -113
- package/dist/eslint-rules/rules/imports.cjs +0 -102
- package/docs/best-practices/README.md +0 -472
- package/docs/best-practices/accessibility.md +0 -604
- package/docs/best-practices/common-patterns.md +0 -516
- package/docs/best-practices/deployment.md +0 -1103
- package/docs/best-practices/performance.md +0 -1328
- package/docs/best-practices/security.md +0 -940
- package/docs/best-practices/testing.md +0 -1034
- package/docs/rbac/compliance/compliance-guide.md +0 -544
- package/docs/standards/01-standards-compliance.md +0 -188
- package/docs/standards/03-solid-principles.md +0 -39
- package/docs/standards/04-testing-standards.md +0 -36
- package/docs/standards/05-bug-reports-and-features.md +0 -27
- package/docs/standards/06-code-quality.md +0 -34
- package/docs/standards/07-tech-stack-compliance.md +0 -30
- package/docs/standards/10-error-handling-patterns.md +0 -401
- package/docs/standards/11-performance-optimization.md +0 -348
- package/docs/standards/12-ci-cd-integration.md +0 -370
- package/docs/standards/ALIGNMENT_REVIEW_SUMMARY.md +0 -192
- package/scripts/audit/audit-compliance.cjs +0 -1295
- package/scripts/audit/audit-components.cjs +0 -260
- package/scripts/audit/audit-rbac.cjs +0 -954
- package/scripts/audit/audit-standards.cjs +0 -1268
- package/scripts/audit/index.cjs +0 -1927
- package/src/components/DataTable/components/DataTableBody.tsx +0 -478
- package/src/components/DataTable/components/DraggableColumnHeader.tsx +0 -156
- package/src/components/DataTable/components/ExpandButton.tsx +0 -113
- package/src/components/DataTable/components/GroupHeader.tsx +0 -54
- package/src/components/DataTable/components/ViewRowModal.tsx +0 -68
- package/src/components/DataTable/components/VirtualizedDataTable.tsx +0 -525
- package/src/components/DataTable/components/__tests__/ExpandButton.test.tsx +0 -462
- package/src/components/DataTable/components/__tests__/GroupHeader.test.tsx +0 -393
- package/src/components/DataTable/components/__tests__/ViewRowModal.test.tsx +0 -476
- package/src/components/DataTable/components/__tests__/VirtualizedDataTable.test.tsx +0 -128
- package/src/components/DataTable/core/DataTableContext.tsx +0 -216
- package/src/components/DataTable/core/__tests__/DataTableContext.test.tsx +0 -136
- package/src/components/DataTable/hooks/__tests__/useColumnReordering.test.ts +0 -570
- package/src/components/DataTable/hooks/useColumnReordering.ts +0 -123
- package/src/components/DataTable/utils/debugTools.ts +0 -514
- package/src/eslint-rules/index.cjs +0 -22
- package/src/eslint-rules/rules/components.cjs +0 -113
- package/src/eslint-rules/rules/imports.cjs +0 -102
- package/src/eslint-rules/rules/rbac.cjs +0 -790
- package/src/eslint-rules/utils/helpers.cjs +0 -42
- package/src/eslint-rules/utils/manifest-loader.cjs +0 -75
|
@@ -11,7 +11,8 @@
|
|
|
11
11
|
* Parse and normalize event_colours to PaletteData
|
|
12
12
|
*
|
|
13
13
|
* Supports input formats:
|
|
14
|
-
* - Object with 'main', 'sec', 'acc' keys
|
|
14
|
+
* - Object with 'main', 'sec', 'acc' keys (standard format)
|
|
15
|
+
* - Object with 'ev-main', 'ev-sec', 'ev-acc' keys (database format with prefix)
|
|
15
16
|
* - JSON string that will be parsed
|
|
16
17
|
*
|
|
17
18
|
* Only includes explicitly defined color values. Does not fill
|
|
@@ -33,6 +34,18 @@
|
|
|
33
34
|
* // Returns: { main: { 500: {...}, raw: {...} }, sec: { 500: {...} }, acc: { 500: {...} } }
|
|
34
35
|
* ```
|
|
35
36
|
*
|
|
37
|
+
* @example
|
|
38
|
+
* ```ts
|
|
39
|
+
* // Database format with ev- prefix
|
|
40
|
+
* const colours = {
|
|
41
|
+
* 'ev-main': { 500: { L: 0.5, C: 0.2, H: 0 } },
|
|
42
|
+
* 'ev-sec': { 500: { L: 0.5, C: 0.2, H: 120 } },
|
|
43
|
+
* 'ev-acc': { 500: { L: 0.5, C: 0.2, H: 240 } }
|
|
44
|
+
* };
|
|
45
|
+
* const palette = parseAndNormalizeEventColours(colours);
|
|
46
|
+
* // Returns: { main: { 500: {...} }, sec: { 500: {...} }, acc: { 500: {...} } }
|
|
47
|
+
* ```
|
|
48
|
+
*
|
|
36
49
|
*/
|
|
37
50
|
declare function parseAndNormalizeEventColours(input: unknown): {
|
|
38
51
|
main: any;
|
package/dist/theming/runtime.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { applyPalette, clearPalette, generateSSRThemeCSS, getCurrentThemeData, isDynamicThemingActive, parseAndNormalizeEventColours } from '../chunk-
|
|
1
|
+
export { applyPalette, clearPalette, generateSSRThemeCSS, getCurrentThemeData, isDynamicThemingActive, parseAndNormalizeEventColours } from '../chunk-ZKAWKYT4.js';
|
|
2
2
|
import '../chunk-TTRFSOKR.js';
|
|
3
3
|
import '../chunk-3RG5ZIWI.js';
|
|
@@ -207,8 +207,6 @@ interface HierarchicalConfig {
|
|
|
207
207
|
defaultExpanded?: boolean | string[];
|
|
208
208
|
/** Callback when expanded state changes */
|
|
209
209
|
onExpandedChange?: (expandedIds: string[]) => void;
|
|
210
|
-
/** Custom expand/collapse button component */
|
|
211
|
-
expandButton?: React__default.ComponentType<ExpandButtonProps>;
|
|
212
210
|
/** Visual indentation for child rows (in pixels) */
|
|
213
211
|
indentSize?: number;
|
|
214
212
|
/** Custom styling for parent rows */
|
|
@@ -216,21 +214,6 @@ interface HierarchicalConfig {
|
|
|
216
214
|
/** Custom styling for child rows */
|
|
217
215
|
childRowClassName?: string;
|
|
218
216
|
}
|
|
219
|
-
/**
|
|
220
|
-
* Props for the expand/collapse button component
|
|
221
|
-
*/
|
|
222
|
-
interface ExpandButtonProps {
|
|
223
|
-
/** Row ID */
|
|
224
|
-
rowId: string;
|
|
225
|
-
/** Whether the row is currently expanded */
|
|
226
|
-
isExpanded: boolean;
|
|
227
|
-
/** Whether this row has children */
|
|
228
|
-
hasChildren: boolean;
|
|
229
|
-
/** Click handler */
|
|
230
|
-
onClick: () => void;
|
|
231
|
-
/** Additional CSS classes */
|
|
232
|
-
className?: string;
|
|
233
|
-
}
|
|
234
217
|
/**
|
|
235
218
|
* Pagination mode determines how data is handled
|
|
236
219
|
*/
|
|
@@ -242,9 +242,9 @@ declare const useOrganisationSecurity: () => OrganisationSecurityHook;
|
|
|
242
242
|
* function MyComponent() {
|
|
243
243
|
* const { appName, isLoading } = useAppConfig();
|
|
244
244
|
*
|
|
245
|
-
* if (isLoading) return <
|
|
245
|
+
* if (isLoading) return <p>Loading...</p>;
|
|
246
246
|
*
|
|
247
|
-
* return <
|
|
247
|
+
* return <p>App: {appName}</p>;
|
|
248
248
|
* }
|
|
249
249
|
* ```
|
|
250
250
|
*/
|
|
@@ -464,16 +464,16 @@ interface StorageConfig {
|
|
|
464
464
|
* const { eventCode } = usePublicRouteParams();
|
|
465
465
|
* const { event, isLoading, error, refetch } = usePublicEvent(eventCode);
|
|
466
466
|
*
|
|
467
|
-
* if (isLoading) return <
|
|
468
|
-
* if (error) return <
|
|
469
|
-
* if (!event) return <
|
|
467
|
+
* if (isLoading) return <p>Loading event...</p>;
|
|
468
|
+
* if (error) return <p>Error: {error.message}</p>;
|
|
469
|
+
* if (!event) return <p>Event not found</p>;
|
|
470
470
|
*
|
|
471
471
|
* return (
|
|
472
|
-
* <
|
|
472
|
+
* <section>
|
|
473
473
|
* <h1>{event.event_name}</h1>
|
|
474
474
|
* <p>Date: {event.event_date}</p>
|
|
475
475
|
* <p>Venue: {event.event_venue}</p>
|
|
476
|
-
* </
|
|
476
|
+
* </section>
|
|
477
477
|
* );
|
|
478
478
|
* }
|
|
479
479
|
* ```
|
|
@@ -575,8 +575,8 @@ declare function getPublicEventCacheStats(): {
|
|
|
575
575
|
* { supabase }
|
|
576
576
|
* );
|
|
577
577
|
*
|
|
578
|
-
* if (isLoading) return <
|
|
579
|
-
* if (error) return <
|
|
578
|
+
* if (isLoading) return <p>Loading...</p>;
|
|
579
|
+
* if (error) return <p>Error: {error.message}</p>;
|
|
580
580
|
*
|
|
581
581
|
* return fileUrl ? <img src={fileUrl} alt="File" /> : null;
|
|
582
582
|
* }
|
|
@@ -668,17 +668,17 @@ declare function getPublicFileDisplayCacheStats(): {
|
|
|
668
668
|
* organisationId
|
|
669
669
|
* );
|
|
670
670
|
*
|
|
671
|
-
* if (isLoading) return <
|
|
672
|
-
* if (error) return <
|
|
671
|
+
* if (isLoading) return <p>Loading logo...</p>;
|
|
672
|
+
* if (error) return <p>Error: {error.message}</p>;
|
|
673
673
|
*
|
|
674
674
|
* return (
|
|
675
|
-
* <
|
|
675
|
+
* <section>
|
|
676
676
|
* {logoUrl ? (
|
|
677
677
|
* <img src={logoUrl} alt={`${eventName} logo`} />
|
|
678
678
|
* ) : (
|
|
679
|
-
* <
|
|
679
|
+
* <p className="logo-fallback">{fallbackText}</p>
|
|
680
680
|
* )}
|
|
681
|
-
* </
|
|
681
|
+
* </section>
|
|
682
682
|
* );
|
|
683
683
|
* }
|
|
684
684
|
* ```
|
|
@@ -783,15 +783,15 @@ declare function getPublicLogoCacheStats(): {
|
|
|
783
783
|
* function PublicEventPage() {
|
|
784
784
|
* const { eventCode, eventId, event, error, isLoading } = usePublicRouteParams();
|
|
785
785
|
*
|
|
786
|
-
* if (isLoading) return <
|
|
787
|
-
* if (error) return <
|
|
788
|
-
* if (!event) return <
|
|
786
|
+
* if (isLoading) return <p>Loading...</p>;
|
|
787
|
+
* if (error) return <p>Error: {error.message}</p>;
|
|
788
|
+
* if (!event) return <p>Event not found</p>;
|
|
789
789
|
*
|
|
790
790
|
* return (
|
|
791
|
-
* <
|
|
791
|
+
* <section>
|
|
792
792
|
* <h1>{event.event_name}</h1>
|
|
793
793
|
* <p>Event Code: {eventCode}</p>
|
|
794
|
-
* </
|
|
794
|
+
* </section>
|
|
795
795
|
* );
|
|
796
796
|
* }
|
|
797
797
|
* ```
|
package/dist/utils.d.ts
CHANGED
|
@@ -6,8 +6,8 @@ export { g as changePasswordSchema, t as combineSchemas, i as contactFormSchema,
|
|
|
6
6
|
import { z } from 'zod';
|
|
7
7
|
export { u as useComponentPerformance } from './useComponentPerformance-DE9l5RkL.js';
|
|
8
8
|
import * as date_fns from 'date-fns';
|
|
9
|
-
import { D as DataTable } from './DataTable-
|
|
10
|
-
import { A as AutocompleteOptions, m as GooglePlaceAutocompletePrediction, P as ParsedAddress } from './types-
|
|
9
|
+
import { D as DataTable } from './DataTable-DRUIgtUH.js';
|
|
10
|
+
import { A as AutocompleteOptions, m as GooglePlaceAutocompletePrediction, P as ParsedAddress } from './types-DXstZpNI.js';
|
|
11
11
|
import React__default, { ComponentType } from 'react';
|
|
12
12
|
import 'clsx';
|
|
13
13
|
import 'react/jsx-runtime';
|
package/dist/utils.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { sanitizeUserInput, emailSchema, nameSchema, sanitizeFormData } from './chunk-
|
|
2
|
-
export { calculatePasswordStrength, createBaseClient, dateSchema, emailSchema, formatCompactNumber, formatCurrency, formatDate, formatDateOnlyForDisplay, formatDateTime, formatDateTimeForDisplay, formatDateTimeForMap, formatDateTimeForTable, formatFileSize, formatNumber, formatPercent, formatTime, getAppConfig, getCurrentAppId, nameSchema, passwordSchema, phoneSchema, sanitizeFormData, sanitizeUserInput, setAppConfig, urlSchema, useSessionTracking } from './chunk-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export { renderSafeHtml, sanitizeHtml, validateHtml } from './chunk-
|
|
6
|
-
export {
|
|
1
|
+
import { sanitizeUserInput, emailSchema, nameSchema, sanitizeFormData } from './chunk-IUBRCBSY.js';
|
|
2
|
+
export { calculatePasswordStrength, createBaseClient, dateSchema, emailSchema, formatCompactNumber, formatCurrency, formatDate, formatDateOnlyForDisplay, formatDateTime, formatDateTimeForDisplay, formatDateTimeForMap, formatDateTimeForTable, formatFileSize, formatNumber, formatPercent, formatTime, getAppConfig, getCurrentAppId, nameSchema, passwordSchema, phoneSchema, sanitizeFormData, sanitizeUserInput, setAppConfig, urlSchema, useSessionTracking } from './chunk-IUBRCBSY.js';
|
|
3
|
+
export { CachedAppIdResolver, cachedAppIdResolver, formatInTimeZone, formatTimeInTimeZone, fromZonedTime, getAppId, getAppIds, getTimeZoneDifference, getTimezoneAbbreviation, getUserTimeZone, roundToNearestMinutes, toZonedTime } from './chunk-FEJLJNWA.js';
|
|
4
|
+
import { LoadingSpinner } from './chunk-A3W6LW53.js';
|
|
5
|
+
export { renderSafeHtml, sanitizeHtml, validateHtml } from './chunk-A3W6LW53.js';
|
|
6
|
+
export { getAppNameFromBuildTime, getAppNameFromEnvironment, getAppNameFromGlobal, getAppNameFromPackageJson, getCurrentAppName, getCurrentAppNameWithFallback, setRBACAppName } from './chunk-OJ4SKRSV.js';
|
|
7
7
|
export { useComponentPerformance } from './chunk-6GLLNA6U.js';
|
|
8
8
|
export { clearInFlightRequests, clearOrganisationContext, createAddressFromPlaceResult, deduplicatedQuery, fetchPlaceAutocomplete, fetchPlaceDetails, generateRequestKey, getAddressByPlaceId, getInFlightRequestStats, getOrCreateRequest, getOrganisationContext, isOrganisationContextAvailable, parseAddressComponents, setOrganisationContext } from './chunk-FYHN4DD5.js';
|
|
9
|
-
export { PERFORMANCE_BUDGETS, performanceBudgetMonitor } from './chunk-
|
|
9
|
+
export { PERFORMANCE_BUDGETS, cn, performanceBudgetMonitor } from './chunk-7ILTDCL2.js';
|
|
10
10
|
import { secureStorage } from './chunk-HF6O3O37.js';
|
|
11
11
|
import { createLogger } from './chunk-TTRFSOKR.js';
|
|
12
12
|
export { LogLevel, Logger, createLogger, logger } from './chunk-TTRFSOKR.js';
|
|
@@ -759,7 +759,7 @@ function createLazyComponent(importFn, componentName, options = {}) {
|
|
|
759
759
|
return WrappedComponent;
|
|
760
760
|
}
|
|
761
761
|
var LazyDataTable = createLazyComponent(
|
|
762
|
-
() => import('./DataTable-
|
|
762
|
+
() => import('./DataTable-7PMH7XN7.js').then((module) => ({ default: module.DataTable })),
|
|
763
763
|
"DataTable"
|
|
764
764
|
);
|
|
765
765
|
|
package/docs/README.md
CHANGED
|
@@ -148,7 +148,7 @@ The table props and supporting types live beside the implementation in [`src/com
|
|
|
148
148
|
2. **Wire authentication** – configure Supabase keys, inactivity handling, and RBAC using the [Authentication concept](./core-concepts/authentication.md) and [RBAC quick start](./rbac/quick-start.md).
|
|
149
149
|
3. **Adopt layout and navigation** – reference the [App layout guide](./implementation-guides/app-layout.md) and [Navigation patterns](./implementation-guides/navigation.md).
|
|
150
150
|
4. **Integrate domain features** – use [Organisation security](./implementation-guides/organisation-security.md), [Inactivity tracking](./implementation-guides/inactivity-tracking.md), and [Data tables](./implementation-guides/data-tables.md) as needed.
|
|
151
|
-
5. **Validate & ship** – confirm best practices with [Testing](./testing/README.md), [
|
|
151
|
+
5. **Validate & ship** – confirm best practices with [Testing](./testing/README.md), [Operations Standards](./standards/9-operations-standards.md#cicd-integration) (deployment), and [Security Standards](./standards/6-security-rbac-standards.md).
|
|
152
152
|
|
|
153
153
|
---
|
|
154
154
|
|
package/docs/api/modules.md
CHANGED
|
@@ -770,7 +770,7 @@ Extends DayPickerProps with pace-core specific customizations.
|
|
|
770
770
|
|
|
771
771
|
#### Defined in
|
|
772
772
|
|
|
773
|
-
[packages/core/src/components/Calendar/Calendar.tsx:
|
|
773
|
+
[packages/core/src/components/Calendar/Calendar.tsx:101](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Calendar/Calendar.tsx#L101)
|
|
774
774
|
|
|
775
775
|
___
|
|
776
776
|
|
|
@@ -845,7 +845,7 @@ Enhanced column definition that extends TanStack's ColumnDef
|
|
|
845
845
|
|
|
846
846
|
#### Defined in
|
|
847
847
|
|
|
848
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
848
|
+
[packages/core/src/components/DataTable/types.ts:245](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L245)
|
|
849
849
|
|
|
850
850
|
___
|
|
851
851
|
|
|
@@ -864,7 +864,7 @@ Defines custom actions that can be performed on table rows.
|
|
|
864
864
|
|
|
865
865
|
#### Defined in
|
|
866
866
|
|
|
867
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
867
|
+
[packages/core/src/components/DataTable/types.ts:379](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L379)
|
|
868
868
|
|
|
869
869
|
___
|
|
870
870
|
|
|
@@ -876,7 +876,7 @@ Toolbar button definition
|
|
|
876
876
|
|
|
877
877
|
#### Defined in
|
|
878
878
|
|
|
879
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
879
|
+
[packages/core/src/components/DataTable/types.ts:419](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L419)
|
|
880
880
|
|
|
881
881
|
___
|
|
882
882
|
|
|
@@ -888,7 +888,7 @@ Aggregate configuration
|
|
|
888
888
|
|
|
889
889
|
#### Defined in
|
|
890
890
|
|
|
891
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
891
|
+
[packages/core/src/components/DataTable/types.ts:441](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L441)
|
|
892
892
|
|
|
893
893
|
___
|
|
894
894
|
|
|
@@ -900,7 +900,7 @@ Empty state configuration
|
|
|
900
900
|
|
|
901
901
|
#### Defined in
|
|
902
902
|
|
|
903
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
903
|
+
[packages/core/src/components/DataTable/types.ts:450](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L450)
|
|
904
904
|
|
|
905
905
|
___
|
|
906
906
|
|
|
@@ -937,7 +937,7 @@ Options provided to the onExport handler for custom export functionality
|
|
|
937
937
|
|
|
938
938
|
#### Defined in
|
|
939
939
|
|
|
940
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
940
|
+
[packages/core/src/components/DataTable/types.ts:628](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L628)
|
|
941
941
|
|
|
942
942
|
___
|
|
943
943
|
|
|
@@ -1012,6 +1012,8 @@ Props for the DialogClose component
|
|
|
1012
1012
|
|
|
1013
1013
|
[packages/core/src/components/Dialog/Dialog.tsx:239](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L239)
|
|
1014
1014
|
|
|
1015
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1365](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1365)
|
|
1016
|
+
|
|
1015
1017
|
___
|
|
1016
1018
|
|
|
1017
1019
|
### DialogHeaderProps
|
|
@@ -1058,7 +1060,7 @@ State interface for the ErrorBoundary component
|
|
|
1058
1060
|
|
|
1059
1061
|
#### Defined in
|
|
1060
1062
|
|
|
1061
|
-
[packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx:
|
|
1063
|
+
[packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx:127](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx#L127)
|
|
1062
1064
|
|
|
1063
1065
|
___
|
|
1064
1066
|
|
|
@@ -1070,7 +1072,7 @@ Props interface for the ErrorBoundary component
|
|
|
1070
1072
|
|
|
1071
1073
|
#### Defined in
|
|
1072
1074
|
|
|
1073
|
-
[packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx:
|
|
1075
|
+
[packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx:144](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/ErrorBoundary/ErrorBoundary.tsx#L144)
|
|
1074
1076
|
|
|
1075
1077
|
___
|
|
1076
1078
|
|
|
@@ -1105,7 +1107,7 @@ Configures file upload behavior including storage location, validation, and call
|
|
|
1105
1107
|
|
|
1106
1108
|
#### Defined in
|
|
1107
1109
|
|
|
1108
|
-
[packages/core/src/components/FileUpload/FileUpload.tsx:
|
|
1110
|
+
[packages/core/src/components/FileUpload/FileUpload.tsx:26](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/FileUpload/FileUpload.tsx#L26)
|
|
1109
1111
|
|
|
1110
1112
|
___
|
|
1111
1113
|
|
|
@@ -2356,7 +2358,7 @@ ergonomic while maintaining strict internal guarantees.
|
|
|
2356
2358
|
|
|
2357
2359
|
#### Defined in
|
|
2358
2360
|
|
|
2359
|
-
[packages/core/src/components/DataTable/types.ts:
|
|
2361
|
+
[packages/core/src/components/DataTable/types.ts:518](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/DataTable/types.ts#L518)
|
|
2360
2362
|
|
|
2361
2363
|
___
|
|
2362
2364
|
|
|
@@ -3283,7 +3285,7 @@ JSX.Element - The rendered calendar element
|
|
|
3283
3285
|
|
|
3284
3286
|
#### Defined in
|
|
3285
3287
|
|
|
3286
|
-
[packages/core/src/components/Calendar/Calendar.tsx:
|
|
3288
|
+
[packages/core/src/components/Calendar/Calendar.tsx:197](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Calendar/Calendar.tsx#L197)
|
|
3287
3289
|
|
|
3288
3290
|
___
|
|
3289
3291
|
|
|
@@ -4008,7 +4010,7 @@ ReactNode
|
|
|
4008
4010
|
|
|
4009
4011
|
#### Defined in
|
|
4010
4012
|
|
|
4011
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4013
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1374](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1374)
|
|
4012
4014
|
|
|
4013
4015
|
___
|
|
4014
4016
|
|
|
@@ -4028,7 +4030,7 @@ Element
|
|
|
4028
4030
|
|
|
4029
4031
|
#### Defined in
|
|
4030
4032
|
|
|
4031
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4033
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1426](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1426)
|
|
4032
4034
|
|
|
4033
4035
|
___
|
|
4034
4036
|
|
|
@@ -4048,7 +4050,7 @@ Element
|
|
|
4048
4050
|
|
|
4049
4051
|
#### Defined in
|
|
4050
4052
|
|
|
4051
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4053
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1446](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1446)
|
|
4052
4054
|
|
|
4053
4055
|
___
|
|
4054
4056
|
|
|
@@ -4068,7 +4070,7 @@ Element
|
|
|
4068
4070
|
|
|
4069
4071
|
#### Defined in
|
|
4070
4072
|
|
|
4071
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4073
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1548](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1548)
|
|
4072
4074
|
|
|
4073
4075
|
___
|
|
4074
4076
|
|
|
@@ -4088,7 +4090,7 @@ ReactNode
|
|
|
4088
4090
|
|
|
4089
4091
|
#### Defined in
|
|
4090
4092
|
|
|
4091
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4093
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1568](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1568)
|
|
4092
4094
|
|
|
4093
4095
|
___
|
|
4094
4096
|
|
|
@@ -4108,7 +4110,7 @@ ReactNode
|
|
|
4108
4110
|
|
|
4109
4111
|
#### Defined in
|
|
4110
4112
|
|
|
4111
|
-
[packages/core/src/components/Dialog/Dialog.tsx:
|
|
4113
|
+
[packages/core/src/components/Dialog/Dialog.tsx:1607](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Dialog/Dialog.tsx#L1607)
|
|
4112
4114
|
|
|
4113
4115
|
___
|
|
4114
4116
|
|
|
@@ -4198,7 +4200,7 @@ Element
|
|
|
4198
4200
|
|
|
4199
4201
|
#### Defined in
|
|
4200
4202
|
|
|
4201
|
-
[packages/core/src/components/FileUpload/FileUpload.tsx:
|
|
4203
|
+
[packages/core/src/components/FileUpload/FileUpload.tsx:58](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/FileUpload/FileUpload.tsx#L58)
|
|
4202
4204
|
|
|
4203
4205
|
___
|
|
4204
4206
|
|
|
@@ -4981,7 +4983,7 @@ The rendered select trigger
|
|
|
4981
4983
|
|
|
4982
4984
|
#### Defined in
|
|
4983
4985
|
|
|
4984
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
4986
|
+
[packages/core/src/components/Select/Select.tsx:233](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L233)
|
|
4985
4987
|
|
|
4986
4988
|
___
|
|
4987
4989
|
|
|
@@ -5003,7 +5005,7 @@ The rendered select value display
|
|
|
5003
5005
|
|
|
5004
5006
|
#### Defined in
|
|
5005
5007
|
|
|
5006
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
5008
|
+
[packages/core/src/components/Select/Select.tsx:409](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L409)
|
|
5007
5009
|
|
|
5008
5010
|
___
|
|
5009
5011
|
|
|
@@ -5025,7 +5027,7 @@ The rendered select content
|
|
|
5025
5027
|
|
|
5026
5028
|
#### Defined in
|
|
5027
5029
|
|
|
5028
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
5030
|
+
[packages/core/src/components/Select/Select.tsx:439](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L439)
|
|
5029
5031
|
|
|
5030
5032
|
___
|
|
5031
5033
|
|
|
@@ -5059,7 +5061,7 @@ ___
|
|
|
5059
5061
|
|
|
5060
5062
|
| Name | Type | Description |
|
|
5061
5063
|
| :------ | :------ | :------ |
|
|
5062
|
-
| `props` | Object & RefAttributes\<
|
|
5064
|
+
| `props` | Object & RefAttributes\<HTMLUListElement\> | Select group configuration |
|
|
5063
5065
|
|
|
5064
5066
|
#### Returns
|
|
5065
5067
|
|
|
@@ -5069,7 +5071,7 @@ The rendered select group
|
|
|
5069
5071
|
|
|
5070
5072
|
#### Defined in
|
|
5071
5073
|
|
|
5072
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
5074
|
+
[packages/core/src/components/Select/Select.tsx:663](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L663)
|
|
5073
5075
|
|
|
5074
5076
|
___
|
|
5075
5077
|
|
|
@@ -5081,7 +5083,7 @@ ___
|
|
|
5081
5083
|
|
|
5082
5084
|
| Name | Type | Description |
|
|
5083
5085
|
| :------ | :------ | :------ |
|
|
5084
|
-
| `props` | Object & RefAttributes\<
|
|
5086
|
+
| `props` | Object & RefAttributes\<HTMLLIElement\> | Select label configuration |
|
|
5085
5087
|
|
|
5086
5088
|
#### Returns
|
|
5087
5089
|
|
|
@@ -5091,7 +5093,7 @@ The rendered select label
|
|
|
5091
5093
|
|
|
5092
5094
|
#### Defined in
|
|
5093
5095
|
|
|
5094
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
5096
|
+
[packages/core/src/components/Select/Select.tsx:688](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L688)
|
|
5095
5097
|
|
|
5096
5098
|
___
|
|
5097
5099
|
|
|
@@ -5103,7 +5105,7 @@ ___
|
|
|
5103
5105
|
|
|
5104
5106
|
| Name | Type | Description |
|
|
5105
5107
|
| :------ | :------ | :------ |
|
|
5106
|
-
| `props` | Object & RefAttributes\<
|
|
5108
|
+
| `props` | Object & RefAttributes\<HTMLHRElement\> | Select separator configuration |
|
|
5107
5109
|
|
|
5108
5110
|
#### Returns
|
|
5109
5111
|
|
|
@@ -5113,7 +5115,7 @@ The rendered select separator
|
|
|
5113
5115
|
|
|
5114
5116
|
#### Defined in
|
|
5115
5117
|
|
|
5116
|
-
[packages/core/src/components/Select/Select.tsx:
|
|
5118
|
+
[packages/core/src/components/Select/Select.tsx:707](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/components/Select/Select.tsx#L707)
|
|
5117
5119
|
|
|
5118
5120
|
___
|
|
5119
5121
|
|
|
@@ -6153,7 +6155,7 @@ void
|
|
|
6153
6155
|
|
|
6154
6156
|
#### Defined in
|
|
6155
6157
|
|
|
6156
|
-
[packages/core/src/hooks/useEventTheme.ts:
|
|
6158
|
+
[packages/core/src/hooks/useEventTheme.ts:98](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/hooks/useEventTheme.ts#L98)
|
|
6157
6159
|
|
|
6158
6160
|
___
|
|
6159
6161
|
|
|
@@ -8607,7 +8609,8 @@ ___
|
|
|
8607
8609
|
Parse and normalize event_colours to PaletteData
|
|
8608
8610
|
|
|
8609
8611
|
Supports input formats:
|
|
8610
|
-
- Object with 'main', 'sec', 'acc' keys
|
|
8612
|
+
- Object with 'main', 'sec', 'acc' keys (standard format)
|
|
8613
|
+
- Object with 'ev-main', 'ev-sec', 'ev-acc' keys (database format with prefix)
|
|
8611
8614
|
- JSON string that will be parsed
|
|
8612
8615
|
|
|
8613
8616
|
Only includes explicitly defined color values. Does not fill
|
|
@@ -8639,9 +8642,22 @@ const palette = parseAndNormalizeEventColours(colours);
|
|
|
8639
8642
|
// Returns: { main: { 500: {...}, raw: {...} }, sec: { 500: {...} }, acc: { 500: {...} } }
|
|
8640
8643
|
```
|
|
8641
8644
|
|
|
8645
|
+
**`Example`**
|
|
8646
|
+
|
|
8647
|
+
```ts
|
|
8648
|
+
// Database format with ev- prefix
|
|
8649
|
+
const colours = {
|
|
8650
|
+
'ev-main': { 500: { L: 0.5, C: 0.2, H: 0 } },
|
|
8651
|
+
'ev-sec': { 500: { L: 0.5, C: 0.2, H: 120 } },
|
|
8652
|
+
'ev-acc': { 500: { L: 0.5, C: 0.2, H: 240 } }
|
|
8653
|
+
};
|
|
8654
|
+
const palette = parseAndNormalizeEventColours(colours);
|
|
8655
|
+
// Returns: { main: { 500: {...} }, sec: { 500: {...} }, acc: { 500: {...} } }
|
|
8656
|
+
```
|
|
8657
|
+
|
|
8642
8658
|
#### Defined in
|
|
8643
8659
|
|
|
8644
|
-
[packages/core/src/theming/parseEventColours.ts:
|
|
8660
|
+
[packages/core/src/theming/parseEventColours.ts:52](https://github.com/jmruthers/pace-core/blob/main/packages/core/src/theming/parseEventColours.ts#L52)
|
|
8645
8661
|
|
|
8646
8662
|
___
|
|
8647
8663
|
|
|
@@ -284,8 +284,6 @@ interface HierarchicalConfig {
|
|
|
284
284
|
defaultExpanded?: boolean | string[];
|
|
285
285
|
/** Callback when expansion state changes */
|
|
286
286
|
onExpandedChange?: (expandedIds: string[]) => void;
|
|
287
|
-
/** Custom expand/collapse button component */
|
|
288
|
-
expandButton?: React.ComponentType<ExpandButtonProps>;
|
|
289
287
|
/** Indentation for child rows in pixels */
|
|
290
288
|
indentSize?: number;
|
|
291
289
|
/** CSS classes for parent rows */
|
|
@@ -1162,10 +1160,10 @@ function MyComponent() {
|
|
|
1162
1160
|
};
|
|
1163
1161
|
|
|
1164
1162
|
return (
|
|
1165
|
-
<
|
|
1163
|
+
<section>
|
|
1166
1164
|
<Button onClick={handleSuccess}>Save Changes</Button>
|
|
1167
1165
|
<Button onClick={handleError}>Trigger Error</Button>
|
|
1168
|
-
</
|
|
1166
|
+
</section>
|
|
1169
1167
|
);
|
|
1170
1168
|
}
|
|
1171
1169
|
|
|
@@ -1240,10 +1238,10 @@ import {
|
|
|
1240
1238
|
<Button>Advanced Tooltip</Button>
|
|
1241
1239
|
</TooltipTrigger>
|
|
1242
1240
|
<TooltipContent side="top" className="bg-main-500 text-main-50">
|
|
1243
|
-
<
|
|
1241
|
+
<section className="space-y-1">
|
|
1244
1242
|
<p className="font-semibold">Advanced Tooltip</p>
|
|
1245
1243
|
<p className="text-xs">With custom styling</p>
|
|
1246
|
-
</
|
|
1244
|
+
</section>
|
|
1247
1245
|
</TooltipContent>
|
|
1248
1246
|
</TooltipRoot>
|
|
1249
1247
|
</TooltipProvider>
|
|
@@ -1289,7 +1287,7 @@ A complete application layout with header, navigation, and content area.
|
|
|
1289
1287
|
import { PaceAppLayout } from '@jmruthers/pace-core';
|
|
1290
1288
|
|
|
1291
1289
|
<PaceAppLayout>
|
|
1292
|
-
<
|
|
1290
|
+
<main>Your app content</main>
|
|
1293
1291
|
</PaceAppLayout>
|
|
1294
1292
|
```
|
|
1295
1293
|
|
|
@@ -1575,10 +1573,10 @@ function App() {
|
|
|
1575
1573
|
loginPath="/login"
|
|
1576
1574
|
loadingFallback={<CustomLoader />}
|
|
1577
1575
|
noEventsFallback={
|
|
1578
|
-
<
|
|
1576
|
+
<section>
|
|
1579
1577
|
<h2>No Events Available</h2>
|
|
1580
1578
|
<p>Contact your administrator for access.</p>
|
|
1581
|
-
</
|
|
1579
|
+
</section>
|
|
1582
1580
|
}
|
|
1583
1581
|
/>
|
|
1584
1582
|
}>
|
|
@@ -1789,7 +1787,7 @@ function PublicEventPage() {
|
|
|
1789
1787
|
}
|
|
1790
1788
|
|
|
1791
1789
|
if (error || !event) {
|
|
1792
|
-
return <
|
|
1790
|
+
return <p>Event not found</p>;
|
|
1793
1791
|
}
|
|
1794
1792
|
|
|
1795
1793
|
return (
|
|
@@ -1885,9 +1883,9 @@ function MyFileUpload() {
|
|
|
1885
1883
|
console.log('URL:', result.file_url);
|
|
1886
1884
|
}}
|
|
1887
1885
|
>
|
|
1888
|
-
<
|
|
1886
|
+
<section className="border-2 border-dashed border-main-300 rounded-lg p-8 text-center">
|
|
1889
1887
|
<p>Drag and drop files here or click to browse</p>
|
|
1890
|
-
</
|
|
1888
|
+
</section>
|
|
1891
1889
|
</FileUpload>
|
|
1892
1890
|
);
|
|
1893
1891
|
}
|
|
@@ -1927,7 +1925,7 @@ function MyApp() {
|
|
|
1927
1925
|
});
|
|
1928
1926
|
|
|
1929
1927
|
return (
|
|
1930
|
-
<
|
|
1928
|
+
<main>
|
|
1931
1929
|
<h1>My App</h1>
|
|
1932
1930
|
|
|
1933
1931
|
<InactivityWarningModal
|
|
@@ -1938,7 +1936,7 @@ function MyApp() {
|
|
|
1938
1936
|
title="Session Timeout Warning"
|
|
1939
1937
|
message="You will be signed out due to inactivity."
|
|
1940
1938
|
/>
|
|
1941
|
-
</
|
|
1939
|
+
</main>
|
|
1942
1940
|
);
|
|
1943
1941
|
}
|
|
1944
1942
|
```
|
|
@@ -1969,14 +1967,14 @@ import { EventLogo } from '@jmruthers/pace-core';
|
|
|
1969
1967
|
|
|
1970
1968
|
function EventHeader({ eventId }: { eventId: string }) {
|
|
1971
1969
|
return (
|
|
1972
|
-
<
|
|
1970
|
+
<section className="text-center">
|
|
1973
1971
|
<EventLogo
|
|
1974
1972
|
eventId={eventId}
|
|
1975
1973
|
size="large"
|
|
1976
1974
|
className="mx-auto mb-4"
|
|
1977
1975
|
/>
|
|
1978
1976
|
<h1>Event Name</h1>
|
|
1979
|
-
</
|
|
1977
|
+
</section>
|
|
1980
1978
|
);
|
|
1981
1979
|
}
|
|
1982
1980
|
```
|
|
@@ -2240,10 +2238,10 @@ import {
|
|
|
2240
2238
|
- **[Component Styling](../styles/component-styling.md)** - How components are styled
|
|
2241
2239
|
- **[Custom Themes](../styles/custom-themes.md)** - Creating custom themes
|
|
2242
2240
|
|
|
2243
|
-
### Best Practices
|
|
2244
|
-
- **[
|
|
2245
|
-
- **[Performance
|
|
2246
|
-
- **[Accessibility
|
|
2241
|
+
### Standards & Best Practices
|
|
2242
|
+
- **[Architecture Standards](../standards/3-architecture-standards.md)** - Component design principles
|
|
2243
|
+
- **[Performance Optimization](../standards/9-operations-standards.md#performance-optimization)** - Performance optimization
|
|
2244
|
+
- **[Accessibility Requirements](../standards/4-code-quality-standards.md#accessibility-requirements)** - Accessibility requirements
|
|
2247
2245
|
|
|
2248
2246
|
### Troubleshooting
|
|
2249
2247
|
- **[Common Issues](../troubleshooting/common-issues.md)** - Component-related problems
|