decidim-proposals 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 (106) hide show
  1. checksums.yaml +4 -4
  2. data/app/cells/decidim/proposals/cost_report_cell.rb +1 -1
  3. data/app/cells/decidim/proposals/proposal_m_cell.rb +4 -0
  4. data/app/cells/decidim/proposals/proposals_picker/show.erb +1 -1
  5. data/app/commands/decidim/proposals/admin/import_proposals.rb +21 -4
  6. data/app/controllers/decidim/proposals/admin/proposals_controller.rb +1 -1
  7. data/app/controllers/decidim/proposals/collaborative_drafts_controller.rb +1 -0
  8. data/app/controllers/decidim/proposals/proposals_controller.rb +1 -0
  9. data/app/forms/decidim/proposals/admin/import_participatory_text_form.rb +1 -0
  10. data/app/forms/decidim/proposals/admin/proposals_import_form.rb +6 -0
  11. data/app/forms/decidim/proposals/proposal_form.rb +7 -4
  12. data/app/helpers/decidim/proposals/map_helper.rb +5 -5
  13. data/app/helpers/decidim/proposals/participatory_texts_helper.rb +1 -1
  14. data/app/helpers/decidim/proposals/proposal_wizard_helper.rb +0 -16
  15. data/app/models/decidim/proposals/proposal.rb +11 -1
  16. data/app/{assets → packs}/documents/decidim/proposals/participatory_texts/participatory_text.md +0 -0
  17. data/app/{assets → packs}/documents/decidim/proposals/participatory_texts/participatory_text.odt +0 -0
  18. data/app/packs/entrypoints/decidim_proposals.js +8 -0
  19. data/app/packs/entrypoints/decidim_proposals_admin.js +3 -0
  20. data/app/{assets/images/decidim/gamification/badges/accepted_proposals.svg → packs/images/decidim/gamification/badges/decidim_gamification_badges_accepted_proposals.svg} +0 -0
  21. data/app/{assets/images/decidim/gamification/badges/proposal_votes.svg → packs/images/decidim/gamification/badges/decidim_gamification_badges_proposal_votes.svg} +0 -0
  22. data/app/{assets/images/decidim/gamification/badges/proposals.svg → packs/images/decidim/gamification/badges/decidim_gamification_badges_proposals.svg} +0 -0
  23. data/app/{assets/images/decidim/proposals/icon.svg → packs/images/decidim/proposals/decidim_proposals.svg} +0 -0
  24. data/app/packs/src/decidim/proposals/add_proposal.js +49 -0
  25. data/app/packs/src/decidim/proposals/admin/proposals.js +143 -0
  26. data/app/{assets/javascripts/decidim/proposals/admin/proposals_form.js.es6 → packs/src/decidim/proposals/admin/proposals_form.js} +2 -2
  27. data/app/{assets/javascripts/decidim/proposals/admin/proposals_picker.js.es6 → packs/src/decidim/proposals/admin/proposals_picker.js} +0 -0
  28. data/app/{assets/javascripts/decidim/proposals/utils.js.es6 → packs/src/decidim/proposals/utils.js} +2 -2
  29. data/app/packs/stylesheets/decidim/proposals/_proposals.scss +1 -0
  30. data/app/{assets/stylesheets/decidim/proposals/proposals/_preview.css.scss → packs/stylesheets/decidim/proposals/proposals/_preview.scss} +0 -0
  31. data/app/presenters/decidim/proposals/proposal_presenter.rb +2 -23
  32. data/app/queries/decidim/proposals/metrics/accepted_proposals_metric_manage.rb +1 -1
  33. data/app/queries/decidim/proposals/metrics/proposals_metric_manage.rb +1 -1
  34. data/app/queries/decidim/proposals/metrics/votes_metric_manage.rb +1 -1
  35. data/app/queries/decidim/proposals/similar_proposals.rb +1 -0
  36. data/app/services/decidim/proposals/proposal_builder.rb +4 -4
  37. data/app/views/decidim/proposals/admin/proposals/_form.html.erb +1 -1
  38. data/app/views/decidim/proposals/admin/proposals/index.html.erb +1 -1
  39. data/app/views/decidim/proposals/admin/proposals_imports/new.html.erb +6 -0
  40. data/app/views/decidim/proposals/collaborative_drafts/_filters.html.erb +1 -1
  41. data/app/views/decidim/proposals/collaborative_drafts/edit.html.erb +1 -1
  42. data/app/views/decidim/proposals/collaborative_drafts/index.html.erb +0 -2
  43. data/app/views/decidim/proposals/collaborative_drafts/new.html.erb +1 -1
  44. data/app/views/decidim/proposals/proposals/_dynamic_map_instructions.html.erb +2 -1
  45. data/app/views/decidim/proposals/proposals/_edit_form_fields.html.erb +5 -1
  46. data/app/views/decidim/proposals/proposals/_filters.html.erb +1 -1
  47. data/app/views/decidim/proposals/proposals/complete.html.erb +1 -1
  48. data/app/views/decidim/proposals/proposals/edit.html.erb +1 -1
  49. data/app/views/decidim/proposals/proposals/edit_draft.html.erb +1 -1
  50. data/app/views/decidim/proposals/proposals/index.html.erb +4 -6
  51. data/app/views/decidim/proposals/proposals/new.html.erb +1 -1
  52. data/app/views/decidim/proposals/proposals/preview.html.erb +7 -31
  53. data/config/assets.rb +10 -0
  54. data/config/locales/ar.yml +3 -1
  55. data/config/locales/bg.yml +3 -1
  56. data/config/locales/ca.yml +10 -4
  57. data/config/locales/cs.yml +12 -3
  58. data/config/locales/de.yml +10 -4
  59. data/config/locales/el.yml +3 -1
  60. data/config/locales/en.yml +12 -3
  61. data/config/locales/es-MX.yml +10 -4
  62. data/config/locales/es-PY.yml +10 -4
  63. data/config/locales/es.yml +10 -4
  64. data/config/locales/eu.yml +3 -1
  65. data/config/locales/fi-plain.yml +12 -3
  66. data/config/locales/fi.yml +12 -3
  67. data/config/locales/fr-CA.yml +8 -3
  68. data/config/locales/fr-LU.yml +903 -0
  69. data/config/locales/fr.yml +8 -3
  70. data/config/locales/gl.yml +11 -3
  71. data/config/locales/hu.yml +3 -1
  72. data/config/locales/id-ID.yml +3 -1
  73. data/config/locales/it.yml +55 -1
  74. data/config/locales/ja.yml +38 -1
  75. data/config/locales/lb-LU.yml +1 -0
  76. data/config/locales/lv.yml +3 -1
  77. data/config/locales/nl.yml +13 -2
  78. data/config/locales/no.yml +3 -1
  79. data/config/locales/pl.yml +14 -10
  80. data/config/locales/pt-BR.yml +199 -1
  81. data/config/locales/pt.yml +3 -1
  82. data/config/locales/ro-RO.yml +6 -1
  83. data/config/locales/ru.yml +3 -1
  84. data/config/locales/sk.yml +3 -1
  85. data/config/locales/sv.yml +13 -4
  86. data/config/locales/tr-TR.yml +3 -4
  87. data/config/locales/uk.yml +3 -1
  88. data/config/locales/zh-CN.yml +3 -1
  89. data/db/migrate/20201002085508_fix_proposals_data.rb +7 -8
  90. data/db/migrate/20210318082934_fix_counters_for_copied_proposals.rb +6 -5
  91. data/lib/decidim/proposals/admin_engine.rb +0 -4
  92. data/lib/decidim/proposals/commentable_proposal.rb +5 -13
  93. data/lib/decidim/proposals/component.rb +4 -4
  94. data/lib/decidim/proposals/engine.rb +14 -19
  95. data/lib/decidim/proposals/proposal_serializer.rb +1 -0
  96. data/lib/decidim/proposals/test/capybara_proposals_picker.rb +10 -0
  97. data/lib/decidim/proposals/test/factories.rb +3 -0
  98. data/lib/decidim/proposals/version.rb +1 -1
  99. data/lib/decidim/proposals.rb +0 -1
  100. metadata +38 -112
  101. data/app/assets/config/admin/decidim_proposals_manifest.js +0 -2
  102. data/app/assets/config/decidim_proposals_manifest.js +0 -4
  103. data/app/assets/javascripts/decidim/proposals/add_proposal.js.es6 +0 -31
  104. data/app/assets/javascripts/decidim/proposals/admin/proposals.es6 +0 -130
  105. data/app/assets/stylesheets/decidim/proposals/_proposals.css.scss +0 -1
  106. data/config/locales/ja-JP.yml +0 -865
