decidim-decidim_awesome 0.8.3 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of decidim-decidim_awesome might be problematic. Click here for more details.

Files changed (115) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +32 -0
  3. data/README.md +54 -45
  4. data/Rakefile +1 -1
  5. data/app/commands/decidim/decidim_awesome/admin/create_constraint.rb +1 -1
  6. data/app/commands/decidim/decidim_awesome/admin/create_custom_redirect.rb +1 -1
  7. data/app/commands/decidim/decidim_awesome/admin/create_menu_hack.rb +1 -1
  8. data/app/commands/decidim/decidim_awesome/admin/create_proposal_custom_field.rb +1 -1
  9. data/app/commands/decidim/decidim_awesome/admin/create_scoped_admin.rb +1 -1
  10. data/app/commands/decidim/decidim_awesome/admin/create_scoped_style.rb +1 -1
  11. data/app/commands/decidim/decidim_awesome/admin/destroy_constraint.rb +1 -1
  12. data/app/commands/decidim/decidim_awesome/admin/destroy_custom_redirect.rb +1 -1
  13. data/app/commands/decidim/decidim_awesome/admin/destroy_menu_hack.rb +1 -1
  14. data/app/commands/decidim/decidim_awesome/admin/destroy_proposal_custom_field.rb +1 -1
  15. data/app/commands/decidim/decidim_awesome/admin/destroy_scoped_admin.rb +1 -1
  16. data/app/commands/decidim/decidim_awesome/admin/destroy_scoped_style.rb +1 -1
  17. data/app/commands/decidim/decidim_awesome/admin/rename_scope_label.rb +1 -1
  18. data/app/commands/decidim/decidim_awesome/admin/update_config.rb +2 -3
  19. data/app/commands/decidim/decidim_awesome/admin/update_constraint.rb +2 -2
  20. data/app/commands/decidim/decidim_awesome/admin/update_custom_redirect.rb +1 -1
  21. data/app/commands/decidim/decidim_awesome/admin/update_menu_hack.rb +1 -1
  22. data/app/commands/decidim/decidim_awesome/command.rb +14 -0
  23. data/app/commands/decidim/decidim_awesome/create_editor_image.rb +1 -1
  24. data/app/controllers/concerns/decidim/decidim_awesome/admin_accountability/admin/filterable.rb +67 -0
  25. data/app/controllers/concerns/decidim/decidim_awesome/admin_accountability/admin/filterable_helper.rb +37 -0
  26. data/app/controllers/decidim/decidim_awesome/admin/admin_accountability_controller.rb +51 -0
  27. data/app/controllers/decidim/decidim_awesome/admin/checks_controller.rb +6 -3
  28. data/app/controllers/decidim/decidim_awesome/admin/config_controller.rb +2 -0
  29. data/app/controllers/decidim/decidim_awesome/admin/custom_redirects_controller.rb +2 -0
  30. data/app/controllers/decidim/decidim_awesome/admin/menu_hacks_controller.rb +2 -0
  31. data/app/controllers/decidim/decidim_awesome/editor_images_controller.rb +0 -2
  32. data/app/forms/decidim/decidim_awesome/admin/config_form.rb +14 -0
  33. data/app/forms/decidim/decidim_awesome/admin/menu_form.rb +1 -1
  34. data/app/forms/decidim/decidim_awesome/proposals/proposal_wizard_create_step_form_override.rb +26 -8
  35. data/app/helpers/decidim/decidim_awesome/admin/config_constraints_helpers.rb +12 -8
  36. data/app/helpers/decidim/decidim_awesome/map_helper.rb +14 -11
  37. data/app/jobs/decidim/decidim_awesome/export_admin_actions_job.rb +28 -0
  38. data/app/middleware/decidim/decidim_awesome/current_config.rb +4 -0
  39. data/app/models/decidim/decidim_awesome/awesome_config.rb +0 -1
  40. data/app/models/decidim/decidim_awesome/config_constraint.rb +0 -2
  41. data/app/models/decidim/decidim_awesome/editor_image.rb +0 -3
  42. data/app/models/decidim/decidim_awesome/paper_trail_version.rb +99 -0
  43. data/app/packs/entrypoints/decidim_admin_decidim_awesome.js +3 -2
  44. data/app/packs/images/decidim/decidim_awesome/pokecode-logo.png +0 -0
  45. data/app/packs/src/decidim/decidim_awesome/admin/auto_edit.js +7 -7
  46. data/app/packs/src/decidim/decidim_awesome/admin/check_redirections.js +2 -2
  47. data/app/packs/src/decidim/decidim_awesome/admin/constraints.js +5 -5
  48. data/app/packs/src/decidim/decidim_awesome/admin/custom_fields_builder.js +11 -10
  49. data/app/packs/src/decidim/decidim_awesome/admin/form_exit_warn.js +1 -0
  50. data/app/packs/src/decidim/decidim_awesome/admin/user_picker.js +1 -0
  51. data/app/packs/src/decidim/decidim_awesome/awesome_map/api/fetcher.js +13 -13
  52. data/app/packs/src/decidim/decidim_awesome/awesome_map/awesome_map.js +14 -12
  53. data/app/packs/src/decidim/decidim_awesome/awesome_map/controllers/controller.js +16 -12
  54. data/app/packs/src/decidim/decidim_awesome/awesome_map/controllers/proposals_controller.js +3 -3
  55. data/app/packs/src/decidim/decidim_awesome/awesome_map/controls_ui.js +25 -26
  56. data/app/packs/src/decidim/decidim_awesome/awesome_map/load_map.js +1 -0
  57. data/app/packs/src/decidim/decidim_awesome/editors/editor.js +33 -12
  58. data/app/packs/src/decidim/decidim_awesome/forms/autosave.js +8 -12
  59. data/app/packs/src/decidim/decidim_awesome/forms/custom_fields_renderer.js +36 -27
  60. data/app/packs/src/decidim/decidim_awesome/forms/rich_text_plugin.js +6 -4
  61. data/app/packs/src/decidim/decidim_awesome/proposals/custom_fields.js +7 -7
  62. data/app/packs/src/decidim/decidim_awesome/proposals/images.js +2 -2
  63. data/app/packs/stylesheets/decidim/decidim_awesome/awesome_admin.scss +8 -5
  64. data/app/permissions/decidim/decidim_awesome/admin/permissions.rb +15 -1
  65. data/app/permissions/decidim/decidim_awesome/permissions.rb +4 -6
  66. data/app/presenters/decidim/decidim_awesome/paper_trail_base_presenter.rb +28 -0
  67. data/app/presenters/decidim/decidim_awesome/participatory_space_role_presenter.rb +45 -0
  68. data/app/presenters/decidim/decidim_awesome/role_base_presenter.rb +102 -0
  69. data/app/presenters/decidim/decidim_awesome/user_entity_presenter.rb +50 -0
  70. data/app/serializers/decidim/decidim_awesome/paper_trail_version_serializer.rb +37 -0
  71. data/app/validators/concerns/decidim/decidim_awesome/etiquette_validator_override.rb +41 -0
  72. data/app/views/decidim/decidim_awesome/admin/admin_accountability/index.html.erb +59 -0
  73. data/app/views/decidim/decidim_awesome/admin/checks/_assets_tester.html.erb +2 -0
  74. data/app/views/decidim/decidim_awesome/admin/config/_form_proposals.html.erb +82 -2
  75. data/app/views/decidim/decidim_awesome/admin/shared/_filters_with_date.html.erb +56 -0
  76. data/app/views/decidim/proposals/admin/proposals/_form.html.erb +1 -1
  77. data/app/views/decidim/proposals/collaborative_drafts/_edit_form_fields.html.erb +9 -17
  78. data/app/views/layouts/decidim/admin/decidim_awesome.html.erb +1 -1
  79. data/app/views/{v0.25 → v0.27}/layouts/decidim/_head.html.erb +12 -4
  80. data/config/i18n-tasks.yml +4 -0
  81. data/config/locales/ca.yml +22 -2
  82. data/config/locales/cs.yml +7 -2
  83. data/config/locales/de.yml +20 -1
  84. data/config/locales/en.yml +90 -1
  85. data/config/locales/es.yml +2 -2
  86. data/config/locales/fr.yml +22 -2
  87. data/config/locales/it.yml +2 -2
  88. data/config/locales/ja.yml +3 -2
  89. data/config/locales/nl.yml +1 -1
  90. data/config/locales/pt-BR.yml +2 -2
  91. data/db/seeds.rb +1 -1
  92. data/lib/decidim/decidim_awesome/admin_engine.rb +15 -1
  93. data/lib/decidim/decidim_awesome/awesome.rb +55 -1
  94. data/lib/decidim/decidim_awesome/checksums.yml +13 -3
  95. data/lib/decidim/decidim_awesome/config.rb +14 -14
  96. data/lib/decidim/decidim_awesome/context_analyzers/request_analyzer.rb +1 -1
  97. data/lib/decidim/decidim_awesome/engine.rb +36 -9
  98. data/lib/decidim/decidim_awesome/iframe_component/component.rb +2 -1
  99. data/lib/decidim/decidim_awesome/menu_hacker.rb +6 -0
  100. data/lib/decidim/decidim_awesome/system_checker.rb +2 -0
  101. data/lib/decidim/decidim_awesome/test/factories.rb +7 -0
  102. data/lib/decidim/decidim_awesome/test/initializer.rb +10 -2
  103. data/lib/decidim/decidim_awesome/test/shared_examples/action_log_presenter_examples.rb +61 -0
  104. data/lib/decidim/decidim_awesome/test/shared_examples/scoped_admins_examples.rb +7 -4
  105. data/lib/decidim/decidim_awesome/test/shared_examples/summary_examples.rb +2 -2
  106. data/lib/decidim/decidim_awesome/version.rb +2 -2
  107. data/lib/tasks/decidim_awesome_active_storage_migrations_tasks.rake +1 -3
  108. data/package.json +21 -164
  109. metadata +39 -39
  110. data/app/packs/images/decidim/decidim_awesome/platoniq-logo.png +0 -0
  111. data/app/packs/src/vendor/image-resize.min.js +0 -1
  112. data/app/packs/src/vendor/image-upload.min.js +0 -6
  113. data/app/packs/src/vendor/leaflet.featuregroup.subgroup.js +0 -184
  114. /data/app/views/{v0.25 → v0.27}/decidim/proposals/collaborative_drafts/_show.html.erb +0 -0
  115. /data/app/views/{v0.25 → v0.27}/layouts/decidim/admin/_header.html.erb +0 -0
