-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Conversation
To @larz0 to review the UX and make suggestions. |
This is awesome @sathyamoorthi. I'm wondering if we could make it so that it highlights the end tag when the cursor is anywhere within > and < so that we don't have to consciously target the tag name when the start tag is long due to attributes. Thoughts? |
@larz0 ahhh. yes. let me check this. |
@larz0 Committed necessary changes to CodeMirror. Please check now. |
@sathyamoorthi the UX is much better now, thanks. We'll get someone to review the code. |
@sathyamoorthi @larz0 can we highlight both tags? I find it a little unbalanced if we just highlight the one. We already highlight open and close brace and other editors highlight open and close tags. |
@JeffryBooher Sounds good. |
@JeffryBooher See this pull request codemirror/codemirror5#1653. @marijnh commented. "I prefer the way things look when only the 'other' tag is highlighted, so I'm going to keep the So i could ask him or gave pull request to CodeMirror to add an option to highlight both tags OR i can customize that add-on for brackets. Need your opinion. |
@njx what do you think? Larz and I agree that it looks more balanced with both open and close tags highlighted but which option do we go with? I'm not as familiar with how code-mirror works and the politics around changing the code-mirror code base but it sounds like we may have to do the work ourselves. @sathyamoorthi already has some of the code done (sans the performance enhancement) it would be pretty straight forward to just take that change. I guess the other option is that we fork the addon and create a new one with a different name and it's never committed back to code-mirror. |
Maybe Marijnh would accept the change it was made as an option on the addon, and not active by default? Which would leave the behavior as it is by default and add the one we desire with an additional option. Might be worth asking him first. |
@TomMalbran @JeffryBooher yes. i prefer this. Let me ask him in codemirror discussion. He is nice guy, he'll do it. I hope. |
@sathyamoorthi excellent! |
@marijnh accepted this patch. @JeffryBooher @larz0 I committed an option to highlight both tags. Please check. |
Nominating for Sprint 31 |
@sathyamoorthi can you merge master into this branch so I can test it with the latest codemirror? |
@sathyamoorthi disregard. I just merged your changes into a new branch and merged master in to that. Looks good! |
Merging this into master. Looks like the travis build error is benign. |
Tag Highlight very important and useful Extension... |
Tag highlight functionality added.
_some tracks_
Google Group Discussion
Trello Card
#3069
Code mirror's matchTags extension only highlight the other tag. In the above screenshot, i put cursor on start tag <form, but it only highlights the other tag </form>. If you want to to highlight both tags, i can rewrite this extension for brackets.