@@ -44,7 +44,9 @@ zh-CN:
44
44
  invalid_document_type: '无效的文档类型。接受的格式为: %{valid_mime_types}'
45
45
  proposal:
46
46
  attributes:
47
- attachment:
47
+ add_documents:
48
+ needs_to_be_reattached: 需要重新连接
49
+ add_photos:
48
50
  needs_to_be_reattached: 需要重新连接
49
51
  body:
50
52
  cant_be_equal_to_template: 不能等于模板
@@ -12,14 +12,13 @@ class FixProposalsData < ActiveRecord::Migration[5.2]
12
12
 
13
13
  locale = author.try(:locale).presence || author.try(:default_locale).presence || author.try(:organization).try(:default_locale).presence
14
14
 
15
- proposal.title = {
16
- locale => proposal.title
17
- }
18
- proposal.body = {
19
- locale => proposal.body
20
- }
21
-
22
- proposal.save!
15
+ # rubocop:disable Rails/SkipsModelValidations
16
+ values = {}
17
+ values[:title] = { locale => proposal.title } unless proposal.title.is_a?(Hash)
18
+ values[:body] = { locale => proposal.body } unless proposal.body.is_a?(Hash)
19
+
20
+ proposal.update_columns(values)
21
+ # rubocop:enable Rails/SkipsModelValidations
23
22
  end
