Coder Social home page Coder Social logo

isoblocks's Introduction

IsoBlocks

What is it?

IsoBlocks is an experimental library to create eye-candy isometric texts. It is written in coffeescript, uses CSS3 transforms for creating the cubes and CSS3 transitions for the animation.

How to use

To use the library, you need to include the following files:

  • js/characters.js
  • js/isoblocks.js
  • css/isoblocks.css

Put the following in your HTML:

<div id="iso_container"></div>

Then in your code create an instance of IsoBlocks class and call the generate method to create the text you want:

NOTE: IsoBlocks requires jQuery to be included before it.

var iso = new IsoBlocks(400); // pass the number of blocks to pre-generate
iso.generate('Your Text Here'); // By Default starts from lower left of the screen

Position it:

iso.generate('Your Text Here', {x: 320, y: 600});

Colorize it (Presently supports- green, red, pink, blue, yellow only):

iso.generate('Your Text Here', {x: 320, y: 600, colors: 'green'}); // Pass a color using 'colors' option

Use multiple colors:

iso.generate('Your Text Here', {x: 320, y: 600, colors: ['green', 'yellow']}); // Pass an array of colors in 'colors'

Try it out

Demo: http://kushagragour.in/lab/isoblocks/

[Works best in Google Chrome]

License

Licensed under The MIT License

isoblocks's People

Contributors

chinchang avatar

Stargazers

Diego MHz avatar

Watchers

Diego MHz avatar

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.