module Playbook::TextAlign
def text_align_props
def text_align_props selected_props = text_align_options.keys.select { |sk| try(sk) } return nil unless selected_props.present? selected_props.map do |k| text_align_value = send(k) if text_align_value.is_a?(Hash) text_align_value.map do |media_size, flex_value| "text_align_#{media_size}_#{flex_value.underscore}" if text_align_values.include? flex_value end else "text_align_#{text_align_value.underscore}" if text_align_values.include? text_align_value end end.compact.join(" ") end