24
23
  end
25
24
 
@@ -2,11 +2,12 @@
2
2
 
3
3
  class FixCountersForCopiedProposals < ActiveRecord::Migration[5.2]
4
4
  def up
5
- copies_ids = Decidim::ResourceLink.where(
6
- name: "copied_from_component",
7
- from_type: "Decidim::Proposals::Proposal",
8
- to_type: "Decidim::Proposals::Proposal"
9
- ).pluck(:to_id)
5
+ copies_ids = Decidim::ResourceLink
6
+ .where(
7
+ name: "copied_from_component",
8
+ from_type: "Decidim::Proposals::Proposal",
9
+ to_type: "Decidim::Proposals::Proposal"
10
+ ).pluck(:to_id)
10
11
 
11
12
  Decidim::Proposals::Proposal.where(id: copies_ids).find_each do |record|
12
13
  record.class.reset_counters(record.id, :follows)
@@ -38,10 +38,6 @@ module Decidim
38
38
  root to: "proposals#index"
39
39
  end
40
40
 
41
- initializer "decidim_proposals.admin_assets" do |app|
42
- app.config.assets.precompile += %w(admin/decidim_proposals_manifest.js)
43
- end
44
-
45
41
  def load_seed
46
42
  nil
47
43
  end
@@ -5,19 +5,9 @@ module Decidim
5
5
  # The data store for a Proposal in the Decidim::Proposals component.
6
6
  module CommentableProposal
7
7
  extend ActiveSupport::Concern
8
- include Decidim::Comments::Commentable
8
+ include Decidim::Comments::CommentableWithComponent
9
9
 
10
10
  included do
11
- # Public: Overrides the `commentable?` Commentable concern method.
12
- def commentable?
13
- component.settings.comments_enabled?
14
- end
15
-
16
- # Public: Overrides the `accepts_new_comments?` Commentable concern method.
17
- def accepts_new_comments?
18
- commentable? && !component.current_settings.comments_blocked
19
- end
20
-
21
11
  # Public: Overrides the `comments_have_alignment?` Commentable concern method.
22
12
  def comments_have_alignment?
23
13
  true
@@ -35,8 +25,10 @@ module Decidim
35
25
  followers
36
26
  end
37
27
 
38
- def user_allowed_to_comment?(user)
39
- can_participate_in_space?(user)
28
+ def user_allowed_to_vote_comment?(user)
29
+ return unless can_participate_in_space?(user)
30
+
31
+ ActionAuthorizer.new(user, "vote_comment", component, self).authorize.ok?
40
32
  end
41
33
  end
42
34
  end
@@ -6,7 +6,7 @@ Decidim.register_component(:proposals) do |component|
6
6
  component.engine = Decidim::Proposals::Engine
