Sha256: 7d3ad2233ebe7c36ff52acfd89f22fec1c8ac29a8a89b7cee0e850c0fa5c7c3c

Contents?: true

Size: 584 Bytes

Versions: 6

Compression:

Stored size: 584 Bytes

Contents

module MissionControl::Jobs::UiHelper
  def blank_status_notice(message)
    tag.div message, class: "mt-6 has-text-centered is-size-3 has-text-grey"
  end

  def blank_status_emoji(status)
    case status.to_s
    when "failed", "blocked" then "😌"
    else ""
    end
  end

  def modifier_for_status(status)
    case status.to_s
    when "failed"      then "is-danger"
    when "blocked"     then "is-warning"
    when "finished"    then "is-success"
    when "scheduled"   then "is-info"
    when "in_progress" then "is-primary"
    else "is-primary is-light"
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
mission_control-jobs-0.3.0 app/helpers/mission_control/jobs/ui_helper.rb
mission_control-jobs-0.2.2 app/helpers/mission_control/jobs/ui_helper.rb
mission_control-jobs-0.2.1 app/helpers/mission_control/jobs/ui_helper.rb
mission_control-jobs-0.2.0 app/helpers/mission_control/jobs/ui_helper.rb
mission_control-jobs-0.1.1 app/helpers/mission_control/jobs/ui_helper.rb
mission_control-jobs-0.1.0 app/helpers/mission_control/jobs/ui_helper.rb