decidim-consultations 0.24.3 → 0.25.0.rc4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (100) hide show
  1. checksums.yaml +4 -4
  2. data/app/cells/decidim/consultations/consultation_m_cell.rb +1 -1
  3. data/app/cells/decidim/consultations/content_blocks/highlighted_consultations/show.erb +1 -1
  4. data/app/commands/decidim/consultations/admin/update_consultation.rb +5 -13
  5. data/app/commands/decidim/consultations/admin/update_question.rb +5 -13
  6. data/app/controllers/concerns/decidim/consultations/needs_question.rb +1 -1
  7. data/app/forms/decidim/consultations/admin/consultation_form.rb +2 -2
  8. data/app/forms/decidim/consultations/admin/question_form.rb +3 -3
  9. data/app/models/decidim/consultation.rb +4 -4
  10. data/app/models/decidim/consultations/question.rb +13 -5
  11. data/app/packs/entrypoints/decidim_consultations.js +8 -0
  12. data/app/{assets/images/decidim/consultations/icon.svg → packs/images/decidim/consultations/decidim_consultations.svg} +0 -0
  13. data/app/packs/src/decidim/consultations/show_more.js +10 -0
  14. data/app/{assets/javascripts/decidim/consultations/utils.js.es6 → packs/src/decidim/consultations/utils.js} +5 -5
  15. data/app/{assets/javascripts → packs/src}/decidim/consultations/utils_multiple.js +2 -1
  16. data/app/{assets/javascripts → packs/src}/decidim/consultations/vote_dialog.js +1 -1
  17. data/app/{assets → packs}/stylesheets/decidim/consultations/_question.scss +0 -0
  18. data/app/{assets → packs}/stylesheets/decidim/consultations/_question_multiple_votes.scss +0 -0
  19. data/app/{assets → packs}/stylesheets/decidim/consultations/_stats.scss +0 -0
  20. data/app/{assets → packs}/stylesheets/decidim/consultations/_video_wrapper.scss +0 -0
  21. data/app/{assets → packs}/stylesheets/decidim/consultations/banners/_block-banner.scss +0 -0
  22. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-banner.scss +0 -0
  23. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-card.scss +0 -0
  24. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-header.scss +0 -0
  25. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-home-banner.scss +0 -0
  26. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-home-intro.scss +0 -0
  27. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-intro.scss +0 -0
  28. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations-title.scss +0 -0
  29. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/_consultations_nav.scss +0 -0
  30. data/app/{assets → packs}/stylesheets/decidim/consultations/consultations/introductory_image.scss +0 -0
  31. data/app/packs/stylesheets/decidim/consultations/consultations.scss +14 -0
  32. data/app/{assets/stylesheets/decidim/consultations/highlighted-content-banner.css.scss → packs/stylesheets/decidim/consultations/highlighted-content-banner.scss} +0 -0
  33. data/app/queries/decidim/consultations/admin/admin_users.rb +16 -12
  34. data/app/views/decidim/consultations/_consultation.html.erb +1 -1
  35. data/app/views/decidim/consultations/admin/consultations/_form.html.erb +1 -1
  36. data/app/views/decidim/consultations/admin/question_configuration/_form.html.erb +1 -1
  37. data/app/views/decidim/consultations/admin/questions/_form.html.erb +1 -1
  38. data/app/views/decidim/consultations/consultations/_consultation_card.html.erb +1 -1
  39. data/app/views/decidim/consultations/consultations/_consultation_details.html.erb +1 -1
  40. data/app/views/decidim/consultations/consultations/_filters.html.erb +1 -0
  41. data/app/views/decidim/consultations/consultations/index.html.erb +1 -2
  42. data/app/views/decidim/consultations/question_multiple_votes/_voting_rules.html.erb +1 -1
  43. data/app/views/decidim/consultations/questions/_right_column.html.erb +1 -1
  44. data/app/views/decidim/consultations/questions/_vote_button.html.erb +1 -2
  45. data/app/views/decidim/consultations/questions/show.html.erb +3 -2
  46. data/app/views/layouts/decidim/_consultation_header.html.erb +1 -1
  47. data/app/views/layouts/decidim/_question_components.html.erb +1 -1
  48. data/app/views/layouts/decidim/_question_header.html.erb +1 -1
  49. data/app/views/layouts/decidim/admin/consultation.html.erb +1 -1
  50. data/app/views/layouts/decidim/admin/question.html.erb +4 -83
  51. data/config/assets.rb +9 -0
  52. data/config/locales/ar.yml +2 -8
  53. data/config/locales/ca.yml +5 -8
  54. data/config/locales/cs.yml +5 -8
  55. data/config/locales/de.yml +5 -8
  56. data/config/locales/el.yml +2 -8
  57. data/config/locales/en.yml +6 -8
  58. data/config/locales/es-MX.yml +5 -8
  59. data/config/locales/es-PY.yml +5 -8
  60. data/config/locales/es.yml +5 -8
  61. data/config/locales/eu.yml +2 -8
  62. data/config/locales/fi-plain.yml +5 -8
  63. data/config/locales/fi.yml +5 -8
  64. data/config/locales/fr-CA.yml +3 -9
  65. data/config/locales/fr-LU.yml +372 -0
  66. data/config/locales/fr.yml +2 -8
  67. data/config/locales/gl.yml +5 -8
  68. data/config/locales/hu.yml +2 -8
  69. data/config/locales/id-ID.yml +2 -8
  70. data/config/locales/is-IS.yml +2 -8
  71. data/config/locales/it.yml +6 -8
  72. data/config/locales/ja.yml +8 -8
  73. data/config/locales/lb-LU.yml +1 -0
  74. data/config/locales/lv.yml +2 -8
  75. data/config/locales/nl.yml +5 -8
  76. data/config/locales/no.yml +2 -8
  77. data/config/locales/pl.yml +5 -8
  78. data/config/locales/pt-BR.yml +90 -8
  79. data/config/locales/pt.yml +2 -8
  80. data/config/locales/ro-RO.yml +5 -8
  81. data/config/locales/ru.yml +2 -8
  82. data/config/locales/sk.yml +2 -8
  83. data/config/locales/sv.yml +5 -8
  84. data/config/locales/tr-TR.yml +2 -8
  85. data/config/locales/uk.yml +2 -8
  86. data/config/locales/zh-CN.yml +2 -8
  87. data/lib/decidim/api/consultation_question_type.rb +8 -0
  88. data/lib/decidim/api/consultation_type.rb +8 -0
  89. data/lib/decidim/consultations/admin_engine.rb +109 -24
  90. data/lib/decidim/consultations/engine.rb +6 -12
  91. data/lib/decidim/consultations/participatory_space.rb +46 -9
  92. data/lib/decidim/consultations/version.rb +1 -1
  93. metadata +37 -38
  94. data/app/assets/config/decidim_consultations_manifest.css +0 -3
  95. data/app/assets/config/decidim_consultations_manifest.js +0 -5
  96. data/app/assets/images/decidim/consultations/icon2.svg +0 -1
  97. data/app/assets/javascripts/decidim/consultations/show_more.js.es6 +0 -12
  98. data/app/assets/stylesheets/decidim/consultations/consultations.scss +0 -6
  99. data/app/helpers/decidim/consultations/admin/consultation_menu_helper.rb +0 -15
  100. data/config/locales/ja-JP.yml +0 -367
