Skip to content

Commit

Permalink
feat(search-panel): increase maximum search results limit to 2000
Browse files Browse the repository at this point in the history
  • Loading branch information
purocean committed Jan 6, 2025
1 parent 9450516 commit 5ee02b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/renderer/components/SearchPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ import { toggleSide } from '@fe/services/layout'
import type { FindInRepositoryQuery, PathItem } from '@fe/types'
import SvgIcon from './SvgIcon.vue'
const MAX_RESULTS = 1000
const MAX_RESULTS = 2000
const SEARCH_LIMIT_SETTING_KEY = 'search.number-limit'
const logger = getLogger('search-panel')
Expand Down Expand Up @@ -394,7 +394,7 @@ async function search () {
excludePattern: buildGlobObject(exclude.value),
},
],
maxResults: Math.min(MAX_RESULTS, getSetting(SEARCH_LIMIT_SETTING_KEY, 300)),
maxResults: Math.min(MAX_RESULTS, getSetting(SEARCH_LIMIT_SETTING_KEY, 700)),
}
try {
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/others/setting-schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,10 @@ const schema: SettingSchema = ({
group: 'other',
},
'search.number-limit': {
defaultValue: 300,
defaultValue: 700,
title: 'T_setting-panel.schema.search.number-limit',
type: 'number',
enum: [100, 200, 300, 400, 500, 600, 700, 800, 900, 1000],
enum: [100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1300, 1600, 2000],
required: true,
group: 'other',
},
Expand Down

0 comments on commit 5ee02b6

Please sign in to comment.