dsh-workspace-ide 1.8.5 → 1.8.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/client.js +24 -4
  2. package/package.json +1 -1
package/lib/client.js CHANGED
@@ -6509,6 +6509,26 @@ function orderQuickFiles(recent, files, limit) {
6509
6509
  return ordered;
6510
6510
  }
6511
6511
  S.orderQuickFiles = orderQuickFiles;
6512
+ /**
6513
+ * Quick-open palette rows for one query. Empty queries are recent-first; typed
6514
+ * queries use fuzzy ranking. Always returns `{path, score}` objects so the
6515
+ * palette renderer has one shape.
6516
+ * @param query - typed query.
6517
+ * @param files - workspace index.
6518
+ * @param recent - open history (oldest first).
6519
+ * @param limit - maximum rows.
6520
+ * @returns rows, best first.
6521
+ */
6522
+ function quickOpenRows(query, files, recent, limit) {
6523
+ const max = typeof limit === 'number' && Number.isFinite(limit) && limit > 0 ? Math.floor(limit) : 50;
6524
+ if (typeof query !== 'string' || query.trim().length === 0) {
6525
+ return orderQuickFiles(recent, files, max).map(function (filePath) {
6526
+ return { path: filePath, score: 0 };
6527
+ });
6528
+ }
6529
+ return rankQuickOpen(query, files, max);
6530
+ }
6531
+ S.quickOpenRows = quickOpenRows;
6512
6532
  /**
6513
6533
  * Extract navigable symbols (functions/classes/types/constants/methods,
6514
6534
  * markdown headings, JSON keys) for Go-to-Symbol. Regex-based on purpose: it
@@ -8245,10 +8265,9 @@ function FilesView(props) {
8245
8265
  const quickResults = useMemo(function () {
8246
8266
  if (quickOpen === false || quickFiles === null)
8247
8267
  return [];
8248
- if (quickQuery.trim().length === 0) {
8249
- return typeof S.orderQuickFiles === 'function' ? S.orderQuickFiles(recentPaths, quickFiles, 50) : quickFiles.slice(0, 50);
8250
- }
8251
- return typeof S.rankQuickOpen === 'function' ? S.rankQuickOpen(quickQuery, quickFiles, 50) : [];
8268
+ return typeof S.quickOpenRows === 'function'
8269
+ ? S.quickOpenRows(quickQuery, quickFiles, recentPaths, 50)
8270
+ : (typeof S.rankQuickOpen === 'function' ? S.rankQuickOpen(quickQuery, quickFiles, 50) : []);
8252
8271
  }, [quickOpen, quickQuery, quickFiles, recentPaths]);
8253
8272
  const symbolItems = useMemo(function () {
8254
8273
  if (symbolsOpen === false || file.status !== 'loaded')
@@ -11300,6 +11319,7 @@ S.face = {
11300
11319
  quickOpenScore: S.quickOpenScore,
11301
11320
  rankQuickOpen: S.rankQuickOpen,
11302
11321
  orderQuickFiles: S.orderQuickFiles,
11322
+ quickOpenRows: S.quickOpenRows,
11303
11323
  extractSymbols: S.extractSymbols,
11304
11324
  duplicateLines: S.duplicateLines,
11305
11325
  moveLines: S.moveLines,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-workspace-ide",
3
- "version": "1.8.5",
3
+ "version": "1.8.6",
4
4
  "private": false,
5
5
  "description": "A JetBrains-inspired workspace IDE panel for DeepSeek Harness: file tree, TypeScript code editor with find & replace, Quick Open, tabs and syntax highlighting, full-text search, and git status / diff / history",
6
6
  "type": "module",