Skip to content

Commit 999fee5

Browse files
authored
Merge pull request #64 from ProjectLighthouseCAU/migrate-to-heroui
Migrate to HeroUI
2 parents 49ff6f6 + 44f8078 commit 999fee5

33 files changed

+16661
-12457
lines changed

package-lock.json

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

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
"version": "0.1.0",
44
"private": true,
55
"dependencies": {
6-
"@nextui-org/react": "^2.4.8",
7-
"@nextui-org/use-infinite-scroll": "^2.1.5",
6+
"@heroui/react": "latest",
7+
"@heroui/use-infinite-scroll": "latest",
88
"@tabler/icons-react": "^3.11.0",
99
"@testing-library/jest-dom": "^6.4.6",
1010
"@testing-library/react": "^16.0.0",
1111
"@testing-library/user-event": "^14.5.2",
12-
"framer-motion": "^10",
12+
"framer-motion": "^11",
1313
"immutable": "^4.3.6",
1414
"nighthouse": "^3.0.2",
1515
"react": "^18.3.1",
@@ -18,7 +18,7 @@
1818
"react-intersection-observer": "^9.13.0",
1919
"react-router-dom": "^6.25.1",
2020
"react-scripts": "^5.0.1",
21-
"react-stately": "^3.33.0",
21+
"react-stately": "^3.35.0",
2222
"tailwindcss": "^3.4.6",
2323
"typescript": "^4.9.3",
2424
"web-vitals": "^4.2.2"

src/App.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ import { ModelContextProvider } from '@luna/contexts/api/model/ModelContext';
44
import { SearchContextProvider } from '@luna/contexts/filter/SearchContext';
55
import { WindowDimensionsContextProvider } from '@luna/contexts/env/WindowDimensionsContext';
66
import { router } from '@luna/routes';
7-
import { NextUIProvider } from '@nextui-org/react';
7+
import { HeroUIProvider } from '@heroui/react';
88
import { RouterProvider } from 'react-router-dom';
99

1010
export function App() {
1111
return (
12-
<NextUIProvider>
12+
<HeroUIProvider>
1313
<ColorSchemeContextProvider>
1414
<WindowDimensionsContextProvider>
1515
<AuthContextProvider>
@@ -21,6 +21,6 @@ export function App() {
2121
</AuthContextProvider>
2222
</WindowDimensionsContextProvider>
2323
</ColorSchemeContextProvider>
24-
</NextUIProvider>
24+
</HeroUIProvider>
2525
);
2626
}

src/components/ApiTokenButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Token } from '@luna/contexts/api/auth/types';
22
import { ApiTokenModal } from '@luna/components/ApiTokenModal';
3-
import { Button, Tooltip, useDisclosure } from '@nextui-org/react';
3+
import { Button, Tooltip, useDisclosure } from '@heroui/react';
44
import { IconKey } from '@tabler/icons-react';
55

66
export interface ApiTokenButtonProps {

src/components/ApiTokenModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
ModalHeader,
77
Skeleton,
88
Snippet,
9-
} from '@nextui-org/react';
9+
} from '@heroui/react';
1010

1111
export interface ApiTokenModalProps {
1212
token: Token | null;

src/components/ColorSchemeButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { ColorSchemeContext } from '@luna/contexts/env/ColorSchemeContext';
2-
import { Button, Tooltip } from '@nextui-org/react';
2+
import { Button, Tooltip } from '@heroui/react';
33
import { IconMoon, IconSun } from '@tabler/icons-react';
44
import { useCallback, useContext } from 'react';
55

src/components/DisplayCard.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { DISPLAY_ASPECT_RATIO, Display } from '@luna/components/Display';
2-
import { Card, CardFooter } from '@nextui-org/react';
2+
import { Card, CardFooter } from '@heroui/react';
33
import React, { memo } from 'react';
44

55
interface DisplayCardProps {

src/components/FormInput.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Input, Tooltip } from '@nextui-org/react';
1+
import { Input, Tooltip } from '@heroui/react';
22
import { ReactNode, useCallback } from 'react';
33

44
export interface FormInputProps {

src/components/RouteLink.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
1-
import { Button } from '@nextui-org/react';
1+
import { Button } from '@heroui/react';
22
import { IconChevronDown, IconChevronRight } from '@tabler/icons-react';
3-
import { ReactNode, useCallback, useState } from 'react';
3+
import { ElementType, ReactNode, useCallback, useState } from 'react';
44
import { NavLink } from 'react-router-dom';
5-
import { AnimatePresence, motion } from 'framer-motion';
5+
import { AnimatePresence as AnimatePresenceFM, motion } from 'framer-motion';
6+
7+
// Workaround for https://github.com/framer/motion/issues/1509
8+
// See https://github.com/withastro/astro/issues/8195#issuecomment-2613930022
9+
const AnimatePresence = AnimatePresenceFM as ElementType;
610

711
interface RouteLinkParams {
812
icon: ReactNode;

src/components/SearchBar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { useDebounce } from '@luna/hooks/useDebounce';
2-
import { Input } from '@nextui-org/react';
2+
import { Input } from '@heroui/react';
33
import { IconSearch } from '@tabler/icons-react';
44
import { useCallback, useState } from 'react';
55

0 commit comments

Comments
 (0)