New Plugin: Gradient

I just added a new plugin called, gradient. It dynamically applies a configurable gradient to the background of an element. You create a gradient like this:

  1. $('.gradient').gradient({ from: '003366', to: 'FFFFFF' });

Check out the visual test, read the docs and grab the code.

6 Responses to “New Plugin: Gradient”

  1. Jörn Zaefferer Says:

    Now that generates a heck lot of divs. Interesting stuff!

  2. Brandon Aaron Says:

    Hey Jörn ... Depending on the length of the gradient it will generate up to 100 divs.

  3. pako Says:

    awesome!!!!!

  4. pako Says:

    but so slow ;[

  5. Brandon Aaron Says:

    How are you using it pako? Do you have an example of where it is so slow?

  6. DK Lynn Says:

    Agreed! Very nice!

    Suggestions:

    1. If length is specified, the remainder of the original should be the filled with the second color rather than black.

    2. It would be helpful to allow block elements in the without having to specify style="display:inline; background-color:transparent;" on the block element. Thanks!

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>