@@ -55,36 +55,121 @@ module Decidim
55
55
 
56
56
  initializer "decidim_consultations.admin_consultation_menu" do
57
57
  Decidim.menu :admin_consultation_menu do |menu|
58
- menu.item I18n.t("info", scope: "decidim.admin.menu.consultations_submenu"),
59
- decidim_admin_consultations.edit_consultation_path(current_consultation),
60
- position: 1.0,
61
- active: is_active_link?(decidim_admin_consultations.edit_consultation_path(current_consultation)),
62
- if: allowed_to?(:update, :consultation, consultation: current_consultation)
63
- menu.item I18n.t("questions", scope: "decidim.admin.menu.consultations_submenu"),
64
- decidim_admin_consultations.consultation_questions_path(current_consultation),
65
- position: 1.1,
66
- active: is_active_link?(decidim_admin_consultations.consultation_questions_path(current_consultation)),
67
- if: allowed_to?(:read, :question)
68
- menu.item I18n.t("results", scope: "decidim.admin.menu.consultations_submenu"),
69
- decidim_admin_consultations.results_consultation_path(current_consultation),
70
- position: 1.0,
71
- active: is_active_link?(decidim_admin_consultations.results_consultation_path(current_consultation)),
72
- if: allowed_to?(:read, :question)
58
+ menu.add_item :edit_consultation,
59
+ I18n.t("info", scope: "decidim.admin.menu.consultations_submenu"),
60
+ decidim_admin_consultations.edit_consultation_path(current_consultation),
61
+ position: 1.0,
62
+ active: is_active_link?(decidim_admin_consultations.edit_consultation_path(current_consultation)),
63
+ if: allowed_to?(:update, :consultation, consultation: current_consultation)
64
+ menu.add_item :consultation_questions,
65
+ I18n.t("questions", scope: "decidim.admin.menu.consultations_submenu"),
66
+ decidim_admin_consultations.consultation_questions_path(current_consultation),
67
+ position: 1.1,
68
+ active: is_active_link?(decidim_admin_consultations.consultation_questions_path(current_consultation)),
69
+ if: allowed_to?(:read, :question)
70
+ menu.add_item :results_consultation,
71
+ I18n.t("results", scope: "decidim.admin.menu.consultations_submenu"),
72
+ decidim_admin_consultations.results_consultation_path(current_consultation),
73
+ position: 1.0,
74
+ active: is_active_link?(decidim_admin_consultations.results_consultation_path(current_consultation)),
75
+ if: allowed_to?(:read, :question)
73
76
  end
