Skip to content

Commit 70a1f0b

Browse files
committed
Enhances debounce
- Adds maxWait, signal, and edges
1 parent 7519c03 commit 70a1f0b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+681
-171
lines changed

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20250,6 +20250,7 @@
2025020250
"@types/node": "20.14.15",
2025120251
"@types/react": "17.0.83",
2025220252
"@types/react-dom": "17.0.25",
20253+
"@types/sinon": "17.0.4",
2025320254
"@types/slug": "5.0.9",
2025420255
"@types/sortablejs": "1.15.8",
2025520256
"@types/vscode": "1.92.0",
@@ -20294,6 +20295,7 @@
2029420295
"sass-loader": "16.0.5",
2029520296
"schema-utils": "4.3.0",
2029620297
"sharp": "0.33.5",
20298+
"sinon": "19.0.2",
2029720299
"svgo": "3.3.2",
2029820300
"terser-webpack-plugin": "5.3.11",
2029920301
"ts-loader": "9.5.2",

pnpm-lock.yaml

Lines changed: 104 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/ai/aiProviderService.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { configuration } from '../system/-webview/configuration';
1515
import type { Storage } from '../system/-webview/storage';
1616
import { supportedInVSCodeVersion } from '../system/-webview/vscode';
1717
import { formatNumeric } from '../system/date';
18-
import { debounce } from '../system/function';
18+
import { debounce } from '../system/function/debounce';
1919
import { map } from '../system/iterable';
2020
import type { Lazy } from '../system/lazy';
2121
import { lazy } from '../system/lazy';

src/annotations/fileAnnotationController.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ import { UriSet } from '../system/-webview/uriMap';
3333
import { isTrackableTextEditor } from '../system/-webview/vscode';
3434
import { debug, log } from '../system/decorators/log';
3535
import { once } from '../system/event';
36-
import type { Deferrable } from '../system/function';
37-
import { debounce } from '../system/function';
36+
import type { Deferrable } from '../system/function/debounce';
37+
import { debounce } from '../system/function/debounce';
3838
import { find } from '../system/iterable';
3939
import { basename } from '../system/path';
4040
import type {

src/annotations/lineAnnotationController.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { configuration } from '../system/-webview/configuration';
99
import { isTrackableTextEditor } from '../system/-webview/vscode';
1010
import { debug, log } from '../system/decorators/log';
1111
import { once } from '../system/event';
12-
import { debounce } from '../system/function';
12+
import { debounce } from '../system/function/debounce';
1313
import { Logger } from '../system/logger';
1414
import { getLogScope, setLogScopeExit } from '../system/logger.scope';
1515
import type { MaybePausedResult } from '../system/promise';

src/avatars.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import type { CommitAuthor } from './git/models/author';
77
import { getGitHubNoReplyAddressParts } from './git/remotes/github';
88
import { configuration } from './system/-webview/configuration';
99
import { getContext } from './system/-webview/context';
10-
import { debounce } from './system/function';
10+
import { debounce } from './system/function/debounce';
1111
import { filterMap } from './system/iterable';
1212
import { base64, equalsIgnoreCase } from './system/string';
1313
import type { ContactPresenceStatus } from './vsls/vsls';

src/commands/quickCommand.steps.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ import { configuration } from '../system/-webview/configuration';
104104
import { formatPath } from '../system/-webview/formatPath';
105105
import { getIconPathUris, openWorkspace } from '../system/-webview/vscode';
106106
import { filterMap, intersection, isStringArray } from '../system/array';
107-
import { debounce } from '../system/function';
107+
import { debounce } from '../system/function/debounce';
108108
import { first, map } from '../system/iterable';
109109
import { Logger } from '../system/logger';
110110
import { getSettledValue } from '../system/promise';

src/env/node/git/localGitProvider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ import { configuration } from '../../../system/-webview/configuration';
6363
import { getBestPath, isFolderUri, relative, splitPath } from '../../../system/-webview/path';
6464
import { gate } from '../../../system/decorators/-webview/gate';
6565
import { debug, log } from '../../../system/decorators/log';
66-
import { debounce } from '../../../system/function';
66+
import { debounce } from '../../../system/function/debounce';
6767
import { first, join } from '../../../system/iterable';
6868
import { Logger } from '../../../system/logger';
6969
import type { LogScope } from '../../../system/logger.scope';

src/git/gitProviderService.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ import { getBestPath } from '../system/-webview/path';
2929
import { joinUnique } from '../system/array';
3030
import { gate } from '../system/decorators/-webview/gate';
3131
import { debug, log } from '../system/decorators/log';
32-
import type { Deferrable } from '../system/function';
33-
import { debounce } from '../system/function';
32+
import type { Deferrable } from '../system/function/debounce';
33+
import { debounce } from '../system/function/debounce';
3434
import { count, filter, first, flatMap, groupByFilterMap, groupByMap, join, map, some, sum } from '../system/iterable';
3535
import { getLoggableName, Logger } from '../system/logger';
3636
import { getLogScope, setLogScopeExit, startLogScope } from '../system/logger.scope';

src/git/models/repository.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ import { getScopedCounter } from '../../system/counter';
1515
import { gate } from '../../system/decorators/-webview/gate';
1616
import { memoize } from '../../system/decorators/-webview/memoize';
1717
import { debug, log, logName } from '../../system/decorators/log';
18-
import type { Deferrable } from '../../system/function';
19-
import { debounce } from '../../system/function';
18+
import type { Deferrable } from '../../system/function/debounce';
19+
import { debounce } from '../../system/function/debounce';
2020
import { filter, groupByMap, join, min, some } from '../../system/iterable';
2121
import { getLoggableName, Logger } from '../../system/logger';
2222
import { getLogScope, startLogScope } from '../../system/logger.scope';

0 commit comments

Comments
 (0)