1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00

Add styled-jsx 2.0 beta support. (#3039)

This commit is contained in:
Arunoda Susiripala 2017-10-04 23:46:06 +05:30 committed by GitHub
parent 97a6a62a6b
commit 2eb8b0e983
3 changed files with 27 additions and 55 deletions

View file

@ -91,7 +91,7 @@
"send": "0.15.6", "send": "0.15.6",
"source-map-support": "0.4.18", "source-map-support": "0.4.18",
"strip-ansi": "4.0.0", "strip-ansi": "4.0.0",
"styled-jsx": "1.0.11", "styled-jsx": "^2.0.0-beta.1",
"touch": "3.1.0", "touch": "3.1.0",
"unfetch": "3.0.0", "unfetch": "3.0.0",
"url": "0.11.0", "url": "0.11.0",

View file

@ -30,10 +30,10 @@ export default function ({ app }, suiteName, render) {
test('renders styled jsx', async () => { test('renders styled jsx', async () => {
const $ = await get$('/styled-jsx') const $ = await get$('/styled-jsx')
const styleId = $('#blue-box').attr('data-jsx') const styleId = $('#blue-box').attr('class')
const style = $(`#__jsx-style-${styleId}`) const style = $('style')
expect(style.text()).toMatch(/color:blue/) expect(style.text().includes(`p.${styleId}{color:blue}`)).toBeTruthy()
}) })
test('renders properties populated asynchronously', async () => { test('renders properties populated asynchronously', async () => {

View file

@ -424,7 +424,7 @@ babel-code-frame@7.0.0-beta.0:
esutils "^2.0.2" esutils "^2.0.2"
js-tokens "^3.0.0" js-tokens "^3.0.0"
babel-code-frame@^6.16.0, babel-code-frame@^6.20.0, babel-code-frame@^6.22.0: babel-code-frame@^6.16.0, babel-code-frame@^6.22.0:
version "6.22.0" version "6.22.0"
resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.22.0.tgz#027620bee567a88c32561574e7fd0801d33118e4" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.22.0.tgz#027620bee567a88c32561574e7fd0801d33118e4"
dependencies: dependencies:
@ -666,7 +666,7 @@ babel-messages@7.0.0-beta.0:
version "7.0.0-beta.0" version "7.0.0-beta.0"
resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-7.0.0-beta.0.tgz#6df01296e49fc8fbd0637394326a167f36da817b" resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-7.0.0-beta.0.tgz#6df01296e49fc8fbd0637394326a167f36da817b"
babel-messages@^6.23.0, babel-messages@^6.8.0: babel-messages@^6.23.0:
version "6.23.0" version "6.23.0"
resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e" resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e"
dependencies: dependencies:
@ -1134,7 +1134,7 @@ babel-runtime@6.26.0, babel-runtime@^6.26.0:
core-js "^2.4.0" core-js "^2.4.0"
regenerator-runtime "^0.11.0" regenerator-runtime "^0.11.0"
babel-runtime@^6.18.0, babel-runtime@^6.20.0, babel-runtime@^6.22.0: babel-runtime@^6.18.0, babel-runtime@^6.22.0:
version "6.23.0" version "6.23.0"
resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.23.0.tgz#0a9489f144de70efb3ce4300accdb329e2fc543b" resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.23.0.tgz#0a9489f144de70efb3ce4300accdb329e2fc543b"
dependencies: dependencies:
@ -1170,20 +1170,6 @@ babel-template@^6.16.0, babel-template@^6.24.1, babel-template@^6.25.0, babel-te
babylon "^6.17.2" babylon "^6.17.2"
lodash "^4.2.0" lodash "^4.2.0"
babel-traverse@6.21.0:
version "6.21.0"
resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.21.0.tgz#69c6365804f1a4f69eb1213f85b00a818b8c21ad"
dependencies:
babel-code-frame "^6.20.0"
babel-messages "^6.8.0"
babel-runtime "^6.20.0"
babel-types "^6.21.0"
babylon "^6.11.0"
debug "^2.2.0"
globals "^9.0.0"
invariant "^2.2.0"
lodash "^4.2.0"
babel-traverse@7.0.0-beta.0: babel-traverse@7.0.0-beta.0:
version "7.0.0-beta.0" version "7.0.0-beta.0"
resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-7.0.0-beta.0.tgz#da14be9b762f62a2f060db464eaafdd8cd072a41" resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-7.0.0-beta.0.tgz#da14be9b762f62a2f060db464eaafdd8cd072a41"
@ -1243,7 +1229,7 @@ babel-types@7.0.0-beta.0:
lodash "^4.2.0" lodash "^4.2.0"
to-fast-properties "^2.0.0" to-fast-properties "^2.0.0"
babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.21.0, babel-types@^6.24.1, babel-types@^6.25.0: babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.25.0:
version "6.25.0" version "6.25.0"
resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.25.0.tgz#70afb248d5660e5d18f811d91c8303b54134a18e" resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.25.0.tgz#70afb248d5660e5d18f811d91c8303b54134a18e"
dependencies: dependencies:
@ -1261,15 +1247,11 @@ babel-types@^6.26.0:
lodash "^4.17.4" lodash "^4.17.4"
to-fast-properties "^1.0.3" to-fast-properties "^1.0.3"
babylon@6.14.1:
version "6.14.1"
resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.14.1.tgz#956275fab72753ad9b3435d7afe58f8bf0a29815"
babylon@7.0.0-beta.22: babylon@7.0.0-beta.22:
version "7.0.0-beta.22" version "7.0.0-beta.22"
resolved "https://registry.yarnpkg.com/babylon/-/babylon-7.0.0-beta.22.tgz#74f0ad82ed7c7c3cfeab74cf684f815104161b65" resolved "https://registry.yarnpkg.com/babylon/-/babylon-7.0.0-beta.22.tgz#74f0ad82ed7c7c3cfeab74cf684f815104161b65"
babylon@^6.11.0, babylon@^6.17.2, babylon@^6.17.4: babylon@^6.17.2, babylon@^6.17.4:
version "6.17.4" version "6.17.4"
resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.17.4.tgz#3e8b7402b88d22c3423e137a1577883b15ff869a" resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.17.4.tgz#3e8b7402b88d22c3423e137a1577883b15ff869a"
@ -2002,12 +1984,6 @@ css-select@~1.2.0:
domutils "1.5.1" domutils "1.5.1"
nth-check "~1.0.1" nth-check "~1.0.1"
css-tree@1.0.0-alpha17:
version "1.0.0-alpha17"
resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha17.tgz#7ab95ab72c533917af8be54313fec81841c5223a"
dependencies:
source-map "^0.5.3"
css-what@2.1: css-what@2.1:
version "2.1.0" version "2.1.0"
resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.0.tgz#9467d032c38cfaefb9f2d79501253062f87fa1bd" resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.0.tgz#9467d032c38cfaefb9f2d79501253062f87fa1bd"
@ -2416,7 +2392,7 @@ escape-html@~1.0.3:
version "1.0.3" version "1.0.3"
resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988"
escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5:
version "1.0.5" version "1.0.5"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4"
@ -5324,7 +5300,7 @@ prop-types-exact@1.1.1:
has "^1.0.1" has "^1.0.1"
object.assign "^4.0.4" object.assign "^4.0.4"
prop-types@15.6.0, prop-types@^15.5.7: prop-types@15.6.0, prop-types@^15.6.0:
version "15.6.0" version "15.6.0"
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.6.0.tgz#ceaf083022fc46b4a35f69e13ef75aed0d639856" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.6.0.tgz#ceaf083022fc46b4a35f69e13ef75aed0d639856"
dependencies: dependencies:
@ -5332,7 +5308,7 @@ prop-types@15.6.0, prop-types@^15.5.7:
loose-envify "^1.3.1" loose-envify "^1.3.1"
object-assign "^4.1.1" object-assign "^4.1.1"
prop-types@^15.5.4, prop-types@~15.5.7: prop-types@^15.5.4:
version "15.5.10" version "15.5.10"
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.5.10.tgz#2797dfc3126182e3a95e3dfbb2e893ddd7456154" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.5.10.tgz#2797dfc3126182e3a95e3dfbb2e893ddd7456154"
dependencies: dependencies:
@ -5442,14 +5418,14 @@ react-deep-force-update@^2.0.1:
version "2.0.1" version "2.0.1"
resolved "https://registry.yarnpkg.com/react-deep-force-update/-/react-deep-force-update-2.0.1.tgz#4f7f6c12c3e7de42f345992a3c518236fa1ecad3" resolved "https://registry.yarnpkg.com/react-deep-force-update/-/react-deep-force-update-2.0.1.tgz#4f7f6c12c3e7de42f345992a3c518236fa1ecad3"
react-dom@15.5.4: react-dom@16.0.0:
version "15.5.4" version "16.0.0"
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.5.4.tgz#ba0c28786fd52ed7e4f2135fe0288d462aef93da" resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.0.0.tgz#9cc3079c3dcd70d4c6e01b84aab2a7e34c303f58"
dependencies: dependencies:
fbjs "^0.8.9" fbjs "^0.8.16"
loose-envify "^1.1.0" loose-envify "^1.1.0"
object-assign "^4.1.0" object-assign "^4.1.1"
prop-types "~15.5.7" prop-types "^15.6.0"
react-hot-loader@3.0.0-beta.7: react-hot-loader@3.0.0-beta.7:
version "3.0.0-beta.7" version "3.0.0-beta.7"
@ -5468,14 +5444,14 @@ react-proxy@^3.0.0-alpha.0:
dependencies: dependencies:
lodash "^4.6.1" lodash "^4.6.1"
react@15.5.4: react@16.0.0:
version "15.5.4" version "16.0.0"
resolved "https://registry.yarnpkg.com/react/-/react-15.5.4.tgz#fa83eb01506ab237cdc1c8c3b1cea8de012bf047" resolved "https://registry.yarnpkg.com/react/-/react-16.0.0.tgz#ce7df8f1941b036f02b2cca9dbd0cb1f0e855e2d"
dependencies: dependencies:
fbjs "^0.8.9" fbjs "^0.8.16"
loose-envify "^1.1.0" loose-envify "^1.1.0"
object-assign "^4.1.0" object-assign "^4.1.1"
prop-types "^15.5.7" prop-types "^15.6.0"
read-pkg-up@^1.0.1: read-pkg-up@^1.0.1:
version "1.0.1" version "1.0.1"
@ -6293,17 +6269,13 @@ strip-json-comments@~2.0.1:
version "2.0.1" version "2.0.1"
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a"
styled-jsx@1.0.11: styled-jsx@^2.0.0-beta.1:
version "1.0.11" version "2.0.0-beta1"
resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-1.0.11.tgz#8454f06916d9d57a2e9aed6a9c2e695177822045" resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-2.0.0-beta1.tgz#2acb5aad06fada054d6c8133d4d18168f5859ffa"
dependencies: dependencies:
babel-plugin-syntax-jsx "6.18.0" babel-plugin-syntax-jsx "6.18.0"
babel-traverse "6.21.0"
babel-types "6.23.0" babel-types "6.23.0"
babylon "6.14.1"
convert-source-map "1.3.0" convert-source-map "1.3.0"
css-tree "1.0.0-alpha17"
escape-string-regexp "1.0.5"
source-map "0.5.6" source-map "0.5.6"
string-hash "1.1.1" string-hash "1.1.1"
stylis "3.2.18" stylis "3.2.18"