Project

undraw

0.07
Low commit activity in last 3 years
No release in over a year
Embed an SVG illustrations by unDraw https://undraw.co/illustrations into your rails app. Take advantage of the on-the-fly color image generation to match your brand identity.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 1.8.0
 Project Readme

unDraw rubygem Gem Version

Embed SVG illustrations by unDraw.io for your rails projects

screenshot

Installation

Add this line to your application's Gemfile:

gem 'undraw'

And then execute:

$ bundle

Or install it yourself as:

$ gem install undraw

Usage

Browse to find the images that fit your needs. Take advantage of the on-the-fly color image generation to match your brand identity.

**hint: downcase the svg title and replace space with underscore. eg: Features Overview to features_overview

# default color
<%= undraw("features_overview") %>
# set size 
<%= undraw("features_overview", color: "#3f51b5", size: "350*150") %>
# set id
<%= undraw("building", color: "#ff6347", id: "undraw-building") %>
# set class
<%= undraw("designer_life", color: "#ff6347", class: "undraw-designer-life") %>

Update

Run bundle update to latest gem released

$ bundle update undraw

Due the license issue, any new illustrations released are no longer added to this gems and existing assets might be removed in a future release. You need to manually download preferred svg file and put on:

\vendor\images\undraw\<asset_name>.svg

# default color
<%= undraw("<asset_name>") %>

Development

DEMO: http://materialize.labs.my/undraw

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/mkhairi/undraw. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Code of Conduct

Everyone interacting in the Undraw project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.