decidim-debates 0.27.4 → 0.28.0.rc5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (99) hide show
  1. checksums.yaml +4 -4
  2. data/app/cells/decidim/debates/debate_activity_cell.rb +1 -12
  3. data/app/cells/decidim/debates/debate_card_metadata_cell.rb +43 -0
  4. data/app/cells/decidim/debates/debate_cell.rb +6 -1
  5. data/app/cells/decidim/debates/debate_l_cell.rb +49 -0
  6. data/app/cells/decidim/debates/debate_s_cell.rb +21 -0
  7. data/app/commands/decidim/debates/admin/close_debate.rb +1 -1
  8. data/app/commands/decidim/debates/close_debate.rb +1 -1
  9. data/app/commands/decidim/debates/create_debate.rb +13 -4
  10. data/app/commands/decidim/debates/update_debate.rb +15 -2
  11. data/app/controllers/decidim/debates/admin/debate_closes_controller.rb +2 -2
  12. data/app/controllers/decidim/debates/admin/debates_controller.rb +5 -5
  13. data/app/controllers/decidim/debates/debates_controller.rb +7 -8
  14. data/app/events/decidim/debates/close_debate_event.rb +1 -1
  15. data/app/events/decidim/debates/create_debate_event.rb +1 -1
  16. data/app/forms/decidim/debates/admin/close_debate_form.rb +1 -1
  17. data/app/forms/decidim/debates/close_debate_form.rb +2 -2
  18. data/app/forms/decidim/debates/debate_form.rb +2 -2
  19. data/app/helpers/decidim/debates/application_helper.rb +42 -17
  20. data/app/jobs/decidim/debates/hide_all_created_by_author_job.rb +13 -0
  21. data/app/jobs/decidim/debates/settings_change_job.rb +2 -2
  22. data/app/models/decidim/debates/debate.rb +4 -4
  23. data/app/packs/entrypoints/decidim_debates.js +2 -0
  24. data/app/packs/images/decidim/gamification/badges/decidim_gamification_badges_commented_debates.svg +42 -1
  25. data/app/presenters/decidim/debates/admin_log/debate_presenter.rb +2 -2
  26. data/app/views/decidim/debates/admin/debate_closes/edit.html.erb +26 -14
  27. data/app/views/decidim/debates/admin/debates/_form.html.erb +40 -39
  28. data/app/views/decidim/debates/admin/debates/edit.html.erb +16 -6
  29. data/app/views/decidim/debates/admin/debates/index.html.erb +60 -58
  30. data/app/views/decidim/debates/admin/debates/new.html.erb +16 -6
  31. data/app/views/decidim/debates/debates/_close_debate_modal.html.erb +22 -11
  32. data/app/views/decidim/debates/debates/_debates.html.erb +11 -9
  33. data/app/views/decidim/debates/debates/_form.html.erb +10 -19
  34. data/app/views/decidim/debates/debates/edit.html.erb +16 -20
  35. data/app/views/decidim/debates/debates/index.html.erb +19 -23
  36. data/app/views/decidim/debates/debates/index.js.erb +3 -4
  37. data/app/views/decidim/debates/debates/new.html.erb +16 -20
  38. data/app/views/decidim/debates/debates/show.html.erb +106 -109
  39. data/app/views/decidim/debates/versions/show.html.erb +14 -5
  40. data/config/environment.rb +3 -0
  41. data/config/locales/ar.yml +1 -17
  42. data/config/locales/bg.yml +0 -4
  43. data/config/locales/ca.yml +11 -29
  44. data/config/locales/cs.yml +11 -29
  45. data/config/locales/de.yml +12 -30
  46. data/config/locales/el.yml +3 -28
  47. data/config/locales/en.yml +12 -30
  48. data/config/locales/es-MX.yml +11 -29
  49. data/config/locales/es-PY.yml +12 -30
  50. data/config/locales/es.yml +11 -29
  51. data/config/locales/eu.yml +42 -60
  52. data/config/locales/fi-plain.yml +11 -29
  53. data/config/locales/fi.yml +11 -29
  54. data/config/locales/fr-CA.yml +12 -30
  55. data/config/locales/fr.yml +12 -30
  56. data/config/locales/ga-IE.yml +0 -15
  57. data/config/locales/gl.yml +0 -16
  58. data/config/locales/hu.yml +3 -29
  59. data/config/locales/id-ID.yml +0 -15
  60. data/config/locales/is-IS.yml +0 -12
  61. data/config/locales/it.yml +0 -31
  62. data/config/locales/ja.yml +10 -31
  63. data/config/locales/lb.yml +0 -21
  64. data/config/locales/lt.yml +8 -29
  65. data/config/locales/lv.yml +0 -17
  66. data/config/locales/nl.yml +0 -28
  67. data/config/locales/no.yml +0 -31
  68. data/config/locales/pl.yml +12 -30
  69. data/config/locales/pt-BR.yml +0 -31
  70. data/config/locales/pt.yml +0 -31
  71. data/config/locales/ro-RO.yml +3 -29
  72. data/config/locales/ru.yml +0 -12
  73. data/config/locales/sk.yml +0 -17
  74. data/config/locales/sl.yml +0 -3
  75. data/config/locales/sq-AL.yml +1 -0
  76. data/config/locales/sr-CS.yml +0 -6
  77. data/config/locales/sv.yml +4 -31
  78. data/config/locales/th-TH.yml +1 -0
  79. data/config/locales/tr-TR.yml +1 -30
  80. data/config/locales/uk.yml +0 -12
  81. data/config/locales/zh-CN.yml +0 -29
  82. data/config/locales/zh-TW.yml +2 -28
  83. data/lib/decidim/debates/component.rb +5 -89
  84. data/lib/decidim/debates/engine.rb +29 -7
  85. data/lib/decidim/debates/seeds.rb +104 -0
  86. data/lib/decidim/debates/test/factories.rb +6 -3
  87. data/lib/decidim/debates/version.rb +1 -1
  88. metadata +29 -27
  89. data/app/cells/decidim/debates/debate_m/data.erb +0 -10
  90. data/app/cells/decidim/debates/debate_m/footer.erb +0 -10
  91. data/app/cells/decidim/debates/debate_m/multiple_dates.erb +0 -17
  92. data/app/cells/decidim/debates/debate_m/open_date.erb +0 -7
  93. data/app/cells/decidim/debates/debate_m/single_date.erb +0 -9
  94. data/app/cells/decidim/debates/debate_m/tags.erb +0 -1
  95. data/app/cells/decidim/debates/debate_m_cell.rb +0 -86
  96. data/app/controllers/decidim/debates/widgets_controller.rb +0 -19
  97. data/app/views/decidim/debates/debates/_count.html.erb +0 -1
  98. data/app/views/decidim/debates/debates/_filters.html.erb +0 -34
  99. data/app/views/decidim/debates/debates/_filters_small_view.html.erb +0 -18
