File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -17,15 +17,15 @@ type SortField = keyof typeof SORT_FIELDS;
1717
1818const MAX_LIMIT = 100 ;
1919const DEFAULT_LIMIT = 20 ;
20- const DEFAULT_SORT : SortField = "stars " ;
20+ const DEFAULT_SORT : SortField = "installs " ;
2121
2222/**
2323 * GET /api/extensions
2424 *
2525 * Query parameters:
2626 * page - Page number, 1-indexed (default: 1)
2727 * limit - Items per page, max 100 (default: 20)
28- * sort - Sort field: "stars" | "installs" | "updated" (default: "stars ")
28+ * sort - Sort field: "stars" | "installs" | "updated" (default: "installs ")
2929 * order - Sort direction: "asc" | "desc" (default: "desc")
3030 * q - Optional search query (matches title, name, description, author)
3131 *
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ interface StoreGridProps {
1515export function StoreGrid ( { extensions } : StoreGridProps ) {
1616 const { t } = useLocale ( ) ;
1717 const [ search , setSearch ] = useState ( "" ) ;
18- const [ sortKey , setSortKey ] = useState < SortKey > ( "stars " ) ;
18+ const [ sortKey , setSortKey ] = useState < SortKey > ( "installs " ) ;
1919
2020 const filtered = useMemo ( ( ) => {
2121 const q = search . toLowerCase ( ) . trim ( ) ;
@@ -40,8 +40,8 @@ export function StoreGrid({ extensions }: StoreGridProps) {
4040 } , [ extensions , search , sortKey ] ) ;
4141
4242 const sortOptions : { key : SortKey ; label : string } [ ] = [
43- { key : "stars" , label : t ( "store.sort.stars" ) } ,
4443 { key : "installs" , label : t ( "store.sort.installs" ) } ,
44+ { key : "stars" , label : t ( "store.sort.stars" ) } ,
4545 { key : "updated" , label : t ( "store.sort.updated" ) } ,
4646 ] ;
4747
You can’t perform that action at this time.
0 commit comments