Sha256: 48a44284ac160ff43b275aa04a31054843088bd935b01ce2e846b845534a261f

Contents?: true

Size: 669 Bytes

Versions: 8

Compression:

Stored size: 669 Bytes

Contents

module Coco
  module App
    module Elements
      class Stamp < Coco::Component
        include Concerns::AcceptsOptions
        include Concerns::AcceptsTheme

        THEMES = [
          "positive",
          "negative",
          "warning",
          "info"
        ]

        DEFAULT_THEME = "info"

        accepts_option :size, from: %i[xs sm md lg], default: :md
        accepts_option :style, from: %i[subtle vivid inverse compact], default: :subtle
        accepts_option :theme, from: THEMES, default: DEFAULT_THEME

        attr_reader :icon_name

        def initialize(icon:, **kwargs)
          @icon_name = icon
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
coveragebook_components-0.12.2 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.12.1 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.12.0 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.11.0 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.10.1.beta.2 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.10.1.beta.1 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.10.1.beta.0 app/components/coco/app/elements/stamp/stamp.rb
coveragebook_components-0.10.0 app/components/coco/app/elements/stamp/stamp.rb