7
7
  component.admin_engine = Decidim::Proposals::AdminEngine
8
8
  component.stylesheet = "decidim/proposals/proposals"
9
- component.icon = "decidim/proposals/icon.svg"
9
+ component.icon = "media/images/decidim_proposals.svg"
10
10
 
11
11
  component.on(:before_destroy) do |instance|
12
12
  raise "Can't destroy this component when there are proposals" if Decidim::Proposals::Proposal.where(component: instance).any?
@@ -16,7 +16,7 @@ Decidim.register_component(:proposals) do |component|
16
16
 
17
17
  component.newsletter_participant_entities = ["Decidim::Proposals::Proposal"]
18
18
 
19
- component.actions = %w(endorse vote create withdraw amend)
19
+ component.actions = %w(endorse vote create withdraw amend comment vote_comment)
20
20
 
21
21
  component.query_type = "Decidim::Proposals::ProposalsType"
22
22
 
@@ -83,7 +83,7 @@ Decidim.register_component(:proposals) do |component|
83
83
  resource.template = "decidim/proposals/proposals/linked_proposals"
84
84
  resource.card = "decidim/proposals/proposal"
85
85
  resource.reported_content_cell = "decidim/proposals/reported_content"
86
- resource.actions = %w(endorse vote amend)
86
+ resource.actions = %w(endorse vote amend comment vote_comment)
87
87
  resource.searchable = true
88
88
  end
89
89
 
@@ -108,7 +108,7 @@ Decidim.register_component(:proposals) do |component|
108
108
 
109
109
  component.register_stat :endorsements_count, priority: Decidim::StatsRegistry::MEDIUM_PRIORITY do |components, start_at, end_at|
110
110
  proposals = Decidim::Proposals::FilteredProposals.for(components, start_at, end_at).not_hidden
111
- Decidim::Endorsement.where(resource_id: proposals.pluck(:id), resource_type: Decidim::Proposals::Proposal.name).count
111
+ proposals.sum(:endorsements_count)
112
112
  end
113
113
 
114
114
  component.register_stat :comments_count, tag: :comments do |components, start_at, end_at|
@@ -1,11 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "kaminari"
4
- require "social-share-button"
5
- require "ransack"
6
- require "cells/rails"
7
- require "cells-erb"
8
- require "cell/partial"
3
+ require "decidim/core"
9
4
 
10
5
  module Decidim
11
6
  module Proposals
@@ -44,10 +39,6 @@ module Decidim
44
39
  root to: "proposals#index"
45
40
  end
46
41
 
47
- initializer "decidim_proposals.assets" do |app|
48
- app.config.assets.precompile += %w(decidim_proposals_manifest.js)
49
- end
50
-
51
42
  initializer "decidim.content_processors" do |_app|
52
43
  Decidim.configure do |config|
53
44
  config.content_processors += [:proposal]
@@ -61,19 +52,23 @@ module Decidim
61
52
  end
62
53
 
63
54
  initializer "decidim_changes" do
64
- Decidim::SettingsChange.subscribe "surveys" do |changes|
65
- Decidim::Proposals::SettingsChangeJob.perform_later(
66
- changes[:component_id],
67
- changes[:previous_settings],
68
- changes[:current_settings]
69
- )
55
+ config.to_prepare do
56
+ Decidim::SettingsChange.subscribe "surveys" do |changes|
57
+ Decidim::Proposals::SettingsChangeJob.perform_later(
58
+ changes[:component_id],
59
+ changes[:previous_settings],
60
+ changes[:current_settings]
61
+ )
62
+ end
70
63
  end
71
64
  end
72
65
 
73
66
  initializer "decidim_proposals.mentions_listener" do
74
- Decidim::Comments::CommentCreation.subscribe do |data|
75
- proposals = data.dig(:metadatas, :proposal).try(:linked_proposals)
76
- Decidim::Proposals::NotifyProposalsMentionedJob.perform_later(data[:comment_id], proposals) if proposals
67
+ config.to_prepare do
68
+ Decidim::Comments::CommentCreation.subscribe do |data|
69
+ proposals = data.dig(:metadatas, :proposal).try(:linked_proposals)
70
+ Decidim::Proposals::NotifyProposalsMentionedJob.perform_later(data[:comment_id], proposals) if proposals
71
+ end
77
72
  end
