class Playbook::PbPopover::Popover

def classname

def classname
  generate_classname_without_spacing("pb_popover_kit")
end

def data

def data
  Hash(values[:data]).merge(
    pb_popover_kit: true,
    pb_popover_position: position,
    pb_popover_trigger_element_id: trigger_element_id,
    pb_popover_tooltip_id: tooltip_id,
    pb_popover_offset: offset,
    pb_popover_close_on_click: close_on_click
  )
end

def popover_spacing_helper

def popover_spacing_helper
  generate_classname(spacing_props.nil? ? "p_sm" : spacing_props)
end

def width_height_class_helper

def width_height_class_helper
  "overflow_handling" if max_height || max_width
end

def width_height_helper

def width_height_helper
  out = ""
  out += "max-height: #{max_height}; " if max_height.present?
  out += "max-width: #{max_width}; " if max_width.present?
  out += "min-height: #{min_height}; " if min_height.present?
  out += "min-width: #{min_width};" if min_width.present?
  out
end

def z_index_helper

def z_index_helper
  z_index.present? ? "z-index: #{z_index}" : ""
end