@@ -51,7 +51,6 @@ zh-TW:
51
51
  confirm_destroy: 您確定嗎?
52
52
  destroy: 刪除
53
53
  edit: 編輯
54
- new: 新增 %{name}
55
54
  title: 操作
56
55
  admin:
57
56
  debate_closes:
@@ -81,9 +80,6 @@ zh-TW:
81
80
  success: 辯論已成功更新
82
81
  exports:
83
82
  comments: 評論
84
- models:
85
- debate:
86
- name: 辯論
87
83
  admin_log:
88
84
  debate:
89
85
  close: "%{user_name} 在 %{space_name} 空間關閉了 %{resource_name} 辯論。"
@@ -96,18 +92,14 @@ zh-TW:
96
92
  invalid: 關閉辯論時出現問題
97
93
  success: 辯論成功關閉
98
94
  close_debate_modal:
99
- close: 關閉
100
95
  description: 這場辯論的總結或結論是什麼?
101
96
  send: 關閉辯論
102
- closed: 關閉
103
97
  count:
104
98
  debates_count:
105
99
  other: "%{count} 場辯論"
106
100
  create:
107
101
  invalid: 建立辯論時出現問題。
108
102
  success: 辯論建立成功。
109
- debate:
110
- participate: 參與
111
103
  edit:
112
104
  back: 返回
113
105
  save: 保存更改
@@ -122,18 +114,11 @@ zh-TW:
122
114
  official: 官方
123
115
  origin: 起源
