Skip to content

Commit fe55832

Browse files
authored
Merge pull request #47 from ozziexsh/ozziexsh/updates
update components and packages to new versions
2 parents 594c5d7 + 7037c56 commit fe55832

File tree

5 files changed

+43
-44
lines changed

5 files changed

+43
-44
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ First install dependencies and run the build script
112112

113113
```shell
114114
npm install
115-
npm build
115+
npm run build
116116
```
117117

118118
Then create a fresh laravel install with jetstream

src/commands/install.ts

+20-22
Original file line numberDiff line numberDiff line change
@@ -25,33 +25,31 @@ export default class Install extends Command {
2525
static args = [];
2626

2727
private devDeps = {
28-
'@prettier/plugin-php': '^0.18.4',
29-
'@tailwindcss/forms': '^0.5.2',
30-
'@tailwindcss/typography': '^0.5.2',
28+
'@prettier/plugin-php': '^0.22.2',
29+
'@tailwindcss/forms': '^0.5.8',
30+
'@tailwindcss/typography': '^0.5.15',
3131
'@types/lodash': '^4.14.181',
32-
'@types/react': '^18.0.25',
33-
'@types/react-dom': '^18.0.8',
34-
'@types/ziggy-js': '^1.3.0',
35-
'@vitejs/plugin-react': '^2.2.0',
36-
autoprefixer: '^10.4.7',
37-
'laravel-vite-plugin': '^0.7.7',
38-
postcss: '^8.4.14',
39-
prettier: '^2.8.4',
40-
tailwindcss: '^3.2.7',
41-
typescript: '^4.6.3',
42-
vite: '^3.0.0',
32+
'@types/react': '^18.3.5',
33+
'@types/react-dom': '^18.3.0',
34+
'@vitejs/plugin-react': '^4.3.1',
35+
autoprefixer: '^10.4.20',
36+
'laravel-vite-plugin': '^1.0.5',
37+
postcss: '^8.4.41',
38+
prettier: '^3.3.3',
39+
tailwindcss: '^3.4.10',
40+
typescript: '^5.5.4',
41+
vite: '^5.4.2',
4342
};
4443

4544
private deps = {
46-
'@headlessui/react': '^1.7.11',
47-
'@inertiajs/core': '^1.0.2',
48-
'@inertiajs/react': '^1.0.2',
49-
axios: '^0.26.1',
50-
classnames: '^2.3.1',
45+
'@headlessui/react': '^2.1.3',
46+
'@inertiajs/react': '^1.2.0',
47+
axios: '^1.7.6',
48+
classnames: '^2.5.1',
5149
lodash: '^4.17.21',
52-
react: '^18.2.0',
53-
'react-dom': '^18.2.0',
54-
'ziggy-js': '^1.4.5',
50+
react: '^18.3.1',
51+
'react-dom': '^18.3.1',
52+
'ziggy-js': '^2.3.0',
5553
};
5654

5755
private oldDeps = [

src/stubs/resources/js/Components/Dropdown.tsx

+13-12
Original file line numberDiff line numberDiff line change
@@ -51,23 +51,24 @@ export default function Dropdown({
5151
leave="transition ease-in duration-75"
5252
leaveFrom="transform opacity-100 scale-100"
5353
leaveTo="transform opacity-0 scale-95"
54-
className={'relative z-50'}
5554
>
56-
<div
57-
className={classNames(
58-
'absolute mt-2 rounded-md shadow-lg',
59-
widthClass,
60-
alignmentClasses,
61-
)}
62-
onClick={() => setOpen(false)}
63-
>
55+
<div className={'relative z-50'}>
6456
<div
6557
className={classNames(
66-
'rounded-md ring-1 ring-black ring-opacity-5',
67-
contentClasses,
58+
'absolute mt-2 rounded-md shadow-lg',
59+
widthClass,
60+
alignmentClasses,
6861
)}
62+
onClick={() => setOpen(false)}
6963
>
70-
{children}
64+
<div
65+
className={classNames(
66+
'rounded-md ring-1 ring-black ring-opacity-5',
67+
contentClasses,
68+
)}
69+
>
70+
{children}
71+
</div>
7172
</div>
7273
</div>
7374
</Transition>

src/stubs/resources/js/Components/Modal.tsx

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Dialog, Transition } from '@headlessui/react';
1+
import { Dialog, Transition, TransitionChild } from '@headlessui/react';
22
import classNames from 'classnames';
33
import React, { PropsWithChildren } from 'react';
44
import ReactDOM from 'react-dom';
@@ -28,7 +28,7 @@ export default function Modal({
2828
}
2929

3030
return ReactDOM.createPortal(
31-
<Transition.Root show={isOpen} as={React.Fragment}>
31+
<Transition show={isOpen} as={React.Fragment}>
3232
<Dialog
3333
as="div"
3434
static
@@ -37,7 +37,7 @@ export default function Modal({
3737
onClose={onClose}
3838
>
3939
<div className="flex items-end justify-center min-h-screen pt-4 px-4 pb-20 text-center sm:block sm:p-0">
40-
<Transition.Child
40+
<TransitionChild
4141
as={React.Fragment}
4242
enter="ease-out duration-300"
4343
enterFrom="opacity-0"
@@ -46,8 +46,8 @@ export default function Modal({
4646
leaveFrom="opacity-100"
4747
leaveTo="opacity-0"
4848
>
49-
<Dialog.Overlay className="fixed inset-0 bg-gray-500 dark:bg-gray-900 bg-opacity-75 transition-opacity" />
50-
</Transition.Child>
49+
<div className="fixed inset-0 bg-gray-500 dark:bg-gray-900 bg-opacity-75 transition-opacity" />
50+
</TransitionChild>
5151

5252
{/* This element is to trick the browser into centering the modal contents. */}
5353
<span
@@ -56,7 +56,7 @@ export default function Modal({
5656
>
5757
&#8203;
5858
</span>
59-
<Transition.Child
59+
<TransitionChild
6060
as={React.Fragment}
6161
enter="ease-out duration-300"
6262
enterFrom="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
@@ -73,10 +73,10 @@ export default function Modal({
7373
>
7474
{children}
7575
</div>
76-
</Transition.Child>
76+
</TransitionChild>
7777
</div>
7878
</Dialog>
79-
</Transition.Root>,
79+
</Transition>,
8080
document.body,
8181
);
8282
}

src/stubs/resources/js/Hooks/useRoute.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import route from 'ziggy-js';
1+
import { route } from 'ziggy-js';
22
import { createContext, useContext } from 'react';
33

44
export const RouteContext = createContext<typeof route | null>(null);

0 commit comments

Comments
 (0)