78
73
  end
79
74
 
@@ -59,6 +59,7 @@ module Decidim
59
59
  private
60
60
 
61
61
  attr_reader :proposal
62
+ alias resource proposal
62
63
 
63
64
  def component
64
65
  proposal.component
@@ -41,6 +41,16 @@ module Capybara
41
41
 
42
42
  expect(proposals_picker).to have_proposals_picked(proposals)
43
43
  end
44
+
45
+ def proposals_remove(proposals_picker, proposals)
46
+ data_picker = proposals_picker.data_picker
47
+
48
+ proposals.each do |proposal|
49
+ data_picker.find("a", text: proposal.title["en"]).find("span").click
50
+ end
51
+
52
+ expect(proposals_picker).to have_proposals_not_picked(proposals)
53
+ end
44
54
  end
45
55
  end
46
56
 
@@ -277,6 +277,9 @@ FactoryBot.define do
277
277
  address { "#{Faker::Address.street_name}, #{Faker::Address.city}" }
278
278
  latitude { Faker::Address.latitude }
279
279
  longitude { Faker::Address.longitude }
280
+ cost { 20_000 }
281
+ cost_report { { en: "My cost report" } }
282
+ execution_period { { en: "My execution period" } }
280
283
 
281
284
  after(:build) do |proposal, evaluator|
282
285
  proposal.title = if evaluator.title.is_a?(String)
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds decidim-proposals version.
5
5
  module Proposals
6
6
  def self.version
7
- "0.24.3"
7
+ "0.25.0.rc4"
8
8
  end
9
9
  end
10
10
  end
@@ -5,7 +5,6 @@ require "decidim/proposals/api"
5
5
  require "decidim/proposals/engine"
6
6
  require "decidim/proposals/admin_engine"
7
7
  require "decidim/proposals/component"
8
- require "acts_as_list"
9
8
 
10
9
  module Decidim
11
10
  # This namespace holds the logic of the `Proposals` component. This component
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-proposals
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
  - Josep Jaume Rey Peroy
@@ -10,78 +10,36 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2021-06-01 00:00:00.000000000 Z
13
+ date: 2021-09-20 00:00:00.000000000 Z
14
14
  dependencies:
15
- - !ruby/object:Gem::Dependency
16
- name: acts_as_list
17
- requirement: !ruby/object:Gem::Requirement
18
- requirements:
19
- - - "~>"
20
- - !ruby/object:Gem::Version
21
- version: '0.9'
22
- type: :runtime
23
- prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- requirements:
26
- - - "~>"
27
- - !ruby/object:Gem::Version
28
- version: '0.9'
29
- - !ruby/object:Gem::Dependency
30
- name: cells-erb
31
- requirement: !ruby/object:Gem::Requirement
32
- requirements:
33
- - - "~>"
34
- - !ruby/object:Gem::Version
35
- version: 0.1.0
36
- type: :runtime
37
- prerelease: false
38
- version_requirements: !ruby/object:Gem::Requirement
39
- requirements:
40
- - - "~>"
41
- - !ruby/object:Gem::Version
42
- version: 0.1.0
43
- - !ruby/object:Gem::Dependency
44
- name: cells-rails
45
- requirement: !ruby/object:Gem::Requirement
46
- requirements:
47
- - - "~>"
48
- - !ruby/object:Gem::Version
49
- version: 0.0.9
50
- type: :runtime
51
- prerelease: false
52
- version_requirements: !ruby/object:Gem::Requirement
53
- requirements:
54
- - - "~>"
55
- - !ruby/object:Gem::Version
56
- version: 0.0.9
57
15
  - !ruby/object:Gem::Dependency
58
16
  name: decidim-comments
59
17
  requirement: !ruby/object:Gem::Requirement
60
18
  requirements:
61
19
  - - '='
62
20
  - !ruby/object:Gem::Version
63
- version: 0.24.3
21
+ version: 0.25.0.rc4
64
22
  type: :runtime
65
23
  prerelease: false
66
24
  version_requirements: !ruby/object:Gem::Requirement
67
25
  requirements:
68
26
  - - '='
69
27
  - !ruby/object:Gem::Version
