pixel-art-react is a free, open source design & prototyping project written in JavaScript and released under MIT. It has 6,033 GitHub stars, 334 forks and 8 open issues, and was last pushed 8 months ago. On this registry it ranks #39 of 71 tracked projects in Design & Prototyping, with 5 head-to-head comparisons available.

What is pixel-art-react?

Pixel Art to CSS is a browser-based drawing and animation editor for anyone who wants pixel art delivered as ready-to-paste CSS rather than as a flat image file.

What it is

Pixel Art to CSS is an online editor built as a JavaScript web application, combining React for the UI, Redux for a Flux-like architecture, ImmutableJS to keep application data free of side effects, and PostCSS to handle its own styles. It is aimed at people who draw frames of pixel art and want the result expressed as code they can drop into a website, and it ships as a hosted site at pixelartcss.com as well as a codebase you can install and run yourself.

The concrete problem it addresses is that pixel art normally has to be shipped as an image asset — a static file, a GIF, or a sprite sheet — which is awkward when what you actually want is markup that inherits your page's styling. The app closes that gap by generating CSS that combines the box-shadow and keyframes properties, so the drawing and its animation are expressed entirely in stylesheets. It therefore stands in for hand-writing those two properties frame by frame, and for the round-trip of exporting images just to place a small animated graphic on a page.

Key capabilities

  • Generates CSS from pixel art by combining box-shadow and keyframes, producing code ready to paste into a site.
  • Exports finished work as a static image, an animated GIF, or a sprite-like image.
  • Lets you customise the colour palette, move back and forth in time along the animation, and modify animation settings.
  • Saves and loads projects, and imports work by submitting text code — the bundled cat animation is shipped as examples/import-export/cat.txt.
  • Ships an example project (a cat animation, visible as screenshots/animation-cat.gif) loaded by default in the LOAD section.
  • Provides separate maintenance scripts: npm run lint (ESLint), npm run csslint (Stylelint), npm run format (Prettier), and npm run test (Jest).
  • Runs the linters and formats staged files automatically on every commit.

Who uses it and how

  • Front-end developers who need a small animated graphic on a page and prefer shipping CSS over committing image assets to a repository.
  • Designers sketching sprite-style animations in the browser, then exporting the same work as a GIF or sprite image for contexts where CSS does not apply.
  • Self-hosters and contributors who clone the repository, install dependencies with npm install, and work against the development script or the production build.
  • Teams relying on the included test and lint tooling, where Jest tests and the ESLint/Stylelint/Prettier suite gate commits.

Getting started

Install with npm install and run the app locally with npm run development; the production build is created with npm run deploy.

How it compares

This registry names no comparable or competing projects alongside it, so Pixel Art to CSS stands alone here as the sole entry for turning pixel art drawings into CSS code.

When to use it — and when not

Pick it when you want a lightweight, MIT-licensed drawing tool whose output is CSS you own and can paste anywhere, and when you are content to operate a Node/npm build pipeline for local use — the app is a client-side React project rather than a service with a database, storage or SMTP to administer. Do not pick it if you need a maintained dependency: the README warns that the repository is in a temporary idle state for a refactor and tech upgrade, and is not currently accepting new pull requests or issues, which also means feature requests and fixes will sit unaddressed until that ends.

project readme (upstream, from github) — read inline

⚠️ Temporary Limited Interaction Notice ⚠️

(Please check Contributing)

Pixel Art to CSS

Animate pixel art and get CSS

travis ci

Did you know that you can create pixel art using CSS?

Pixel Art to CSS is an online editor that helps you with that task.

Combining the power of both box-shadow and keyframes CSS properties, you will get CSS code ready to use in your site.

Furthermore, you can download your work in different formats such as a static image, animated GIF or sprite like image.

:pencil2: Try it out

Pixel Art to CSS aims to be an intuitive tool by its simplicity, however it is equipped with a wide range of features: customize your color palette, go back and forth in time, modify animation settings, save or load your projects, among others.

Example

By default, you will find the following project within the LOAD section:

Cat animation example

See it live at pixelartcss

You can also import it directly submitting this code.

Technical overview

This application has been built with the following technologies:

  • React: Library to build the UI.
  • Redux: Implements a Flux like architecture.
  • ImmutableJS Helps to keep the data immutable aiming to avoid side effects.
  • PostCSS Handle the app CSS.

Installation

npm install

Development

npm run development

Deploy

Create the production build.

npm run deploy

Lint

There are several libraries used in the project that help us to keep our codebase healthy:

Every time we commit something it will execute the linters and format the staged files if needed.

If you want to check them individually you could execute the following scripts:

npm run lint
npm run csslint
npm run format

Testing

We are using Jest as the testing platform.

npm run test

Contributing

⚠️ Please Note: This repository is currently in a temporary idle state due to a refactor and tech upgrade. I am not accepting new Pull Requests or Issues at the moment. Sorry for the inconveniences.

#### Help me to improve it :seedling:

Create a GitHub issue if there is something wrong or to be improved.

Pull requests are also welcome, please take the following requirements as a checklist before opening one:

- [x] The PR does fix a problem or adds a new feature, not just cosmetic or syntactic sugar changes. - [x] It would be great to open an issue in advance. - [x] The PR should be issued to the develop branch. - [x] The PR should have a explanation or be related to an issue.

Thank you!

License

MIT Copyright © 2016 Javier Valencia Romero (@jvalen)

Frequently asked questions

Is pixel-art-react free to use?

pixel-art-react is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does pixel-art-react do?

Pixel art animation and drawing web app powered by React

What is pixel-art-react written in?

pixel-art-react is primarily written in JavaScript. Its source is publicly available at https://github.com/jvalen/pixel-art-react, and it has 6,033 GitHub stars.