Open Bug 1836873 Opened 2 years ago Updated 2 months ago

[META] Support CSS Nesting within Rules panel

Categories

(DevTools :: Inspector: Rules, task, P3)

task

Tracking

(Not tracked)

People

(Reporter: sebo, Unassigned)

References

(Depends on 6 open bugs, Blocks 1 open bug, )

Details

(Keywords: dev-doc-needed, meta)

Attachments

(2 files)

The Rules panel should support nested CSS rules. I.e. give some hints to authors regarding nested selectors.

Sebastian

We should also make sure that the "selector highlighter" button works as expected with nested rules

Emilio, do you have an ETA for when nesting is going to ride the train? It would be helpful for us to know so we can plan DevTools work

Flags: needinfo?(emilio)

I hope to finish the implementation within the next month or two... I'm happy to help out as needed with DevTools of course :)

Flags: needinfo?(emilio)

(In reply to Emilio Cobos Álvarez (:emilio) from comment #3)

I hope to finish the implementation within the next month or two... I'm happy to help out as needed with DevTools of course :)

okay great, so I guess that's giving us some time to properly think of how we want to do things in the inspector and fix the various issues nesting is going to bring

at the moment, nested rules are viewed as regular properties, we may have a simple bug to already filter those out, to start with

Here's a screenshot showing what other browser vendors are doing

Chrome is only showing the rule actual selector, and hovering the & character will display the selector tree in a tooltip, but on a single line, as if all selectors are separated with a space.

Safari is showing the entire "selector tree", including nested at rules. You can also edit each selector individually, and this will update the right selector rule

From an authoring standpoint, I feel like Safari's approach is nicer as you can see everything at once, and it also fits what we do with nested rules at the moment.
We might want to add some styling to emphasise the nesting a bit, but that's not what we do at the moment with at-rules, so we can do that in a separate bug.

Depends on: 1835062
Depends on: 1838011
Depends on: 1838012
Depends on: 1838026
Type: enhancement → task
Depends on: 1838163, 1838164
Keywords: meta
Summary: Support CSS Nesting within Rules panel → [META] Support CSS Nesting within Rules panel
Depends on: 1838179
Depends on: 1838217
Depends on: 1838626
Depends on: 1838802
Depends on: 1838803
Depends on: 1838806
Depends on: 1839434
Depends on: 1839575
Depends on: 1840116
Depends on: 1844446
Depends on: 1844499

Because this is the actual release in which nesting is supported by default, DevTools support for it should be mentioned in https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Releases/117.

Sebastian

Keywords: dev-doc-needed
Depends on: 1865042
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: