Comparing version 10.8.2 to 11.0.0
@@ -23,2 +23,20 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; | ||
var sortMediaQuery = function sortMediaQuery() { | ||
var mediaQueryOrder = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : []; | ||
return function (a, b) { | ||
if (mediaQueryOrder.indexOf(b) === -1) { | ||
if (mediaQueryOrder.indexOf(a) === -1) { | ||
return 0; | ||
} | ||
return -1; | ||
} | ||
if (mediaQueryOrder.indexOf(a) === -1) { | ||
return 1; | ||
} | ||
return mediaQueryOrder.indexOf(a) - mediaQueryOrder.indexOf(b); | ||
}; | ||
}; | ||
export default function createRenderer() { | ||
@@ -31,3 +49,3 @@ var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; | ||
plugins: config.plugins || [], | ||
mediaQueryOrder: config.mediaQueryOrder || [], | ||
sortMediaQuery: config.sortMediaQuery || sortMediaQuery(config.mediaQueryOrder), | ||
supportQueryOrder: config.supportQueryOrder || [], | ||
@@ -34,0 +52,0 @@ ruleOrder: [/^:link/, /^:visited/, /^:hover/, /^:focus-within/, /^:focus/, /^:active/], |
@@ -73,2 +73,20 @@ 'use strict'; | ||
var sortMediaQuery = function sortMediaQuery() { | ||
var mediaQueryOrder = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : []; | ||
return function (a, b) { | ||
if (mediaQueryOrder.indexOf(b) === -1) { | ||
if (mediaQueryOrder.indexOf(a) === -1) { | ||
return 0; | ||
} | ||
return -1; | ||
} | ||
if (mediaQueryOrder.indexOf(a) === -1) { | ||
return 1; | ||
} | ||
return mediaQueryOrder.indexOf(a) - mediaQueryOrder.indexOf(b); | ||
}; | ||
}; | ||
function createRenderer() { | ||
@@ -81,3 +99,3 @@ var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; | ||
plugins: config.plugins || [], | ||
mediaQueryOrder: config.mediaQueryOrder || [], | ||
sortMediaQuery: config.sortMediaQuery || sortMediaQuery(config.mediaQueryOrder), | ||
supportQueryOrder: config.supportQueryOrder || [], | ||
@@ -84,0 +102,0 @@ ruleOrder: [/^:link/, /^:visited/, /^:hover/, /^:focus-within/, /^:focus/, /^:active/], |
{ | ||
"name": "fela", | ||
"version": "10.8.2", | ||
"version": "11.0.0", | ||
"description": "State-Driven Styling in JavaScript", | ||
@@ -17,3 +17,3 @@ "typings": "index.d.ts", | ||
], | ||
"repository": "https://github.com/rofrischmann/fela/", | ||
"repository": "https://github.com/robinweser/fela/", | ||
"keywords": [ | ||
@@ -39,6 +39,6 @@ "fela", | ||
"fast-loops": "^1.0.0", | ||
"fela-utils": "^10.8.2", | ||
"fela-utils": "^11.0.0", | ||
"isobject": "^3.0.1" | ||
}, | ||
"gitHead": "9e672da639a79155774bab89060d47bd8d461d57" | ||
"gitHead": "ff394c7a5d741ddd039145fd6d5944bf3e918f58" | ||
} |
@@ -8,8 +8,8 @@ <h1><img alt="Fela" src="docs/res/logo.png" width="203"/></h1> | ||
Fela can be used with [React](https://github.com/rofrischmann/fela/tree/master/packages/react-fela) or with any other view library. It even supports [React Native](http://fela.js.org/docs/guides/UsageWithReactNative.html). | ||
Fela can be used with [React](https://github.com/robinweser/fela/tree/master/packages/react-fela) or with any other view library. It even supports [React Native](http://fela.js.org/docs/guides/UsageWithReactNative.html). | ||
<img alt="TravisCI" src="https://travis-ci.org/robinweser/fela.svg?branch=master"> <a href="https://codeclimate.com/github/robinweser/fela/coverage"><img alt="Test Coverage" src="https://codeclimate.com/github/rofrischmann/fela/badges/coverage.svg"></a> <a href="https://bundlephobia.com/result?p=fela@latest"><img alt="Bundlephobia" src="https://img.shields.io/bundlephobia/minzip/fela.svg"></a> <img alt="npm downloads" src="https://img.shields.io/npm/dm/fela.svg"> <a href="https://spectrum.chat/fela?tab=posts"><img alt="Spectrum" src="https://img.shields.io/badge/support-spectrum-brightgreen.svg"></a> | ||
<img alt="TravisCI" src="https://travis-ci.org/robinweser/fela.svg?branch=master"> <a href="https://codeclimate.com/github/robinweser/fela/coverage"><img alt="Test Coverage" src="https://codeclimate.com/github/robinweser/fela/badges/coverage.svg"></a> <a href="https://bundlephobia.com/result?p=fela@latest"><img alt="Bundlephobia" src="https://img.shields.io/bundlephobia/minzip/fela.svg"></a> <img alt="npm downloads" src="https://img.shields.io/npm/dm/fela.svg"> <a href="https://spectrum.chat/fela?tab=posts"><img alt="Spectrum" src="https://img.shields.io/badge/support-spectrum-brightgreen.svg"></a> | ||
## Support Us | ||
Support Robin Frischmann's work on Fela and its ecosystem directly via [**Patreon**](https://www.patreon.com/rofrischmann). | ||
Support Robin Frischmann's work on Fela and its ecosystem directly via [**Patreon**](https://www.patreon.com/robinweser). | ||
@@ -25,2 +25,3 @@ ## Installation | ||
* Scoped Atomic CSS | ||
* Minimal Bundle Size | ||
* No Specificity Issues | ||
@@ -30,2 +31,3 @@ * No Naming Conflicts | ||
* Huge Ecosystem | ||
* i18n Support | ||
@@ -153,15 +155,15 @@ ## The Gist | ||
## Talks | ||
* [**CSS in JS: The Good & Bad Parts**](https://www.youtube.com/watch?v=95M-2YzyTno) ([Slides](https://speakerdeck.com/rofrischmann/css-in-js-the-good-and-bad-parts))<br> - *by [Robin Frischmann](https://twitter.com/rofrischmann)* | ||
* [**CSS in JS: The Good & Bad Parts**](https://www.youtube.com/watch?v=95M-2YzyTno) ([Slides](https://speakerdeck.com/robinweser/css-in-js-the-good-and-bad-parts))<br> - *by [Robin Frischmann](https://twitter.com/robinweser)* | ||
* [**CSS in JS: Patterns**](https://www.webexpo.net/prague2018/talk?id=css-in-js-patterns)<br> - *by [Vojtech Miksu](https://twitter.com/vmiksu)* | ||
## Posts | ||
* [**Style as a Function of State**](https://medium.com/@rofrischmann/styles-as-functions-of-state-1885627a63f7#.6k6i4kdch)<br> - *by [Robin Frischmann](https://twitter.com/rofrischmann)* | ||
* [**Style as a Function of State**](https://medium.com/@robinweser/styles-as-functions-of-state-1885627a63f7#.6k6i4kdch)<br> - *by [Robin Frischmann](https://twitter.com/robinweser)* | ||
* [**CSS in JS: The Argument Refined**](https://medium.com/@steida/css-in-js-the-argument-refined-471c7eb83955#.3otvkubq4)<br> - *by [Daniel Steigerwald](https://twitter.com/steida)* | ||
* [**What is Fela?**](https://davidsinclair.io/thoughts/what-is-fela)<br> - *by [David Sinclair](https://davidsinclair.io)* | ||
* [**Choosing a CSS in JS library**](https://gist.github.com/troch/c27c6a8cc47b76755d848c6d1204fdaf#file-choosing-a-css-in-js-library-md)<br> - *by [Thomas Roch](https://twitter.com/tcroch)* | ||
* [**Introducing Fela 6.0**](https://medium.com/felajs/the-future-of-fela-d4dad2efad00)<br> - *by [Robin Frischmann](https://twitter.com/rofrischmann)* | ||
* [**Introducing Fela 6.0**](https://medium.com/felajs/the-future-of-fela-d4dad2efad00)<br> - *by [Robin Frischmann](https://twitter.com/robinweser)* | ||
* [**A journey into CSS and then into CSS-in-JS**](https://www.zeolearn.com/magazine/a-journey-into-css-and-then-into-css-in-js)<br> - *by [Prithvi Raju](https://twitter.com/aga5tya)* | ||
* [**CSS In JS — Future of styling components**](https://we-are.bookmyshow.com/css-in-js-future-of-styling-components-ad315eb5448b)<br> - *by [Manjula Dube](https://twitter.com/manjula_dube)* | ||
* [**Styling Components with React Fela**](https://alligator.io/react/styling-with-react-fela/)<br> - *by [Josh Sherman](https://twitter.com/joshtronic)* | ||
* [**The Future of Fela**](https://medium.com/@rofrischmann/introducing-fela-6-0-289c84b52dd5)<br> - *by [Robin Frischmann](https://twitter.com/rofrischmann)* | ||
* [**The Future of Fela**](https://medium.com/@robinweser/introducing-fela-6-0-289c84b52dd5)<br> - *by [Robin Frischmann](https://twitter.com/robinweser)* | ||
@@ -192,3 +194,3 @@ ## Ecosystem | ||
* [htz-frontend](https://github.com/Haaretz/htz-frontend) - Source for Haaretz frontend app(s) | ||
* [kilvin](https://github.com/rofrischmann/kilvin) - Primitive React Layout Components with Fela | ||
* [kilvin](https://github.com/robinweser/kilvin) - Primitive React Layout Components with Fela | ||
* [olymp](https://github.com/olymp/olymp) - Create and build a next gen app using node, react, cssInJS and other cool stuff | ||
@@ -212,3 +214,3 @@ * [preact-fela-simple](https://github.com/pshev/preact-fela-simple) - Super simple Preact bindings for Fela | ||
> Your company is using Fela, but is not listed yet? [Add your company / organisation](https://github.com/rofrischmann/fela/edit/master/README.md#L121) | ||
> Your company is using Fela, but is not listed yet? [Add your company / organisation](https://github.com/robinweser/fela/edit/master/README.md#L121) | ||
@@ -219,4 +221,6 @@ - [abilis](https://www.abilis.de) | ||
- [Cloudflare](https://www.cloudflare.com) | ||
- [dm-drogerie markt](https://www.dm.de) | ||
- [dmTECH](https://www.dmtech.de) | ||
- [Espressive](https://www.espressive.com) | ||
- [dm-drogerie markt](https://www.dm.de/arbeiten-und-lernen/arbeiten-bei-uns/filiadata-c534052.html) | ||
- [Gazzer](https://www.gazzer.io) | ||
- [HelloFresh](https://www.hellofresh.de) | ||
@@ -232,2 +236,3 @@ - [Indoqa](https://www.indoqa.com) | ||
- [Optisure](https://www.optisure.de) | ||
- [Robin Weser](http://weser.io) | ||
- [Rocket Station](http://rstation.io) | ||
@@ -240,3 +245,2 @@ - [Root Systems](https://www.rootsystems.nz) | ||
## Contributing | ||
@@ -253,2 +257,2 @@ | ||
Documentation is licensed under [Creative Common License](http://creativecommons.org/licenses/by/4.0/).<br> | ||
Created with ♥ by [@rofrischmann](http://rofrischmann.de) and all the great contributors. | ||
Created with ♥ by [@robinweser](http://weser.io) and all the great contributors. |
Sorry, the diff of this file is not supported yet
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
68111
1225
249
+ Addedfela-utils@11.7.0(transitive)
- Removedfela-utils@10.8.2(transitive)
Updatedfela-utils@^11.0.0