Giter Club home page Giter Club logo

css-flip's People

Contributors

brettstimmerman avatar caniszczyk avatar cvrebert avatar mathiasbynens avatar necolas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

css-flip's Issues

Create/enable plugins-like architecture

Hi!

It would be nice if css-flip could provide some plug-in mechanism to hook custom declaration processors. Is something like this in the roadmap?

We're currently using R2, and have had to fork/patch it to be able to process some framework-specific properties. (YUI3, FontAwesome). It would be great if css-flip would cover this use case out of the box.

support gulp.js

Hi
I've been added gulp.js support for css-filp.
I was interesting to know if you'd like me to share the code so you can added it to the repository.
Thanks
Itay

update 'css' package

Note to self: update the 'css' package once 'css-parse' and 'css-stringify' have new major releases.

Grunt plugin?

Are there any plans for an (un)officially-endorsed Grunt plugin for css-flip?

either throw if not a string or cast it

Minor thing but I've wasted a bit of time passing a string buffer out of a fs.readFileSync โ€ฆ I had undefined problem cause the buffer is not converted as String(CSS) and if that's meant, a throw "this is not a String" would be nicer for other stupid and lazy devs that might pass utf8 buffers around careless when it comes to build stuff.

@alunny simplified with {encoding:"utf8"} as second argument but I am too lazy for that :D

Stringify inserts double newlines into multi-line comments

Our CSS files have multi-line copyright headers at the top like the following:

/* ***************************************************************** */
/* Copyright 1970, 2038                                              */
/* ***************************************************************** */

After applying a parse() + stringify() like the gulp-flip plugin does, the headers are all interleaved by double newlines. This can be easily reproduced with this simple test case:

var css = require('css');
var obj = css.parse('/* */\n/* */\n/* */', {});
console.log(css.stringify(obj, {}));

Which prints:

/* */

/* */

/* */

SyntaxError: Unexpected identifier

hi
i install node-v0.12.7-x64.msi and run as administrator
the install css-flip
the run below command
can anyone help me?

css-flip c:\css\style.css > c:\css\style.rtl2.css
SyntaxError: Unexpected identifier
at Object.exports.createScript (vm.js:44:10)
at REPLServer.defaultEval (repl.js:117:23)
at bound (domain.js:254:14)
at REPLServer.runBound as eval
at REPLServer. (repl.js:279:12)
at REPLServer.emit (events.js:107:17)
at REPLServer.Interface._onLine (readline.js:214:10)
at REPLServer.Interface._line (readline.js:553:8)
at REPLServer.Interface._ttyWrite (readline.js:830:14)
at ReadStream.onkeypress (readline.js:109:10)

background-position 0 converts to 100%

When running css-flip on my project the background-position value gets converted from 0 to 100%

e.g:

background-position: 0 -100px;

becomes:

background-position: 100% -100px;

Is there a good reason for this or a bug?

Improve percentage handling

The handling of percentages doesn't align with the CSS spec for percentage values. More specifically, exponents and sign (positive-/negative-ness) are not handled well.

Support for :before and :after pseudo elements

Hi, could you please add new option to swap :before and :after pseudo elements? I'm using font-icons that are applied to element via those pseudo class and in RTL I need them to be swapped.

Example
Code

border-radius doesn't require prefixes

Currently, there is a support for -webkit- and -moz- prefixes of border-radius, but border-radius doesn't require prefixes in any browser.

Why are they still here?

Support LTR/RTL-only declarations

For example, flipping sprites or setting different generated content for icon fonts.

.a {
  /* @onlyrtl */ background-position: 0 -30px;
  /* @onlyltr */ background-position: 0 -100px;
}

Maximum call stack size exceeded

I am getting a 'Maximum call stack size exceeded' when using cssFlip the file is about 11000 lines long if that helps, and is being run as part of a grunt task.

Don't mutate property name case

Need to preserve the input property names (e.g., in custom properties) and only use the .toLowercase it in the comparison check.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.