Skip to content

Commit

Permalink
More type fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminleonard committed Dec 17, 2024
1 parent bf47ae8 commit f8e52a3
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app/components/Dropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const DropdownSubTrigger = ({
children: JSX.Element | string
className?: string
}) => (
<Dropdown.SubTrigger className={cn(dropdownOuterStyles, classNames, dropdownInnerStyles)}>
<Dropdown.SubTrigger className={cn(dropdownOuterStyles, className, dropdownInnerStyles)}>
{children}
<Icon
name="carat-down"
Expand Down
2 changes: 1 addition & 1 deletion app/components/SelectRfdCombobox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ const ComboboxItem = ({
}) => {
const [shouldPrefetch, setShouldPrefetch] = useState(false)

const timer = useRef<NodeJS.Timeout | null>(null)
const timer = useRef<ReturnType<typeof setTimeout> | null>(null)

function clear() {
if (timer.current) clearTimeout(timer.current)
Expand Down
2 changes: 1 addition & 1 deletion app/components/home/FilterDropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ const DropdownFilterItem = ({
}) => (
<DropdownItem
onSelect={onSelect}
classNames={selected ? 'bg-accent-secondary text-accent' : ''}
className={selected ? 'text-accent bg-accent-secondary' : ''}
>
{selected && <Outline />}
<div className="flex items-center justify-between">
Expand Down
2 changes: 1 addition & 1 deletion app/components/note/NoteForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export const NoteForm = ({
body={body}
onChange={(val) => {
setStatus('unsaved')
setBody(val)
setBody(val || '')
}}
/>
</div>
Expand Down
4 changes: 2 additions & 2 deletions app/routes/notes.$id.publish.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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 })
Expand Down

0 comments on commit f8e52a3

Please sign in to comment.