rsnext/packages/next-swc/crates/styled_components/tests/fixtures/add-identifier-and-display-name/output.js
Donny/강동윤 16f7084e7f
feat(next-swc): Update swc crates (#35996)
* Move

* Adjust

* publish = false

* Tree

* Move tests

* fixup

* Split `emotion`

* Split `styled_jsx`

* Split `styled_jsx`

* fmt

* `--fix`

* clippy

* Update crates

* fixup

* publish

* Bump

* Rename

* authors

* Update

* More update

* Oh

* Update test refs

* Update test refs

* Update again

* Fix
2022-04-11 11:59:16 +02:00

71 lines
1.8 KiB
JavaScript

import styled from 'styled-components';
const Test = styled.div.withConfig({
displayName: "Test",
componentId: "sc-e0d5b7ad-0"
})`
width: 100%;
`;
const Test2 = true ? styled.div.withConfig({
displayName: "Test2",
componentId: "sc-e0d5b7ad-1"
})`` : styled.div.withConfig({
displayName: "Test2",
componentId: "sc-e0d5b7ad-2"
})``;
const styles = {
One: styled.div.withConfig({
displayName: "One",
componentId: "sc-e0d5b7ad-3"
})``
};
let Component;
Component = styled.div.withConfig({
displayName: "Component",
componentId: "sc-e0d5b7ad-4"
})``;
const WrappedComponent = styled(Inner).withConfig({
displayName: "WrappedComponent",
componentId: "sc-e0d5b7ad-5"
})``;
const WrappedComponent2 = styled.div.withConfig({
displayName: "WrappedComponent2",
componentId: "sc-e0d5b7ad-6"
})({});
const WrappedComponent3 = styled(Inner).withConfig({
displayName: "WrappedComponent3",
componentId: "sc-e0d5b7ad-7"
})({});
const WrappedComponent4 = styled(Inner).attrs(()=>({
something: 'else'
})
)({});
const WrappedComponent5 = styled.div.attrs(()=>({
something: 'else'
})
)({});
const WrappedComponent6 = styled.div.attrs(()=>({
something: 'else'
})
).withConfig({
displayName: "WrappedComponent6",
componentId: "sc-e0d5b7ad-8"
})``;
const WrappedComponent7 = styled.div.withConfig({
shouldForwardProp: ()=>{},
displayName: "WrappedComponent7",
componentId: "sc-e0d5b7ad-9"
})({});
const WrappedComponent8 = styled.div.withConfig({
shouldForwardProp: ()=>{}
}).attrs(()=>({
something: 'else'
})
)({});
const WrappedComponent9 = styled.div.attrs(()=>({
something: 'else'
})
).withConfig({
shouldForwardProp: ()=>{},
displayName: "WrappedComponent9",
componentId: "sc-e0d5b7ad-10"
})({});