70
- version: 0.24.3
28
+ version: 0.25.0.rc4
71
29
  - !ruby/object:Gem::Dependency
72
30
  name: decidim-core
73
31
  requirement: !ruby/object:Gem::Requirement
74
32
  requirements:
75
33
  - - '='
76
34
  - !ruby/object:Gem::Version
77
- version: 0.24.3
35
+ version: 0.25.0.rc4
78
36
  type: :runtime
79
37
  prerelease: false
80
38
  version_requirements: !ruby/object:Gem::Requirement
81
39
  requirements:
82
40
  - - '='
83
41
  - !ruby/object:Gem::Version
84
- version: 0.24.3
42
+ version: 0.25.0.rc4
85
43
  - !ruby/object:Gem::Dependency
86
44
  name: doc2text
87
45
  requirement: !ruby/object:Gem::Requirement
@@ -96,40 +54,6 @@ dependencies:
96
54
  - - "~>"
97
55
  - !ruby/object:Gem::Version
98
56
  version: 0.4.3
99
- - !ruby/object:Gem::Dependency
100
- name: kaminari
101
- requirement: !ruby/object:Gem::Requirement
102
- requirements:
103
- - - "~>"
104
- - !ruby/object:Gem::Version
105
- version: '1.2'
106
- - - ">="
107
- - !ruby/object:Gem::Version
108
- version: 1.2.1
109
- type: :runtime
110
- prerelease: false
111
- version_requirements: !ruby/object:Gem::Requirement
112
- requirements:
113
- - - "~>"
114
- - !ruby/object:Gem::Version
115
- version: '1.2'
116
- - - ">="
117
- - !ruby/object:Gem::Version
118
- version: 1.2.1
119
- - !ruby/object:Gem::Dependency
120
- name: ransack
121
- requirement: !ruby/object:Gem::Requirement
122
- requirements:
123
- - - "~>"
124
- - !ruby/object:Gem::Version
125
- version: 2.1.1
126
- type: :runtime
127
- prerelease: false
128
- version_requirements: !ruby/object:Gem::Requirement
129
- requirements:
130
- - - "~>"
131
- - !ruby/object:Gem::Version
132
- version: 2.1.1
133
57
  - !ruby/object:Gem::Dependency
134
58
  name: redcarpet
135
59
  requirement: !ruby/object:Gem::Requirement
@@ -156,84 +80,84 @@ dependencies:
156
80
  requirements:
157
81
  - - '='
158
82
  - !ruby/object:Gem::Version
159
- version: 0.24.3
83
+ version: 0.25.0.rc4
160
84
  type: :development
161
85
  prerelease: false
162
86
  version_requirements: !ruby/object:Gem::Requirement
163
87
  requirements:
164
88
  - - '='
165
89
  - !ruby/object:Gem::Version
166
- version: 0.24.3
90
+ version: 0.25.0.rc4
167
91
  - !ruby/object:Gem::Dependency
168
92
  name: decidim-assemblies
169
93
  requirement: !ruby/object:Gem::Requirement
170
94
  requirements:
171
95
  - - '='
172
96
  - !ruby/object:Gem::Version
173
- version: 0.24.3
97
+ version: 0.25.0.rc4
174
98
  type: :development
175
99
  prerelease: false
176
100
  version_requirements: !ruby/object:Gem::Requirement
177
101
  requirements:
178
102
  - - '='
179
103
  - !ruby/object:Gem::Version
180
- version: 0.24.3
104
+ version: 0.25.0.rc4
181
105
  - !ruby/object:Gem::Dependency
182
106
  name: decidim-budgets
183
107
  requirement: !ruby/object:Gem::Requirement
184
108
  requirements:
185
109
  - - '='
186
110
  - !ruby/object:Gem::Version
187
- version: 0.24.3
111
+ version: 0.25.0.rc4
188
112
  type: :development
189
113
  prerelease: false
190
114
  version_requirements: !ruby/object:Gem::Requirement
191
115
  requirements:
192
116
  - - '='
193
117
  - !ruby/object:Gem::Version
194
- version: 0.24.3
118
+ version: 0.25.0.rc4
195
119
  - !ruby/object:Gem::Dependency
196
120
  name: decidim-dev
197
121
  requirement: !ruby/object:Gem::Requirement
