Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Many more tests and some improvements to styped interface #1133

Merged
merged 1 commit into from
Jun 17, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## Next

### Bug Fixes

- [react-jss] Experimental styled API got some fixes and many more tests ([#1118](https://github.com/cssinjs/jss/pull/1118))

## 10.0.0-alpha.18 (2019-6-14)

### Features
Expand Down
26 changes: 13 additions & 13 deletions packages/react-jss/.size-snapshot.json
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
{
"dist/react-jss.js": {
"bundled": 166059,
"minified": 57815,
"gzipped": 18791
"bundled": 167089,
"minified": 57967,
"gzipped": 18853
},
"dist/react-jss.min.js": {
"bundled": 109367,
"minified": 41185,
"gzipped": 13853
"bundled": 110364,
"minified": 41321,
"gzipped": 13914
},
"dist/react-jss.cjs.js": {
"bundled": 24763,
"minified": 11127,
"gzipped": 3649
"bundled": 25739,
"minified": 11339,
"gzipped": 3704
},
"dist/react-jss.esm.js": {
"bundled": 23800,
"minified": 10291,
"gzipped": 3521,
"bundled": 24767,
"minified": 10494,
"gzipped": 3582,
"treeshaked": {
"rollup": {
"code": 1946,
"import_statements": 538
},
"webpack": {
"code": 3517
"code": 3544
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion packages/react-jss/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"dependencies": {
"@babel/runtime": "^7.3.1",
"@emotion/is-prop-valid": "^0.7.3",
"css-jss": "10.0.0-alpha.18",
"css-jss": "^10.0.0-alpha.18",
"hoist-non-react-statics": "^3.2.0",
"is-in-browser": "^1.1.3",
"jss": "10.0.0-alpha.18",
Expand Down
2 changes: 1 addition & 1 deletion packages/react-jss/src/createUseStyles.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const reducer = (prevState, action) => {
}

const createUseStyles = <Theme: {}>(styles: Styles<Theme>, options?: HookOptions<Theme> = {}) => {
const {index = getSheetIndex(), theming, name = 'Hook', ...sheetOptions} = options
const {index = getSheetIndex(), theming, name, ...sheetOptions} = options
const ThemeContext = (theming && theming.context) || DefaultThemeContext
const useTheme =
typeof styles === 'function'
Expand Down
Loading