rofrischmann/fela

View on GitHub
packages/fela-dom/src/server/__tests__/__snapshots__/renderToMarkup-test.js.snap

Summary

Maintainability
Test Coverage
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`Rendering to HTML markup should add custom style attributes 1`] = `
"<style type=\"text/css\" data-fela-rehydration=\"1\" data-fela-type=\"STATIC\" none=\"abc\">
    * {
        box-sizing: border-box
    }
</style>
<style type=\"text/css\" data-fela-rehydration=\"1\" data-fela-type=\"RULE\" none=\"abc\">
    .a {
        color: red
    }
</style>"
`;

exports[`Rendering to HTML markup should correctly sort rules 1`] = `
"<style type=\"text/css\" data-fela-rehydration=\"3\" data-fela-type=\"RULE\">
    .a:hover {
        color: red
    }

    .c:hover {
        color: #000
    }

    .b:active {
        color: #fff
    }
</style>"
`;

exports[`Rendering to HTML markup should return a single HTML markup string 1`] = `
"<style type=\"text/css\" data-fela-rehydration=\"6\" data-fela-type=\"STATIC\">
    * {
        box-sizing: border-box
    }

    div {
        display: flex
    }
</style>
<style type=\"text/css\" data-fela-rehydration=\"6\" data-fela-type=\"RULE\">
    .a {
        color: red
    }
</style>
<style type=\"text/css\" data-fela-rehydration=\"6\" data-fela-type=\"RULE\" data-fela-support=\"true\">
    @supports (display:flex) {
        .b {
            color: yellow
        }
    }

    @supports (display:grid) {
        .c {
            color: brown
        }
    }
</style>
<style type=\"text/css\" data-fela-rehydration=\"6\" data-fela-type=\"RULE\" media=\"(min-height: 300px)\">
    .d {
        color: blue
    }
</style>
<style type=\"text/css\" data-fela-rehydration=\"6\" data-fela-type=\"RULE\" data-fela-support=\"true\" media=\"(min-height: 300px)\">
    @supports (display:flex) {
        .e {
            color: green
        }
    }

    @supports (display:grid) {
        .f {
            color: black
        }
    }
</style>"
`;