Lutra/ui/src/i18n/en.json
danny 578160a2ba M3.5: go to definition, find references and rename through Phpactor
Engine (`cmd/lsp_nav.rs`, on the pending outcomes of 20d1d28):
- `lsp.definition` (F12) and `lsp.references` (Shift+F12, sorted, with
  line previews) return project-relative locations; locations outside
  the project, such as PHAR stubs and symlink escapes, are dropped.
- `lsp.prepareRename` uses the word at the cursor when the server has
  no prepareProvider.
- `lsp.rename` (F2) applies the workspace edit (`lsp_nav/edit.rs`):
  1. Check everything first: inside the project, ranges fit (UTF-16,
     CRLF), open buffers unchanged since the request, no file
     operations, no incomplete edit.
  2. Write closed files atomically through the VFS, restoring earlier
     writes when a later one fails.
  3. Change open buffers through `buffer.edit` (dirty, undoable).
  4. Send each written file to Phpactor as didOpen/didSave/didClose
     plus didChangeWatchedFiles; without this its index kept the old
     names. Then the summary notification `notification.lsp.renamed`.

UI (`components/editor/nav/`):
- Mod+click goes to the definition, with a pointer cursor while Mod is
  held.
- A location picker for several definitions (exclusive modal).
- A References tab in the bottom panel, grouped by file.
- An inline rename field with a use/file count (exclusive modal).
- `BufferSync.beginUndoableRemote` puts the engine's rename edit into
  the editor history as one undo step per buffer.
- Catalog strings and tokens only.

Fake LSP server: `--script FILE` with scripted capabilities and
answers (additive next to M3.4's arms).

Tests:
- `crates/engine/tests/lsp_nav.rs` (fake): definition; bad positions;
  references; prepareRename; a multi-file rename incl. a closed CRLF
  file; refusals for outside the project, a bad range, a stale buffer,
  bad names and no server.
- The ignored real-Phpactor test covers definition, references and a
  rename and back across 3 files.
- Vitest `ui/tests/nav/`.

Live (Phpactor 2026.06.25.0, Windows, port 7935, tick on):
- definition 93 ms cold / 7-18 ms warm
- references ~140 ms
- prepareRename ~11 ms
- rename 28-59 ms
- index follows written files in 140 ms
- Phpactor 57 MB working set, ~1.6% of a core while ticking idle

Gate: 13 steps, 197 s, Vitest 484 + 1 skipped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 18:50:15 +02:00

240 lines
13 KiB
JSON

{
"app.statusBar.version": "{name} {version}",
"command.editor.complete": "Complete Code",
"command.editor.parameterInfo": "Parameter Info",
"command.editor.quickDocumentation": "Quick Documentation",
"command.editor.reveal": "Reveal Cursor in Editor",
"command.find.open": "Find in Files…",
"command.goto.classOpen": "Go to Class…",
"command.goto.fileOpen": "Go to File…",
"command.goto.symbolOpen": "Go to Symbol…",
"command.key.alt": "Alt",
"command.key.cmd": "Cmd",
"command.key.ctrl": "Ctrl",
"command.key.option": "Option",
"command.key.shift": "Shift",
"command.menu.open": "Open Main Menu",
"command.palette.open": "Command Palette",
"command.problems.open": "Problems",
"command.settings.open": "Settings…",
"command.terminal.open": "Terminal",
"command.unavailable": "{command} cannot run right now",
"command.view.toggleProjectTree": "Show or Hide Project",
"command.view.toggleStructure": "Show or Hide Structure",
"common.cancel": "Cancel",
"common.close": "Close",
"common.dismiss": "Dismiss",
"common.dontSave": "Don't Save",
"common.error.unexpectedResult": "unexpected result of {command}",
"common.save": "Save",
"common.toolWindow.bottomTabs": "Bottom tool windows",
"common.toolWindow.collapse": "Collapse {title}",
"common.toolWindow.expand": "Expand {title}",
"common.toolWindow.hide": "Hide {title}",
"common.toolWindow.resize": "Resize {title}",
"common.toolWindow.show": "Show {title}",
"common.toolWindow.stripe": "Tool windows",
"editor.assist.kind.class": "Class",
"editor.assist.kind.color": "Colour",
"editor.assist.kind.constant": "Constant",
"editor.assist.kind.constructor": "Constructor",
"editor.assist.kind.enum": "Enum",
"editor.assist.kind.enumMember": "Enum case",
"editor.assist.kind.event": "Event",
"editor.assist.kind.field": "Field",
"editor.assist.kind.file": "File",
"editor.assist.kind.folder": "Folder",
"editor.assist.kind.function": "Function",
"editor.assist.kind.interface": "Interface",
"editor.assist.kind.keyword": "Keyword",
"editor.assist.kind.method": "Method",
"editor.assist.kind.module": "Namespace",
"editor.assist.kind.operator": "Operator",
"editor.assist.kind.property": "Property",
"editor.assist.kind.reference": "Reference",
"editor.assist.kind.snippet": "Snippet",
"editor.assist.kind.struct": "Structure",
"editor.assist.kind.text": "Text",
"editor.assist.kind.typeParameter": "Type parameter",
"editor.assist.kind.unit": "Unit",
"editor.assist.kind.value": "Value",
"editor.assist.kind.variable": "Variable",
"editor.assist.signature.count": "{index} of {count}",
"editor.closePrompt.question": "Save changes to {name} before closing?",
"editor.notice.changedOnDisk": "{name} changed on disk. Your unsaved changes are kept; saving overwrites the file.",
"editor.notice.removedOnDisk": "{name} was deleted on disk. Your text is kept; saving writes it again.",
"editor.reveal.invalidParams": "editor.reveal needs a path (string), line and column (numbers)",
"editor.reveal.openFailed": "could not open {path}",
"editor.saveFailed": "save failed",
"editor.tabs.close": "Close {name}",
"editor.tabs.label": "Editor tabs",
"editor.tabs.unsaved": "unsaved changes",
"find.action.search": "Search",
"find.exclude.label": "Exclude files",
"find.exclude.placeholder": "Exclude, e.g. *.min.js, var/**",
"find.include.label": "Include files",
"find.include.placeholder": "Include, e.g. *.php, src/**",
"find.option.caseSensitive": "Match case",
"find.option.regex": "Regular expression",
"find.option.wholeWord": "Whole words",
"find.query.label": "Text to find",
"find.query.placeholder": "Find in files",
"find.results.label": "Search results",
"find.status.cancelled": "Cancelled · {matches} matches in {files} files",
"find.status.done": "{matches} matches in {files} files · {ms} ms",
"find.status.idle": "Type a text and press Enter",
"find.status.none": "No matches",
"find.status.running": "Searching… {matches} matches in {files} files",
"find.status.truncated": "Stopped at {matches} matches; narrow the query or the files to see the rest",
"find.toolWindow.title": "Find",
"goto.empty.noMatches": "Nothing matches",
"goto.empty.prompt": "Type a name",
"goto.indexing": "Indexing… results may be incomplete",
"goto.indexingProgress": "Indexing {done} of {total} files… results may be incomplete",
"goto.label": "Go to",
"goto.library": "library",
"goto.mode.class": "Classes",
"goto.mode.file": "Files",
"goto.mode.symbol": "Symbols",
"goto.modes": "What to find",
"goto.placeholder.class": "Class, interface, trait or enum name",
"goto.placeholder.file": "File name or path",
"goto.placeholder.symbol": "Function, method, property or constant; Class::member",
"goto.switchHint": "Tab switches",
"menu.button": "Main menu",
"menu.group.edit": "Edit",
"menu.group.file": "File",
"menu.group.go": "Go",
"menu.group.help": "Help",
"menu.group.view": "View",
"menu.label": "Main menu",
"nav.definition.none": "No definition found for {name}",
"nav.picker.line": "line {line}",
"nav.picker.title": "Definitions of {name}",
"nav.references.failed": "Find References failed: {message}",
"nav.references.label": "References",
"nav.references.none": "No references to {name} found",
"nav.references.searching": "Searching references to {name}…",
"nav.references.summary": "{uses} references to {name} in {files} files",
"nav.references.title": "References",
"nav.rename.busy": "Renaming…",
"nav.rename.counting": "Counting uses…",
"nav.rename.label": "New name for {name}",
"nav.rename.notHere": "There is nothing to rename at the cursor",
"nav.rename.preview": "Changes {uses} uses in {files} files. Enter to rename, Escape to cancel",
"notification.close": "Close notification",
"notification.command.failed": "{command} failed: {message}",
"notification.lsp.failed": "The PHP language server stopped: {reason}. Run Restart PHP Language Server to try again.",
"notification.lsp.renamed": "Renamed to {name}: {edits} changes in {files} files ({written} closed files saved)",
"notification.project.notLocal": "The chosen folder is not on this computer: {reason}",
"notification.project.openFailed": "Cannot open {path}: {reason}",
"notification.project.unsavedChanges": "Cannot open {path} while {what} has unsaved changes. Save or close it first.",
"notification.recovery.corrupt": "Skipped an unreadable recovery file ({file}): {reason}",
"notification.recovery.unavailable": "Could not read the recovery journal: {reason}",
"notification.recovery.writeFailed": "Could not keep a recovery copy of {path}: {reason}",
"notification.save.failed": "{name} could not be saved: {reason}",
"notification.settings.corrupt": "Your settings file could not be read ({reason}). It was moved to {backup} and the defaults are used.",
"notification.settings.corruptNotMoved": "Your settings file could not be read ({reason}) or moved aside ({error}). The defaults are used and changes are not saved.",
"notification.settings.unavailable": "Settings cannot be loaded ({error}). The defaults are used and changes are not saved.",
"notification.stack.label": "Notifications",
"notification.stack.more": "+{count} more",
"notification.toolchain.downloadDone": "Phpactor {version} is ready, downloaded and verified in {seconds} s.",
"notification.toolchain.downloadFailed": "Phpactor {version} could not be downloaded: {reason}",
"notification.toolchain.downloadStarted": "Downloading Phpactor {version} from GitHub for PHP language features…",
"notification.toolchain.phpMissing": "PHP language features need PHP {min} or newer: {reason}. Install PHP or set the PHP executable in Settings.",
"notification.vfs.pumpFailed": "Applying changes on disk failed: {reason}",
"notification.watch.failed": "Lutra stopped watching the project for changes on disk: {reason}",
"palette.label": "Command palette",
"palette.noMatches": "No matching commands",
"palette.placeholder": "Type a command name",
"problems.empty": "No problems found in open files",
"problems.file.count": "{count} problems",
"problems.list.label": "Problems of the project",
"problems.lsp.failed": "Phpactor stopped: {message}",
"problems.lsp.restarting": "Phpactor is restarting: {message}",
"problems.lsp.starting": "Phpactor is starting…",
"problems.lsp.stopped": "No PHP language server is running. It starts when PHP and Phpactor are available.",
"problems.position": "line {line}, column {column}",
"problems.severity.error": "Error",
"problems.severity.hint": "Hint",
"problems.severity.info": "Information",
"problems.severity.warning": "Warning",
"problems.summary": "{errors} errors, {warnings} warnings, {infos} other",
"problems.toolWindow.title": "Problems",
"project.empty.noFolder": "No folder is open.",
"project.openFolder": "Open Folder…",
"project.toolWindow.title": "Project",
"project.tree.loading": "Loading…",
"project.tree.truncated": "Listing truncated: more entries than can be shown",
"recovery.dialog.changedOnDisk": "The file changed on disk since then",
"recovery.dialog.discard": "Discard",
"recovery.dialog.failed": "{path} could not be restored: {message}",
"recovery.dialog.intro": "Lutra stopped before these files were saved. Restore your unsaved changes?",
"recovery.dialog.restoreAll": "Restore All",
"recovery.dialog.restoreSelected": "Restore Selected",
"recovery.dialog.savedAt": "Saved {time}",
"recovery.dialog.title": "Unsaved changes found",
"settings.appearance.theme.description": "Colours of the whole window. System follows the light or dark preference of your operating system.",
"settings.appearance.theme.label": "Theme",
"settings.appearance.theme.value.lutraDark": "Lutra Dark",
"settings.appearance.theme.value.lutraLight": "Lutra Light",
"settings.appearance.theme.value.system": "Same as system",
"settings.dialog.loadFailed": "Settings could not be loaded: {message}",
"settings.dialog.noMatches": "No settings match your search",
"settings.dialog.reset": "Reset to default",
"settings.dialog.resetLabel": "Reset {name} to default",
"settings.dialog.search": "Search settings",
"settings.dialog.sections": "Settings sections",
"settings.dialog.title": "Settings",
"settings.editor.autosave.idleSeconds.description": "Save changed files after this many seconds without typing. 0 turns idle saving off.",
"settings.editor.autosave.idleSeconds.label": "Autosave after idle (seconds)",
"settings.editor.autosave.onBlur.description": "Save changed files when the Lutra window loses focus, for example when you switch to a browser or a terminal.",
"settings.editor.autosave.onBlur.label": "Autosave when leaving the window",
"settings.editor.autosave.onTabSwitch.description": "Save changed files when you switch to another editor tab.",
"settings.editor.autosave.onTabSwitch.label": "Autosave on tab switch",
"settings.editor.fontSize.description": "Size of the text in the editor, in pixels.",
"settings.editor.fontSize.label": "Editor font size",
"settings.error.int": "Enter a whole number",
"settings.error.intRange": "Enter a whole number from {min} to {max}",
"settings.php.executable.description": "Path to the PHP executable (8.2 or newer) that runs Phpactor. Leave empty to use php from PATH.",
"settings.php.executable.label": "PHP executable",
"settings.phpactor.autoDownload.description": "When a PHP project opens and Phpactor is missing, download the pinned Phpactor release from GitHub and check its SHA-256. This is the only network access Lutra makes.",
"settings.phpactor.autoDownload.label": "Download Phpactor automatically",
"settings.phpactor.path.description": "Path to your own phpactor.phar. Leave empty to use the pinned, verified Phpactor that Lutra downloads.",
"settings.phpactor.path.label": "Phpactor PHAR",
"settings.section.appearance": "Appearance",
"settings.section.editor": "Editor",
"settings.section.php": "PHP",
"settings.ui.language.description": "Language of the interface. More languages follow.",
"settings.ui.language.label": "Language",
"settings.ui.language.value.en": "English",
"structure.empty.noFile": "Open a file to see its structure",
"structure.empty.none": "No declarations in this file",
"structure.empty.parsing": "Reading the file…",
"structure.empty.tooLarge": "This file is too large to show its structure",
"structure.kind.class": "Class",
"structure.kind.constant": "Constant",
"structure.kind.enum": "Enum",
"structure.kind.enumCase": "Enum case",
"structure.kind.function": "Function",
"structure.kind.interface": "Interface",
"structure.kind.method": "Method",
"structure.kind.namespace": "Namespace",
"structure.kind.property": "Property",
"structure.kind.trait": "Trait",
"structure.toolWindow.title": "Structure",
"structure.tree.label": "Declarations of the file",
"terminal.error.badAnswer": "The engine answered without a terminal id",
"terminal.error.create": "Cannot start a terminal: {message}",
"terminal.exited.closed": "Terminal closed",
"terminal.exited.code": "Process exited with code {code}",
"terminal.new": "New terminal",
"terminal.tab.close": "Close {title}",
"terminal.tab.exited": "{title} (ended)",
"terminal.tab.first": "Local",
"terminal.tab.numbered": "Local ({n})",
"terminal.tabs.label": "Terminals",
"terminal.toolWindow.title": "Terminal",
"theme.lutraDark": "Lutra Dark",
"theme.lutraLight": "Lutra Light"
}