198
122
  requirements:
199
123
  - - '='
200
124
  - !ruby/object:Gem::Version
201
- version: 0.24.3
125
+ version: 0.25.0.rc4
202
126
  type: :development
203
127
  prerelease: false
204
128
  version_requirements: !ruby/object:Gem::Requirement
205
129
  requirements:
206
130
  - - '='
207
131
  - !ruby/object:Gem::Version
208
- version: 0.24.3
132
+ version: 0.25.0.rc4
209
133
  - !ruby/object:Gem::Dependency
210
134
  name: decidim-meetings
211
135
  requirement: !ruby/object:Gem::Requirement
212
136
  requirements:
213
137
  - - '='
214
138
  - !ruby/object:Gem::Version
215
- version: 0.24.3
139
+ version: 0.25.0.rc4
216
140
  type: :development
217
141
  prerelease: false
218
142
  version_requirements: !ruby/object:Gem::Requirement
219
143
  requirements:
220
144
  - - '='
221
145
  - !ruby/object:Gem::Version
222
- version: 0.24.3
146
+ version: 0.25.0.rc4
223
147
  - !ruby/object:Gem::Dependency
224
148
  name: decidim-participatory_processes
225
149
  requirement: !ruby/object:Gem::Requirement
226
150
  requirements:
227
151
  - - '='
228
152
  - !ruby/object:Gem::Version
229
- version: 0.24.3
153
+ version: 0.25.0.rc4
230
154
  type: :development
231
155
  prerelease: false
232
156
  version_requirements: !ruby/object:Gem::Requirement
233
157
  requirements:
234
158
  - - '='
235
159
  - !ruby/object:Gem::Version
236
- version: 0.24.3
160
+ version: 0.25.0.rc4
237
161
  description: A proposals component for decidim's participatory spaces.
238
162
  email:
239
163
  - josepjaume@gmail.com
@@ -245,21 +169,6 @@ extra_rdoc_files: []
245
169
  files:
246
170
  - README.md
247
171
  - Rakefile
248
- - app/assets/config/admin/decidim_proposals_manifest.js
249
- - app/assets/config/decidim_proposals_manifest.js
250
- - app/assets/documents/decidim/proposals/participatory_texts/participatory_text.md
251
- - app/assets/documents/decidim/proposals/participatory_texts/participatory_text.odt
252
- - app/assets/images/decidim/gamification/badges/accepted_proposals.svg
253
- - app/assets/images/decidim/gamification/badges/proposal_votes.svg
254
- - app/assets/images/decidim/gamification/badges/proposals.svg
255
- - app/assets/images/decidim/proposals/icon.svg
256
- - app/assets/javascripts/decidim/proposals/add_proposal.js.es6
257
- - app/assets/javascripts/decidim/proposals/admin/proposals.es6
258
- - app/assets/javascripts/decidim/proposals/admin/proposals_form.js.es6
259
- - app/assets/javascripts/decidim/proposals/admin/proposals_picker.js.es6
260
- - app/assets/javascripts/decidim/proposals/utils.js.es6
261
- - app/assets/stylesheets/decidim/proposals/_proposals.css.scss
262
- - app/assets/stylesheets/decidim/proposals/proposals/_preview.css.scss
263
172
  - app/cells/decidim/proposals/collaborative_draft_cell.rb
264
173
  - app/cells/decidim/proposals/collaborative_draft_link_to_proposal/show.erb
265
174
  - app/cells/decidim/proposals/collaborative_draft_link_to_proposal_cell.rb
@@ -415,6 +324,21 @@ files:
415
324
  - app/models/decidim/proposals/proposal_note.rb
416
325
  - app/models/decidim/proposals/proposal_vote.rb
417
326
  - app/models/decidim/proposals/valuation_assignment.rb
