-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Custom HTML tag loses end angle bracket on delete #87959
Comments
Duplicate of #87067. Sorry about that. |
@octref Cool. I'm glad my edit stuff is already getting discussed in another thread, the original issue isn't getting discussed there. If I remove the edit sections from my OP, will you reopen this issue and remove the "duplicate" tag? |
@rickmacgillis That's the expected behavior of multiple cursors. You have two cursors. Pressing delete would delete a character after each cursor. |
@octref So that's the intended behavior? |
This is consistent with all multi-cursor actions: With the current implementation, fixing this will only add more "magic" to the whole mirror cursor, and makes it less understandable. You can follow #88424, which would eliminate this problem once implemented. I can't make the editor delete only one character when two cursors are present. Other people will be unhappy. |
@octref It doesn't matter to me who's name is attached to the ticket that got it fixed. I'm only interested in having it fixed. So, if your ticket stops the bug (yes, it's a bug) then I'm happy with it. |
Steps to Reproduce:
<app-server-element *ngFor="let serverElement of serverElements"></app-server-element>
<app-server-element
and you should see VS Code highlight all of the angle brackets for that tag.<app-server-element*ngFor="let serverElement of serverElements"></app-server-element
<-- Notice the lack of an angle bracket here.The reason why this bug is so important is that when I refactor long lines of HTML code, I usually start by deleting the space after the tag name, then I hit enter to move the attribute to a new line. I repeat that process for each attribute. I often get browser errors because the ending angle bracket gets removed, and I have to manually add it back.
Does this issue occur when all extensions are disabled?: Yes
EDIT:
Just a quick follow up on this topic: there's also a related bug that I want to address. It also relates to improper parsing of a custom HTML tag. When you go to add an attribute to the custom HTML element, it adds the attribute inside of the end tag as well.
To reproduce:
<app-odd></app-odd>
.<app-odd [number]="incrementTick"></app-odd>
<app-odd [number]="incrementTick"></app-odd [number]="incrementTick">
EDIT 2:
This issue is also present when pasting in an attribute on a NON-custom HTML element. For example, the creation of
<p *ngSwitchCase="10">Value is 10</p *ngSwitchCase="10">
The text was updated successfully, but these errors were encountered: