-
#2929
13afe030
Thanks @Andarist! - Updated the underlying parser (stylis). -
Updated dependencies [
c02b1214
]:- @emotion/serialize@1.1.1
- #2858
005e211d
Thanks @Andarist! - Fixed an issue in the styles minifier that caused interpolations to be sometimes included more than once in the output.
- #2819
bbad8c79
Thanks @nicksrandall! -exports
field has been added to thepackage.json
manifest. It limits what files can be imported from a package but we've tried our best to allow importing all the files that were considered to be a part of the public API.
- Updated dependencies [
bbad8c79
]:- @emotion/hash@0.9.0
- @emotion/memoize@0.8.0
- @emotion/serialize@1.1.0
- #2799
5b99a849
Thanks @Andarist! - Fixed an issue with the lack of/*#__PURE__*/
annotations before styled calls transformed from tagged template expressions.
-
#2721
ae0f650b
Thanks @Andarist! - Fixed an issue in the minifying logic that could remove rules with the same context values as their parent rules. Like in the example below:styled.div` > div { color: blue; > div { color: hotpink; } } `
- #2585
b830c7dc
Thanks @Andarist! - Fixed label extraction crashing in some cases involving variable declarations with array and object patterns.
- #2585
b830c7dc
Thanks @kddc, @Andarist! - Improved label extraction for named function expressions and anonymous functions used as object property values.
- #2602
b02f349d
Thanks @Andarist! - Fixed an issue with styled transformer sometimes not using the used local name for the imported named export when used withimportMap
.
- #2590
1554a7e2
Thanks @Andarist! - Upgraded and pinned the version of Stylis - the CSS parser that Emotion uses under the hood.
-
36a51c27
#2340 Thanks @Andarist! - Fixed a crash when extracting labels from object properties with string literal keys in certain situations. -
Updated dependencies [
662f0e0f
,830dd0e6
]:- @emotion/serialize@1.0.2
c9b57f36
#2157 Thanks @Andarist! - Fixed an issue withstyled
transformer not respectingautoLabel: 'dev-only'
setting.
-
de378ab8
#2147 Thanks @macalinao! - Fixed an issue with template strings minifier crashing on two consecutive interpolations without any meaningful string in between them. -
Updated dependencies [
ee6a673f
]:- @emotion/memoize@0.7.5
b8476e08
#1675 Thanks @mitchellhamilton! - Renamebabel-plugin-emotion
to@emotion/babel-plugin
. Please replace"plugins": ["emotion"]
with"plugins": ["@emotion"]
in your Babel config.
-
c5b12d90
#1220 Thanks @mitchellhamilton! - Removed support for theinstances
option, any usage of it should be replaced with theimportMap
option
-
c7850e61
#1656 Thanks @Andarist! -autoLabel
option no longer is a simple boolean. Instead we accept now 3 values:dev-only
(the default),always
andnever
.Each possible value for this option produces different output code:
- with
dev-only
we optimize the production code, so there are no labels added there, but at the same time we keep labels for development environments, - with
always
we always add labels when possible, - with
never
we disable this entirely and no labels are added.
- with
b7d21373
#2080 Thanks @Andarist! -cssPropOptimization
defaults now totrue
regardless of the@emotion/react
import presence.
-
c5b12d90
#1220 Thanks @mitchellhamilton! - Added theimportMap
option which allows you to tell@emotion/babel-plugin
what imports it should look at to determine what it should transform so if you re-export Emotion's exports, you can still use the Babel transforms -
c672175b
#1130 Thanks @jtmthf! - Adjust how arrays passed to css prop are transformed so function elements can be resolved at runtime.
-
5e803106
#1893 Thanks @Andarist! - Added support for converting assignment expressions to labels in cases like this:styles = css`` Timeline.Item = styled.li`` Timeline.Item.Anchor = styled.a``
-
5c7ec859
#1805 Thanks @Andarist! - Requirements for a label extraction have been relaxed. In certain situations it was previously required for a containing function to have a PascalCased name. -
828111cd
#1639 Thanks @Andarist! -Global
gets handled by the Babel plugin now - this gives inline css-less expressions source maps.
b0ad4f0c
#1602 Thanks @Andarist! - Avoid transpiling vanilla emotion calls in already transpiled code to avoid double labels and such
-
9e998e37
#1817 Thanks @Andarist! - Fixed an issue in our tagged template expressions minifier which has caused whitespace before nested orphaned pseudo selectors being incorrectly removed. In a selector like& :hover
the whitespace before colon has a semantic meaning and needs to be preserved. -
Updated dependencies [
e3d7db87
,8a896a31
,5c55fd17
,a085003d
,5d692a6a
,c6431074
]:- @emotion/serialize@1.0.0
- Updated dependencies [
9c4ebc16
]:- @emotion/serialize@1.0.0-rc.0
- Updated dependencies [
76e3dc4d
]:- @emotion/serialize@1.0.0-next.5
- Updated dependencies []:
- @emotion/serialize@0.11.15-next.4
- Updated dependencies [
5d692a6a
]:- @emotion/serialize@1.0.0-next.3
-
5e803106
#1893 Thanks @Andarist! - Added support for converting assignment expressions to labels in cases like this:styles = css`` Timeline.Item = styled.li`` Timeline.Item.Anchor = styled.a``
-
9e998e37
#1817 Thanks @Andarist! - Fixed an issue in our tagged template expressions minifier which has caused whitespace before nested orphaned pseudo selectors being incorrectly removed. In a selector like& :hover
the whitespace before colon has a semantic meaning and needs to be preserved. -
Updated dependencies []:
- @emotion/serialize@0.11.15-next.2
5c7ec859
#1805 Thanks @Andarist! - Requirements for a label extraction have been relaxed. In certain situations it was previously required for a containing function to have a PascalCased name.
-
e3d7db87
#1732 Thanks @Andarist! - Fixed a regression from a PR which has optimized Babel output which has caused inserted label not being extracted correctly and also broke styles composition in certain situations. -
Updated dependencies [
e3d7db87
]:- @emotion/serialize@1.0.0-next.1
- Updated dependencies [
f08ef5a3
]:- @emotion/serialize@0.11.15-next.4
b8476e08
#1675 Thanks @mitchellhamilton! - Renamebabel-plugin-emotion
to@emotion/babel-plugin
. Please replace"plugins": ["emotion"]
with"plugins": ["@emotion"]
in your Babel config.
-
c7850e61
#1656 Thanks @Andarist! -autoLabel
option no longer is a simple boolean. Instead we accept now 3 values:dev-only
(the default),always
andnever
.Each possible value for this option produces different output code:
- with
dev-only
we optimize the production code, so there are no labels added there, but at the same time we keep labels for development environments, - with
always
we always add labels when possible, - with
never
we disable this entirely and no labels are added.
- with
-
843bfb11
#1630 Thanks @Andarist! - Removed@emotion/css
- it's main purpose was to allowcss
to be a Babel macro, but since babel-plugin-macros allows us to keep imports nowadays this is no longer needed.@emotion/core/macro
has been added to account for this use case and appropriate changes has been made tobabel-plugin-emotion
to facilitate those changes.If you have used
@emotion/css
directly (it was always reexported from@emotion/core
) or you have been using its macro then you should update your code like this:-import css from '@emotion/css' +import { css } from '@emotion/core' // or -import css from '@emotion/css/macro' +import { css } from '@emotion/core/macro'
828111cd
#1639 Thanks @Andarist! -Global
gets handled by the Babel plugin now - this gives inline css-less expressions source maps.
c5b12d90
#1220 Thanks @mitchellhamilton! - Removed support for theinstances
option, any usage of it should be replaced with theimportMap
option
f9feab1a
#1575 Thanks @mitchellhamilton! - Removed support for@emotion/styled-base
package. It has been moved to@emotion/styled
and is available as@emotion/styled/base
. This simplifies how the regular and base versions relate to each other and eliminates problems with stricter package managers when@emotion/styled-base
was not installed explicitly by a user.
c5b12d90
#1220 Thanks @mitchellhamilton! - Added theimportMap
option which allows you to tell babel-plugin-emotion what imports it should look at to determine what it should transform so if you re-export Emotion's exports, you can still use the Babel transforms
c5b12d90
#1220 Thanks @mitchellhamilton! - Fix issue with not updating referenced import when bailing out on already transpiled vanilla emotion nodes (a regression introduced in #1602)- Updated dependencies [
8a896a31
,a085003d
]:- @emotion/serialize@0.11.15-next.1
- Updated dependencies [
1eaa3a38
]:- @emotion/serialize@1.0.0-next.0
302bdba1
#1600 Thanks @mitchellhamilton! - Ensure packages are major bumped so that pre-release versions of the linked packages are consistent in the major number
b0ad4f0c
#1602 Thanks @Andarist! - Avoid transpiling vanilla emotion calls in already transpiled code to avoid double labels and such
b9f8ae3
#1829 Thanks @Andarist! - Skip appending source maps & labels to Babel-transpiled tagged template expressions.
- Updated dependencies [
446e756
]:- @emotion/hash@0.8.0
- @emotion/serialize@0.11.16
4dfe558
#1731 Thanks @ndelangen! - Fixed an issue with addinglabel
&target
options tostyled
-related calls when those properties were already set, causing those properties to be duplicated. This could have happened for example when transpiling already transpiled code or when providing those options manually (latter being less likely).
af07afb
#1761 Thanks @mansourkheffache! - Push source maps & labels to cooked/raw arrays in TS-transpiled tagged template expressions containing interpolations. This is a case not covered previously by #1538.
4c62ae9
#1698 Thanks @Andarist! - Add LICENSE file- Updated dependencies [
4c62ae9
]:- @emotion/hash@0.7.4
- @emotion/memoize@0.7.4
- @emotion/serialize@0.11.15
3927293d
#1569 Thanks @Andarist! - Add dev hint about css object (generated by Babel) being stringified by accident
-
b3a0f148
#1574 Thanks @Andarist! - Fix babel plugin crashing when called programmatically without providing a filename -
Updated dependencies [
a55f3d49
,ca95f385
]:- @emotion/serialize@0.11.14
-
1bb3efe3
#1554 Thanks @Andarist! - Prepend appended label string with semicolon to avoid problems with declaration blocks without a final semicolon -
Updated dependencies [
4fc5657a
,10211951
,57a767ea
]:- @emotion/serialize@0.11.12
- 0eafebb5 #1538 Thanks @Andarist! - Push source maps & labels to cooked/raw arrays in TS-transpiled tagged template expressions
- 1b3791d4 #1526 Thanks @ahutchings! - Fix
autoLabel
crash oncss
used in expression assigned to an object pattern
- Updated dependencies [c81c0033]:
- @emotion/serialize@0.11.11
- @emotion/hash@0.7.3
- @emotion/memoize@0.7.3
- 1ea9b3a6 - Fix an inconsistency with Babel config ordering in the README
- 4a3b18a2 #1451 Thanks @Andarist! - Fixed issue with auto-labelling crashing on $ at runtime
- 284f8fa #1336 Thanks @Zenwolf! - Keep CSS comments that include
@
- c0eb604d #1419 Thanks @mitchellhamilton! - Update build tool