debian-mirror-gitlab/app/components/pajamas/progress_component.rb
2022-11-25 23:54:43 +05:30

12 lines
310 B
Ruby

# frozen_string_literal: true
module Pajamas
class ProgressComponent < Pajamas::Component
def initialize(value: 0, variant: :primary)
@value = value
@variant = filter_attribute(variant, VARIANT_OPTIONS, default: :primary)
end
VARIANT_OPTIONS = [:primary, :success].freeze
end
end