Skip to content

Allow custom prefix separator #4085

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

Merged
merged 2 commits into from
Mar 15, 2021
Merged

Allow custom prefix separator #4085

merged 2 commits into from
Mar 15, 2021

Conversation

thisisdano
Copy link
Contributor

Now you can use a custom prefix separator. Some systems don't parse the : separator character in the default USWDS responsive and state prefixes like tablet:margin-x-2. Now you can set the value of $theme-prefix-separator to output any character or string between the prefix and the main class.

Note that the default needs two \ characters to properly output the escaped : character in the final CSS.

$theme-prefix-separator: "\\:",
ex: .tablet\:margin-x-2
      <div class="margin:x-2">

$theme-prefix-separator: "--",
ex: .tablet--margin-x-2
      <div class="margin--x-2">

Fixes #3045

@thisisdano thisisdano requested a review from mejiaj March 15, 2021 03:17
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