@@ -6,6 +6,7 @@ locales: [en]
6
6
  data:
7
7
  external:
8
8
  - "<%= %x[bundle info decidim-core --path].chomp %>/config/locales/%{locale}.yml"
9
+ - "<%= %x[bundle info decidim-admin --path].chomp %>/config/locales/%{locale}.yml"
9
10
  - "<%= %x[bundle info decidim-proposals --path].chomp %>/config/locales/%{locale}.yml"
10
11
  - "<%= %x[bundle info decidim-meetings --path].chomp %>/config/locales/%{locale}.yml"
11
12
 
@@ -14,3 +15,6 @@ ignore_unused:
14
15
 
15
16
  ignore_missing:
16
17
  - decidim.participatory_processes.scopes.global
18
+ # TODO: remove when diching support for 0.26
19
+ - decidim.proposals.collaborative_drafts.new.add_file
20
+ - decidim.proposals.collaborative_drafts.new.edit_file
@@ -21,6 +21,14 @@ ca:
21
21
  scoped_admins: 'Grup d''administradores acotades #%{id}'
22
22
  scoped_styles: 'Personalització d''estils #%{id}'
23
23
  use_markdown_editor: Fes servir l'editor Markdown en comptes de l'editor HTML
24
+ validate_body_max_caps_percent: Percentatge màxim de majúscules en el cos de la proposta
25
+ validate_body_max_marks_together: Nombre màxim de símbols consecutius permesos al cos de la proposta
26
+ validate_body_min_length: Nombre de caràcters mínims requerits pel cos de la proposta
27
+ validate_body_start_with_caps: Força que el text del cos s'inici amb una majúscula
28
+ validate_title_max_caps_percent: Percentatge màxim de majúscules en el títol de la proposta
29
+ validate_title_max_marks_together: Nombre màxim de símbols consecutius permesos al títol de la proposta
30
+ validate_title_min_length: Nombre de caràcters mínims requerits pel títol de la proposta
31
+ validate_title_start_with_caps: Força que el text del títol s'inici amb una majúscula
24
32
  constraint:
