Skip to content

Commit 2f15900

Browse files
committed
fix: downgrade vitest
Signed-off-by: Innei <i@innei.in>
1 parent 4eb47d4 commit 2f15900

File tree

3 files changed

+63
-72
lines changed

3 files changed

+63
-72
lines changed

apps/renderer/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@
119119
"fake-indexeddb": "6.0.0",
120120
"react": "^18.3.1",
121121
"react-dom": "^18.3.1",
122-
"typescript": "^5.6.2"
122+
"typescript": "^5.6.2",
123+
"vitest": "2.0"
123124
}
124125
}

apps/renderer/src/modules/profile/hooks.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,18 +49,20 @@ export const usePresentUserProfileModal = (variant: Variant = "dialog") => {
4949
return useCallback(
5050
(userId: string | undefined, overrideVariant?: Variant) => {
5151
if (!userId) return
52+
const finalVariant = overrideVariant || variant
5253
present({
5354
title: "User Profile",
5455
content: () =>
5556
createElement(UserProfileModalContent, {
5657
userId,
57-
variant: overrideVariant || variant,
58+
variant: finalVariant,
5859
}),
5960
CustomModalComponent: PlainModal,
6061
clickOutsideToDismiss: true,
61-
modal: variant === "dialog",
62-
overlay: variant === "dialog",
63-
modalContainerClassName: variant === "drawer" ? "right-4 left-[auto] top-4 bottom-4" : "",
62+
modal: finalVariant === "dialog",
63+
overlay: finalVariant === "dialog",
64+
modalContainerClassName:
65+
finalVariant === "drawer" ? "right-4 left-[auto] top-4 bottom-4" : "",
6466
})
6567
},
6668
[present, variant],

pnpm-lock.yaml

Lines changed: 55 additions & 67 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)