124
116
  participants: 參與者
125
- scope: 範圍
126
117
  search: 搜尋
127
118
  state: 狀態
128
119
  state_values:
129
120
  closed: 關閉
130
121
  open: 開啟
131
- user_groups: 群組
132
- filters_small_view:
133
- close_modal: 關閉視窗
134
- filter: 篩選
135
- filter_by: 篩選條件
136
- unfold: 展開
137
122
  form:
138
123
  select_a_category: 請選擇一個類別
139
124
  index:
@@ -149,31 +134,20 @@ zh-TW:
149
134
  recent: 最近
150
135
  updated: 最近更新
151
136
  show:
152
- back: 返回列表
153
137
  close_debate: 關閉辯論
154
- date: 日期
155
138
  debate_closed: 關閉
156
139
  debate_conclusions_are: '此辯論已於 %{date} 結束,以下是總結結論:'
157
140
  edit_conclusions: 修改結論
158
141
  edit_debate: 編輯辯論
159
142
  groups_count: 群組
160
- last_comment_by: 最後評論
161
- no_comments_yet: 尚無留言
162
143
  open: 開放性辯論
163
144
  participants_count: 參與者
164
145
  update:
165
146
  invalid: 更新此辯論時發生問題。
166
147
  success: 辯論已成功更新
167
- versions:
168
- debates:
169
- back_to_resource: 返回辯論
170
- index:
171
- title: 版本
172
- versions_list:
173
- back_to_resource: 返回辯論
174
148
  last_activity:
175
- debate_updated_at_html: "<span>辯論已更新,連結網址為 %{link}</span>"
176
- new_debate_at_html: "<span>新的辯論,連結網址為 %{link}</span>"
149
+ debate_updated: '辯論已更新:'
150
+ new_debate: '新辯論:'
177
151
  models:
178
152
  debate:
179
153
  fields:
@@ -1,11 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "decidim/components/namer"
4
-
5
3
  Decidim.register_component(:debates) do |component|
6
4
  component.engine = Decidim::Debates::Engine
7
5
  component.admin_engine = Decidim::Debates::AdminEngine
8
6
  component.icon = "media/images/decidim_debates.svg"
7
+ component.icon_key = "discuss-line"
9
8
  component.permissions_class_name = "Decidim::Debates::Permissions"
10
9
 
11
10
  component.query_type = "Decidim::Debates::DebatesType"
@@ -14,14 +13,14 @@ Decidim.register_component(:debates) do |component|
14
13
  component.newsletter_participant_entities = ["Decidim::Debates::Debate"]
15
14
 
16
15
  component.on(:before_destroy) do |instance|
17
- raise StandardError, "Can't remove this component" if Decidim::Debates::Debate.where(component: instance).any?
16
+ raise StandardError, "Cannot remove this component" if Decidim::Debates::Debate.where(component: instance).any?
18
17
  end
19
18
 
20
19
  component.settings(:global) do |settings|
21
20
  settings.attribute :scopes_enabled, type: :boolean, default: false
22
21
  settings.attribute :scope_id, type: :scope
23
22
  settings.attribute :comments_enabled, type: :boolean, default: true
24
- settings.attribute :comments_max_length, type: :integer, required: false
23
+ settings.attribute :comments_max_length, type: :integer, required: true
25
24
  settings.attribute :announcement, type: :text, translated: true, editor: true
26
25
  end
27
26
 
@@ -68,91 +67,8 @@ Decidim.register_component(:debates) do |component|
68
67
  end
69
68
 
70
69
  component.seeds do |participatory_space|