25
33
  component_id: o específicament a
26
34
  component_manifest: Només en components de tipus
@@ -151,6 +159,15 @@ ca:
151
159
  scoped_styles: Crea CSS personalitzats que només s'apliquin a determinades parts de la web pública (per fer-ho, utilitza l'editor de restriccions)
152
160
  scoped_styles_variables: 'Pots fer servir les següents variables CSS pels colors personalitzats de l''organització:'
153
161
  use_markdown_editor: Això substituirà l'editor HTML (Quill), en el seu lloc s'utilitzarà un editor Markdown tant a l'admin com a la pàgina pública per processar el text (a la base de dades el text es desarà com a markdown)
162
+ validate_body_max_caps_percent: Zero no permetrà cap majúscula, 100 obligarà a escriure-ho tot en majúscules
163
+ validate_body_max_marks_together: 'Limiteu el nombre de signes d''interrogació i d''exclamació que es poden escriure junts. És a dir: si és 2, aleshores ''!!!'' no es permetrà al text'
164
+ validate_body_min_length: Aquest nombre pot ser zero, això farà que aquest camp no sigui obligatori
165
+ validate_title_max_caps_percent: Zero no permetrà cap majúscula, 100 obligarà a escriure-ho tot en majúscules
166
+ validate_title_max_marks_together: 'Limiteu el nombre de signes d''interrogació i d''exclamació que es poden escriure junts. És a dir: si és 2, aleshores ''!!!'' no es permetrà al text'
167
+ validate_title_min_length: El títol sempre és obligatori i aquest número no pot ser zero
168
+ validators:
169
+ body: Validacions d'entrada per l'usuari en el camp cos de la proposta
170
+ title: Validacions d'entrada per l'usuari en el camp títol de la proposta
154
171
  form_proposal_custom_fields:
155
172
  new: Afegeix una nova caixa de "camps personalitzats"
156
173
  remove: Elimina aquesta caixa de "camps personalitzats"
@@ -260,6 +277,7 @@ ca:
260
277
  hidden: Sempre ocult
261
278
  logged: Només visible per usuàries loguejades
262
279
  non_logged: Només visible per usuàries no loguejades
280
+ verified_user: Només visible per als usuaris amb una autorització vàlida
263
281
  index:
264
282
  confirm_destroy: Confirmes que vols eliminar aquest retoc?
265
283
  edit: Editar
@@ -302,7 +320,7 @@ ca:
302
320
  text_settings: Configuració del text
303
321
  title: Títol
304
322
  truncate: Nombre màxim de caràcters per les descripcions emergents
305
- credits: Decidim Awesome %{version} · Made with ♥ by Platoniq
323
+ credits: Decidim Awesome %{version} · Maintained with ♥ by %{company}
306
324
  custom_fields:
307
325
  errors:
308
326
  invalid_fields: No s'ha pogut analitzar el contingut però s'ha assignat al camp '%{field}'
@@ -313,7 +331,7 @@ ca:
313
331
  success: Imatge pujada correctament
314
332
  map_component:
315
333
  map:
316
- api_not_ready: |2
334
+ api_not_ready: |
317
335
  <b>Avís:</b> aquesta instal·lació de Decidim té l'API configurada amb una complexitat màxima de <b>%{current_complexity}</b>.
318
336
  Aquest component probablement no funcionarà amb aquesta configuració. Us recomanem que la configureu en un inicialitzador
319
337
  (per exemple, al final de <code>config/initializers/decidim.rb</code>) hi poseu les línies següents:<br>
@@ -328,6 +346,8 @@ ca:
328
346
  show:
329
347
  view_meeting: Veure trobada
330
348
  view_proposal: Veure proposta
349
+ validators:
350
+ too_much_caps: Fa servir massa lletres majúscules (més %{percent}% del text)
331
351
  layouts:
332
352
  decidim:
333
353
  admin:
@@ -21,6 +21,10 @@ cs:
21
21
  scoped_admins: 'Skupina Škálovaní administrátoři #%{id}'
22
22
  scoped_styles: Vlastní styly číslo %{id}
23
23
  use_markdown_editor: Použít Markdown editor namísto HTML editoru
24
+ validate_body_max_caps_percent: Maximální povolený procentní podíl velkých písmen pro tělo zprávy
25
+ validate_body_max_marks_together: Maximální počet po sobě jdoucích značek povolených v těle zprávy
26
+ validate_body_min_length: Minimální požadované znaky pro tělo zprávy
27
+ validate_title_max_caps_percent: Maximální povolený procentní podíl velkých písmen pro nadpis zprávy
24
28
  constraint:
25
29
  component_id: nebo konkrétně v
26
30
  component_manifest: Pouze v komponentách typu
@@ -260,6 +264,7 @@ cs:
260
264
  hidden: Vždy skryto
261
265
  logged: Viditelné pouze pro přihlášené uživatele
262
266
  non_logged: Viditelné pouze pro nepřihlášené uživatele
267
+ verified_user: Viditelné pouze pro uživatele s platnou autorizací
263
268
  index:
264
269
  confirm_destroy: Opravdu chcete odstranit toto přizpůsobení?
265
270
  edit: Upravit
@@ -302,7 +307,7 @@ cs:
302
307
  text_settings: Nastavení textu
303
308
  title: Nadpis
304
309
  truncate: Maximum znaků pro popisy vyskakovacích oken