327
+ - app/packs/documents/decidim/proposals/participatory_texts/participatory_text.md
328
+ - app/packs/documents/decidim/proposals/participatory_texts/participatory_text.odt
329
+ - app/packs/entrypoints/decidim_proposals.js
330
+ - app/packs/entrypoints/decidim_proposals_admin.js
331
+ - app/packs/images/decidim/gamification/badges/decidim_gamification_badges_accepted_proposals.svg
332
+ - app/packs/images/decidim/gamification/badges/decidim_gamification_badges_proposal_votes.svg
333
+ - app/packs/images/decidim/gamification/badges/decidim_gamification_badges_proposals.svg
334
+ - app/packs/images/decidim/proposals/decidim_proposals.svg
335
+ - app/packs/src/decidim/proposals/add_proposal.js
336
+ - app/packs/src/decidim/proposals/admin/proposals.js
337
+ - app/packs/src/decidim/proposals/admin/proposals_form.js
338
+ - app/packs/src/decidim/proposals/admin/proposals_picker.js
339
+ - app/packs/src/decidim/proposals/utils.js
340
+ - app/packs/stylesheets/decidim/proposals/_proposals.scss
341
+ - app/packs/stylesheets/decidim/proposals/proposals/_preview.scss
418
342
  - app/permissions/decidim/proposals/admin/permissions.rb
419
343
  - app/permissions/decidim/proposals/permissions.rb
420
344
  - app/presenters/decidim/proposals/admin_log/proposal_note_presenter.rb
@@ -519,6 +443,7 @@ files:
519
443
  - app/views/decidim/proposals/proposals/show.html.erb
520
444
  - app/views/decidim/proposals/versions/index.html.erb
521
445
  - app/views/decidim/proposals/versions/show.html.erb
446
+ - config/assets.rb
522
447
  - config/locales/am-ET.yml
523
448
  - config/locales/ar-SA.yml
524
449
  - config/locales/ar.yml
@@ -545,6 +470,7 @@ files:
545
470
  - config/locales/fi-plain.yml
546
471
  - config/locales/fi.yml
547
472
  - config/locales/fr-CA.yml
473
+ - config/locales/fr-LU.yml
548
474
  - config/locales/fr.yml
549
475
  - config/locales/ga-IE.yml
550
476
  - config/locales/gl.yml
@@ -555,10 +481,10 @@ files:
555
481
  - config/locales/is-IS.yml
556
482
  - config/locales/is.yml
557
483
  - config/locales/it.yml
558
- - config/locales/ja-JP.yml
559
484
  - config/locales/ja.yml
560
485
  - config/locales/ko-KR.yml
561
486
  - config/locales/ko.yml
487
+ - config/locales/lb-LU.yml
562
488
  - config/locales/lt-LT.yml
563
489
  - config/locales/lt.yml
564
490
  - config/locales/lv.yml
@@ -681,9 +607,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
681
607
  version: '2.7'
682
608
  required_rubygems_version: !ruby/object:Gem::Requirement
683
609
  requirements:
684
- - - ">="
610
+ - - ">"
685
611
  - !ruby/object:Gem::Version
686
- version: '0'
612
+ version: 1.3.1
687
613
  requirements: []
688
614
  rubygems_version: 3.1.2
689
615
  signing_key:
@@ -1,2 +0,0 @@
1
- //= link decidim/proposals/admin/proposals.js
2
- //= link decidim/proposals/admin/proposals_picker.js
@@ -1,4 +0,0 @@
1
- //= link decidim/proposals/add_proposal.js
2
- //= link decidim/proposals/admin/proposals_form.js
3
- //= link_tree ../images/decidim
4
- //= link_tree ../documents/decidim
@@ -1,31 +0,0 @@
1
- $(() => {
2
- const { attachGeocoding } = window.Decidim;
3
-
4
- window.DecidimProposals = window.DecidimProposals || {};
5
-
6
- window.DecidimProposals.bindProposalAddress = () => {
7
- const $checkbox = $("input:checkbox[name$='[has_address]']");
8
- const $addressInput = $("#address_input");
9
- const $addressInputField = $("input", $addressInput);
10
-
11
- if ($checkbox.length > 0) {
12
- const toggleInput = () => {
13
- if ($checkbox[0].checked) {
14
- $addressInput.show();
15
- $addressInputField.prop("disabled", false);
16
- } else {
17
- $addressInput.hide();
18
- $addressInputField.prop("disabled", true);
19
- }
20
- }
21
- toggleInput();
22
- $checkbox.on("change", toggleInput);
23
- }
24
-
25
- if ($addressInput.length > 0) {
26
- attachGeocoding($addressInputField);
27
- }
28
- };
29
-
30
- window.DecidimProposals.bindProposalAddress();
31
- });