diff --git a/app/components/Dropdown.tsx b/app/components/Dropdown.tsx index d383b64..d68a13d 100644 --- a/app/components/Dropdown.tsx +++ b/app/components/Dropdown.tsx @@ -47,7 +47,7 @@ export const DropdownSubTrigger = ({ children: JSX.Element | string className?: string }) => ( - + {children} { const [shouldPrefetch, setShouldPrefetch] = useState(false) - const timer = useRef(null) + const timer = useRef | null>(null) function clear() { if (timer.current) clearTimeout(timer.current) diff --git a/app/components/home/FilterDropdown.tsx b/app/components/home/FilterDropdown.tsx index bbbcc54..c7cd987 100644 --- a/app/components/home/FilterDropdown.tsx +++ b/app/components/home/FilterDropdown.tsx @@ -149,7 +149,7 @@ const DropdownFilterItem = ({ }) => ( {selected && }
diff --git a/app/components/note/NoteForm.tsx b/app/components/note/NoteForm.tsx index 2b743c7..455bb10 100644 --- a/app/components/note/NoteForm.tsx +++ b/app/components/note/NoteForm.tsx @@ -171,7 +171,7 @@ export const NoteForm = ({ body={body} onChange={(val) => { setStatus('unsaved') - setBody(val) + setBody(val || '') }} />
diff --git a/app/routes/notes.$id.publish.tsx b/app/routes/notes.$id.publish.tsx index dd180fa..7c74056 100644 --- a/app/routes/notes.$id.publish.tsx +++ b/app/routes/notes.$id.publish.tsx @@ -5,11 +5,11 @@ * * Copyright Oxide Computer Company */ -import { json, type ActionArgs } from '@remix-run/node' +import { json, type ActionFunction } from '@remix-run/node' import { isAuthenticated } from '~/services/authn.server' -export async function action({ request, params }: ActionArgs) { +export const action: ActionFunction = async ({ request, params }) => { const user = await isAuthenticated(request) if (!user) throw new Response('User not found', { status: 401 })