305
- credits: Vylepšení Decidim %{version} · Vyrobeno s ♥ od Platoniq
310
+ credits: Decidim Awesome %{version} · Udržováno s ♥ od %{company}
306
311
  custom_fields:
307
312
  errors:
308
313
  invalid_fields: Obsah nemohl být analyzován, ale byl přiřazen do pole '%{field}'
@@ -313,7 +318,7 @@ cs:
313
318
  success: Obrázek byl úspěšně nahrán
314
319
  map_component:
315
320
  map:
316
- api_not_ready: |2
321
+ api_not_ready: |
317
322
  <b>Upozornění:</b> Tato instalace Decidim má API nastaveno na maximální složitost <b>%{current_complexity}</b>.
318
323
  Tato komponenta pravděpodobně nebude fungovat v této konfiguraci. Doporučujeme nastavit v inicializátoru
319
324
  (například na konci <code>config/initializers/decidim.rb</code>) následující řádky:<br>
@@ -21,6 +21,14 @@ de:
21
21
  scoped_admins: Eingeschränkte Admin-Gruppe %{id}
22
22
  scoped_styles: Eigene Eingabefelder %{id}
23
23
  use_markdown_editor: Markdown Editor anstelle des HTML-Editors verwenden
24
+ validate_body_max_caps_percent: Maximal erlaubter Prozentsatz an Großbuchstaben für den Textkörper
25
+ validate_body_max_marks_together: Maximal erlaubte aufeinanderfolgende Zeichen im Textkörper
26
+ validate_body_min_length: Minimale zwingend erforderliche Anzahl Zeichen im Textkörper
27
+ validate_body_start_with_caps: Textkörper muss zwingend mit einem Großbuchstaben beginnen
28
+ validate_title_max_caps_percent: Maximal erlaubter Prozentsatz an Großbuchstaben für den Titel
29
+ validate_title_max_marks_together: Maximal erlaubte aufeinanderfolgende Zeichen im Titel
30
+ validate_title_min_length: Minimale zwingend erforderliche Anzahl Zeichen im Titel
31
+ validate_title_start_with_caps: Titel muss zwingend mit einem Großbuchstaben beginnen
24
32
  constraint:
25
33
  component_id: oder spezifisch in
26
34
  component_manifest: Nur in Komponenten vom Typ
@@ -151,6 +159,15 @@ de:
151
159
  scoped_styles: Erstellen Sie benutzerdefinierte CSS, die nur in bestimmten Bereichen der öffentlichen Seite gelten (vewenden Sie dazu die Einschränkungen)
152
160
  scoped_styles_variables: 'Sie können die folgenden CSS-Variablen für die benutzerdefinierter Farben der Organisation verwenden:'
153
161
  use_markdown_editor: Markdown Editor benutzen
162
+ validate_body_max_caps_percent: 0 lässt keinen Großbuchstaben zu, 100 lässt ausschliesslich Großbuchstaben zu
163
+ validate_body_max_marks_together: 'Begrenzt die Anzahl der Frage- und Ausrufezeichen, die zusammen geschrieben werden können. Zum Beispiel: Der Wert 2 führt dazu, dass ''!!!'' im Text nicht erlaubt ist'
164
+ validate_body_min_length: Diese Zahl kann Null sein, was das Feld dann effektiv als "nicht obligatorisch" setzt
165
+ validate_title_max_caps_percent: 0 lässt keinen Großbuchstaben zu, 100 lässt ausschliesslich Großbuchstaben zu
166
+ validate_title_max_marks_together: 'Begrenzt die Anzahl der Frage- und Ausrufezeichen, die zusammen geschrieben werden können. Zum Beispiel: Der Wert 2 führt dazu, dass ''!!!'' im Text nicht erlaubt ist'
167
+ validate_title_min_length: Der Titel ist immer obligatorisch und diese Zahl kann nicht Null sein
168
+ validators:
169
+ body: Eingabevalidierungen für das Feld "Textkörper"
170
+ title: Eingabevalidierungen für das Feld "Titel"
154
171
  form_proposal_custom_fields:
155
172
  new: Neues Eingabefeld
156
173
  remove: Eingabefeld entfernen
@@ -256,6 +273,7 @@ de:
256
273
  hidden: Immer versteckt
257
274
  logged: Nur für angemeldete Nutzende sichtbar
258
275
  non_logged: Nur sichtbar für nicht angemeldete Nutzende
276
+ verified_user: Nur für Benutzer mit einer gültigen Berechtigung sichtbar
259
277
  index:
260
278
  confirm_destroy: Sind Sie sicher, dass Sie diese Anpassung entfernen wollen?
261
279
  edit: Bearbeiten
@@ -298,7 +316,6 @@ de:
298
316
  text_settings: Text-Einstellungen
299
317
  title: Titel
300
318
  truncate: Maximale Zeichenanzahl für Popup-Beschreibungen
301
- credits: Danksagungen
302
319
  custom_fields:
303
320
  errors:
304
321
  invalid_fields: Der Inhalt konnte nicht geparst werden, wurde aber dem Feld '%{field}' zugewiesen.
@@ -316,6 +333,8 @@ de:
316
333
  show:
317
334
  view_meeting: Sitzung ansehen
318
335
  view_proposal: Vorschlag ansehen
336
+ validators:
337
+ too_much_caps: Es werden zu viele Großbuchstaben verwendet (über %{percent}% des Textes)
319
338
  layouts:
320
339
  decidim:
321
340
  admin:
@@ -26,6 +26,18 @@ en:
26
26
  scoped_admins: Scoped admins group %{id}
27
27
  scoped_styles: Custom styles %{id}
28
28
  use_markdown_editor: Use a Markdown editor instead of the HTML editor
29
+ validate_body_max_caps_percent: Maximum allowed percentage of capital letters
30
+ for the body
31
+ validate_body_max_marks_together: Maximum consecutive marks symbols allowed
32
+ in the body
33
+ validate_body_min_length: Minimum required characters for the body
34
+ validate_body_start_with_caps: Force the body to start with a capital letter
35
+ validate_title_max_caps_percent: Maximum allowed percentage of capital letters
36
+ for the title
37
+ validate_title_max_marks_together: Maximum consecutive marks symbols allowed
38
+ in the title
39
+ validate_title_min_length: Minimum required characters for the title
40
+ validate_title_start_with_caps: Force the title to start with a capital letter
29
41
  constraint:
