mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 17:31:43 +00:00
Svelte: follow up on display limit TODO (#62681)
This updates the svelte webapp to respect the new search.displayLimit.
This commit is contained in:
parent
653489c02f
commit
7e2d0bf0d8
@ -82,7 +82,7 @@ class NonCachingStreamManager {
|
||||
|
||||
const streamManager = browser ? new CachingStreamManager() : new NonCachingStreamManager()
|
||||
|
||||
export const load: PageLoad = ({ url, depends }) => {
|
||||
export const load: PageLoad = async ({ parent, url, depends }) => {
|
||||
const hasQuery = url.searchParams.has('q')
|
||||
const cachePolicy = getCachePolicyFromURL(url)
|
||||
const trace = url.searchParams.get('trace') ?? undefined
|
||||
@ -116,8 +116,7 @@ export const load: PageLoad = ({ url, depends }) => {
|
||||
featureOverrides: [],
|
||||
chunkMatches: true,
|
||||
searchMode,
|
||||
// TODO: populate this from user settings
|
||||
displayLimit: 1500,
|
||||
displayLimit: (await parent()).settings?.['search.displayLimit'] ?? 1500,
|
||||
// 5kb is a conservative upper bound on a reasonable line to show
|
||||
// to a user. In practice we can likely go much lower.
|
||||
maxLineLen: 5 * 1024,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user