From 7e7a60f4ba36b835b774c640e64d5de19f68fd61 Mon Sep 17 00:00:00 2001 From: Henriette Darge Date: Fri, 11 Oct 2024 11:34:11 +0200 Subject: [PATCH] Add "action" to the list of data attributes that accept multiple values (#3076) --- .changeset/lemon-kiwis-learn.md | 5 +++++ app/lib/primer/attributes_helper.rb | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .changeset/lemon-kiwis-learn.md diff --git a/.changeset/lemon-kiwis-learn.md b/.changeset/lemon-kiwis-learn.md new file mode 100644 index 0000000000..41851e6c4d --- /dev/null +++ b/.changeset/lemon-kiwis-learn.md @@ -0,0 +1,5 @@ +--- +"@primer/view-components": patch +--- + +Add "action" to the list of data attributes that accept multiple values in the `merge_data` helper diff --git a/app/lib/primer/attributes_helper.rb b/app/lib/primer/attributes_helper.rb index 1e39d7215b..d72fe0d6b6 100644 --- a/app/lib/primer/attributes_helper.rb +++ b/app/lib/primer/attributes_helper.rb @@ -4,7 +4,7 @@ module Primer # :nodoc: module AttributesHelper PLURAL_ARIA_ATTRIBUTES = %i[describedby labelledby].freeze - PLURAL_DATA_ATTRIBUTES = %i[target targets].freeze + PLURAL_DATA_ATTRIBUTES = %i[target targets action].freeze def aria(val, system_arguments) system_arguments[:"aria-#{val}"] || system_arguments.dig(:aria, val.to_sym)