30
42
  component_id: or specifically in
31
43
  component_manifest: Only in components of type
@@ -47,7 +59,23 @@ en:
47
59
  proposal_custom_fields: Custom fields
48
60
  decidim:
49
61
  admin:
62
+ filters:
63
+ admin_accountability:
64
+ admin_role_type:
65
+ label: Role type
66
+ participatory_space_type_eq:
67
+ label: Participatory space type
68
+ role:
69
+ label: Role
70
+ role_type_eq:
71
+ label: Role type
72
+ label:
73
+ search_field_end_date: 'To date:'
74
+ search_field_start_date: 'From date:'
75
+ search_placeholder:
76
+ user_name_or_user_email_cont: Search by user name, email
50
77
  menu:
78
+ admin_accountability: Admin accountability
51
79
  decidim_awesome: Decidim awesome
52
80
  components:
53
81
  awesome_iframe:
@@ -92,6 +120,46 @@ en:
92
120
  show_withdrawn: Show withdrawn proposals
93
121
  decidim_awesome:
94
122
  admin:
123
+ admin_accountability:
124
+ admin_roles:
125
+ admin: Super admin
126
+ user_manager: User manager
127
+ created_at: Role created at
128
+ currently_active: Currently active
129
+ deleted_user: Deleted user
130
+ email: Email
131
+ exports:
132
+ button: Export this search
133
+ export_as: Export as %{export_format}
134
+ export_format:
135
+ csv: CSV
136
+ json: JSON
137
+ xlsx: XLSX
138
+ notice: Export job has been enqueued. You will receive an email when it's
139
+ ready.
140
+ index:
141
+ description: Listed here you'll find all users that have had some role
142
+ in the administration of a participatory space. Normal admins are not
143
+ listed.
144
+ global_description: Listed here you'll find all users that have had some
145
+ global role in administrating this organization. Participatory space
146
+ admins are not listed.
147
+ see_global: List global admins
148
+ see_spaces: List participatory space admins
149
+ title: Admin accountability
150
+ last_login: Last sign in date
151
+ missing_info: "(missing information)"
152
+ missing_user: User not in the database
153
+ name: Name
154
+ never_logged: Never logged yet
155
+ participatory_space: Participatory space
156
+ removal_date: Role removed at
157
+ role: Role
158
+ roles:
159
+ admin: Administrator
160
+ collaborator: Collaborator
161
+ moderator: Moderator
162
+ valuator: Valuator
95
163
  checks:
96
164
  index:
97
165
  admin_head_tags: Awesome tags included in the admin application header
@@ -199,6 +267,23 @@ en:
199
267
  use_markdown_editor: This will substitute the Quill WYSIWYG editor,
200
268
  to use a Markdown editor instead. Text will be converted and saved
201
269
  as HTML in the database.
270
+ validate_body_max_caps_percent: Zero won't allow any capital letter,
271
+ 100 will force to write everything in capital letters
272
+ validate_body_max_marks_together: 'Limit the number of question and
273
+ exclamation marks that can be written together. Ie: if it is 2, then
274
+ ''!!!'' won''t be allowed in the text'
275
+ validate_body_min_length: This number can be zero, this will effectively
276
+ make this field non-mandatory
277
+ validate_title_max_caps_percent: Zero won't allow any capital letter,
278
+ 100 will force to write everything in capital letters
279
+ validate_title_max_marks_together: 'Limit the number of question and
280
+ exclamation marks that can be written together. Ie: if it is 2, then
281
+ ''!!!'' won''t be allowed in the text'
282
+ validate_title_min_length: Title is always mandatory and this number
283
+ cannot be zero
284
+ validators:
285
+ body: User input validations for the "body" field
286
+ title: User input validations for the "title" field
202
287
  form_proposal_custom_fields:
203
288
  new: Add a new "custom fields" box
204
289
  remove: Remove this "custom fields" box
@@ -313,6 +398,7 @@ en:
313
398
  hidden: Always hidden
314
399
  logged: Only visible for logged users
315
400
  non_logged: Only visible for non-logged users
401
+ verified_user: Only visible for users with a valid authorization
316
402
  index:
317
403
  confirm_destroy: Are you sure to remove this customization?
318
404
  edit: Edit
@@ -359,7 +445,7 @@ en:
359
445
  text_settings: Text settings
360
446
  title: Title
361
447
  truncate: Maximum characters for popup descriptions
362
- credits: Decidim Awesome %{version} · Made with ♥ by Platoniq
448
+ credits: Decidim Awesome %{version} · Maintained with ♥ by %{company}
363
449
  custom_fields:
364
450
  errors:
365
451
  invalid_fields: Content couldn't be parsed but has been assigned to the
@@ -388,6 +474,9 @@ en:
388
474
  show:
389
475
  view_meeting: View meeting
390
476
  view_proposal: View proposal
477
+ validators:
478
+ too_much_caps: Is using too many capital letters (over %{percent}% of the
479
+ text)
391
480
  layouts:
392
481
  decidim:
393
482
  admin:
@@ -302,7 +302,7 @@ es:
302
302
  text_settings: Ajustes del texto
303
303
  title: Título
304
304
  truncate: Número máximo de caracteres para las descripciones emergentes
305
- credits: Decidim Awesome %{version} · Made with ♥ by Platoniq
305
+ credits: Decidim Awesome %{version} · Maintained with ♥ by %{company}
306
306
  custom_fields:
307
307
  errors:
308
308
  invalid_fields: No se ha podido analizar el contenido pero se ha asignado al campo '%{field}'
@@ -313,7 +313,7 @@ es:
313
313
  success: Imagen subida correctamente
314
314
  map_component:
315
315
  map:
316
- api_not_ready: |2
316
+ api_not_ready: |
317
317
  <b>Advertencia:</b> Esta instalación de Decidim tiene la API configurada a una complejidad máxima de <b>%{current_complexity}</b>.
318
318
  Este componente probablemente no funcione correctament bajo esta configuración. Es recomendado configurar en un inicializador
319
319
  (por ejemplo al final de <code>config/initializers/decidim. b</code>) añadir las siguientes líneas:<br>
@@ -21,6 +21,14 @@ fr:
21
21
  scoped_admins: Groupe d'administrateurs restreints %{id}
22
22
  scoped_styles: Style personnalisés %{id}
23
23
  use_markdown_editor: Utiliser un éditeur Markdown au lieu de l'éditeur HTML
24
+ validate_body_max_caps_percent: Pourcentage maximum autorisé de lettres majuscules pour le corps
25
+ validate_body_max_marks_together: Nombre maximum de caractères spéciaux autorisés dans le corps
26
+ validate_body_min_length: Nombre de caractères minimum pour le corps
27
+ validate_body_start_with_caps: Forcer le corps à commencer par une lettre majuscule
28
+ validate_title_max_caps_percent: Pourcentage maximum autorisé de lettres majuscules pour le titre
29
+ validate_title_max_marks_together: Nombre maximum de caractères spéciaux consécutifs dans le titre
30
+ validate_title_min_length: Nombre de caractères minimum pour le titre
31
+ validate_title_start_with_caps: Forcer le titre à commencer par une lettre majuscule
24
32
  constraint:
25
33
  component_id: ou spécifiquement dans
26
34
  component_manifest: Uniquement dans les composants de type
@@ -151,6 +159,15 @@ fr:
151
159
  scoped_styles: Créer un CSS personnalisé qui s'applique uniquement à certaines parties du site web public (front-end) (utilisez l'éditeur de restrictions pour cela)
152
160
  scoped_styles_variables: 'Vous pouvez utiliser les variables CSS suivantes pour les couleurs personnalisées de l''organisation :'
153
161
  use_markdown_editor: Cela remplacera l'éditeur Quill WYSIWYG par un éditeur Markdown. Le texte sera affiché en HTML dans les pages publiques (le texte dans la base de données sera sauvegardé en tant que texte markdown)
162
+ validate_body_max_caps_percent: Zéro n'autorisera aucune lettre majuscule, 100 forcera à tout écrire en majuscule
163
+ validate_body_max_marks_together: 'Limiter le nombre de points d''interrogation et d''exclamation qui peuvent être écrits ensemble. Par exemple : si c''est 2, alors ''!!!'' ne sera pas autorisé dans le texte'
164
+ validate_body_min_length: Ce nombre peut être zéro, ce qui rendra ce champ non obligatoire
165
+ validate_title_max_caps_percent: Zéro n'autorisera aucune lettre majuscule, 100 forcera à tout écrire en majuscule
166
+ validate_title_max_marks_together: 'Limiter le nombre de points d''interrogation et d''exclamation qui peuvent être écrits ensemble. Par exemple : si c''est 2, alors ''!!!'' ne sera pas autorisé dans le texte'
167
+ validate_title_min_length: Le titre est toujours obligatoire et ce nombre ne peut être égal à zéro
168
+ validators:
169
+ body: Validations d'entrée de l'utilisateur pour le champ "body"
170
+ title: Validations d'entrée de l'utilisateur pour le champ "body"
154
171
  form_proposal_custom_fields:
155
172
  new: Ajouter une nouvelle boîte de champs personnalisés
156
173
  remove: Supprimer cette boîte de champs personnalisés
@@ -260,6 +277,7 @@ fr:
260
277
  hidden: Toujours caché
261
278
  logged: Uniquement visible pour utilisateurs identifiés
262
279
  non_logged: Visible uniquement pour les utilisateurs non connectés
280
+ verified_user: Visible uniquement pour les utilisateurs ayant une autorisation valide
263
281
  index:
264
282
  confirm_destroy: Êtes-vous sûr de vouloir supprimer cette personnalisation ?
265
283
  edit: Modifier
@@ -302,7 +320,7 @@ fr:
302
320
  text_settings: Paramètres de texte
303
321
  title: Titre
304
322
  truncate: Caractères maximum pour les descriptions des popups
305
- credits: Décidim Awesome %{version} · Fait avecpar Platoniq
323
+ credits: Décidim Awesome %{version} · Maintained withby %{company}
306
324
  custom_fields:
307
325
  errors:
308
326
  invalid_fields: Le contenu n'a pas pu être analysé mais a été assigné au champ '%{field}'
@@ -313,7 +331,7 @@ fr:
313
331
  success: Image ajoutée avec succès
314
332
  map_component:
315
333
  map:
316
- api_not_ready: |2
334
+ api_not_ready: |
317
335
  <b>Attention :</b> Cette installation de Decidim a l'API configurée à une complexité maximale de <b>%{current_complexity}</b>.
318
336
  Ce composant ne fonctionnera probablement pas avec cette configuration. Nous vous recommandons de configurer dans un initialiseur
319
337
  (par exemple à la fin de <code>config/initializers/decidim.rb</code>) les lignes suivantes :<br>
@@ -328,6 +346,8 @@ fr:
328
346
  show:
329
347
  view_meeting: Voir la rencontre
330
348
  view_proposal: Voir la proposition
349
+ validators:
350
+ too_much_caps: Utilise trop de majuscule (plus de %{percent} du texte)
331
351
  layouts:
332
352
  decidim:
333
353
  admin:
@@ -302,7 +302,7 @@ it:
302
302
  text_settings: Impostazioni Testo
303
303
  title: Titolo
304
304
  truncate: Numero massimo di caratteri per le descrizioni nei popup
305
- credits: Decidim Awesome %{version} · Fatto conda Platoniq
305
+ credits: Decidim Awesome %{version} · Maintained withby %{company}
306
306
  custom_fields:
307
307
  errors:
308
308
  invalid_fields: Il contenuto non può essere analizzato ma è stato assegnato al campo '%{field}'
@@ -313,7 +313,7 @@ it:
313
313
  success: Immagine caricata correttamente