74
77
  end
75
78
  initializer "decidim_consultations.admin_menu" do
76
79
  Decidim.menu :admin_menu do |menu|
77
- menu.item I18n.t("menu.consultations", scope: "decidim.admin"),
78
- decidim_admin_consultations.consultations_path,
79
- icon_name: "comment-square",
80
- position: 2.65,
81
- active: :inclusive,
82
- if: allowed_to?(:enter, :space_area, space_name: :consultations)
80
+ menu.add_item :consultations,
81
+ I18n.t("menu.consultations", scope: "decidim.admin"),
82
+ decidim_admin_consultations.consultations_path,
83
+ icon_name: "comment-square",
84
+ position: 2.65,
85
+ active: :inclusive,
86
+ if: allowed_to?(:enter, :space_area, space_name: :consultations)
83
87
  end
84
88
  end
85
- initializer "decidim_consultations.action_controller" do |_app|
86
- ActiveSupport.on_load :action_controller do
87
- helper Decidim::Consultations::Admin::ConsultationMenuHelper if respond_to?(:helper)
89
+
90
+ initializer "decidim_consultations.admin_question_menu" do
91
+ Decidim.menu :admin_question_menu do |menu|
92
+ menu.add_item :edit_consultation,
93
+ I18n.t("consultation", scope: "decidim.admin.menu.questions_submenu"),
94
+ decidim_admin_consultations.edit_consultation_path(current_participatory_space.consultation),
95
+ position: 1.0,
96
+ active: is_active_link?(decidim_admin_consultations.edit_consultation_path(current_participatory_space.consultation)),
97
+ if: allowed_to?(:update, :consultation, consultation: current_participatory_space.consultation)
98
+ menu.add_item :consultation_questions,
99
+ I18n.t("questions", scope: "decidim.admin.menu.consultations_submenu"),
100
+ decidim_admin_consultations.consultation_questions_path(current_participatory_space.consultation),
101
+ position: 1.0,
102
+ active: is_active_link?(decidim_admin_consultations.consultation_questions_path(current_participatory_space.consultation)),
103
+ submenu: { target_menu: :admin_questions_menu }
104
+
105
+ menu.add_item :results_consultation,
106
+ I18n.t("results", scope: "decidim.admin.menu.consultations_submenu"),
107
+ decidim_admin_consultations.results_consultation_path(current_participatory_space.consultation),
108
+ position: 1.0,
109
+ active: is_active_link?(decidim_admin_consultations.results_consultation_path(current_participatory_space.consultation))
110
+ end
111
+ end
112
+ initializer "decidim_consultations.admin_questions_menu" do
113
+ Decidim.menu :admin_questions_menu do |menu|
114
+ menu.add_item :edit_question,
115
+ I18n.t("info", scope: "decidim.admin.menu.questions_submenu"),
116
+ decidim_admin_consultations.edit_question_path(current_participatory_space),
117
+ position: 1.0,
118
+ active: is_active_link?(decidim_admin_consultations.edit_question_path(current_participatory_space)),
119
+ if: allowed_to?(:update, :question, question: current_participatory_space)
120
+
121
+ menu.add_item :edit_question_configuration,
122
+ I18n.t("configuration", scope: "decidim.admin.menu.questions_submenu"),
123
+ decidim_admin_consultations.edit_question_configuration_path(current_participatory_space),
124
+ position: 1.0,
125
+ active: is_active_link?(decidim_admin_consultations.edit_question_configuration_path(current_participatory_space)),
126
+ if: allowed_to?(:configure, :question, question: current_participatory_space)
127
+ menu.add_item :responses,
128
+ I18n.t("responses", scope: "decidim.admin.menu.questions_submenu"),
129
+ decidim_admin_consultations.responses_path(current_participatory_space),
130
+ position: 1.0,
131
+ active: is_active_link?(decidim_admin_consultations.responses_path(current_participatory_space)) ||
132
+ is_active_link?(decidim_admin_consultations.response_groups_path(current_participatory_space)),
133
+ if: allowed_to?(:read, :response)
134
+
135
+ menu.add_item :components,
136
+ I18n.t("components", scope: "decidim.admin.menu.questions_submenu"),
137
+ decidim_admin_consultations.components_path(current_participatory_space),
138
+ position: 1.0,
139
+ active: is_active_link?(decidim_admin_consultations.components_path(current_participatory_space)),
140
+ if: allowed_to?(:read, :component),
141
+ submenu: { target_menu: :admin_consultation_components_menu, options: { container_options: { id: "components-list" } } }
142
+
143
+ menu.add_item :categories,
144
+ I18n.t("categories", scope: "decidim.admin.menu.questions_submenu"),
145
+ decidim_admin_consultations.categories_path(current_participatory_space),
146
+ position: 1.0,
147
+ active: is_active_link?(decidim_admin_consultations.categories_path(current_participatory_space)),
148
+ if: allowed_to?(:read, :category)
149
+ menu.add_item :question_attachments,
150
+ I18n.t("attachments", scope: "decidim.admin.menu.questions_submenu"),
151
+ decidim_admin_consultations.question_attachments_path(current_participatory_space),
152
+ position: 1.0,
153
+ active: is_active_link?(decidim_admin_consultations.question_attachments_path(current_participatory_space)),
154
+ if: allowed_to?(:read, :attachment)
155
+ end
156
+ end
157
+ initializer "decidim_consultations.admin_consultation_components_menu" do
158
+ Decidim.menu :admin_consultation_components_menu do |menu|
159
+ current_participatory_space.components.each do |component|
160
+ caption = translated_attribute(component.name)
161
+ if component.primary_stat.present?
162
+ caption += content_tag(:span, component.primary_stat, class: component.primary_stat.zero? ? "component-counter component-counter--off" : "component-counter")
163
+ end
164
+
165
+ menu.add_item [component.manifest_name, component.id].join("_"),
166
+ caption.html_safe,
167
+ manage_component_path(component),
168
+ active: is_active_link?(manage_component_path(component)) ||
169
+ is_active_link?(decidim_admin_consultations.edit_component_path(current_participatory_space, component)) ||
170
+ is_active_link?(decidim_admin_consultations.edit_component_permissions_path(current_participatory_space, component)),
171
+ if: component.manifest.admin_engine && user_role_config.component_is_accessible?(component.manifest_name)
172
+ end
88
173
  end
