@xelqun/forms 0.5.0 → 0.6.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xelqun/forms",
3
- "version": "0.5.0",
3
+ "version": "0.6.0",
4
4
  "description": "Vue renderer for Xelqun Forms: PHP-defined, schema-driven forms for Laravel + Inertia.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -107,9 +107,10 @@ function mountNotifications(label?: string): () => void {
107
107
  const host = document.body.appendChild(document.createElement('div'));
108
108
  const toaster = createApp(XqNotifications, { label });
109
109
  const stopListening = router.on('flash', (event) => {
110
- const { [FLASH_KEY]: notifications } = event.detail.flash;
110
+ // An app can type its flash data, and this key is ours, not part of that type.
111
+ const flash = event.detail.flash as Record<string, unknown>;
111
112
 
112
- (notifications as XqNotification[] | undefined)?.forEach(notify);
113
+ (flash[FLASH_KEY] as XqNotification[] | undefined)?.forEach(notify);
113
114
  });
114
115
 
115
116
  toaster.mount(host);