314
314
  map_component:
315
315
  map:
316
- api_not_ready: |2
316
+ api_not_ready: |
317
317
  <b>Attenzione:</b> Questa installazione di Decidim ha configurato l'API ad una complessità massima di <b>%{current_complexity}</b>.
318
318
  Questo componente probabilmente non funzionerà con questa configurazione, Si consiglia di impostare in un initializer
319
319
  (per esempio alla fine del <code>config/initializers/decidim.rb</code>) con il seguente contenuti:<br>
@@ -261,6 +261,7 @@ ja:
261
261
  hidden: 常に非表示
262
262
  logged: ログインしたユーザーにのみ表示
263
263
  non_logged: ログインしていないユーザーにのみ表示
264
+ verified_user: 権限のあるユーザーのみ表示
264
265
  index:
265
266
  confirm_destroy: この設定を削除しますか?
266
267
  edit: 編集
@@ -303,7 +304,7 @@ ja:
303
304
  text_settings: テキストの設定
304
305
  title: タイトル
305
306
  truncate: ポップアップの説明のための最大文字数
306
- credits: Decidim Awesome %{version} · Made with ♥ by Platoniq
307
+ credits: Decidim Awesome %{version} · Maintained with ♥ by %{company}
307
308
  custom_fields:
308
309
  errors:
309
310
  invalid_fields: コンテンツは解析できませんでしたが、フィールド '%{field}' に割り当てられました
@@ -314,7 +315,7 @@ ja:
314
315
  success: 画像は正常にアップロードされました
315
316
  map_component:
316
317
  map:
317
- api_not_ready: |2
318
+ api_not_ready: |
318
319
  <b>警告:</b> この Decidim のインストールでは、APIの最大複雑度が <b>%{current_complexity}</b> に設定されています。このコンポーネントは、この設定では動作しないかもしれません。初期化の設定を (例えば<code>config/initializers/decidim.rb</code>の末尾で) 以下のようにすることを推奨します:<br>
319
320
  <br>
320
321
  <pre># Api configuration
@@ -211,7 +211,7 @@ nl:
211
211
  show_rejected: Toon afgewezen voorstellen
212
212
  show_withdrawn: Toon ingetrokken voorstellen
213
213
  truncate: Maximaal aantal tekens voor popup beschrijvingen
214
- credits: Decidim Awesome %{version} · Gemaakt metdoor Platoniq
214
+ credits: Decidim Awesome %{version} · Maintained withby %{company}
215
215
  editor_images:
216
216
  create:
217
217
  error: Fout bij uploaden afbeelding!
@@ -302,7 +302,7 @@ pt-BR:
302
302
  text_settings: Configurações de texto
303
303
  title: Título
304
304
  truncate: Máximo de caracteres para descrições em popup
305
- credits: Decidim Incrível %{version} · Feito compor Platoniq
305
+ credits: Decidim Incrível %{version} · Maintained withby %{company}
306
306
  custom_fields:
307
307
  errors:
308
308
  invalid_fields: O conteúdo não pode ser analisado, mas foi atribuído ao campo '%{field}'
@@ -313,7 +313,7 @@ pt-BR:
313
313
  success: Imagem enviada com sucesso
314
314
  map_component:
315
315
  map:
316
- api_not_ready: |2
316
+ api_not_ready: |
317
317
  <b>Aviso:</b> Esta instalação Decidim tem a API configurada para uma complexidade máxima de <b>%{current_complexity}</b>.
318
318
  Este componente provavelmente não funcionará sob esta configuração. Recomendamos que você configure em um inicializador
319
319
  (por exemplo, no final do <code>config/initializers/decidim. b</code>) as seguintes linhas:<br>
data/db/seeds.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- if !Rails.env.production? || ENV["SEED"]
3
+ if !Rails.env.production? || ENV.fetch("SEED", nil)
4
4
  print "Creating seeds for decidim_awesome...\n" unless Rails.env.test?
5
5
 
6
6
  organization = Decidim::Organization.first
@@ -22,6 +22,8 @@ module Decidim
22
22
  resources :scoped_styles, param: :var, only: [:create, :destroy]
23
23
  resources :proposal_custom_fields, param: :var, only: [:create, :destroy]
24
24
  resources :scoped_admins, param: :var, only: [:create, :destroy]
25
+ get :admin_accountability, to: "admin_accountability#index", as: "admin_accountability"
26
+ post :export_admin_accountability, to: "admin_accountability#export", as: "export_admin_accountability"
25
27
  get :users, to: "config#users"
26
28
  post :rename_scope_label, to: "config#rename_scope_label"
27
29
  get :checks, to: "checks#index"
@@ -38,7 +40,7 @@ module Decidim
38
40
  initializer "decidim_awesome.admin_menu" do
39
41
  Decidim.menu :admin_menu do |menu|
40
42
  menu.add_item :awesome_menu,
41
- I18n.t("menu.decidim_awesome", scope: "decidim.admin", default: "Decidim Awesome"),
43
+ I18n.t("menu.decidim_awesome", scope: "decidim.admin"),
42
44
  decidim_admin_decidim_awesome.config_path(:editors),
43
45
  icon_name: "fire",
44
46
  position: 7.5,
@@ -47,6 +49,18 @@ module Decidim
47
49
  end
48
50
  end
49
51
 
52
+ initializer "decidim_awesome.admin_menu" do
53
+ Decidim.menu :admin_user_menu do |menu|
54
+ if DecidimAwesome.enabled? :admin_accountability
55
+ menu.add_item :admin_accountability,
56
+ I18n.t("menu.admin_accountability", scope: "decidim.admin"),
57
+ decidim_admin_decidim_awesome.admin_accountability_path,
58
+ active: is_active_link?(decidim_admin_decidim_awesome.admin_accountability_path, :inclusive),
59
+ position: 7
60
+ end
61
+ end
62
+ end
63
+
50
64
  def load_seed
51
65
  nil
52
66
  end
@@ -61,6 +61,41 @@ module Decidim
61
61
  false
