Module: Sass::Script::Functions
- Defined in:
- lib/wfs/sass_extensions.rb
Instance Method Summary collapse
Instance Method Details
#font_files(*args) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/wfs/sass_extensions.rb', line 4 def font_files(*args) raise Sass::SyntaxError, "An even number of arguments must be passed to font_files()" unless args.size % 2 == 0 files = [] while args.size > 0 files << "url('fonts/#{args.shift}') format('fonts/#{args.shift}')" end Sass::Script::String.new(files.join(", ")) end |