-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
rofrischmann
committed
Mar 6, 2017
1 parent
de52666
commit a97ee39
Showing
7 changed files
with
55 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
# Changelog | ||
|
||
### 1.0.3 | ||
* performance improvements | ||
|
||
### 1.0.2 | ||
* added `resolveArrayValue` and `assignStyle` | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import isUnitlessProperty from '../isUnitlessProperty' | ||
|
||
describe('Checking for unitless CSS properties', () => { | ||
it('should return true for unitless properties', () => { | ||
expect(isUnitlessProperty('fontWeight')).toEqual(true) | ||
expect(isUnitlessProperty('flex')).toEqual(true) | ||
expect(isUnitlessProperty('gridColumn')).toEqual(true) | ||
}) | ||
|
||
it('should return true for hypenated unitless properties', () => { | ||
expect(isUnitlessProperty('font-weight')).toEqual(true) | ||
expect(isUnitlessProperty('grid-column')).toEqual(true) | ||
}) | ||
|
||
it('should return true for prefixed unitless properties', () => { | ||
expect(isUnitlessProperty('WebkitFlex')).toEqual(true) | ||
expect(isUnitlessProperty('msFlex')).toEqual(true) | ||
expect(isUnitlessProperty('WebkitColumnCount')).toEqual(true) | ||
expect(isUnitlessProperty('msColumnCount')).toEqual(true) | ||
}) | ||
|
||
it('should return true for hypenated prefixed unitless properties', () => { | ||
expect(isUnitlessProperty('-webkit-flex')).toEqual(true) | ||
expect(isUnitlessProperty('-ms-flex')).toEqual(true) | ||
expect(isUnitlessProperty('-webkit-column-count')).toEqual(true) | ||
expect(isUnitlessProperty('-ms-column-count')).toEqual(true) | ||
}) | ||
|
||
it('should equal false for other properties', () => { | ||
expect(isUnitlessProperty('fontSize')).toEqual(false) | ||
expect(isUnitlessProperty('font-size')).toEqual(false) | ||
expect(isUnitlessProperty('-webkit-border-radius')).toEqual(false) | ||
expect(isUnitlessProperty('-ms-border-radius')).toEqual(false) | ||
expect(isUnitlessProperty('WebkitBorderRadius')).toEqual(false) | ||
expect(isUnitlessProperty('msBorderRadius')).toEqual(false) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters