post cherry-pick: restore useEffectEvent wrapper + fix configuration import

Two typecheck regressions surfaced after pulling duckietm PR #126 onto
this branch:

- NotificationBadgeReceivedBubbleView lost its `useEffectEvent` wrapper
  during conflict resolution. The PR rewrote the effect to use a plain
  `useEffect(..., [activeBadgeCodes.length])`; reintroduce the
  `requestBadgesIfEmpty = useEffectEvent(...)` shape that the rest of
  this branch uses, applied to the renamed activeBadgeCodes selector.
- `src/bootstrap.ts` was importing `GetConfiguration` from the package
  alias `@nitrots/configuration`, which Vite resolves via filesystem
  alias but tsgo does not. Swap to the monolithic
  `@nitrots/nitro-renderer` re-export, matching how App.tsx already
  imports the same symbol.

Both fixes get `yarn typecheck` green again and all 113 Vitest cases
still pass.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
simoleo89
2026-05-13 21:16:52 +02:00
parent 3a7c9ba940
commit 9ef6983632
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
import { GetConfiguration } from '@nitrots/configuration';
import { GetConfiguration } from '@nitrots/nitro-renderer';
import { configFileUrl, getClientMode, installSecureFetch } from './secure-assets';
const ensureMobileViewport = () =>
@@ -14,6 +14,8 @@ export const NotificationBadgeReceivedBubbleView: FC<NotificationBadgeReceivedBu
const { item = null, onClose = null, ...rest } = props;
const { activeBadgeCodes = [], toggleBadge = null, isWearingBadge = null, canWearBadges = null } = useInventoryBadges();
const requestBadgesIfEmpty = useEffectEvent(() =>
{
if(activeBadgeCodes.length === 0) SendMessageComposer(new RequestBadgesComposer());
});