Rename goals FilterLinks component to TagCloud

This is more consistent with the "tag_cloud" partial name.
This commit is contained in:
Javi Martín
2021-02-02 17:49:51 +01:00
parent ad56b01a9a
commit 999d1a2cfd
5 changed files with 7 additions and 7 deletions

View File

@@ -1,4 +1,4 @@
.sdg-goal-filter-links {
.sdg-goal-tag-cloud {
.sdg-goal-tag-list {
@extend %sdg-goal-list;

View File

@@ -1,4 +1,4 @@
<div class="sdg-goal-filter-links">
<div class="sdg-goal-tag-cloud">
<div class="sidebar-divider"></div>
<h2 class="sidebar-title"><%= heading %></h2>
<%= render SDG::Goals::TagListComponent.new(class_name) %>

View File

@@ -1,4 +1,4 @@
class SDG::Goals::FilterLinksComponent < ApplicationComponent
class SDG::Goals::TagCloudComponent < ApplicationComponent
attr_reader :class_name
def initialize(class_name)

View File

@@ -13,4 +13,4 @@
</ul>
</div>
<%= render SDG::Goals::FilterLinksComponent.new(taggable) %>
<%= render SDG::Goals::TagCloudComponent.new(taggable) %>

View File

@@ -1,6 +1,6 @@
require "rails_helper"
describe SDG::Goals::FilterLinksComponent, type: :component do
describe SDG::Goals::TagCloudComponent, type: :component do
before do
Setting["feature.sdg"] = true
Setting["sdg.process.debates"] = true
@@ -8,7 +8,7 @@ describe SDG::Goals::FilterLinksComponent, type: :component do
end
it "renders a title" do
component = SDG::Goals::FilterLinksComponent.new("Debate")
component = SDG::Goals::TagCloudComponent.new("Debate")
render_inline component
@@ -16,7 +16,7 @@ describe SDG::Goals::FilterLinksComponent, type: :component do
end
it "renders all goals" do
component = SDG::Goals::FilterLinksComponent.new("Proposal")
component = SDG::Goals::TagCloudComponent.new("Proposal")
render_inline component