Unverified Commit 78aefee1 authored by magic-akari's avatar magic-akari Committed by GitHub

fix(swc/emotion): Correct the `SPACE_AROUND_COLON` regex (#39710)



## Bug

- [x] fixes #39672 
- [x] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`
parent 9c416341
...@@ -82,7 +82,7 @@ static EMOTION_OFFICIAL_LIBRARIES: Lazy<Vec<EmotionModuleConfig>> = Lazy::new(|| ...@@ -82,7 +82,7 @@ static EMOTION_OFFICIAL_LIBRARIES: Lazy<Vec<EmotionModuleConfig>> = Lazy::new(||
}); });
static SPACE_AROUND_COLON: Lazy<Regex> = static SPACE_AROUND_COLON: Lazy<Regex> =
Lazy::new(|| Regex::new(r"\s*(?P<s>[:|;|,|\{,\}])\s*").unwrap()); Lazy::new(|| Regex::new(r"\s*(?P<s>[:;,\{,\}])\s*").unwrap());
#[derive(Debug, Clone, Serialize, Deserialize)] #[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")] #[serde(rename_all = "camelCase")]
......
import styled from '@emotion/styled'
const SelectedComponent = styled.p`
color: red;
&:after {
content: ' | ';
}
`
import styled from '@emotion/styled';
const SelectedComponent = /*#__PURE__*/ styled("p", {
target: "ekie5mj0",
label: "SelectedComponent"
})("color:red;&:after{content:' | ';}", "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5wdXQudHMiLCJzb3VyY2VzIjpbImlucHV0LnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJ1xuXG5jb25zdCBTZWxlY3RlZENvbXBvbmVudCA9IHN0eWxlZC5wYFxuICBjb2xvcjogcmVkO1xuXG4gICY6YWZ0ZXIge1xuICAgIGNvbnRlbnQ6ICcgfCAnO1xuICB9XG5gXG4iXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBRTBCIn0= */");
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment