diff --git a/.changeset/new-lamps-poke.md b/.changeset/new-lamps-poke.md new file mode 100644 index 0000000000..c26bf263e7 --- /dev/null +++ b/.changeset/new-lamps-poke.md @@ -0,0 +1,5 @@ +--- +'@primer/view-components': patch +--- + +Fix: Allow month attribute for Primer::Beta::RelativeTime diff --git a/app/components/primer/beta/relative_time.rb b/app/components/primer/beta/relative_time.rb index 65c1411f56..a511619fff 100644 --- a/app/components/primer/beta/relative_time.rb +++ b/app/components/primer/beta/relative_time.rb @@ -131,7 +131,7 @@ def initialize( @system_arguments[:hour] = fetch_or_fallback(HOUR_OPTIONS, hour, HOUR_DEFAULT) if hour.present? @system_arguments[:weekday] = fetch_or_fallback(WEEKDAY_OPTIONS, weekday, WEEKDAY_DEFAULT) if weekday.present? @system_arguments[:day] = fetch_or_fallback(DAY_OPTIONS, day, DAY_DEFAULT) if day.present? - @system_arguments[:month] = fetch_or_fallback(MONTH_DEFAULT, month, MONTH_DEFAULT) if month.present? + @system_arguments[:month] = fetch_or_fallback(MONTH_OPTIONS, month, MONTH_DEFAULT) if month.present? @system_arguments[:year] = fetch_or_fallback(YEAR_OPTIONS, year, YEAR_DEFAULT) if year.present? @system_arguments[:"time-zone-name"] = fetch_or_fallback(TIMEZONENAME_OPTIONS, time_zone_name, TIMEZONENAME_DEFAULT) if time_zone_name.present? @system_arguments[:threshold] = threshold if threshold.present?