Sha256: 5cdc8a896ff706e32be7031beacec72dba6e409ddf5336bd56bacad2168ec73f
Contents?: true
Size: 886 Bytes
Versions: 1
Compression:
Stored size: 886 Bytes
Contents
module TokyoMetro::App::Renderer::Icon FONT_AWESOME_ICON = ::YAML.load_file( "#{ ::TokyoMetro::DICTIONARY_DIR }/view/icon/font_awesome_icon.yaml" ) IMAGE = ::YAML.load_file( "#{ ::TokyoMetro::DICTIONARY_DIR }/view/icon/image.yaml" ) raise if ( FONT_AWESOME_ICON.keys & IMAGE.keys ).present? def self.font_awesome_icons FONT_AWESOME_ICON end def self.images IMAGE end FONT_AWESOME_ICON.each do | key , value | eval <<-DEF def self.#{ key }( request , size = 1 , spin: nil , pulse: nil , inverse: nil ) FontAwesome.new( request , "#{ value }" , size , spin: spin , pulse: pulse , inverse: inverse ) end DEF end IMAGE.each do | key , value | eval <<-DEF def self.#{ key }( request , size = 1 , class_name: nil ) Image.new( request , "#{ value }" , size , class_name: class_name ) end DEF end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
tokyo_metro-0.10.1 | lib/tokyo_metro/app/renderer/icon.rb |