62
62
  end
63
63
 
64
+ # Configuration options to handle different validations in proposals
65
+ # (maybe in the future will apply to other places)
66
+ # Set it to :disabled if you don't want to use this feature
67
+ config_accessor :validate_title_min_length do
68
+ 15
69
+ end
70
+
71
+ config_accessor :validate_title_max_caps_percent do
72
+ 25
73
+ end
74
+
75
+ config_accessor :validate_title_max_marks_together do
76
+ 1
77
+ end
78
+
79
+ config_accessor :validate_title_start_with_caps do
80
+ true
81
+ end
82
+
83
+ config_accessor :validate_body_min_length do
84
+ 15
85
+ end
86
+
87
+ config_accessor :validate_body_max_caps_percent do
88
+ 25
89
+ end
90
+
91
+ config_accessor :validate_body_max_marks_together do
92
+ 1
93
+ end
94
+
95
+ config_accessor :validate_body_start_with_caps do
96
+ true
97
+ end
98
+
64
99
  config_accessor :intergram_for_public do
65
100
  false
66
101
  end
@@ -186,6 +221,21 @@ module Decidim
186
221
  }
187
222
  end
188
223
 
224
+ # If true, enables a new section in "Participants" where to audit all the admin roles that have been enabled/disabled historically in Decidim
225
+ # Set to :disabled to completly remove this feature
226
+ config_accessor :admin_accountability do
227
+ [:participatory_space_roles, :admin_roles]
228
+ end
229
+
230
+ # Roles for which it is necessary to show admin_accountability
231
+ config_accessor :participatory_space_roles do
232
+ [
233
+ "Decidim::AssemblyUserRole",
234
+ "Decidim::ParticipatoryProcessUserRole",
235
+ "Decidim::ConferenceUserRole"
236
+ ]
237
+ end
238
+
189
239
  #
190
240
  # HELPERS
191
241
  #
@@ -194,7 +244,7 @@ module Decidim
194
244
  def self.enabled?(config_vars)
195
245
  config_vars = [config_vars] unless config_vars.respond_to?(:detect)
196
246
 
197
- config_vars.detect do |item|
247
+ config_vars.any? do |item|
198
248
  next unless config.has_key?(item.to_sym)
199
249
 
200
250
  config.send(item) != :disabled
@@ -210,5 +260,9 @@ module Decidim
210
260
  def self.register_component(manifest, &block)
211
261
  registered_components << [manifest, block]
212
262
  end
263
+
264
+ def self.legacy_version?
265
+ Decidim.version[0..3] == "0.26"
266
+ end
213
267
  end
214
268
  end
@@ -2,29 +2,39 @@ decidim-admin:
2
2
  /app/views/layouts/decidim/admin/_header.html.erb:
3
3
  decidim-0.25: 1aff077428830b12306d6c42e6b37216
4
4
  decidim-core:
5
+ /app/validators/etiquette_validator.rb:
6
+ decidim-0.25: f7a4a652005385a994208f1ab41c4f08
7
+ decidim-0.26.4: f1f0fdf15be88f695c8359afab80f73f
5
8
  /app/views/layouts/decidim/_head.html.erb:
6
- decidim-0.25: eb490aa482477ff70f541d20cddec773
7
9
  decidim-0.26: 0927fc81123addec70853c2e7986c538
10
+ decidim-0.27: c82ac6defe55b6d4f6a54544dbf2ac58
8
11
  /app/packs/src/decidim/editor.js:
9
12
  decidim-0.25: 742698903a30034094c01aecaca6de84
10
13
  decidim-0.26: 651830d87aeeeff39316a787fc70d461
14
+ decidim-0.26.4: eac4ea47c09762aa2e56300bf7e98f31
11
15
  /app/presenters/decidim/menu_presenter.rb:
12
16
  decidim-0.25: f3b05daf279f909f8b3b628658dd5810
13
17
  /app/presenters/decidim/menu_item_presenter.rb:
14
18
  decidim-0.25: 860ffb160ec5f8552cc2855a6a47851b
19
+ decidim-0.26.4: d6d0129d81845c61884bcfd07885e911
20
+ decidim-0.27: c82bc2ea3c8f792472670d5996613ecf
15
21
  /app/helpers/decidim/amendments_helper.rb:
16
22
  decidim-0.25: 63532a04fcf07cf92b789833a9421416
17
23
  decidim-0.26: 636943ccb2e994fe0124dc87e72e49e9
18
24
  decidim-proposals:
19
25
  /app/forms/decidim/proposals/proposal_wizard_create_step_form.rb:
20
26
  decidim-0.24: db69edd0ba8ffa3965a5c44a6bfaba8d
27
+ decidim-0.27: b495d37088ecebcbe4ac9563bb3498d5
21
28
  /app/helpers/decidim/proposals/application_helper.rb:
22
- decidim-0.24: c5f99f5fa7de9a6e45776983330e9d73
23
29
  decidim-0.26: 216c974bc425393c18b01bfc4eed4f0b
30
+ decidim-0.26.4: 2e673d2aabe66a80a971d7ff80ebdbb8
31
+ decidim-0.27: c0ebeac39ebe4926bf0e5fc585a384d7
32
+ decidim-0.27.1: a4f902d1c4829a7f7f62299686f8604e
24
33
  /app/views/decidim/proposals/collaborative_drafts/show.html.erb:
25
34
  decidim-0.24: 2a7e0a4c65361f238fd1b917f39c8642
26
35
  /app/views/decidim/proposals/collaborative_drafts/_edit_form_fields.html.erb:
27
- decidim-0.24: 6f717555a20e2ab3f555003c337d3003
28
36
  decidim-0.26: 97fa28043a26fc2940d30d38d9a7369b
37
+ decidim-0.27: f356c7611279e76f16d12bb164e11e83
29
38
  /app/views/decidim/proposals/admin/proposals/_form.html.erb:
30
39
  decidim-0.25: 90a04984d4269398b7cd21aa33763a1f
40
+ decidim-0.27: f60168e432e1d419e5aec5d3d1e53f0e