71
- admin_user = Decidim::User.find_by(
72
- organization: participatory_space.organization,
73
- email: "admin@example.org"
74
- )
75
-
76
- user = Decidim::User.find_by(
77
- organization: participatory_space.organization,
78
- email: "user@example.org"
79
- )
80
-
81
- params = {
82
- name: Decidim::Components::Namer.new(participatory_space.organization.available_locales, :debates).i18n_name,
83
- manifest_name: :debates,
84
- published_at: Time.current,
85
- participatory_space: participatory_space
86
- }
87
-
88
- component = Decidim.traceability.perform_action!(
89
- "publish",
90
- Decidim::Component,
91
- admin_user,
92
- visibility: "all"
93
- ) do
94
- Decidim::Component.create!(params)
95
- end
96
-
97
- 5.times do |x|
98
- finite = x != 2
99
- if finite
100
- start_time = [rand(1..20).weeks.from_now, rand(1..20).weeks.ago].sample
101
- end_time = start_time + [rand(1..4).hours, rand(1..20).days].sample
102
- else
103
- start_time = nil
104
- end_time = nil
105
- end
106
- params = {
107
- component: component,
108
- category: participatory_space.categories.sample,
109
- title: Decidim::Faker::Localized.sentence(word_count: 2),
110
- description: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
111
- Decidim::Faker::Localized.paragraph(sentence_count: 3)
112
- end,
113
- instructions: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
114
- Decidim::Faker::Localized.paragraph(sentence_count: 3)
115
- end,
116
- start_time: start_time,
117
- end_time: end_time,
118
- author: component.organization
119
- }
120
-
121
- debate = Decidim.traceability.create!(
122
- Decidim::Debates::Debate,
123
- admin_user,
124
- params,
125
- visibility: "all"
126
- )
127
-
128
- Decidim::Comments::Seed.comments_for(debate)
129
- end
130
-
131
- closed_debate = Decidim::Debates::Debate.last
132
- closed_debate.conclusions = Decidim::Faker::Localized.wrapped("<p>", "</p>") do
133
- Decidim::Faker::Localized.paragraph(sentence_count: 3)
134
- end
135
- closed_debate.closed_at = Time.current
136
- closed_debate.save!
137
-
138
- params = {
139
- component: component,
140
- category: participatory_space.categories.sample,
141
- title: Decidim::Faker::Localized.sentence(word_count: 2),
142
- description: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
143
- Decidim::Faker::Localized.paragraph(sentence_count: 3)
144
- end,
145
- instructions: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
146
- Decidim::Faker::Localized.paragraph(sentence_count: 3)
147
- end,
148
- author: user
149
- }
70
+ require "decidim/debates/seeds"
150
71
 
151
- Decidim.traceability.create!(
152
- Decidim::Debates::Debate,
153
- user,
154
- params,
155
- visibility: "all"
156
- )
72
+ Decidim::Debates::Seeds.new(participatory_space:).call
157
73
  end
158
74
  end
@@ -13,13 +13,19 @@ module Decidim
13
13
  member do
14
14
  post :close
15
15
  end
16
- resources :versions, only: [:show, :index]
17
- resource :widget, only: :show, path: "embed"
16
+ resources :versions, only: [:show]
18
17
  end
19
- root to: "debates#index"
18
+ scope "/debates" do
19
+ root to: "debates#index"
20
+ end
21
+ get "/", to: redirect("debates", status: 301)
22
+ end
23
+
24
+ initializer "decidim_debates.register_icons" do
25
+ Decidim.icons.register(name: "Decidim::Debates::Debate", icon: "discuss-line", description: "Debate", category: "activity", engine: :debates)
20
26
  end
21
27
 
22
- initializer "decidim_changes" do
28
+ initializer "decidim_debates.settings_changes" do
23
29
  config.to_prepare do
24
30
  Decidim::SettingsChange.subscribe "debates" do |changes|