89
174
  end
90
175
  end
@@ -52,13 +52,6 @@ module Decidim
52
52
  end
53
53
  end
54
54
 
55
- initializer "decidim_consultations.assets" do |app|
56
- app.config.assets.precompile += %w(
57
- decidim_consultations_manifest.js
58
- decidim_consultations_manifest.css
59
- )
60
- end
61
-
62
55
  initializer "decidim.stats" do
63
56
  Decidim.stats.register :consultations_count, priority: StatsRegistry::HIGH_PRIORITY do |organization, _start_at, _end_at|
64
57
  Decidim::Consultation.where(organization: organization).published.count
@@ -72,11 +65,12 @@ module Decidim
72
65
 
73
66
  initializer "decidim_consultations.menu" do
74
67
  Decidim.menu :menu do |menu|
75
- menu.item I18n.t("menu.consultations", scope: "decidim"),
76
- decidim_consultations.consultations_path,
77
- position: 2.65,
78
- if: Decidim::Consultation.where(organization: current_organization).published.any?,
79
- active: :inclusive
68
+ menu.add_item :consultations,
69
+ I18n.t("menu.consultations", scope: "decidim"),
70
+ decidim_consultations.consultations_path,
71
+ position: 2.65,
72
+ if: Decidim::Consultation.where(organization: current_organization).published.any?,
73
+ active: :inclusive
80
74
  end
81
75
  end
82
76
 
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  Decidim.register_participatory_space(:consultations) do |participatory_space|
4
- participatory_space.icon = "decidim/consultations/icon.svg"
4
+ participatory_space.icon = "decidim_consultations.svg"
5
5
  participatory_space.model_class_name = "Decidim::Consultation"
6
6
  participatory_space.permissions_class_name = "Decidim::Consultations::Permissions"
7
7
  participatory_space.stylesheet = "decidim/consultations/consultations"
@@ -31,7 +31,7 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
31
31
 
32
32
  participatory_space.register_resource(:question) do |resource|
33
33
  resource.model_class_name = "Decidim::Consultations::Question"
34
- resource.actions = %w(vote)
34
+ resource.actions = %w(vote comment)
35
35
  end
36
36
 
37
37
  participatory_space.seeds do
@@ -50,7 +50,12 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
50
50
  start_voting_date: Time.zone.today,
51
51
  end_voting_date: Time.zone.today + 1.month,
52
52
  organization: organization,
53
- banner_image: File.new(File.join(seeds_root, "city2.jpeg")), # Keep after organization
53
+ banner_image: ActiveStorage::Blob.create_after_upload!(
54
+ io: File.open(File.join(seeds_root, "city2.jpeg")),
55
+ filename: "banner_image.jpeg",
56
+ content_type: "image/jpeg",
57
+ metadata: nil
58
+ ), # Keep after organization
54
59
  introductory_video_url: "https://www.youtube.com/embed/zhMMW0TENNA",
55
60
  decidim_highlighted_scope_id: Decidim::Scope.reorder(Arel.sql("RANDOM()")).first.id
56
61
  }
@@ -77,7 +82,12 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
77
82
  start_voting_date: Time.zone.today - 2.months,
78
83
  end_voting_date: Time.zone.today - 1.month,
79
84
  organization: organization,
