in app/components/primer/counter_component.rb [39:65]
def initialize(
count: 0,
scheme: DEFAULT_SCHEME,
limit: 5_000,
hide_if_zero: false,
text: "",
round: false,
**system_arguments
)
@count = count
@limit = limit
@hide_if_zero = hide_if_zero
@text = text
@round = round
@system_arguments = deny_tag_argument(**system_arguments)
@has_limit = !@limit.nil?
@system_arguments[:title] = title
@system_arguments[:tag] = :span
@system_arguments[:classes] = class_names(
"Counter",
@system_arguments[:classes],
SCHEME_MAPPINGS[fetch_or_fallback(SCHEME_OPTIONS, scheme, DEFAULT_SCHEME, deprecated_values: DEPRECATED_SCHEME_OPTIONS)]
)
@system_arguments[:hidden] = true if count == 0 && hide_if_zero
end