@asteby/metacore-runtime-react 50.2.0 → 52.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/README.md +26 -0
- package/dist/activity-diff.d.ts +5 -0
- package/dist/activity-diff.d.ts.map +1 -1
- package/dist/activity-timeline.d.ts.map +1 -1
- package/dist/activity-timeline.js +10 -3
- package/dist/audit-info.d.ts.map +1 -1
- package/dist/audit-info.js +17 -3
- package/dist/barcode-scanner.js +4 -4
- package/dist/dialogs/dynamic-record.d.ts +3 -1
- package/dist/dialogs/dynamic-record.d.ts.map +1 -1
- package/dist/dialogs/dynamic-record.js +19 -6
- package/dist/dynamic-columns.d.ts +6 -0
- package/dist/dynamic-columns.d.ts.map +1 -1
- package/dist/dynamic-columns.js +41 -7
- package/dist/dynamic-date-field.js +1 -1
- package/dist/dynamic-form.js +2 -2
- package/dist/dynamic-kanban.js +6 -5
- package/dist/dynamic-table.d.ts.map +1 -1
- package/dist/dynamic-table.js +6 -4
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/org-runtime-context.d.ts +65 -0
- package/dist/org-runtime-context.d.ts.map +1 -1
- package/dist/org-runtime-context.js +24 -0
- package/dist/org-runtime-provider.d.ts +25 -1
- package/dist/org-runtime-provider.d.ts.map +1 -1
- package/dist/org-runtime-provider.js +3 -3
- package/dist/provenance.d.ts +216 -0
- package/dist/provenance.d.ts.map +1 -0
- package/dist/provenance.js +386 -0
- package/dist/record-history.d.ts.map +1 -1
- package/dist/record-history.js +6 -2
- package/dist/sidebar-layout-manager.js +2 -2
- package/dist/widgets/widget-card.d.ts +7 -2
- package/dist/widgets/widget-card.d.ts.map +1 -1
- package/dist/widgets/widget-card.js +6 -3
- package/package.json +3 -3
- package/src/__tests__/org-runtime-number-locale-system-actor.test.tsx +80 -0
- package/src/__tests__/provenance.test.tsx +209 -0
- package/src/activity-diff.tsx +5 -0
- package/src/activity-timeline.tsx +16 -2
- package/src/audit-info.tsx +20 -3
- package/src/barcode-scanner.tsx +4 -4
- package/src/dialogs/dynamic-record.tsx +26 -5
- package/src/dynamic-columns.tsx +68 -6
- package/src/dynamic-date-field.tsx +1 -1
- package/src/dynamic-form.tsx +2 -2
- package/src/dynamic-kanban.tsx +6 -5
- package/src/dynamic-table.tsx +6 -4
- package/src/index.ts +2 -0
- package/src/org-runtime-context.ts +92 -0
- package/src/org-runtime-provider.tsx +50 -3
- package/src/provenance.tsx +585 -0
- package/src/record-history.tsx +17 -4
- package/src/sidebar-layout-manager.tsx +2 -2
- package/src/widgets/widget-card.tsx +26 -3
|
@@ -114,12 +114,35 @@ export function WidgetEmpty({ message }: { message: string }) {
|
|
|
114
114
|
)
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
-
/**
|
|
118
|
-
|
|
117
|
+
/**
|
|
118
|
+
* Per-widget error state — isolated so a broken widget never tumbles the grid.
|
|
119
|
+
* Pass `onRetry` to offer a retry (e.g. the widget query's `refetch`).
|
|
120
|
+
*/
|
|
121
|
+
export function WidgetError({
|
|
122
|
+
message,
|
|
123
|
+
onRetry,
|
|
124
|
+
retryLabel = 'Reintentar',
|
|
125
|
+
}: {
|
|
126
|
+
message: string
|
|
127
|
+
onRetry?: () => void
|
|
128
|
+
retryLabel?: string
|
|
129
|
+
}) {
|
|
119
130
|
return (
|
|
120
|
-
<div
|
|
131
|
+
<div
|
|
132
|
+
role="alert"
|
|
133
|
+
className="flex flex-1 flex-wrap items-center justify-center gap-2 py-6 text-center text-xs text-destructive"
|
|
134
|
+
>
|
|
121
135
|
<DynamicIcon name="TriangleAlert" className="size-4" />
|
|
122
136
|
<span>{message}</span>
|
|
137
|
+
{onRetry && (
|
|
138
|
+
<button
|
|
139
|
+
type="button"
|
|
140
|
+
onClick={onRetry}
|
|
141
|
+
className="rounded-md border px-2 py-0.5 font-medium text-foreground hover:bg-muted focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
142
|
+
>
|
|
143
|
+
{retryLabel}
|
|
144
|
+
</button>
|
|
145
|
+
)}
|
|
123
146
|
</div>
|
|
124
147
|
)
|
|
125
148
|
}
|