80
- banner_image: File.new(File.join(seeds_root, "city2.jpeg")), # Keep after organization
85
+ banner_image: ActiveStorage::Blob.create_after_upload!(
86
+ io: File.open(File.join(seeds_root, "city2.jpeg")),
87
+ filename: "banner_image.jpeg",
88
+ content_type: "image/jpeg",
89
+ metadata: nil
90
+ ), # Keep after organization
81
91
  introductory_video_url: "https://www.youtube.com/embed/zhMMW0TENNA",
82
92
  decidim_highlighted_scope_id: Decidim::Scope.reorder(Arel.sql("RANDOM()")).first.id
83
93
  }
@@ -103,7 +113,12 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
103
113
  start_voting_date: Time.zone.today + 1.month + 1.day,
104
114
  end_voting_date: Time.zone.today + 2.months,
105
115
  organization: organization,
106
- banner_image: File.new(File.join(seeds_root, "city2.jpeg")), # Keep after organization
116
+ banner_image: ActiveStorage::Blob.create_after_upload!(
117
+ io: File.open(File.join(seeds_root, "city2.jpeg")),
118
+ filename: "banner_image.jpeg",
119
+ content_type: "image/jpeg",
120
+ metadata: nil
121
+ ), # Keep after organization
107
122
  introductory_video_url: "https://www.youtube.com/embed/zhMMW0TENNA",
108
123
  decidim_highlighted_scope_id: Decidim::Scope.reorder(Arel.sql("RANDOM()")).first.id
109
124
  }
@@ -133,8 +148,18 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
133
148
  Decidim::Faker::Localized.paragraph(sentence_count: 3)
134
149
  end,
135
150
  organization: organization,
136
- hero_image: File.new(File.join(seeds_root, "city.jpeg")), # Keep after organization
137
- banner_image: File.new(File.join(seeds_root, "city2.jpeg")), # Keep after organization
151
+ hero_image: ActiveStorage::Blob.create_after_upload!(
152
+ io: File.open(File.join(seeds_root, "city.jpeg")),
153
+ filename: "hero_image.jpeg",
154
+ content_type: "image/jpeg",
155
+ metadata: nil
156
+ ), # Keep after organization
157
+ banner_image: ActiveStorage::Blob.create_after_upload!(
158
+ io: File.open(File.join(seeds_root, "city2.jpeg")),
159
+ filename: "banner_image.jpeg",
160
+ content_type: "image/jpeg",
161
+ metadata: nil
162
+ ), # Keep after organization
138
163
  promoter_group: Decidim::Faker::Localized.sentence(word_count: 3),
139
164
  participatory_scope: Decidim::Faker::Localized.sentence(word_count: 3),
140
165
  published_at: Time.now.utc
@@ -162,14 +187,26 @@ Decidim.register_participatory_space(:consultations) do |participatory_space|
162
187
  title: Decidim::Faker::Localized.sentence(word_count: 2),
163
188
  description: Decidim::Faker::Localized.sentence(word_count: 5),
164
189
  attached_to: question,
165
- file: File.new(File.join(seeds_root, "city.jpeg")) # Keep after attached_to
190
+ content_type: "image/jpeg",
191
+ file: ActiveStorage::Blob.create_after_upload!(
192
+ io: File.open(File.join(seeds_root, "city.jpeg")),
193
+ filename: "city.jpeg",
194
+ content_type: "image/jpeg",
195
+ metadata: nil
196
+ ) # Keep after attached_to
166
197
  )
167
198
 
168
199
  Decidim::Attachment.create!(
169
200
  title: Decidim::Faker::Localized.sentence(word_count: 2),
170
201
  description: Decidim::Faker::Localized.sentence(word_count: 5),
171
202
  attached_to: question,
172
- file: File.new(File.join(seeds_root, "Exampledocument.pdf")) # Keep after attached_to
203
+ content_type: "application/pdf",
204
+ file: ActiveStorage::Blob.create_after_upload!(
205
+ io: File.open(File.join(seeds_root, "Exampledocument.pdf")),
206
+ filename: "Exampledocument.pdf",
207
+ content_type: "application/pdf",
208
+ metadata: nil
209
+ ) # Keep after attached_to
173
210
  )
174
211
  end
175
212
  end
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Consultations
5
5
  def self.version
6
- "0.24.3"
6
+ "0.25.0.rc4"
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-consultations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.24.3
4
+ version: 0.25.0.rc4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Salvador Perez Garcia
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-01 00:00:00.000000000 Z
11
+ date: 2021-09-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: decidim-admin
@@ -16,56 +16,56 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 0.24.3
19
+ version: 0.25.0.rc4
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 0.24.3
26
+ version: 0.25.0.rc4
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: decidim-comments
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 0.24.3
33
+ version: 0.25.0.rc4
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 0.24.3
40
+ version: 0.25.0.rc4
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: decidim-core
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 0.24.3
47
+ version: 0.25.0.rc4
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 0.24.3
54
+ version: 0.25.0.rc4
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: decidim-dev
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - '='
60
60
  - !ruby/object:Gem::Version
61
- version: 0.24.3
61
+ version: 0.25.0.rc4
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - '='
67
67
  - !ruby/object:Gem::Version
