styled-components 6.0.0-alpha.7 → 6.0.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/styled-components-macro.cjs.js +1 -1
- package/dist/styled-components-macro.cjs.js.map +1 -1
- package/dist/styled-components-macro.esm.js +1 -1
- package/dist/styled-components-macro.esm.js.map +1 -1
- package/dist/styled-components.browser.cjs.js +1 -1
- package/dist/styled-components.browser.cjs.js.map +1 -1
- package/dist/styled-components.browser.esm.js +1 -1
- package/dist/styled-components.browser.esm.js.map +1 -1
- package/dist/styled-components.cjs.js +1 -1
- package/dist/styled-components.cjs.js.map +1 -1
- package/dist/styled-components.esm.js +1 -1
- package/dist/styled-components.esm.js.map +1 -1
- package/dist/styled-components.js +1 -1
- package/dist/styled-components.js.map +1 -1
- package/dist/styled-components.min.js +1 -1
- package/dist/styled-components.min.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/native/dist/styled-components.native.cjs.js +432 -400
- package/native/dist/styled-components.native.cjs.js.map +1 -1
- package/native/dist/styled-components.native.esm.js +432 -400
- package/native/dist/styled-components.native.esm.js.map +1 -1
- package/package.json +8 -7
- package/test-utils/setupTestFramework.ts +9 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "styled-components",
|
|
3
|
-
"version": "6.0.0-
|
|
3
|
+
"version": "6.0.0-beta.0",
|
|
4
4
|
"description": "Visual primitives for the component age. Use the best bits of ES6 and CSS to style your apps without stress",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/styled-components.cjs.js",
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"postbuild": "yarn lint:size",
|
|
21
21
|
"pretest": "yarn generateErrors",
|
|
22
22
|
"test": "yarn test:web && yarn test:native",
|
|
23
|
-
"test:web": "jest -c jest.config.main.js",
|
|
24
|
-
"test:native": "jest -c jest.config.native.js",
|
|
23
|
+
"test:web": "jest -c jest.config.main.js --forceExit",
|
|
24
|
+
"test:native": "jest -c jest.config.native.js --forceExit",
|
|
25
25
|
"test:integration": "jest -c jest.config.integration.js --runInBand --forceExit",
|
|
26
26
|
"format": "eslint ./**/*.js --fix",
|
|
27
27
|
"lint": "eslint src",
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
"@rollup/plugin-typescript": "^8.3.3",
|
|
91
91
|
"@types/babel-plugin-macros": "^2.8.4",
|
|
92
92
|
"@types/enzyme": "^3.10.9",
|
|
93
|
-
"@types/jest": "^
|
|
93
|
+
"@types/jest": "^28.1.6",
|
|
94
94
|
"@types/js-beautify": "^1.13.1",
|
|
95
95
|
"@types/node": "^14.0.0",
|
|
96
96
|
"@types/react": "^17.0.22",
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
"@typescript-eslint/eslint-plugin": "^4.20.0",
|
|
104
104
|
"@typescript-eslint/parser": "^4.20.0",
|
|
105
105
|
"babel-eslint": "^10.0.1",
|
|
106
|
-
"babel-jest": "^
|
|
106
|
+
"babel-jest": "^28.1.3",
|
|
107
107
|
"babel-plugin-add-module-exports": "^1.0.4",
|
|
108
108
|
"babel-plugin-macros": "^3.1.0",
|
|
109
109
|
"babel-plugin-styled-components": "^2.0.5",
|
|
@@ -114,9 +114,11 @@
|
|
|
114
114
|
"eslint-plugin-prettier": "^4.0.0",
|
|
115
115
|
"eslint-plugin-react": "^7.20.6",
|
|
116
116
|
"eslint-plugin-react-hooks": "^4.2.0",
|
|
117
|
-
"jest": "^
|
|
117
|
+
"jest": "^28.1.3",
|
|
118
|
+
"jest-environment-jsdom": "^28.1.3",
|
|
118
119
|
"jest-image-snapshot": "^4.2.0",
|
|
119
120
|
"jest-serializer-html": "^7.0.0",
|
|
121
|
+
"jest-watch-typeahead": "^2.0.0",
|
|
120
122
|
"js-beautify": "^1.13.0",
|
|
121
123
|
"prettier": "^2.2.0",
|
|
122
124
|
"prop-types": "^15.7.2",
|
|
@@ -133,7 +135,6 @@
|
|
|
133
135
|
"rollup-plugin-sourcemaps": "^0.6.3",
|
|
134
136
|
"rollup-plugin-terser": "^7.0.2",
|
|
135
137
|
"stylis-plugin-rtl": "^2.1.1",
|
|
136
|
-
"tslib": "^2.4.0",
|
|
137
138
|
"typescript": "^4.7.4",
|
|
138
139
|
"utility-types": "^3.10.0"
|
|
139
140
|
},
|
|
@@ -3,14 +3,20 @@ const consoleError = console.error;
|
|
|
3
3
|
const suppressedErrors = [
|
|
4
4
|
'Error: Could not parse CSS stylesheet',
|
|
5
5
|
'Warning: Use the `defaultValue` or `value` props instead of setting children on <textarea>',
|
|
6
|
+
'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
|
|
6
7
|
];
|
|
7
8
|
|
|
8
9
|
beforeEach(() => {
|
|
9
10
|
// Suppress errors from JSDOM CSS parser
|
|
10
11
|
// See: https://github.com/jsdom/jsdom/issues/2177
|
|
11
|
-
console.error = (
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
console.error = (logged: any) => {
|
|
13
|
+
const message = logged.stack || logged;
|
|
14
|
+
|
|
15
|
+
if (
|
|
16
|
+
typeof message !== 'string' ||
|
|
17
|
+
!suppressedErrors.some(suppressedError => message.includes(suppressedError))
|
|
18
|
+
) {
|
|
19
|
+
consoleError(logged);
|
|
14
20
|
}
|
|
15
21
|
};
|
|
16
22
|
});
|