25
31
  Decidim::Debates::SettingsChangeJob.perform_later(
@@ -31,12 +37,12 @@ module Decidim
31
37
  end
32
38
  end
33
39
 
34
- initializer "decidim_meetings.add_cells_view_paths" do
40
+ initializer "decidim_debates.add_cells_view_paths" do
35
41
  Cell::ViewModel.view_paths << File.expand_path("#{Decidim::Debates::Engine.root}/app/cells")
36
42
  Cell::ViewModel.view_paths << File.expand_path("#{Decidim::Debates::Engine.root}/app/views") # for partials
37
43
  end
38
44
 
39
- initializer "decidim.debates.commented_debates_badge" do
45
+ initializer "decidim_debates.commented_debates_badge" do
40
46
  Decidim::Gamification.register_badge(:commented_debates) do |badge|
41
47
  badge.levels = [1, 5, 10, 30, 50]
42
48
 
@@ -45,7 +51,7 @@ module Decidim
45
51
  badge.reset = lambda do |user|
46
52
  debates = Decidim::Comments::Comment.where(
47
53
  author: user,
48
- decidim_root_commentable_type: "Decidim::Debates::Debate"\
54
+ decidim_root_commentable_type: "Decidim::Debates::Debate"
49
55
  )
50
56
  debates.pluck(:decidim_root_commentable_id).uniq.count
51
57
  end
@@ -101,6 +107,22 @@ module Decidim
101
107
  initializer "decidim_debates.webpacker.assets_path" do
102
108
  Decidim.register_assets_path File.expand_path("app/packs", root)
103
109
  end
110
+
111
+ initializer "decidim_debates.authorization_transfer" do
112
+ config.to_prepare do
113
+ Decidim::AuthorizationTransfer.register(:debates) do |transfer|
114
+ transfer.move_records(Decidim::Debates::Debate, :decidim_author_id)
115
+ end
116
+ end
117
+ end
118
+
119
+ initializer "decidim_debates.moderation_content" do
120
+ config.to_prepare do
121
+ ActiveSupport::Notifications.subscribe("decidim.admin.block_user:after") do |_event_name, data|
122
+ Decidim::Debates::HideAllCreatedByAuthorJob.perform_later(**data)
123
+ end
124
+ end
125
+ end
104
126
  end
105
127
  end
106
128
  end
@@ -0,0 +1,104 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "decidim/components/namer"
4
+
5
+ module Decidim
6
+ module Debates
7
+ class Seeds
8
+ attr_reader :participatory_space
9
+
10
+ def initialize(participatory_space:)
11
+ @participatory_space = participatory_space
12
+ end
13
+
14
+ def call
15
+ admin_user = Decidim::User.find_by(
16
+ organization: participatory_space.organization,
17
+ email: "admin@example.org"
18
+ )
19
+
20
+ user = Decidim::User.find_by(
21
+ organization: participatory_space.organization,
22
+ email: "user@example.org"
23
+ )
24
+
25
+ params = {
26
+ name: Decidim::Components::Namer.new(participatory_space.organization.available_locales, :debates).i18n_name,
27
+ manifest_name: :debates,
28
+ published_at: Time.current,
29
+ participatory_space:
30
+ }
31
+
32
+ component = Decidim.traceability.perform_action!(
33
+ "publish",
34
+ Decidim::Component,
35
+ admin_user,
36
+ visibility: "all"
37
+ ) do
38
+ Decidim::Component.create!(params)
39
+ end
40
+
41
+ 5.times do |x|
42
+ finite = x != 2
43
+ if finite
44
+ start_time = [rand(1..20).weeks.from_now, rand(1..20).weeks.ago].sample
45
+ end_time = start_time + [rand(1..4).hours, rand(1..20).days].sample
46
+ else
47
+ start_time = nil
48
+ end_time = nil
49
+ end
50
+ params = {
51
+ component:,
52
+ category: participatory_space.categories.sample,
53
+ title: Decidim::Faker::Localized.sentence(word_count: 2),
54
+ description: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
55
+ Decidim::Faker::Localized.paragraph(sentence_count: 3)
56
+ end,
57
+ instructions: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
58
+ Decidim::Faker::Localized.paragraph(sentence_count: 3)
59
+ end,
60
+ start_time:,
61
+ end_time:,
62
+ author: component.organization
63
+ }
64
+
65
+ debate = Decidim.traceability.create!(
66
+ Decidim::Debates::Debate,
67
+ admin_user,
68
+ params,
69
+ visibility: "all"
70
+ )
71
+
72
+ Decidim::Comments::Seed.comments_for(debate)
73
+ end
74
+
75
+ closed_debate = Decidim::Debates::Debate.last
76
+ closed_debate.conclusions = Decidim::Faker::Localized.wrapped("<p>", "</p>") do
77
+ Decidim::Faker::Localized.paragraph(sentence_count: 3)
78
+ end
79
+ closed_debate.closed_at = Time.current
80
+ closed_debate.save!
81
+
82
+ params = {
83
+ component:,
84
+ category: participatory_space.categories.sample,
85
+ title: Decidim::Faker::Localized.sentence(word_count: 2),
86
+ description: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
87
+ Decidim::Faker::Localized.paragraph(sentence_count: 3)
88
+ end,
89
+ instructions: Decidim::Faker::Localized.wrapped("<p>", "</p>") do
90
+ Decidim::Faker::Localized.paragraph(sentence_count: 3)
91
+ end,
92
+ author: user
93
+ }
94
+
95
+ Decidim.traceability.create!(
96
+ Decidim::Debates::Debate,
97
+ user,
98
+ params,
99
+ visibility: "all"
100
+ )
101
+ end
102
+ end
103
+ end
104
+ end
@@ -1,5 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require "decidim/components/namer"
4
+
3
5
  def generate_localized_debate_title
4
6
  Decidim::Faker::Localized.localized { "<script>alert(\"TITLE\");</script> #{generate(:title)}" }
5
7
  end
@@ -20,7 +22,7 @@ FactoryBot.define do
20
22
  description { Decidim::Faker::Localized.wrapped("<p>", "</p>") { generate_localized_debate_title } }
21
23
  information_updates { Decidim::Faker::Localized.wrapped("<p>", "</p>") { generate_localized_debate_title } }
22
24
  instructions { Decidim::Faker::Localized.wrapped("<p>", "</p>") { generate_localized_debate_title } }
23
- component { build(:component, manifest_name: "debates") }
25
+ component { build(:debates_component) }
24
26
  author { component.try(:organization) }
25
27
 
26
28
  trait :open_ama do
@@ -64,10 +66,11 @@ FactoryBot.define do
64
66
  factory :debates_component, parent: :component do
65
67
  name { Decidim::Components::Namer.new(participatory_space.organization.available_locales, :debates).i18n_name }
66
68
  manifest_name { :debates }
67
- participatory_space { create(:participatory_process, :with_steps, organization: organization) }
69
+ participatory_space { create(:participatory_process, :with_steps, organization:) }
68
70
  settings do
69
71
  {
70
- comments_enabled: true
72
+ comments_enabled: true,
73
+ comments_max_length: organization.comments_max_length
71
74
  }
72
75
  end
73
76
 
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds the decidim-debates version.
5
5
  module Debates
6
6
  def self.version
7
- "0.27.4"
7
+ "0.28.0.rc5"
8
8
  end
9
9
  end
10
10
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-debates
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.27.4
4
+ version: 0.28.0.rc5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2023-07-27 00:00:00.000000000 Z
14
+ date: 2023-12-18 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: decidim-comments
@@ -19,56 +19,56 @@ dependencies:
19
19
  requirements:
20
20
  - - '='
21
21
  - !ruby/object:Gem::Version
22
- version: 0.27.4
22
+ version: 0.28.0.rc5
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - '='
28
28
  - !ruby/object:Gem::Version
29
- version: 0.27.4
29
+ version: 0.28.0.rc5
30
30
  - !ruby/object:Gem::Dependency
31
31
  name: decidim-core
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  requirements:
34
34
  - - '='
35
35
  - !ruby/object:Gem::Version
36
- version: 0.27.4
36
+ version: 0.28.0.rc5
37
37
  type: :runtime
38
38
  prerelease: false
39
39
  version_requirements: !ruby/object:Gem::Requirement
40
40
  requirements:
41
41
  - - '='
42
42
  - !ruby/object:Gem::Version
43
- version: 0.27.4
43
+ version: 0.28.0.rc5
44
44
  - !ruby/object:Gem::Dependency
45
45
  name: decidim-admin
46
46
  requirement: !ruby/object:Gem::Requirement
47
47
  requirements:
48
48
  - - '='
49
49
  - !ruby/object:Gem::Version
50
- version: 0.27.4
50
+ version: 0.28.0.rc5
51
51
  type: :development
52
52
  prerelease: false
53
53
  version_requirements: !ruby/object:Gem::Requirement
54
54
  requirements:
55
55
  - - '='
56
56
  - !ruby/object:Gem::Version
57
- version: 0.27.4
57
+ version: 0.28.0.rc5
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: decidim-dev
60
60
  requirement: !ruby/object:Gem::Requirement
61
61
  requirements:
62
62
  - - '='
63
63
  - !ruby/object:Gem::Version
64
- version: 0.27.4
64
+ version: 0.28.0.rc5
65
65
  type: :development
66
66
  prerelease: false
67
67
  version_requirements: !ruby/object:Gem::Requirement
68
68
  requirements:
69
69
  - - '='
70
70
  - !ruby/object:Gem::Version
71
- version: 0.27.4
71
+ version: 0.28.0.rc5
72
72
  description: A debates component for decidim's participatory spaces.
73
73
  email:
74
74
  - josepjaume@gmail.com
@@ -82,14 +82,10 @@ files:
82
82
  - README.md
83
83
  - Rakefile
84
84
  - app/cells/decidim/debates/debate_activity_cell.rb
85
+ - app/cells/decidim/debates/debate_card_metadata_cell.rb
85
86
  - app/cells/decidim/debates/debate_cell.rb
86
- - app/cells/decidim/debates/debate_m/data.erb
87
- - app/cells/decidim/debates/debate_m/footer.erb
88
- - app/cells/decidim/debates/debate_m/multiple_dates.erb
89
- - app/cells/decidim/debates/debate_m/open_date.erb
90
- - app/cells/decidim/debates/debate_m/single_date.erb
91
- - app/cells/decidim/debates/debate_m/tags.erb
92
- - app/cells/decidim/debates/debate_m_cell.rb
87
+ - app/cells/decidim/debates/debate_l_cell.rb
88
+ - app/cells/decidim/debates/debate_s_cell.rb
93
89
  - app/cells/decidim/debates/reported_content/show.erb
94
90
  - app/cells/decidim/debates/reported_content_cell.rb
95
91
  - app/commands/decidim/debates/admin/close_debate.rb
@@ -105,7 +101,6 @@ files:
105
101
  - app/controllers/decidim/debates/debates_controller.rb
106
102
  - app/controllers/decidim/debates/orderable.rb
107
103
  - app/controllers/decidim/debates/versions_controller.rb
108
- - app/controllers/decidim/debates/widgets_controller.rb
109
104
  - app/events/decidim/debates/close_debate_event.rb
110
105
  - app/events/decidim/debates/create_debate_event.rb
111
106
  - app/events/decidim/debates/creation_disabled_event.rb
@@ -117,9 +112,11 @@ files:
117
112
  - app/helpers/decidim/debates/admin/application_helper.rb
118
113
  - app/helpers/decidim/debates/application_helper.rb
119
114
  - app/helpers/decidim/debates/debate_cells_helper.rb
115
+ - app/jobs/decidim/debates/hide_all_created_by_author_job.rb
120
116
  - app/jobs/decidim/debates/settings_change_job.rb
121
117
  - app/models/decidim/debates/application_record.rb
122
118
  - app/models/decidim/debates/debate.rb
119
+ - app/packs/entrypoints/decidim_debates.js
123
120
  - app/packs/entrypoints/decidim_debates_admin.js
124
121
  - app/packs/images/decidim/debates/decidim_debates.svg
125
122
  - app/packs/images/decidim/gamification/badges/decidim_gamification_badges_commented_debates.svg
@@ -143,11 +140,8 @@ files:
143
140
  - app/views/decidim/debates/admin/debates/index.html.erb
144
141
  - app/views/decidim/debates/admin/debates/new.html.erb
145
142
  - app/views/decidim/debates/debates/_close_debate_modal.html.erb
146
- - app/views/decidim/debates/debates/_count.html.erb
147
143
  - app/views/decidim/debates/debates/_debate.html.erb
148
144
  - app/views/decidim/debates/debates/_debates.html.erb
149
- - app/views/decidim/debates/debates/_filters.html.erb
150
- - app/views/decidim/debates/debates/_filters_small_view.html.erb
151
145
  - app/views/decidim/debates/debates/_form.html.erb
152
146
  - app/views/decidim/debates/debates/edit.html.erb
153
147
  - app/views/decidim/debates/debates/index.html.erb
@@ -224,9 +218,11 @@ files:
224
218
  - config/locales/sk.yml
225
219
  - config/locales/sl.yml
226
220
  - config/locales/so-SO.yml
221
+ - config/locales/sq-AL.yml
227
222
  - config/locales/sr-CS.yml
228
223
  - config/locales/sv.yml
229
224
  - config/locales/sw-KE.yml
225
+ - config/locales/th-TH.yml
230
226
  - config/locales/ti-ER.yml
231
227
  - config/locales/tr-TR.yml
232
228
  - config/locales/uk.yml
@@ -263,12 +259,18 @@ files:
263
259
  - lib/decidim/debates/api.rb
264
260
  - lib/decidim/debates/component.rb
265
261
  - lib/decidim/debates/engine.rb
262
+ - lib/decidim/debates/seeds.rb
266
263
  - lib/decidim/debates/test/factories.rb
267
264
  - lib/decidim/debates/version.rb
268
- homepage: https://github.com/decidim/decidim
265
+ homepage: https://decidim.org
269
266
  licenses:
270
267
  - AGPL-3.0
271
- metadata: {}
268
+ metadata:
269
+ bug_tracker_uri: https://github.com/decidim/decidim/issues
270
+ documentation_uri: https://docs.decidim.org/
271
+ funding_uri: https://opencollective.com/decidim
272
+ homepage_uri: https://decidim.org
273
+ source_code_uri: https://github.com/decidim/decidim
272
274
  post_install_message:
273
275
  rdoc_options: []
274
276
  require_paths:
@@ -277,14 +279,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
277
279
  requirements:
278
280
  - - ">="
279
281
  - !ruby/object:Gem::Version
280
- version: '3.0'
282
+ version: '3.1'
281
283
  required_rubygems_version: !ruby/object:Gem::Requirement
282
284
  requirements:
283
- - - ">="
285
+ - - ">"
284
286
  - !ruby/object:Gem::Version
285
- version: '0'
287
+ version: 1.3.1
286
288
  requirements: []
287
- rubygems_version: 3.2.22
289
+ rubygems_version: 3.4.22
288
290
  signing_key:
289
291
  specification_version: 4
290
292
  summary: Decidim debates module
@@ -1,10 +0,0 @@
1
- <% if debate_date.present? %>
2
- <div class="card__icondata">
3
- <ul class="card-data">
4
- <li class="card-data__item">
5
- <%= icon "datetime", class: "icon--big", role: "img", aria_label: t("decidim.debates.debates.show.date") %>
6
- </li>
7
- <%= debate_date %>
8
- </ul>
9
- </div>
10
- <% end %>
@@ -1,10 +0,0 @@
1
- <div class="card__footer">
2
- <div class="card__support">
3
- <% if presenter.last_comment_by %>
4
- <% author = presenter.last_comment_by %>
5
- <%= cell "decidim/author", author, from: model, author_name_text: t(".commented_time_ago", time: presenter.last_comment_at), context: { extra_classes: ["author-data--small"] } %>
6
- <% end %>
7
-
8
- <%= link_to t("participate", scope: "decidim.debates.debates.debate"), resource_path, class: "card__button button button--sc small" %>
9
- </div>
10
- </div>
@@ -1,17 +0,0 @@
1
- <li class="card-data__item">
2
- <div class="card-data__item--multiple">
3
- <div>
4
- <strong>
5
- <%= l start_date, format: :decidim_with_month_name %>
6
- </strong>
7
- <%= formatted_start_time %>
8
- </div>
9
- <%= icon "arrow-thin-right", class: "icon--big muted", role: "img", "aria-hidden": true %>
10
- <div>
11
- <strong>
12
- <%= l end_date, format: :decidim_with_month_name %>
13
- </strong>
14
- <%= formatted_end_time %>
15
- </div>
16
- </div>
17
- </li>
@@ -1,7 +0,0 @@
1
- <li class="card-data__item">
2
- <div>
3
- <strong>
4
- <%= t("decidim.debates.debates.show.open") %>
5
- </strong>
6
- </div>
7
- </li>
@@ -1,9 +0,0 @@
1
- <li class="card-data__item">
2
- <div>
3
- <strong>
4
- <%= l start_date, format: :decidim_with_month_name %>
5
- </strong>
6
- &nbsp;·&nbsp;
7
- <%= formatted_start_time %> - <%= formatted_end_time %>
8
- </div>
9
- </li>
@@ -1 +0,0 @@
1
- <%= render partial: "decidim/shared/tags.html", locals: { resource: model, tags_class_extra: "tags--debate" } %>