diff --git a/app/views/components/card_component.rb b/app/views/components/card_component.rb index 7858d1664bc..236975a1a7f 100644 --- a/app/views/components/card_component.rb +++ b/app/views/components/card_component.rb @@ -6,7 +6,7 @@ class CardComponent < ApplicationComponent def view_template(&) color = "bg-white dark:bg-black border border-neutral-200 dark:border-neutral-800 text-neutral-900 dark:text-white " box = "w-full px-4 py-6 md:p-10 mb-10 rounded-md shadow overflow-hidden" - article(**classes(color, box), &) + section(**classes(color, box), &) end def head(title = nil, icon: nil, count: nil, url: nil, **options, &block) diff --git a/test/views/card_component_test.rb b/test/views/card_component_test.rb index a36daccf46f..20e355e2d7e 100644 --- a/test/views/card_component_test.rb +++ b/test/views/card_component_test.rb @@ -16,7 +16,7 @@ def render(...) end end - assert_selector "article" + assert_selector "section" assert_selector "h3", text: "Gems" assert_selector "svg.fill-orange" assert_selector "span", text: "3" @@ -36,7 +36,7 @@ def render(...) end end - assert_selector "article" + assert_selector "section" assert_selector "h3", text: "History" assert_text "content" refute_text "View all"