Skip to content

Nested CSS #136

@lasse333

Description

@lasse333

Are you guys aware of nested css

here is some documentation: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_nesting/Using_CSS_nesting

this can be converted

/* base.css */
body {
  background: url(../images/Website_background.webp);
  background-repeat: repeat!important;
  margin: auto;                                                                   /* classless.css */
  max-width: 50rem;
  padding: 2rem 0.5rem 0;
  overflow-x: hidden;
}

body > div:not(.tox) {
    position: fixed!important;
    width: 100%!important;
    height: 100%!important;
    left: 0!important;
    top: 0!important;
    margin: 0!important;
}
body > div:not(.tox) > div {
    position: fixed!important;
    width: 100%!important;
    height: 100%!important;
    left: 0!important;
    top: 0!important;
    margin: 0!important;
}

to this

/* how base.css could look */
body {
  background: url(../images/Website_background.webp);
  background-repeat: repeat!important;
  margin: auto;                                                                   /* classless.css */
  max-width: 50rem;
  padding: 2rem 0.5rem 0;
  overflow-x: hidden;

    & > div:not(.tox) {
        position: fixed!important;
        width: 100%!important;
        height: 100%!important;
        left: 0!important;
        top: 0!important;
        margin: 0!important;

        & > div {
            position: fixed!important;
            width: 100%!important;
            height: 100%!important;
            left: 0!important;
            top: 0!important;
            margin: 0!important;
        }
    }
}

Metadata

Metadata

Labels

📩 EnhancementNew feature or request💻FrontendIssues connected to front-end features.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions