-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
Linked edits (rename on type for matching HTML tags) do not work when editing HTML markup inside .php files. When renaming an opening or closing HTML tag, the counterpart tag is not updated simultaneously.
This feature works as expected in .html files, but fails in .php files even when the cursor is within a purely HTML context (e.g., not inside a PHP block).
Steps to Reproduce
- Enable Linked edits option in settings
- Open a
.phpfile containing HTML markup - Place the cursor on an HTML opening tag (e.g.,
<div>) - Edit the tag name
- Expected: the matching closing tag (
</div>) updates in sync - Actual: only the edited tag changes — the counterpart is not updated
Expected Behavior
Linked editing should work for HTML tags within .php files, consistent with behavior in .html files.
Possible Cause
The PHP language extension may not be registering linked edit range support for embedded HTML regions. The language server or Tree-sitter grammar may need to surface linkedEditingRange for HTML nodes within the PHP syntax tree.
Environment
- Zed version:
0.226.4 - OS:
macOS - PHP extension version:
0.4.10
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels