Skip to content

Commit

Permalink
fixup! chore(deps): update dependency prettier to v3.3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
morremeyer committed Nov 23, 2024
1 parent 8bc7351 commit a1dff8a
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 26 deletions.
10 changes: 5 additions & 5 deletions cypress/support/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ declare namespace Cypress {
* @example
* cy.getByTitle("Create Budget")
*/
getByTitle(title: string): Chainable<any>
getInputFor(label: string): Chainable<any>
getAutocompleteFor(label: string): Chainable<any>
clickAndWait(element: string): Chainable<any>
awaitLoading(): Chainable<any>
getByTitle(title: string): Chainable
getInputFor(label: string): Chainable
getAutocompleteFor(label: string): Chainable
clickAndWait(element: string): Chainable
awaitLoading(): Chainable
resetDb(): void
}
}
2 changes: 1 addition & 1 deletion src/components/ArchiveButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { ArchivableResource, ApiConnection, Translation } from '../types'
type Props = {
resource: ArchivableResource
resourceTypeTranslation: string
apiConnection: ApiConnection<ArchivableResource>
apiConnection: ApiConnection
onSuccess: (data: ArchivableResource) => void
onError: (error: string) => void
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/Autocomplete.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const Autocomplete = <T extends ArchivableResource>({
wrapperClass,
labelClass,
inputWrapperClass,
}: Props<T>) => {
}: Props) => {
const { t }: Translation = useTranslation()
const [query, setQuery] = useState('')

Expand Down
4 changes: 2 additions & 2 deletions src/components/FormField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ type Props = {
label: string
value?: string
options?: { [option: string]: string | boolean }
onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void
onFocus?: (e: React.FocusEvent<HTMLInputElement>) => void
onChange?: (e: React.ChangeEvent) => void
onFocus?: (e: React.FocusEvent) => void
children?: React.ReactNode
note?: string
tooltip?: string
Expand Down
2 changes: 1 addition & 1 deletion src/components/InfiniteScroll.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { useEffect, useState } from 'react'
type Props = {
children: React.ReactNode
batchSize: number
onLoadMore: (offset: number) => Promise<boolean>
onLoadMore: (offset: number) => Promise
}

const InfiniteScroll = ({ children, batchSize, onLoadMore }: Props) => {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ const Layout = ({
<div className={`${hideNav ? '' : 'lg:pl-64'} flex flex-1 flex-col`}>
<div
className="sticky top-0 z-10 bg-gray-100 px-6 pt-4 dark:bg-slate-900 lg:hidden"
ref={headerRef as React.RefObject<HTMLDivElement>}
ref={headerRef as React.RefObject}
>
<button
type="button"
Expand Down
2 changes: 1 addition & 1 deletion src/components/MonthPicker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { useTranslation } from 'react-i18next'

type Props = {
open: boolean
setOpen: Dispatch<SetStateAction<boolean>>
setOpen: Dispatch
activeMonth: string
}

Expand Down
2 changes: 1 addition & 1 deletion src/lib/submit-on-meta-enter.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const submitOnMetaEnter = (e: React.KeyboardEvent<HTMLFormElement>) => {
const submitOnMetaEnter = (e: React.KeyboardEvent) => {
if (e.code === 'Enter' && (e.metaKey || e.ctrlKey)) {
const target = e.target as HTMLInputElement
target?.form?.requestSubmit()
Expand Down
23 changes: 10 additions & 13 deletions src/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,22 +29,19 @@ export type UnpersistedAccount = {
}

export type ApiConnection<T> = {
getAll: (parent: ApiObject, filterOptions: FilterOptions) => Promise<T>
get: (id: UUID, parent: ApiObject) => Promise<T>
update: (object: T, url?: string) => Promise<T>
create: (object: T, budget: Budget, url?: string) => Promise<T>
delete: (
object: ApiObject | undefined,
options: { url?: string }
) => Promise<T>
getAll: (parent: ApiObject, filterOptions: FilterOptions) => Promise
get: (id: UUID, parent: ApiObject) => Promise
update: (object: T, url?: string) => Promise
create: (object: T, budget: Budget, url?: string) => Promise
delete: (object: ApiObject | undefined, options: { url?: string }) => Promise
}

export type BudgetApiConnection = {
updateBudget: (budget: Budget) => Promise<Budget>
updateBudget: (budget: Budget) => Promise
deleteBudget: (budget: Budget) => void
getBudgets: () => Promise<Budget[]>
getBudget: (id: UUID) => Promise<Budget>
createBudget: (data: UnpersistedBudget) => Promise<Budget>
getBudgets: () => Promise
getBudget: (id: UUID) => Promise
createBudget: (data: UnpersistedBudget) => Promise
}

export type Account = UnpersistedAccount &
Expand Down Expand Up @@ -116,7 +113,7 @@ export type Category = UnpersistedCategory &
envelopes: Envelope[]
}

export type CategoryMonth = Omit<Category, 'envelopes'> & {
export type CategoryMonth = Omit & {
envelopes: EnvelopeMonth[]
spent: string
allocation: string
Expand Down

0 comments on commit a1dff8a

Please sign in to comment.