@material-ui/system
Advanced tools
Comparing version 4.0.0-beta.0 to 4.0.0-beta.1
@@ -1,2 +0,2 @@ | ||
/** @license Material-UI v4.0.0-beta.0 | ||
/** @license Material-UI v4.0.0-beta.1 | ||
* | ||
@@ -3,0 +3,0 @@ * This source code is licensed under the MIT license found in the |
import { CSSProperties } from '@material-ui/styles'; | ||
import * as CSS from 'csstype'; | ||
// disable automatic export | ||
export {}; | ||
type ThemeOf<Props> = Props extends WithTheme<infer Theme> ? Theme : never; | ||
@@ -12,3 +15,3 @@ type WithThemeOfProps<Props> = WithTheme<ThemeOf<Props>>; | ||
: never; | ||
type StyleFunction<Props> = (props: Props) => any; | ||
export type StyleFunction<Props> = (props: Props) => any; | ||
type SimpleStyleFunction<PropKey extends keyof any> = StyleFunction<Partial<Record<PropKey, any>>>; | ||
@@ -38,3 +41,2 @@ | ||
* | ||
* @param styleFunction | ||
* @returns An enhanced stylefunction that considers breakpoints | ||
@@ -54,6 +56,6 @@ */ | ||
*/ | ||
type ComposedArg<T> = T extends ((arg: infer P) => any)[] ? P : never; | ||
type ComposedArg<T> = T extends Array<(arg: infer P) => any> ? P : never; | ||
type ComposedStyleProps<T> = ComposedArg<T>; | ||
type Composed<T extends StyleFunction<any>[]> = StyleFunction<ComposedStyleProps<T>>; | ||
export function compose<T extends StyleFunction<any>[]>(...args: T): Composed<T>; | ||
type Composed<T extends Array<StyleFunction<any>>> = StyleFunction<ComposedStyleProps<T>>; | ||
export function compose<T extends Array<StyleFunction<any>>>(...args: T): Composed<T>; | ||
@@ -63,3 +65,3 @@ // css.js | ||
styleFunction: StyleFunction<Props>, | ||
): StyleFunction<Props & { css: Omit<Props, 'theme'> }>; | ||
): StyleFunction<Props | { css: Omit<Props, 'theme'> }>; | ||
@@ -66,0 +68,0 @@ // default display.js TODO |
@@ -1,2 +0,2 @@ | ||
/** @license Material-UI v4.0.0-beta.0 | ||
/** @license Material-UI v4.0.0-beta.1 | ||
* | ||
@@ -3,0 +3,0 @@ * This source code is licensed under the MIT license found in the |
{ | ||
"name": "@material-ui/system", | ||
"version": "4.0.0-beta.0", | ||
"version": "4.0.0-beta.1", | ||
"private": false, | ||
@@ -5,0 +5,0 @@ "author": "Material-UI Team", |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
485760
1942