Sha256: d697051b280e87f5e82e37989c5cc1795dc1a49e00bcc6b199052fa33227d0d4
Contents?: true
Size: 833 Bytes
Versions: 39
Compression:
Stored size: 833 Bytes
Contents
# frozen_string_literal: true module Playbook module PbStatChange class StatChange include Playbook::Props partial "pb_stat_change/stat_change" prop :change, type: Playbook::Props::Enum, values: %w[neutral increase decrease], default: "neutral" prop :value, type: Playbook::Props::Percentage def status case change when "increase" "positive" when "decrease" "negative" else "neutral" end end def icon case change when "increase" "arrow-up" when "decrease" "arrow-down" else false end end def classname generate_classname("pb_stat_change_kit", status) end end end end
Version data entries
39 entries across 39 versions & 1 rubygems