@lvce-editor/text-search-worker 5.14.0 → 5.15.0

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.
@@ -2092,7 +2092,7 @@ const copy = async state => {
2092
2092
  return state;
2093
2093
  };
2094
2094
 
2095
- const copyPath = async state => {
2095
+ const copyPath$1 = async state => {
2096
2096
  const {
2097
2097
  items,
2098
2098
  focusedIndex
@@ -2289,6 +2289,8 @@ const ConfirmReplaceManyOccurrencesInOneFile = "Replace {PH1} occurrences across
2289
2289
  const ConfirmReplaceManyOccurrencesInOneFileNoValue = 'Replace {PH1} occurrences across 1 file';
2290
2290
  const ConfirmReplaceOneOccurrenceInOneFile = "Replace 1 occurrence across 1 file with '{PH1}'";
2291
2291
  const ConfirmReplaceOneOccurrenceInOneFileNoValue = 'Replace 1 occurrence across 1 file';
2292
+ const CopyPath = 'Copy Path';
2293
+ const Dismiss = 'Dismiss';
2292
2294
  const Exclude = 'Exclude';
2293
2295
  const FilesToExclude$1 = 'Files to Exclude';
2294
2296
  const FilesToInclude$1 = 'Files to Include';
@@ -2408,9 +2410,15 @@ const replaceAll$1 = () => {
2408
2410
  const replace = () => {
2409
2411
  return i18nString(Replace);
2410
2412
  };
2413
+ const dismiss = () => {
2414
+ return i18nString(Dismiss);
2415
+ };
2411
2416
  const theResultSetOnlyContainsASubSetOfMatches = () => {
2412
2417
  return i18nString(TheResultSetOnlyContainsASubSetOfMatches);
2413
2418
  };
2419
+ const copyPath = () => {
2420
+ return i18nString(CopyPath);
2421
+ };
2414
2422
  const refresh$1 = () => {
2415
2423
  return i18nString(Refresh$1);
2416
2424
  };
@@ -2821,12 +2829,12 @@ const getMenuEntryIds = () => {
2821
2829
  const getMenuEntries = () => {
2822
2830
  return [{
2823
2831
  id: 'dismiss',
2824
- label: 'dismiss',
2832
+ label: dismiss(),
2825
2833
  flags: None$1,
2826
2834
  command: /* TODO */''
2827
2835
  }, {
2828
2836
  id: 'copyPath',
2829
- label: 'copyPath',
2837
+ label: copyPath(),
2830
2838
  flags: None$1,
2831
2839
  command: /* TODO */''
2832
2840
  }];
@@ -3050,8 +3058,7 @@ const getRipGrepArgs = ({
3050
3058
  searchString,
3051
3059
  useRegularExpression
3052
3060
  }) => {
3053
- const ripGrepArgs = ['--hidden', '--no-require-git', '--smart-case', '--stats', '--json'];
3054
- ripGrepArgs.push('--threads', `${threads}`);
3061
+ const ripGrepArgs = ['--hidden', '--no-require-git', '--smart-case', '--stats', '--json', '--threads', `${threads}`];
3055
3062
  if (isCaseSensitive) {
3056
3063
  ripGrepArgs.push('--case-sensitive');
3057
3064
  } else {
@@ -3585,13 +3592,17 @@ const launchSearchProcessNode = async () => {
3585
3592
  return rpc;
3586
3593
  };
3587
3594
 
3588
- const initialize = async platform => {
3595
+ const setSearchProcessFactory = platform => {
3589
3596
  if (platform === Electron) {
3590
3597
  setFactory(launchSearchProcessElectron);
3591
3598
  } else if (platform === Remote) {
3592
3599
  setFactory(launchSearchProcessNode);
3593
3600
  }
3594
- // TODO
3601
+ };
3602
+ const initialize = async platform => {
3603
+ setSearchProcessFactory(platform);
3604
+
3605
+ // TODO connect to icon theme worker
3595
3606
  };
3596
3607
 
3597
3608
  // TODO optimize this function to return the minimum number
@@ -5429,9 +5440,7 @@ const show = async (x, y, id, ...args) => {
5429
5440
 
5430
5441
  const handleContextMenuKeyboard = async state => {
5431
5442
  const {
5432
- x
5433
- } = state; // TODO
5434
- const {
5443
+ x,
5435
5444
  y
5436
5445
  } = state; // TODO
5437
5446
  await show(x, y, Search$1);
@@ -5463,7 +5472,7 @@ const commandMap = {
5463
5472
  'TextSearch.collapseAll': wrapCommand(collapseAll$1),
5464
5473
  'TextSearch.collapseDetails': wrapCommand(collapseDetails),
5465
5474
  'TextSearch.copy': wrapCommand(copy),
5466
- 'TextSearch.copyPath': wrapCommand(copyPath),
5475
+ 'TextSearch.copyPath': wrapCommand(copyPath$1),
5467
5476
  'TextSearch.diff2': diff2,
5468
5477
  'TextSearch.dismissItem': wrapCommand(dismissItem),
5469
5478
  'TextSearch.expandDetails': wrapCommand(expandDetails),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/text-search-worker",
3
- "version": "5.14.0",
3
+ "version": "5.15.0",
4
4
  "description": "Text Search Worker",
5
5
  "keywords": [
6
6
  "text-search"