Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Direct child selector (">") is ignored #272

Open
skrhlm opened this issue May 12, 2022 · 0 comments
Open

Direct child selector (">") is ignored #272

skrhlm opened this issue May 12, 2022 · 0 comments

Comments

@skrhlm
Copy link

skrhlm commented May 12, 2022

When inlining CSS using a direct child selector all child elements are affected by the styling as if the ">" was not there.

example:

css:

.pad-t-12 > td {
    padding-top: 12px;
}

html:

<table>
    <tr class="pad-t-12">
        <td>
            <table>
                 <tr>
                     <td></td>
                 </tr>
            </table>
        </td>
    </tr>
</table>

results in:

<table>
    <tr>
        <td style="padding-top:12px;">
            <table>
                 <tr>
                      <td style="padding-top:12px;"></td>
                 </tr>
            </table>
        </td>
    </tr>
</table>

Desired behavior:

<table>
    <tr>
        <td style="padding-top:12px;">
            <table>
                 <tr>
                      <td></td>
                 </tr>
            </table>
        </td>
    </tr>
</table>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant