From efd0338a33f7622102c37c298887e7e07c168339 Mon Sep 17 00:00:00 2001 From: Rob Watson Date: Sat, 4 Jul 2020 08:40:58 +0200 Subject: [PATCH] Add TypeScript annotations --- server/ui/src/components/search.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/ui/src/components/search.tsx b/server/ui/src/components/search.tsx index c6357ee..47471f4 100644 --- a/server/ui/src/components/search.tsx +++ b/server/ui/src/components/search.tsx @@ -111,7 +111,7 @@ export class Search extends Component { ) } - sortLink(sortKey) { + sortLink(sortKey: string) { return ( @@ -122,7 +122,7 @@ export class Search extends Component { ) } - buildSortURL(sortKey) { + buildSortURL(sortKey: string) { const searchParams = this.state.searchParams; let page, sortDir; if (sortKey === searchParams.sort_key) { @@ -135,7 +135,7 @@ export class Search extends Component { return `/#/search/${searchParams.type_}/${searchParams.q}/${page}/${sortKey}/${sortDir}`; } - sortLinkIcon(sortKey) { + sortLinkIcon(sortKey: string) { const searchParams = this.state.searchParams; if (searchParams.sort_key !== sortKey) {