mirror of
https://github.com/chrisbenincasa/tunarr.git
synced 2026-04-18 09:03:35 -04:00
chore: update Typescript to 5.9.3
This commit is contained in:
@@ -52,7 +52,7 @@
|
||||
"overrides": {
|
||||
"eslint": "9.17.0",
|
||||
"@types/node": "22.10.7",
|
||||
"typescript": "5.7.3"
|
||||
"typescript": "5.9.3"
|
||||
}
|
||||
},
|
||||
"lint-staged": {
|
||||
|
||||
444
pnpm-lock.yaml
generated
444
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -11,6 +11,7 @@ import {
|
||||
useDeleteSmartCollection,
|
||||
useSmartCollections,
|
||||
} from '../../hooks/smartCollectionHooks.ts';
|
||||
import type { RootSearchQueryParams } from '../../routes/__root.tsx';
|
||||
import { Route } from '../../routes/__root.tsx';
|
||||
import type { Maybe } from '../../types/util.ts';
|
||||
import { RouterButtonLink } from '../base/RouterButtonLink.tsx';
|
||||
@@ -76,7 +77,10 @@ export const SmartCollectionsTable = () => {
|
||||
<RouterButtonLink
|
||||
variant="contained"
|
||||
to="/search"
|
||||
search={(prev) => ({ ...prev, query: undefined })}
|
||||
search={(prev: RootSearchQueryParams) => ({
|
||||
...prev,
|
||||
query: undefined,
|
||||
})}
|
||||
startIcon={<Search />}
|
||||
>
|
||||
Create
|
||||
|
||||
@@ -19,13 +19,15 @@ const searchQuerySchema = z.object({
|
||||
query: z.string().optional().catch(undefined),
|
||||
});
|
||||
|
||||
export type RootSearchQueryParams = z.infer<typeof searchQuerySchema>;
|
||||
|
||||
export const Route = createRootRouteWithContext<RouterContext>()({
|
||||
validateSearch: zodValidator(searchQuerySchema),
|
||||
search: {
|
||||
middlewares: [retainSearchParams(['query'])],
|
||||
},
|
||||
loader: async ({ context: { queryClient }, location: { search } }) => {
|
||||
const parsed = search as z.infer<typeof searchQuerySchema>;
|
||||
const parsed = search as RootSearchQueryParams;
|
||||
if (!isNonEmptyString(parsed.query)) {
|
||||
useStore.setState((s) => {
|
||||
s.currentSearchRequest = null;
|
||||
|
||||
Reference in New Issue
Block a user