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

Properly attach nested selectors to CSV parent selector #136

Merged
merged 2 commits into from
Mar 23, 2023
Merged

Properly attach nested selectors to CSV parent selector #136

merged 2 commits into from
Mar 23, 2023

Conversation

brandongregoryscott
Copy link
Contributor

Resolves the issue described in segmentio/evergreen#1622

Essentially, when providing a CSV selector with nested selectors, the nested selectors would only be added once to the end of the parent selector string, whereas we would expect the csv to be expanded and each individual selector has the nested one appended.

<Box
  selectors={{
    '&[aria-current="page"],&[aria-selected="true"]': {
      "&:before": {
        transform: "scaleY(1)",
      },
    },
  }}
/>
-.ub-tfrm_qu4iyp_fiauus[aria-current="page"], .ub-tfrm_qu4iyp_fiauus[aria-selected="true"]:before {
+.ub-tfrm_qu4iyp_fiauus[aria-current="page"]:before, .ub-tfrm_qu4iyp_fiauus[aria-selected="true"]:before {
  transform: scaleY(1);
}

…arated parent selector instead of just on the last entry
@brandongregoryscott brandongregoryscott merged commit d41c0a3 into segmentio:master Mar 23, 2023
@brandongregoryscott brandongregoryscott deleted the selector-expansion-with-nested branch March 23, 2023 14:46
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

Successfully merging this pull request may close these issues.

2 participants