68
- version: 0.24.3
68
+ version: 0.25.0.rc4
69
69
  description: Extends Decidim adding a first level public consultation component
70
70
  email:
71
71
  - jsperezg@gmail.com
@@ -75,30 +75,6 @@ extra_rdoc_files: []
75
75
  files:
76
76
  - README.md
77
77
  - Rakefile
78
- - app/assets/config/decidim_consultations_manifest.css
79
- - app/assets/config/decidim_consultations_manifest.js
80
- - app/assets/images/decidim/consultations/icon.svg
81
- - app/assets/images/decidim/consultations/icon2.svg
82
- - app/assets/javascripts/decidim/consultations/show_more.js.es6
83
- - app/assets/javascripts/decidim/consultations/utils.js.es6
84
- - app/assets/javascripts/decidim/consultations/utils_multiple.js
85
- - app/assets/javascripts/decidim/consultations/vote_dialog.js
86
- - app/assets/stylesheets/decidim/consultations/_question.scss
87
- - app/assets/stylesheets/decidim/consultations/_question_multiple_votes.scss
88
- - app/assets/stylesheets/decidim/consultations/_stats.scss
89
- - app/assets/stylesheets/decidim/consultations/_video_wrapper.scss
90
- - app/assets/stylesheets/decidim/consultations/banners/_block-banner.scss
91
- - app/assets/stylesheets/decidim/consultations/consultations.scss
92
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-banner.scss
93
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-card.scss
94
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-header.scss
95
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-home-banner.scss
96
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-home-intro.scss
97
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-intro.scss
98
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations-title.scss
99
- - app/assets/stylesheets/decidim/consultations/consultations/_consultations_nav.scss
100
- - app/assets/stylesheets/decidim/consultations/consultations/introductory_image.scss
101
- - app/assets/stylesheets/decidim/consultations/highlighted-content-banner.css.scss
102
78
  - app/cells/decidim/consultation_activity_cell.rb
103
79
  - app/cells/decidim/consultations/consultation_cell.rb
104
80
  - app/cells/decidim/consultations/consultation_m/data.erb
@@ -165,7 +141,6 @@ files:
165
141
  - app/forms/decidim/consultations/admin/response_group_form.rb
166
142
  - app/forms/decidim/consultations/multi_vote_form.rb
167
143
  - app/forms/decidim/consultations/vote_form.rb
168
- - app/helpers/decidim/consultations/admin/consultation_menu_helper.rb
169
144
  - app/helpers/decidim/consultations/admin/consultations_helper.rb
170
145
  - app/helpers/decidim/consultations/admin/questions_helper.rb
171
146
  - app/helpers/decidim/consultations/consultations_helper.rb
@@ -178,6 +153,28 @@ files:
178
153
  - app/models/decidim/consultations/response.rb
179
154
  - app/models/decidim/consultations/response_group.rb
180
155
  - app/models/decidim/consultations/vote.rb
156
+ - app/packs/entrypoints/decidim_consultations.js
157
+ - app/packs/images/decidim/consultations/decidim_consultations.svg
158
+ - app/packs/src/decidim/consultations/show_more.js
159
+ - app/packs/src/decidim/consultations/utils.js
160
+ - app/packs/src/decidim/consultations/utils_multiple.js
161
+ - app/packs/src/decidim/consultations/vote_dialog.js
162
+ - app/packs/stylesheets/decidim/consultations/_question.scss
163
+ - app/packs/stylesheets/decidim/consultations/_question_multiple_votes.scss
164
+ - app/packs/stylesheets/decidim/consultations/_stats.scss
165
+ - app/packs/stylesheets/decidim/consultations/_video_wrapper.scss
166
+ - app/packs/stylesheets/decidim/consultations/banners/_block-banner.scss
167
+ - app/packs/stylesheets/decidim/consultations/consultations.scss
168
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-banner.scss
169
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-card.scss
170
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-header.scss
171
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-home-banner.scss
172
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-home-intro.scss
173
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-intro.scss
174
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations-title.scss
175
+ - app/packs/stylesheets/decidim/consultations/consultations/_consultations_nav.scss
176
+ - app/packs/stylesheets/decidim/consultations/consultations/introductory_image.scss
177
+ - app/packs/stylesheets/decidim/consultations/highlighted-content-banner.scss
181
178
  - app/permissions/decidim/consultations/admin/permissions.rb
182
179
  - app/permissions/decidim/consultations/permissions.rb
183
180
  - app/presenters/decidim/consultations/question_stats_presenter.rb
@@ -245,6 +242,7 @@ files:
245
242
  - app/views/layouts/decidim/consultation_choose.html.erb
246
243
  - app/views/layouts/decidim/question.html.erb
247
244
  - app/views/layouts/decidim/question_multivote.html.erb
245
+ - config/assets.rb
248
246
  - config/locales/am-ET.yml
249
247
  - config/locales/ar-SA.yml
250
248
  - config/locales/ar.yml
@@ -271,6 +269,7 @@ files:
271
269
  - config/locales/fi-plain.yml
272
270
  - config/locales/fi.yml
273
271
  - config/locales/fr-CA.yml
272
+ - config/locales/fr-LU.yml
274
273
  - config/locales/fr.yml
275
274
  - config/locales/ga-IE.yml
276
275
  - config/locales/gl.yml
@@ -281,10 +280,10 @@ files:
281
280
  - config/locales/is-IS.yml
282
281
  - config/locales/is.yml
283
282
  - config/locales/it.yml
284
- - config/locales/ja-JP.yml
285
283
  - config/locales/ja.yml
286
284
  - config/locales/ko-KR.yml
287
285
  - config/locales/ko.yml
286
+ - config/locales/lb-LU.yml
288
287
  - config/locales/lt-LT.yml
289
288
  - config/locales/lt.yml
290
289
  - config/locales/lv.yml
@@ -379,9 +378,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
379
378
  version: '2.7'
380
379
  required_rubygems_version: !ruby/object:Gem::Requirement
381
380
  requirements:
382
- - - ">="
381
+ - - ">"
383
382
  - !ruby/object:Gem::Version
384
- version: '0'
383
+ version: 1.3.1
385
384
  requirements: []
386
385
  rubygems_version: 3.1.2
387
386
  signing_key:
