Sha256: b114b9bc351a162e817c9d3657f23ef87d462464f979cc0e9d917921eee6d9da
Contents?: true
Size: 342 Bytes
Versions: 91
Compression:
Stored size: 342 Bytes
Contents
# frozen_string_literal: true # atome sanitizer class Atome private def create_color_hash(params) rgb_color = Color::CSS[params].css_rgb split_data = rgb_color.sub('rgb(', '').sub(')', '').gsub(',', '').split('%') { red: split_data[0].to_f / 100, green: split_data[1].to_f / 100, blue: split_data[2].to_f / 100 } end end
Version data entries
91 entries across 91 versions & 1 rubygems