@@ -18,8 +18,8 @@ import { getNoteImgSrc, useIsPending } from '#app/utils/misc.tsx'
1818import { requireUserWithPermission } from '#app/utils/permissions.server.ts'
1919import { redirectWithToast } from '#app/utils/toast.server.ts'
2020import { userHasPermission , useOptionalUser } from '#app/utils/user.ts'
21- import { type Route , type Info } from './+types/notes.$noteId.ts'
22- import { type Info as notesInfo } from './+types/notes.ts'
21+ import { type Route } from './+types/notes.$noteId.ts'
22+ import { type Route as NotesRoute } from './+types/notes.ts'
2323
2424export async function loader ( { params } : Route . LoaderArgs ) {
2525 const note = await prisma . note . findUnique ( {
@@ -173,7 +173,7 @@ export function DeleteNote({
173173 actionData,
174174} : {
175175 id : string
176- actionData : Info [ 'actionData' ] | undefined
176+ actionData : Route . ComponentProps [ 'actionData' ] | undefined
177177} ) {
178178 const isPending = useIsPending ( )
179179 const [ form ] = useForm ( {
@@ -205,7 +205,7 @@ export function DeleteNote({
205205export const meta : Route . MetaFunction = ( { data, params, matches } ) => {
206206 const notesMatch = matches . find (
207207 ( m ) => m ?. id === 'routes/users+/$username_+/notes' ,
208- ) as { data : notesInfo [ 'loaderData' ] } | undefined
208+ ) as { data : NotesRoute . ComponentProps [ 'loaderData' ] } | undefined
209209
210210 const displayName = notesMatch ?. data ?. owner . name ?? params . username
211211 const noteTitle = data ?. note . title ?? 'Note'
0 commit comments