Commit Graph

37 Commits

Author SHA1 Message Date
Phil Pluckthun
b6aa46e3a9 Remove react-is package and from rollup.config.js 2021-01-08 14:41:20 +00:00
Evan Jacobs
ee3cc0e24c update flow 2020-08-31 20:25:39 -04:00
Evan Jacobs
7e11092c7a switch back to mainline hoist-non-react-statics (#2934)
should fix #2930
2019-12-23 11:27:01 -05:00
Evan Jacobs
3bc57b3a3a add @babel/traverse, update flowtypes 2019-11-07 16:02:46 -05:00
Evan Jacobs
7b32b43d67 update flow to 0.100 2019-11-07 16:02:33 -05:00
Bhargav Ponnapalli
4aa2fdbb3b Move to a mono-repo structure
wip

Add gitignore and edit rollup config

Update gitignore

Wip

WIP

Get rid of older json files and use js files to extend across pkgs later

Make test:native work again, thanks to @SimenB

No haste and get integration test to work

Update husky

Update package.json

Update travis and appveyor

Add lint script

Update sandbox

Update yarn version

Move eslint into sc package

Remove unnecessary files

Update lint-staged

Update CONTRIBUTING.md

Update version in lerna.json

Update contributing

Update scripts

Update contributing

Update contributing

Update contributing.md and publish script

Update contributing

v4.1.4-alpha.0

Update package json

Update lerna version

v4.1.4-alpha.0

v4.1.4-alpha.1

Independent version for sandbox and styled-components

Yarn instead of npm

Add readme to styled-components package to show up on npm

Publish

 - styled-components@4.1.4-alpha.2

Update prepublisOnly and contributing

Update gitignore

Publish

 - styled-components@4.1.4-alpha.3

Test without readme

Remove readme

Publish

 - styled-components@4.1.4-alpha.4

Copy readme prepublishOnly

Publish

 - styled-components@4.1.4-alpha.5
2019-01-18 21:04:15 +05:30
luc
bd0a793a75 add flow types 2018-12-13 23:20:52 +08:00
Viktor Havrylin
c5405e0e9a better typing for @emotion/unitless 2018-11-01 09:39:06 +02:00
Viktor Havrylin
512dfcce72 use @emotion/unitless 2018-11-01 09:34:40 +02:00
Evan Scott
f379b7fa12 update flow 2018-10-09 18:58:07 -05:00
Luc
4e40f85134 Add a babel-macro (#2032)
* create macro

* add sourceType module when using babel.template

* babel.types needs to be passed down to visitors

* add tests

* add pureAnnotation visitor from babel-plugin-styled-components

* add test with require()

* export 'styled-components/macro'

* add css to macro

* add keyframes to macro

* update test snapshots

* allow to import all helpers from src/index.js

* add error when tags are not used with template literals

* add test : should allow all helpers exported from styled-components

* add injectGlobal to taggedTemplateImports

* add missing tests and refactor tests

* add typescript types

* add flow types

* replace injectGlobal by createGlobalStyle

* just use babel-plugin-styled-components and apply to the whole file

* update babel-plugin-styled-components to 1.8.0

* remove typescript files

* add comments and fix styling of code

* generate allowedImports from src/index.js

* Remove unnecessary test to check allowedImports

* move babel-plugin-styled-components to peerDependencies

* fix tests : add babel-plugin-styled-components to devDependencies

* move babel-plugin-styled-components to deps, with a lenient version

* add macro to files

* add changelog entry
2018-10-08 16:37:34 -05:00
Evan Scott
0ecbb475fd revise some prettier rules 2018-09-20 19:38:54 -05:00
Evan Scott
481c3654c8 inline hyphenateStyleName 2018-09-05 23:10:06 -05:00
Evan Scott
d68b5d55df use React.forwardRef 2018-08-22 11:20:45 -05:00
Evan Scott
6d67ce7b65 refactor away from enzyme
Using the React-provided test renderer and test utilities.

I couldn't figure out how to deal with the innerRef tests yet, but
since that API is going away in one of my open PRs, I figured it
wasn't worth the time to get working.
2018-08-22 02:06:34 -05:00
Evan Scott
b130038fca update flow-typed 2018-08-21 18:00:43 -05:00
Evan Scott
caafe8855d use @emotion/is-prop-valid instead of our validAttr file
It's lighter and faster since its memoized. Saw some nice perf
gain in benchmarking.

before:

---Mount deep tree---
17.14 ±01.82 ms
(S/L) 13.06/04.08 ms

---Mount wide tree---
22.89 ±02.67 ms
(S/L) 16.91/05.98 ms

---Update dynamic styles---
23.47 ±05.14 ms
(S/L) 07.98/15.49 ms

after:

---Mount deep tree---
16.07 ±01.72 ms
(S/L) 12.03/04.05 ms

---Mount wide tree---
21.45 ±02.74 ms
(S/L) 15.59/05.85 ms

---Update dynamic styles---
22.49 ±05.28 ms
(S/L) 07.50/14.99 ms
2018-08-21 11:20:55 -05:00
Alexander Nanberg
f242f9acdb Use new context API (#1894)
* Update ThemeProvider to use new context API

* Fix flow

* Set theme as context

* Fix nested ThemeProviders

* Add ThemeProvider tests

* Add missing propagation test

* Improve ThemeProvider propagation test

* Rename children spy function

* Add flow types

* Upgrade withTheme to use new context

* Migrate StyledComponent to use new context api

* Add ThemeContextShape type

* Cache ThemeConsumer render function

* Upgrade enzyme and revert back tests

* Update lockfile

* Migrate StyleSheetManager

* Use StyleSheetConsumer

* Fix StyleSheetManager tests

* Update ssr snapshot

* Revert back enzyme adapter

* Remove extraneous dependency

* Cleanup context shape

* Fix tests

* Add StyleSheet type and EMPTY_OBJECT

* Update lockfile

* Fix jest/jsdom localStorage errors

* Migrate StyledNativeComponent

* Fix integration test

* Fix some primitive tests

* Fix tests

* Fix flow

* Fix flow

* Update memoize-one flow-typed

* Add StrictMode test

* Remove extraneous dependencies

* Cleanup flow definitions

* Fix import statement

* Change react peerDependency

* Rename variable

* Add changelog entry

* Cleanup import statement

* Fix errors after merge

* Refactor ThemeProvider test to use withTheme and styled
2018-08-12 01:58:07 -05:00
halvves
a59a9d0561 remove lodash flow-typed defs
it appears as though lodash was removed in favor of smaller utils. this
manually edited flow-typed defs was failing flow checks.
2018-05-25 14:43:07 -04:00
halvves
87bf0d7acd chore: upgrade flow-bin to latest
upgrades flow-bin along with other dependencies necessary to keep
flow checks running properly.

also corrects all new warning/errors surfaced by the upgrade (save
for a few $flowFixMe TODOs)
2018-05-20 21:39:16 -04:00
Clayton Ferris
c6b79334a0 Upgrade to enzyme v3 2018-01-13 16:06:49 -07:00
Orta Therox
49b79c77ac Update to Danger 2.0 2017-11-04 13:59:32 -04:00
Orta Therox
91e4737263 Update Danger to 2.0b2 2017-10-31 09:40:08 -04:00
Phil Plückthun
51fbfa0ccb Remove unused autoprefixing code and inline-style-prefixer 2017-06-07 16:24:04 +01:00
Glen Maddern
a7a3e01960 Merge branch 'v2' into rework-stylesheet-for-ssr
Conflicts:
	src/constructors/keyframes.js
	src/models/ComponentStyle.js
	src/models/test/ThemeProvider.test.js
	src/test/extending.test.js
	src/vendor/glamor/hash.js
2017-04-11 10:27:15 +10:00
Glen Maddern
078a445641 working on getting the basic tests passing but just realised i dun broke sumthin 2017-04-10 15:14:22 +10:00
Max
cd1be80f3b Remove glamor from our dependencies
This'll make our npm installs much faster-we were downloading glamor for
a single file.
2017-04-07 19:11:23 +02:00
Max Stoiber
9b911c68f2 Merge branch 'master' into danger-js 2017-01-03 10:41:00 +01:00
orta
28052dff02 Merge changes 2016-12-31 14:23:32 -05:00
Rolf Erik Lekang
ef38fb6f82 Update flow-typed files
This was done by running flow-typed install
2016-12-27 16:58:33 +01:00
Jacob Parker
ee131cced7 Add workaround for React Native border radius property due to issues with Image elements only accepting a single value for all radii 2016-11-24 18:20:43 +00:00
Max
031a88d33d Merge branch 'master' into css-to-react-native 2016-11-20 08:53:15 +01:00
Patrick Stapfer
065001c725 Expose flow types & add detailed usage docs
This commit introduces a few flow-related things (and also some misc
stuff):

* Fix some typing errors with glamor / nameGenerator
* Move adapted `flow-typed/npm` libdefs to `flow-typed`
* Add some flow related ignore rules for eslintrc / flowconfig etc.
* Add a `build:flow` script and add it to the build step
* Add docs for making `styled-components` and `flow` work for the consumer

MISC:
* Add test for generateAlphabeticName

As soon as this feature is merged, there will be `flow.js` files
vendored along with transpiled `lib` files on every build.
2016-11-19 21:37:21 +01:00
Jacob Parker
f7ddc817d5 Use css-to-react-native to parse ReactNative stylesheets 2016-11-17 10:27:14 +00:00
Orta Therox
089cfc1728 Added more rules to the Dangerfile 2016-11-07 15:31:06 +01:00
Rolf Erik Lekang
f7b608113e Enhance flow annotations 2016-10-31 20:41:59 +01:00
Rolf Erik Lekang
4ecbcb5297 Install libdefs with flow-typed 2016-10-31 20:39:37 +01:00