This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 268059 - Navigator shows as class which is not there
Summary: Navigator shows as class which is not there
Status: NEW
Alias: None
Product: web
Classification: Unclassified
Component: HTML Navigator (show other bugs)
Version: 8.2
Hardware: PC Other
: P3 normal (vote)
Assignee: Milutin Kristofic
Depends on:
Reported: 2016-09-16 09:27 UTC by Christian Lenz
Modified: 2016-09-16 09:36 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:

NetBeans HTML Navigator problem (48.88 KB, image/png)
2016-09-16 09:29 UTC, Christian Lenz
Webstorm structure window (7.71 KB, image/png)
2016-09-16 09:36 UTC, Christian Lenz

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Lenz 2016-09-16 09:27:29 UTC
As you can see in my screenshot, I have a tpl.html file which uses Angular for placeholder etc. And if you have a look inside the navigator, the css->classes shows .{ as a class, which is not there. When I search for class it has 5 matches but in the navigator there is as 6th item. I not expect more classes than it is shown inside the html file.

Double click on CSS id or class is not working, navigator not jumps to it. For ID it should be easy to jump to it, because ID should only available one time. Class is not so easy, maybe jump to the first one? Or show all classes, doesn't matter whether there are more than one class with the same name or not. I think the navigator expects classes in the same file to jump to it but as you can see there is only the usage of the class and not the declaration, this was handled in a separate scss file.

I hope the navigator will not split into other developers for js, css and html, because as you can see the JS part, there is some missing. First it shows that label is of type listModeVm.listModes which is kind of ok I think, but what is with mode? First mode has no type but mode relects to label, active, description. This is my JS object in the JS file:

var listModes = {
   VALUE1: {
      'label': 'translation',
      'description': 'translation',
      'active': true
   VALUE2: {
      'label': 'translation',
      'description': 'translation',
      'active': false
   VALUE3: {
      'label': 'translation',
      'description': 'translation',
      'active': true

so I expect that mode is type of object for example and I miss the values on it, like label, description, active in the navigator so that I can jump to it too.

And what is missing to first the overall vm object called listModeVm which has properties like: listmodes, onListModeChange(), and listMode.



P.S. I tested it with NB 8.2 RC so I don't know whether this is still a problem in 8.1.
Comment 1 Christian Lenz 2016-09-16 09:29:27 UTC
Created attachment 162075 [details]
NetBeans HTML Navigator problem
Comment 2 Christian Lenz 2016-09-16 09:34:09 UTC
I had a look in WebStorm to see what they will show.

First they only show HTML or the DOM structure so I like the NB most, because here is Angular inside and NB resolved them too, so very nice work first.

Second, they don't have a separate classes section because all classes and IDs are right after the HTML elements like div#myId or div.myClass, which I prefer more because it doesn't make sense in this context to separate it, first there are only id and class usages and no declarations and second the classes and ids depends on the tags and make no sense to separate it from them. I know that HTML shows id=myId but please use the selectors for that only # and . is needed, not more. Developers knows what is that.

Other thing what is missing is the text inside the tags. WebStorm shows {{mode.description| translate}} which netbeans shows not. Please add it to the same.

If you want me to create separate tickets or each thing, please let me know that and what do you want to see in a separate ticket thx.

See the screenshot of WebStorm for more info.
Comment 3 Christian Lenz 2016-09-16 09:36:05 UTC
Created attachment 162076 [details]
Webstorm structure window