@@ -1,3 +0,0 @@
1
- /*
2
- *= link decidim/consultations/highlighted-content-banner.css.scss
3
- */
@@ -1,5 +0,0 @@
1
- //= link_directory ../images/decidim/consultations
2
- //= link decidim/consultations/utils.js
3
- //= link decidim/consultations/utils_multiple.js
4
- //= link decidim/consultations/vote_dialog.js
5
- //= link decidim/consultations/show_more.js
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" xmlns:svg="http://www.w3.org/2000/svg" id="svg2" width="129.16" height="129.16" version="1.1" viewBox="0 0 121.088 121.088"><metadata id="metadata7"/><g id="layer1" transform="translate(-31.864728,-35.267277)"><path id="path4136" fill="#000" fill-opacity="1" fill-rule="nonzero" stroke="none" stroke-dasharray="none" stroke-dashoffset="0" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" stroke-opacity="1" stroke-width="2.9" d="m 92.408203,35.267578 c -33.420312,0 -60.542969,27.122657 -60.542969,60.542969 -1e-6,33.420313 27.122657,60.544923 60.542969,60.544923 33.420317,0 60.544927,-27.12461 60.544917,-60.544923 0,-33.420313 -27.1246,-60.54297 -60.544917,-60.542969 z m 0,2.900391 c 31.853037,-10e-7 57.644527,25.789542 57.644527,57.642578 1e-5,31.853033 -25.79149,57.644533 -57.644527,57.644533 -31.853036,0 -57.642579,-25.7915 -57.642578,-57.644533 0,-31.853036 25.789543,-57.642578 57.642578,-57.642578 z" baseline-shift="baseline" clip-rule="nonzero" color="#000" color-interpolation="sRGB" color-interpolation-filters="linearRGB" color-rendering="auto" direction="ltr" display="inline" enable-background="accumulate" font-family="sans-serif" font-size="medium" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" image-rendering="auto" letter-spacing="normal" opacity="1" overflow="visible" shape-rendering="auto" text-anchor="start" text-decoration="none" text-rendering="auto" visibility="visible" word-spacing="normal" writing-mode="lr-tb" style="line-height:normal;text-indent:0;text-align:start;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000;text-transform:none;block-progression:tb;white-space:normal;isolation:auto;mix-blend-mode:normal;solid-color:#000;solid-opacity:1"/><path id="rect4138" fill="#000" fill-opacity="1" fill-rule="nonzero" stroke="none" stroke-dasharray="none" stroke-dashoffset="0" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" stroke-opacity="1" stroke-width="3.631" d="m 58.978516,67.554688 0,1.816406 0,24.173828 25.990234,0 0,-25.990234 -25.990234,0 z m 3.630859,3.630859 18.726563,0 0,18.728515 -18.726563,0 0,-18.728515 z" baseline-shift="baseline" clip-rule="nonzero" color="#000" color-interpolation="sRGB" color-interpolation-filters="linearRGB" color-rendering="auto" direction="ltr" display="inline" enable-background="accumulate" font-family="sans-serif" font-size="medium" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" image-rendering="auto" letter-spacing="normal" opacity="1" overflow="visible" shape-rendering="auto" text-anchor="start" text-decoration="none" text-rendering="auto" visibility="visible" word-spacing="normal" writing-mode="lr-tb" style="line-height:normal;text-indent:0;text-align:start;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000;text-transform:none;block-progression:tb;white-space:normal;isolation:auto;mix-blend-mode:normal;solid-color:#000;solid-opacity:1"/><path id="rect4140" fill="#000" fill-opacity="1" fill-rule="nonzero" stroke="none" stroke-dasharray="none" stroke-dashoffset="0" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" stroke-opacity="1" stroke-width="3.631" d="m 58.978516,100.10938 0,1.81445 0,24.17383 25.990234,0 0,-25.98828 -25.990234,0 z m 3.630859,3.63085 18.726563,0 0,18.72657 -18.726563,0 0,-18.72657 z" baseline-shift="baseline" clip-rule="nonzero" color="#000" color-interpolation="sRGB" color-interpolation-filters="linearRGB" color-rendering="auto" direction="ltr" display="inline" enable-background="accumulate" font-family="sans-serif" font-size="medium" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" image-rendering="auto" letter-spacing="normal" opacity="1" overflow="visible" shape-rendering="auto" text-anchor="start" text-decoration="none" text-rendering="auto" visibility="visible" word-spacing="normal" writing-mode="lr-tb" style="line-height:normal;text-indent:0;text-align:start;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000;text-transform:none;block-progression:tb;white-space:normal;isolation:auto;mix-blend-mode:normal;solid-color:#000;solid-opacity:1"/><path id="path4142" fill="#000" fill-opacity="1" fill-rule="evenodd" stroke="none" stroke-dasharray="none" stroke-dashoffset="0" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" stroke-opacity="1" stroke-width="5" d="m 94.357422,76.933594 0,5 35.392578,0 0,-5 -35.392578,0 z" baseline-shift="baseline" clip-rule="nonzero" color="#000" color-interpolation="sRGB" color-interpolation-filters="linearRGB" color-rendering="auto" direction="ltr" display="inline" enable-background="accumulate" font-family="sans-serif" font-size="medium" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" image-rendering="auto" letter-spacing="normal" opacity="1" overflow="visible" shape-rendering="auto" text-anchor="start" text-decoration="none" text-rendering="auto" visibility="visible" word-spacing="normal" writing-mode="lr-tb" style="line-height:normal;text-indent:0;text-align:start;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000;text-transform:none;block-progression:tb;white-space:normal;isolation:auto;mix-blend-mode:normal;solid-color:#000;solid-opacity:1"/><path id="path4150" fill="#000" fill-opacity="1" fill-rule="evenodd" stroke="none" stroke-dasharray="none" stroke-dashoffset="0" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" stroke-opacity="1" stroke-width="5" d="m 94.357422,110.93359 0,5 35.392578,0 0,-5 -35.392578,0 z" baseline-shift="baseline" clip-rule="nonzero" color="#000" color-interpolation="sRGB" color-interpolation-filters="linearRGB" color-rendering="auto" direction="ltr" display="inline" enable-background="accumulate" font-family="sans-serif" font-size="medium" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" image-rendering="auto" letter-spacing="normal" opacity="1" overflow="visible" shape-rendering="auto" text-anchor="start" text-decoration="none" text-rendering="auto" visibility="visible" word-spacing="normal" writing-mode="lr-tb" style="line-height:normal;text-indent:0;text-align:start;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000;text-transform:none;block-progression:tb;white-space:normal;isolation:auto;mix-blend-mode:normal;solid-color:#000;solid-opacity:1"/><g id="text4154" fill="#000" fill-opacity="1" stroke="none" stroke-linecap="butt" stroke-linejoin="miter" stroke-opacity="1" stroke-width="1" font-family="OpenSymbol" font-size="41.113" font-stretch="normal" font-style="normal" font-variant="normal" font-weight="normal" letter-spacing="0" word-spacing="0" style="line-height:125%;-inkscape-font-specification:OpenSymbol"><path id="path4153" d="m 89.716183,63.201072 0.702622,1.02382 q -4.838051,3.673707 -9.957151,10.318499 -4.737677,6.22322 -7.608388,12.225616 -2.228314,1.465468 -3.974831,2.870711 -2.710112,-8.873107 -6.303519,-10.3185 2.027565,-2.308614 3.994905,-2.308614 1.686292,0 4.075205,5.641048 7.668613,-12.948312 19.071157,-19.45258 z"/></g></g></svg>
@@ -1,12 +0,0 @@
1
- /* eslint-disable no-invalid-this */
2
-
3
- (function() {
4
- $(() => {
5
-
6
- $(".show-more").on("click", function() {
7
- $(this).hide();
8
- $(".show-more-panel").removeClass("hide");
9
- });
10
-
11
- })
12
- }(window));
@@ -1,6 +0,0 @@
1
- @import "question";
2
- @import "question_multiple_votes";
3
- @import "video_wrapper";
4
- @import "stats";
5
- @import "consultations/*";
6
- @import "banners/*";
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Decidim
4
- module Consultations
5
- module Admin
6
- module ConsultationMenuHelper
7
- include Decidim::Admin::SidebarMenuHelper
8
-
9
- def admin_consultation_menu
10
- @admin_consultation_menu ||= sidebar_menu(:admin_consultation_menu)
11
- end
12
- end
13
- end
14
- end
15
- end