decidim-core 0.14.4 → 0.15.0

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

Potentially problematic release.


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

Files changed (263) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +20 -0
  3. data/app/assets/images/decidim/cc-badge.png +0 -0
  4. data/app/assets/images/decidim/gamification/badges/continuity.svg +73 -0
  5. data/app/assets/images/decidim/gamification/badges/followers.svg +115 -0
  6. data/app/assets/images/decidim/icons.svg +1 -0
  7. data/app/assets/javascripts/decidim/vizzs/areachart.js.es6 +186 -208
  8. data/app/assets/javascripts/decidim/vizzs/linechart.js.es6 +263 -0
  9. data/app/assets/javascripts/decidim/vizzs/metrics.js.es6 +36 -26
  10. data/app/assets/javascripts/decidim/vizzs/orgchart.js.es6 +3 -2
  11. data/app/assets/javascripts/decidim/vizzs/rowchart.js.es6 +324 -0
  12. data/app/assets/stylesheets/decidim/_decidim.scss +1 -0
  13. data/app/assets/stylesheets/decidim/modules/_cards.scss +1 -0
  14. data/app/assets/stylesheets/decidim/modules/_conference-diploma.scss +75 -0
  15. data/app/assets/stylesheets/decidim/modules/_conference-media.scss +44 -0
  16. data/app/assets/stylesheets/decidim/modules/_conference-programme.scss +5 -1
  17. data/app/assets/stylesheets/decidim/modules/_conference-registration.scss +34 -0
  18. data/app/assets/stylesheets/decidim/modules/_list-request.scss +16 -0
  19. data/app/assets/stylesheets/decidim/modules/_modules.scss +4 -4
  20. data/app/assets/stylesheets/decidim/modules/_process-phase.scss +1 -0
  21. data/app/assets/stylesheets/decidim/modules/_reveal.scss +6 -1
  22. data/app/assets/stylesheets/decidim/utils/_helpers.scss +1 -1
  23. data/app/assets/stylesheets/decidim/{modules → vizzs}/_areachart.scss +8 -11
  24. data/app/assets/stylesheets/decidim/{modules → vizzs}/_chart-tooltip.scss +0 -0
  25. data/app/assets/stylesheets/decidim/vizzs/_linechart.scss +115 -0
  26. data/app/assets/stylesheets/decidim/vizzs/_rowchart.scss +77 -0
  27. data/app/cells/decidim/activities/show.erb +3 -0
  28. data/app/cells/decidim/activities_cell.rb +38 -0
  29. data/app/cells/decidim/activity/show.erb +21 -0
  30. data/app/cells/decidim/activity_cell.rb +85 -0
  31. data/app/cells/decidim/address/details.erb +7 -0
  32. data/app/cells/decidim/address/show.erb +14 -0
  33. data/app/cells/decidim/address_cell.rb +19 -0
  34. data/app/cells/decidim/author/contact.erb +1 -1
  35. data/app/cells/decidim/author_cell.rb +1 -0
  36. data/app/cells/decidim/badge/show.erb +2 -2
  37. data/app/cells/decidim/badge/small.erb +5 -0
  38. data/app/cells/decidim/badge_cell.rb +36 -14
  39. data/app/cells/decidim/badges/show.erb +6 -3
  40. data/app/cells/decidim/badges_cell.rb +4 -4
  41. data/app/cells/decidim/coauthorships_cell.rb +8 -2
  42. data/app/cells/decidim/collapsible_authors/show.erb +9 -7
  43. data/app/cells/decidim/content_blocks/html/show.erb +3 -0
  44. data/app/cells/decidim/content_blocks/html_cell.rb +11 -0
  45. data/app/cells/decidim/content_blocks/html_settings_form/show.erb +3 -0
  46. data/app/cells/decidim/content_blocks/html_settings_form_cell.rb +17 -0
  47. data/app/cells/decidim/content_blocks/last_activity/show.erb +17 -0
  48. data/app/cells/decidim/content_blocks/last_activity_cell.rb +60 -0
  49. data/app/cells/decidim/content_blocks/metrics/show.erb +13 -0
  50. data/app/cells/decidim/content_blocks/metrics_cell.rb +18 -0
  51. data/app/cells/decidim/content_blocks/stats/show.erb +2 -1
  52. data/app/cells/decidim/groups/show.erb +10 -0
  53. data/app/cells/decidim/groups_cell.rb +19 -0
  54. data/app/cells/decidim/members/show.erb +9 -0
  55. data/app/cells/decidim/members_cell.rb +32 -0
  56. data/app/cells/decidim/profile/show.erb +3 -11
  57. data/app/cells/decidim/profile/user_group_tabs.erb +5 -0
  58. data/app/cells/decidim/profile/user_tabs.erb +12 -0
  59. data/app/cells/decidim/profile_cell.rb +7 -2
  60. data/app/cells/decidim/profile_sidebar/show.erb +108 -23
  61. data/app/cells/decidim/profile_sidebar_cell.rb +36 -2
  62. data/app/cells/decidim/user_group_admin_membership_profile/footer.erb +29 -0
  63. data/app/cells/decidim/user_group_admin_membership_profile_cell.rb +14 -0
  64. data/app/cells/decidim/user_group_membership_profile/tags.erb +1 -0
  65. data/app/cells/decidim/user_group_membership_profile_cell.rb +8 -0
  66. data/app/cells/decidim/user_group_pending_invitations_list/show.erb +23 -0
  67. data/app/cells/decidim/user_group_pending_invitations_list_cell.rb +26 -0
  68. data/app/cells/decidim/user_group_pending_requests_list/show.erb +23 -0
  69. data/app/cells/decidim/user_group_pending_requests_list_cell.rb +26 -0
  70. data/app/cells/decidim/user_profile/header.erb +1 -1
  71. data/app/cells/decidim/user_profile_cell.rb +15 -9
  72. data/app/commands/decidim/accept_group_invitation.rb +43 -0
  73. data/app/commands/decidim/accept_user_group_join_request.rb +53 -0
  74. data/app/commands/decidim/create_follow.rb +6 -0
  75. data/app/commands/decidim/create_registration.rb +13 -23
  76. data/app/commands/decidim/create_user_group.rb +57 -0
  77. data/app/commands/decidim/delete_follow.rb +7 -0
  78. data/app/commands/decidim/demote_membership.rb +57 -0
  79. data/app/commands/decidim/destroy_account.rb +6 -0
  80. data/app/commands/decidim/invite_user.rb +1 -3
  81. data/app/commands/decidim/invite_user_to_group.rb +62 -0
  82. data/app/commands/decidim/join_user_group.rb +63 -0
  83. data/app/commands/decidim/leave_user_group.rb +41 -0
  84. data/app/commands/decidim/promote_membership.rb +55 -0
  85. data/app/commands/decidim/reject_group_invitation.rb +42 -0
  86. data/app/commands/decidim/reject_user_group_join_request.rb +53 -0
  87. data/app/commands/decidim/remove_user_from_group.rb +53 -0
  88. data/app/commands/decidim/update_user_group.rb +53 -0
  89. data/app/controllers/concerns/decidim/locale_switcher.rb +3 -3
  90. data/app/controllers/concerns/decidim/paginable.rb +1 -0
  91. data/app/controllers/decidim/application_controller.rb +7 -0
  92. data/app/controllers/decidim/devise/omniauth_registrations_controller.rb +1 -1
  93. data/app/controllers/decidim/devise/sessions_controller.rb +1 -1
  94. data/app/controllers/decidim/gamification/badges_controller.rb +11 -0
  95. data/app/controllers/decidim/group_admins_controller.rb +41 -0
  96. data/app/controllers/decidim/group_invites_controller.rb +74 -0
  97. data/app/controllers/decidim/group_members_controller.rb +59 -0
  98. data/app/controllers/decidim/groups_controller.rb +85 -0
  99. data/app/controllers/decidim/last_activities_controller.rb +46 -0
  100. data/app/controllers/decidim/pages_controller.rb +9 -1
  101. data/app/controllers/decidim/profiles_controller.rb +35 -5
  102. data/app/controllers/decidim/user_group_join_requests_controller.rb +69 -0
  103. data/app/events/decidim/demoted_membership_event.rb +28 -0
  104. data/app/events/decidim/invited_to_group_event.rb +33 -0
  105. data/app/events/decidim/join_request_accepted_event.rb +28 -0
  106. data/app/events/decidim/join_request_created_event.rb +28 -0
  107. data/app/events/decidim/join_request_rejected_event.rb +28 -0
  108. data/app/events/decidim/promoted_to_admin_event.rb +28 -0
  109. data/app/events/decidim/removed_from_group_event.rb +28 -0
  110. data/app/forms/decidim/account_form.rb +1 -1
  111. data/app/forms/decidim/invite_user_to_group_form.rb +29 -0
  112. data/app/forms/decidim/notifications_settings_form.rb +4 -0
  113. data/app/forms/decidim/registration_form.rb +0 -27
  114. data/app/forms/decidim/user_group_form.rb +81 -0
  115. data/app/helpers/decidim/component_path_helper.rb +10 -0
  116. data/app/helpers/decidim/filters_helper.rb +3 -2
  117. data/app/helpers/decidim/icon_helper.rb +3 -1
  118. data/app/helpers/decidim/map_helper.rb +1 -1
  119. data/app/jobs/decidim/metric_job.rb +14 -0
  120. data/app/mailers/decidim/newsletter_mailer.rb +2 -0
  121. data/app/mailers/decidim/notification_mailer.rb +1 -1
  122. data/app/models/decidim/action_log.rb +66 -0
  123. data/app/models/decidim/coauthorship.rb +9 -0
  124. data/app/models/decidim/component.rb +5 -0
  125. data/app/models/decidim/continuity_badge_status.rb +9 -0
  126. data/app/models/decidim/gamification/badge_score.rb +1 -1
  127. data/app/models/decidim/messaging/message.rb +1 -0
  128. data/app/models/decidim/metric.rb +13 -0
  129. data/app/models/decidim/participatory_space_private_user.rb +4 -0
  130. data/app/models/decidim/user.rb +14 -38
  131. data/app/models/decidim/user_base_entity.rb +52 -0
  132. data/app/models/decidim/user_group.rb +48 -9
  133. data/app/models/decidim/user_group_membership.rb +8 -0
  134. data/app/permissions/decidim/permissions.rb +21 -0
  135. data/app/presenters/decidim/admin_log/organization_presenter.rb +0 -2
  136. data/app/presenters/decidim/admin_log/participatory_space_private_user_presenter.rb +38 -0
  137. data/app/presenters/decidim/metric_charts_presenter.rb +53 -0
  138. data/app/presenters/decidim/metric_object_presenter.rb +28 -0
  139. data/app/presenters/decidim/user_group_presenter.rb +16 -8
  140. data/app/presenters/decidim/user_presenter.rb +14 -0
  141. data/app/queries/decidim/metric_manage.rb +59 -0
  142. data/app/queries/decidim/metrics/users_metric_manage.rb +26 -0
  143. data/app/queries/decidim/user_groups/accepted_memberships.rb +36 -0
  144. data/app/queries/decidim/user_groups/accepted_user_groups.rb +38 -0
  145. data/app/queries/decidim/user_groups/accepted_users.rb +36 -0
  146. data/app/queries/decidim/user_groups/admin_memberships.rb +37 -0
  147. data/app/queries/decidim/user_groups/invited_memberships.rb +36 -0
  148. data/app/queries/decidim/user_groups/manageable_user_groups.rb +39 -0
  149. data/app/queries/decidim/user_groups/member_memberships.rb +37 -0
  150. data/app/resolvers/decidim/core/metric_resolver.rb +38 -0
  151. data/app/services/decidim/action_logger.rb +4 -2
  152. data/app/services/decidim/activity_search.rb +76 -0
  153. data/app/services/decidim/continuity_badge_tracker.rb +64 -0
  154. data/app/services/decidim/resource_search.rb +0 -1
  155. data/app/types/decidim/core/metric_history_type.rb +17 -0
  156. data/app/types/decidim/core/metric_type.rb +14 -0
  157. data/app/types/decidim/core/session_type.rb +1 -1
  158. data/app/types/decidim/core/user_group_type.rb +2 -2
  159. data/app/views/decidim/authorization_modals/show.html.erb +40 -27
  160. data/app/views/decidim/devise/registrations/new.html.erb +0 -19
  161. data/app/views/decidim/gamification/badges/index.html.erb +42 -0
  162. data/app/views/decidim/group_admins/index.html.erb +18 -0
  163. data/app/views/decidim/group_invites/index.html.erb +27 -0
  164. data/app/views/decidim/group_members/index.html.erb +19 -0
  165. data/app/views/decidim/groups/_form.html.erb +23 -0
  166. data/app/views/decidim/groups/edit.html.erb +26 -0
  167. data/app/views/decidim/groups/new.html.erb +26 -0
  168. data/app/views/decidim/last_activities/_activities.html.erb +13 -0
  169. data/app/views/decidim/last_activities/index.html.erb +18 -0
  170. data/app/views/decidim/last_activities/index.js.erb +6 -0
  171. data/app/views/decidim/profiles/show.html.erb +1 -1
  172. data/app/views/layouts/decidim/_user_menu.html.erb +0 -1
  173. data/app/views/layouts/decidim/_wrapper.html.erb +1 -1
  174. data/config/initializers/devise.rb +1 -1
  175. data/config/initializers/foundation_rails_helper.rb +1 -0
  176. data/config/locales/ca.yml +325 -32
  177. data/config/locales/de.yml +325 -32
  178. data/config/locales/en.yml +325 -32
  179. data/config/locales/es-PY.yml +325 -32
  180. data/config/locales/es.yml +325 -32
  181. data/config/locales/eu.yml +325 -32
  182. data/config/locales/fi.yml +330 -37
  183. data/config/locales/fr.yml +325 -32
  184. data/config/locales/gl.yml +325 -32
  185. data/config/locales/hu.yml +327 -34
  186. data/config/locales/it.yml +325 -32
  187. data/config/locales/nl.yml +325 -32
  188. data/config/locales/pl.yml +329 -32
  189. data/config/locales/pt-BR.yml +326 -33
  190. data/config/locales/pt.yml +325 -32
  191. data/config/locales/ru.yml +4 -33
  192. data/config/locales/sv.yml +346 -53
  193. data/config/locales/uk.yml +4 -33
  194. data/config/routes.rb +27 -1
  195. data/db/migrate/20170128112958_change_user_groups_verified_to_timestamp.rb +11 -0
  196. data/db/migrate/20180705134647_create_decidim_metrics.rb +16 -0
  197. data/db/migrate/20180730071851_add_core_content_blocks.rb +3 -3
  198. data/db/migrate/20180810092428_move_organization_fields_to_hero_content_block.rb +4 -2
  199. data/db/migrate/20180918072506_add_visibility_to_action_logs.rb +8 -0
  200. data/db/migrate/20181001124950_move_users_groups_to_users_table.rb +84 -0
  201. data/db/migrate/20181008102144_add_badge_switch_to_organizations.rb +8 -0
  202. data/db/migrate/20181010044613_create_decidim_continuity_badge_statuses.rb +11 -0
  203. data/db/migrate/20181011080252_add_roles_to_memberships.rb +24 -0
  204. data/db/migrate/20181016091601_make_authors_polymorphic.rb +31 -0
  205. data/db/migrate/20181029112820_fix_user_follows.rb +18 -0
  206. data/db/migrate/20181030090144_destroy_deleted_users_follows.rb +16 -0
  207. data/db/seeds.rb +18 -4
  208. data/lib/decidim/attributes.rb +1 -0
  209. data/lib/decidim/attributes/localized_date.rb +16 -0
  210. data/lib/decidim/attributes/time_with_zone.rb +3 -1
  211. data/lib/decidim/authorable.rb +5 -4
  212. data/lib/decidim/authorization_form_builder.rb +2 -2
  213. data/lib/decidim/coauthorable.rb +68 -18
  214. data/lib/decidim/content_block_manifest.rb +7 -0
  215. data/lib/decidim/content_processor.rb +17 -7
  216. data/lib/decidim/core.rb +12 -0
  217. data/lib/decidim/core/engine.rb +54 -6
  218. data/lib/decidim/core/test/factories.rb +63 -17
  219. data/lib/decidim/core/test/shared_examples/coauthorable.rb +27 -9
  220. data/lib/decidim/core/test/shared_examples/coauthorable_interface_examples.rb +2 -2
  221. data/lib/decidim/core/version.rb +1 -1
  222. data/lib/decidim/data_portability.rb +3 -1
  223. data/lib/decidim/data_portability_file_reader.rb +1 -1
  224. data/lib/decidim/events/author_event.rb +4 -1
  225. data/lib/decidim/events/coauthor_event.rb +4 -1
  226. data/lib/decidim/faker/localized.rb +5 -4
  227. data/lib/decidim/form_builder.rb +18 -17
  228. data/lib/decidim/gamification.rb +8 -2
  229. data/lib/decidim/gamification/badge.rb +34 -0
  230. data/lib/decidim/gamification/badge_scorer.rb +29 -14
  231. data/lib/decidim/gamification/badge_status.rb +2 -0
  232. data/lib/decidim/hashtaggable.rb +1 -1
  233. data/lib/decidim/manifest_registry.rb +5 -3
  234. data/lib/decidim/metric_manifest.rb +20 -0
  235. data/lib/decidim/metric_registry.rb +71 -0
  236. data/lib/decidim/participable.rb +1 -1
  237. data/lib/decidim/participatory_space_resourceable.rb +0 -1
  238. data/lib/decidim/query_extensions.rb +19 -0
  239. data/lib/decidim/resourceable.rb +1 -0
  240. data/lib/decidim/searchable.rb +2 -1
  241. data/lib/tasks/decidim_metrics_tasks.rake +41 -0
  242. data/lib/tasks/decidim_tasks.rake +1 -0
  243. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.ca.js +1 -2
  244. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.es.js +1 -2
  245. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.fr.js +1 -2
  246. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.gl.js +1 -2
  247. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.pt.js +1 -2
  248. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.ru.js +1 -2
  249. data/vendor/assets/javascripts/datepicker-locales/foundation-datepicker.uk.js +1 -2
  250. data/vendor/assets/javascripts/form_datepicker.js.es6 +1 -11
  251. metadata +144 -23
  252. data/app/cells/decidim/invitations_toggle/content.erb +0 -1
  253. data/app/cells/decidim/invitations_toggle/label.erb +0 -1
  254. data/app/cells/decidim/invitations_toggle_cell.rb +0 -27
  255. data/app/cells/decidim/toggle/show.erb +0 -8
  256. data/app/cells/decidim/toggle_cell.rb +0 -42
  257. data/app/commands/decidim/invite_friends.rb +0 -48
  258. data/app/controllers/decidim/invitations_controller.rb +0 -32
  259. data/app/forms/decidim/invitations_form.rb +0 -37
  260. data/app/views/decidim/invitations/index.html.erb +0 -48
  261. data/app/views/devise/mailer/invite_friend.html.erb +0 -27
  262. data/app/views/devise/mailer/invite_friend.text.erb +0 -19
  263. data/lib/decidim/rectify_ext.rb +0 -32
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 764e8ad04a20136bd5cb60d469539a44a3daf525fb2f919d2238bc8c769c7207
4
- data.tar.gz: 1ec59f790b551fa23653036833a4c792e8be24ceadb116844a34a07a83e7807b
3
+ metadata.gz: fd907f208b0e6119def3e21d5aec1deae3572ba56a42a3b45eabd0388b67e023
4
+ data.tar.gz: 2dba6d175f38c3b27ae0d844f43138fd6d31e4cb7b70eb21529c0acc5e84ed21
5
5
  SHA512:
6
- metadata.gz: cce89237411e450379a09aaec484ed8280e20fc80543f9b8148cd6305d6eea590997de910ac343e16f92f9c2a7e1d3ff0ce03550024fe25d1c12052735dd887f
7
- data.tar.gz: db7fa38122774efe43266033293357f6bd3089aa8eaf97fe553168ecb6aa41611766a7516becf4411efed64427f41c29f7327293b361e4b05817826b9219ee3a
6
+ metadata.gz: cf9fa7d9de2f139b2a4dbdd88d1089dc7628210f19339424188d9c70f265a2993b883bcfa2731af706732cb04fe22c2948230d083419c23215c0bf1e40148d91
7
+ data.tar.gz: 8f9185e4d5e70e7894a7b497ab15d974fa49f88656060b2ba62d588a4e0f4ef891647a091df3e37d3df3521573fce100f8d302a4cf7cc380d0f5c73de0cbffeb
data/README.md CHANGED
@@ -20,6 +20,26 @@ And then execute:
20
20
  bundle
21
21
  ```
22
22
 
23
+ ## Global Search
24
+
25
+ Core implements a Search Engine that indexes models from all modules globally.
26
+ This feature is implemented using [PostgreSQL capability for full text search](https://www.postgresql.org/docs/current/static/textsearch.html) via [`pg_search` gem](https://github.com/Casecommons/pg_search).
27
+
28
+ This module also includes the following models to Decidim's Global Search:
29
+
30
+ - `Users`
31
+
32
+ ### Key artifacts
33
+
34
+ - `Searchable` module: A concern with the features needed when you want a model to be searchable.
35
+ - `SearchableResource` class: The ActiveRecord that finally includes PgSearch and maps the indexed documents into a model.
36
+
37
+ Models that want to be indexed must include `Searchable` and declare `Searchable.searchable_fields`.
38
+
39
+ ## Metrics docs
40
+
41
+ Core adds an implementation to show APP metrics within some pages. You can see specific documentation at [Metrics](https://github.com/decidim/decidim/tree/master/docs/advanced/metrics.md)
42
+
23
43
  ## Contributing
24
44
 
25
45
  See [Decidim](https://github.com/decidim/decidim).
Binary file
@@ -0,0 +1,73 @@
1
+ <svg version="1.1" id="continuity-svg"
2
+ xmlns="http://www.w3.org/2000/svg"
3
+ xmlns:xlink="http://www.w3.org/1999/xlink" x="0px"
4
+ y="0px" width="1080px" height="1080px" viewBox="0 0 1080 1080" enable-background="new 0 0 1080 1080" xml:space="preserve">
5
+ <g id="continuity" class="stroke-primary">
6
+ <g id="battery">
7
+ <rect x="331.5" y="244.5" fill="none" stroke="#31536E" stroke-width="16" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" width="417" height="642"/>
8
+ <polygon class="fill-primary" fill="#31536E" points="331.5,244.5 331.5,408.5 748.5,408.5 748.5,244.5 "/>
9
+ </g>
10
+ <path class="fill-primary" id="_x35_0-pct_1_" fill="#31536E" fill-opacity="0.5" stroke="#31536E" stroke-width="16" stroke-miterlimit="10" d="
11
+ M461.5,244.5v-21c0-16.016,12.984-29,29-29h98c16.017,0,29,12.984,29,29v21"/>
12
+ <g id="logo">
13
+ <circle class="fill-primary" id="_x35_0-pct_2_" fill="#31536E" fill-opacity="0.5" cx="540" cy="595.5" r="126.584"/>
14
+ <g id="disc">
15
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
16
+ M468.726,700.476c-34.152-22.929-56.629-61.906-56.629-106.135c0-57.949,38.585-106.885,91.466-122.519"/>
17
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
18
+ M661.436,555.076c3.992,12.37,6.148,25.564,6.148,39.265c0,70.551-57.192,127.743-127.744,127.743
19
+ c-8.941,0-17.67-0.919-26.095-2.668"/>
20
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
21
+ M582.435,473.871c20.134,7.118,37.948,19.14,52.013,34.63"/>
22
+ </g>
23
+ <polygon id="ray" fill="#FFFFFF" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" points="
24
+ 633.544,318.861 433.096,589.5 553.5,589.5 433.096,794.533 667.584,526.5 542.5,526.5 "/>
25
+ </g>
26
+ <rect class="fill-primary" id="_x32_5-pct" x="331.5" y="814" fill="#31536E" fill-opacity="0.25" width="417" height="72.5"/>
27
+ <g id="stars_6" class="stars">
28
+ <path fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
29
+ M429.205,157.817c0-14.688-18.667-35.355-35.355-35.355c15.355,0,35.355-20.333,35.355-35.355
30
+ c0,15.022,16.666,35.355,35.355,35.355C445.538,122.462,429.205,143.129,429.205,157.817z"/>
31
+ <g>
32
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="860.587" cy="124.874" r="13.5"/>
33
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="844.088" y1="108.138" x2="822.875" y2="86.925"/>
34
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="878.029" y1="142.08" x2="899.242" y2="163.292"/>
35
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="877.322" y1="108.845" x2="898.535" y2="87.632"/>
36
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="844.088" y1="142.08" x2="822.875" y2="163.292"/>
37
+ </g>
38
+ <g>
39
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="244.817" y1="931.557" x2="218.655" y2="957.721"/>
40
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="209.463" y1="966.912" x2="183.3" y2="993.076"/>
41
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="244.11" y1="993.076" x2="217.947" y2="966.912"/>
42
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="208.756" y1="957.721" x2="182.593" y2="931.557"/>
43
+ </g>
44
+ <path fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
45
+ M1028.797,902.071c0,0-21.566,4.035-26.516,8.983c-4.948,4.947-8.982,26.515-8.982,26.515s-4.035-21.565-8.984-26.515
46
+ c-4.947-4.948-26.514-8.983-26.514-8.983s22.077-4.546,26.514-8.983c4.438-4.438,8.984-26.515,8.984-26.515
47
+ s4.034,21.565,8.982,26.515C1007.23,898.037,1028.797,902.071,1028.797,902.071z"/>
48
+ <g>
49
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="705.706" cy="938.129" r="16.604"/>
50
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="669.805" cy="938.129" r="6.432"/>
51
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="705.706" cy="974.03" r="6.433"/>
52
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="741.607" cy="938.129" r="6.432"/>
53
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="705.706" cy="902.229" r="6.432"/>
54
+ </g>
55
+ <g>
56
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="68.951" y1="617.436" x2="123.854" y2="672.34"/>
57
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="123.854" y1="617.436" x2="68.951" y2="672.34"/>
58
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="78.205" y1="644.463" x2="51.205" y2="644.463"/>
59
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="116.205" y1="644.463" x2="143.205" y2="644.463"/>
60
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="97.205" y1="663.463" x2="97.205" y2="690.463"/>
61
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="97.205" y1="625.463" x2="97.205" y2="598.463"/>
62
+ </g>
63
+ <g>
64
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="143.205" y1="197.462" x2="143.205" y2="276.462"/>
65
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="182.205" y1="237.462" x2="103.205" y2="237.462"/>
66
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="123.205" cy="256.962" r="7.039"/>
67
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="123.205" cy="216.962" r="7.039"/>
68
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="163.205" cy="256.962" r="7.039"/>
69
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="163.205" cy="216.962" r="7.039"/>
70
+ </g>
71
+ </g>
72
+ </g>
73
+ </svg>
@@ -0,0 +1,115 @@
1
+ <svg version="1.1" id="followers-svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px"
2
+ y="0px" width="1080px" height="1080px" viewBox="0 0 1080 1080" enable-background="new 0 0 1080 1080" xml:space="preserve">
3
+ <g id="followers" class="stroke-primary">
4
+ <g id="body">
5
+ <polygon class="fill-primary" id="_x32_5-pct_18_" fill="#31536E" fill-opacity="0.25" points="466.42,706.727 492.508,651.525 586.244,651.525
6
+ 611.366,707.714 540.5,726.233 "/>
7
+ <path class="fill-primary" id="_x35_0-pct_19_" fill="#31536E" fill-opacity="0.5" d="M534.882,724.466c0,0-78.723-30.463-142.562,4.424
8
+ c-56.672,30.97-100.529,85.6-100.529,85.6s65.89,2.94,126.558-19.197C479.016,773.153,534.882,724.466,534.882,724.466z"/>
9
+ <path class="fill-primary" id="_x35_0-pct_18_" fill="#31536E" fill-opacity="0.5" d="M545.43,724.466c0,0,78.724-30.463,142.562,4.424
10
+ c56.673,30.97,100.529,85.6,100.529,85.6s-65.138,0.761-126.558-19.197C595.599,773.728,545.43,724.466,545.43,724.466z"/>
11
+ <polygon class="fill-primary" id="_x32_5-pct_17_" fill="#31536E" fill-opacity="0.25" points="540.5,825.466 577.674,900.786 660.794,912.865
12
+ 600.646,971.492 614.846,1054.277 540.5,1015.192 466.155,1054.277 480.354,971.492 420.207,912.865 503.327,900.786 "/>
13
+ <path fill="none" stroke="#31536E" stroke-width="16" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
14
+ M836,1080V953.182c0-127.941-95.656-233.538-219.353-249.177C600.003,716.924,572.112,725.4,540.5,725.4
15
+ s-59.503-8.478-76.147-21.396C340.658,719.644,245,825.24,245,953.182V1080"/>
16
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
17
+ M540.5,725.4c-62.794,48.019-107.389,75.709-256.852,93.877"/>
18
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
19
+ M538.519,725.4c62.794,48.019,107.391,75.709,256.851,93.877"/>
20
+
21
+ <line fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="343.5" y1="916.339" x2="343.5" y2="1080"/>
22
+
23
+ <line fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="737.5" y1="916.339" x2="737.5" y2="1080"/>
24
+ </g>
25
+ <g id="neck">
26
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
27
+ M464.353,704.005c18.279-32.779,14.076-26.623,28.155-59.947"/>
28
+ <path fill="none" stroke="#31536E" stroke-width="8" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
29
+ M616.647,704.005c-18.278-32.779-15.2-29.974-30.403-59.947"/>
30
+ </g>
31
+ <g id="head">
32
+ <path class="fill-primary" id="_x35_0-pct_20_" fill="#31536E" fill-opacity="0.5" stroke="#31536E" stroke-width="16" stroke-miterlimit="10" d="
33
+ M663.305,584.391c57.733-10.182,101.283-60.593,101.283-121.247V360.95c0-60.122-42.788-110.17-99.769-120.962
34
+ c-15.029-26.02-47.096-44.025-84.809-44.025H500.99c-37.84,0-70.607,18.129-85.57,44.289
35
+ c-56.298,11.331-99.007,61.061-99.007,120.698v102.194c0,59.5,42.359,109.142,98.464,120.624"/>
36
+
37
+ <path fill="#FFFFFF" stroke="#31536E" stroke-width="16" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
38
+ M686.402,346.582l-75.264,44.534l-71.254-44.534l-76.722,44.534l-69.796-44.534l-0.616-2.869v162.525
39
+ c0,80.24,65.664,145.288,145.903,145.288h2.462c80.241,0,144.673-65.048,144.673-145.288V343.713"/>
40
+ </g>
41
+ <g id="stars_10" class="stars">
42
+
43
+ <path fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
44
+ M694.889,179.355c0-14.688-18.667-35.355-35.354-35.355c15.354,0,35.354-20.333,35.354-35.355
45
+ c0,15.022,16.666,35.355,35.355,35.355C711.222,144,694.889,164.667,694.889,179.355z"/>
46
+ <g>
47
+
48
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="902.301" cy="389.356" r="13.5"/>
49
+
50
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="885.801" y1="372.621" x2="864.588" y2="351.408"/>
51
+
52
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="919.742" y1="406.562" x2="940.955" y2="427.775"/>
53
+
54
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="919.035" y1="373.328" x2="940.248" y2="352.115"/>
55
+
56
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="885.801" y1="406.562" x2="864.588" y2="427.775"/>
57
+ </g>
58
+ <g>
59
+
60
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="137.5" y1="925.094" x2="111.339" y2="951.258"/>
61
+
62
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="102.146" y1="960.449" x2="75.984" y2="986.613"/>
63
+
64
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="136.793" y1="986.613" x2="110.631" y2="960.449"/>
65
+
66
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="101.439" y1="951.258" x2="75.277" y2="925.094"/>
67
+ </g>
68
+
69
+ <path fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="
70
+ M278.612,644.347c0,0-21.565,4.034-26.517,8.981c-4.948,4.948-8.981,26.517-8.981,26.517s-4.035-21.566-8.983-26.517
71
+ c-4.948-4.947-26.515-8.981-26.515-8.981s22.076-4.547,26.515-8.983c4.438-4.438,8.983-26.515,8.983-26.515
72
+ s4.033,21.564,8.981,26.515C257.046,640.312,278.612,644.347,278.612,644.347z"/>
73
+ <g>
74
+
75
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="962.39" cy="748.667" r="16.604"/>
76
+
77
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="926.488" cy="748.667" r="6.433"/>
78
+
79
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="962.39" cy="784.568" r="6.432"/>
80
+
81
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="998.291" cy="748.667" r="6.433"/>
82
+
83
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="962.39" cy="712.766" r="6.432"/>
84
+ </g>
85
+ <g>
86
+
87
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="346.635" y1="97.973" x2="401.538" y2="152.878"/>
88
+
89
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="401.538" y1="97.973" x2="346.635" y2="152.878"/>
90
+
91
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="355.889" y1="125" x2="328.889" y2="125"/>
92
+
93
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="393.889" y1="125" x2="420.889" y2="125"/>
94
+
95
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="374.889" y1="144" x2="374.889" y2="171"/>
96
+
97
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="374.889" y1="106" x2="374.889" y2="79"/>
98
+ </g>
99
+ <g>
100
+
101
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="117.889" y1="238" x2="117.889" y2="317"/>
102
+
103
+ <line fill="none" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" x1="156.889" y1="278" x2="77.889" y2="278"/>
104
+
105
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="97.889" cy="297.5" r="7.039"/>
106
+
107
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="97.889" cy="257.5" r="7.039"/>
108
+
109
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="137.889" cy="297.5" r="7.039"/>
110
+
111
+ <circle fill="#FFD92B" stroke="#31536E" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" cx="137.889" cy="257.5" r="7.039"/>
112
+ </g>
113
+ </g>
114
+ </g>
115
+ </svg>
@@ -242,6 +242,7 @@
242
242
  <symbol viewBox="0 0 34 34" id="icon-euro-outline"> <title>euro-outline</title> <path d="M10.57 15.302a8.323 8.323 0 0 1 8.17-6.738.9.9 0 1 1 0 1.8 6.523 6.523 0 0 0-6.328 4.938h5.503c.234 0 .424.403.424.9s-.19.9-.424.9h-5.693c.015.437.072.862.168 1.273h4.649a.9.9 0 1 1 0 1.8h-3.93a6.517 6.517 0 0 0 5.63 3.23.9.9 0 0 1 0 1.8 8.322 8.322 0 0 1-7.644-5.03H9.618a.9.9 0 1 1 0-1.8h.934a8.353 8.353 0 0 1-.13-1.273h-.88c-.234 0-.424-.403-.424-.9s.19-.9.424-.9h1.027zM17 34C7.611 34 0 26.389 0 17S7.611 0 17 0s17 7.611 17 17-7.611 17-17 17zm0-2c8.284 0 15-6.716 15-15 0-8.284-6.716-15-15-15C8.716 2 2 8.716 2 17c0 8.284 6.716 15 15 15z"/> </symbol>
243
243
  <symbol viewBox="0 0 36 36" id="icon-datetime"> <title>datetime</title> <path d="M18 0c9.941 0 18 8.059 18 18s-8.059 18-18 18S0 27.941 0 18 8.059 0 18 0zm0 2C9.163 2 2 9.163 2 18s7.163 16 16 16 16-7.163 16-16S26.837 2 18 2zm0 17.193l6.66 5.856a1 1 0 1 1-1.32 1.502l-7-6.155a1 1 0 0 1-.34-.751V9a1 1 0 0 1 2 0v10.193z"/> </symbol>
244
244
  <symbol viewBox="0 0 34 34" id="icon-members"> <title>members</title> <path d="M17 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111c8.347 0 15.111-6.764 15.111-15.111 0-8.346-6.765-15.111-15.111-15.111zM17 0c9.39 0 17 7.61 17 17s-7.61 17-17 17S0 26.39 0 17C0 7.611 7.611 0 17 0zm8.162 12.43a3.561 3.561 0 1 0-7.123 0 3.561 3.561 0 0 0 7.123 0zm-1.89 0a1.672 1.672 0 1 1-3.344 0 1.672 1.672 0 0 1 3.345 0zm4.993 9.771a6.77 6.77 0 0 0-10.298-4.518.944.944 0 0 0 1.016 1.593 4.882 4.882 0 0 1 7.423 3.257.944.944 0 0 0 1.86-.332zM16.14 14.043a3.561 3.561 0 1 0-7.122 0 3.561 3.561 0 0 0 7.122 0zm-1.89 0a1.672 1.672 0 1 1-3.344 0 1.672 1.672 0 0 1 3.345 0zm4.994 9.771a6.772 6.772 0 0 0-13.297-.167.944.944 0 1 0 1.85.377 4.882 4.882 0 0 1 9.588.122.944.944 0 1 0 1.86-.332z"/> </symbol>
245
+ <symbol viewBox="0 0 34 34" id="icon-speakers"> <title>speakers</title> <path d="M17 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111c8.347 0 15.111-6.764 15.111-15.111 0-8.346-6.765-15.111-15.111-15.111zM17 0c9.39 0 17 7.61 17 17s-7.61 17-17 17S0 26.39 0 17C0 7.611 7.611 0 17 0zm8.162 12.43a3.561 3.561 0 1 0-7.123 0 3.561 3.561 0 0 0 7.123 0zm-1.89 0a1.672 1.672 0 1 1-3.344 0 1.672 1.672 0 0 1 3.345 0zm4.993 9.771a6.77 6.77 0 0 0-10.298-4.518.944.944 0 0 0 1.016 1.593 4.882 4.882 0 0 1 7.423 3.257.944.944 0 0 0 1.86-.332zM16.14 14.043a3.561 3.561 0 1 0-7.122 0 3.561 3.561 0 0 0 7.122 0zm-1.89 0a1.672 1.672 0 1 1-3.344 0 1.672 1.672 0 0 1 3.345 0zm4.994 9.771a6.772 6.772 0 0 0-13.297-.167.944.944 0 1 0 1.85.377 4.882 4.882 0 0 1 9.588.122.944.944 0 1 0 1.86-.332z"/> </symbol>
245
246
  <symbol viewBox="0 0 34 34" id="icon-profile"><title>profile</title> <path d="M17 0c9.389 0 17 7.611 17 17 0 9.39-7.61 17-17 17S0 26.39 0 17C0 7.611 7.611 0 17 0zm0 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111 32.111 25.346 32.111 17 25.346 1.889 17 1.889zm3.99 10.854a4.006 4.006 0 1 1-8.012 0 4.006 4.006 0 0 1 8.012 0zm-1.889 0a2.118 2.118 0 1 0-4.236 0 2.118 2.118 0 0 0 4.236 0zm5.526 11.467a.944.944 0 1 1-1.86.331 5.876 5.876 0 0 0-11.539-.146.944.944 0 0 1-1.85-.379 7.766 7.766 0 0 1 15.249.194z"/> </symbol>
246
247
  <symbol viewBox="0 0 34 34" id="icon-videos"> <title>videos</title> <path d="M17 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111 32.111 25.346 32.111 17 25.346 1.889 17 1.889zM17 0c9.389 0 17 7.611 17 17s-7.611 17-17 17S0 26.389 0 17 7.611 0 17 0zm-5.667 13.757l6.848 3.583-6.848 3.565v-7.148zm-1.18 7.763l.076-.04a.704.704 0 0 0-.076.04zm9.517-3.407l-.08-.036a.803.803 0 0 0 .08.036zm.844.14c.75-.447.716-1.504-.092-1.872l-9.395-4.915c-.721-.432-1.583.135-1.583.965v9.798c0 .83.862 1.397 1.629.94l9.393-4.889.048-.026zm2.153-6.92v10.41a.944.944 0 1 0 1.889 0v-10.41a.944.944 0 0 0-1.89 0z"/> </symbol>
247
248
  <symbol viewBox="0 0 34 34" id="icon-consultation"><title>consultation</title> <path d="M17 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111 32.111 25.346 32.111 17 25.346 1.889 17 1.889zM17 0c9.389 0 17 7.611 17 17s-7.611 17-17 17S0 26.389 0 17 7.611 0 17 0zm-2.327 14.005c.026-1.153.867-2.08 2.024-2.099h.137c1.901.032 2.584 2.347 1.065 3.915-.12.123-.951.935-1.16 1.17-.688.776-.982 1.563-.982 2.793a.944.944 0 1 0 1.89 0c0-.772.126-1.113.505-1.54.155-.174.942-.942 1.104-1.11 2.59-2.672 1.298-7.055-2.406-7.116h-.168c-2.232.036-3.85 1.817-3.898 3.945a.944.944 0 1 0 1.889.042zm2.029 10.327a1.168 1.168 0 1 0 0-2.336 1.168 1.168 0 0 0 0 2.336zm0-.945a.224.224 0 1 1 0-.447.224.224 0 0 1 0 .447z"/> </symbol>
@@ -1,226 +1,204 @@
1
- /* global d3, DATACHARTS, fetchDatacharts */
1
+ /* global d3 */
2
2
  /* eslint-disable id-length, no-unused-vars, multiline-ternary, no-ternary, no-nested-ternary, no-invalid-this */
3
3
  /* eslint prefer-reflect: ["error", { "exceptions": ["call"] }] */
4
4
  /* eslint dot-location: ["error", "property"] */
5
5
 
6
6
  // = require d3
7
7
 
8
- const renderAreaCharts = () => {
9
- // lib
10
- const areachart = (opts = {}) => {
11
- // parse opts
12
- let data = opts.data
13
- let title = opts.title
14
- let container = d3.select(opts.container)
15
- let showAxis = opts.axis
16
- let ratio = opts.ratio
17
- let showTooltip = opts.tip !== "false"
18
-
19
- // set the dimensions and margins of the graph
20
- let margin = {
21
- top: 0,
22
- right: 0,
23
- bottom: 0,
24
- left: 0
25
- }
8
+ // lib
9
+ const areachart = (opts = {}) => {
26
10
 
27
- let width = Number(container.node().getBoundingClientRect().width) - margin.left - margin.right
28
- let height = (width / ratio) - margin.top - margin.bottom
29
- let titlePadding = d3.min([width / 10, 32])
30
-
31
- // set the ranges
32
- let x = d3.scaleTime().range([0, width]);
33
- let y = d3.scaleLinear().range([height, 0]);
34
-
35
- // define the area
36
- let area = d3.area()
37
- .x((d) => x(d.key))
38
- .y0(height)
39
- .y1((d) => y(d.value));
40
-
41
- // define the line
42
- let valueline = d3.line()
43
- .x((d) => x(d.key))
44
- .y((d) => y(d.value));
45
-
46
- let svg = container.append("svg")
47
- .attr("width", width + margin.left + margin.right)
48
- .attr("height", height + margin.top + margin.bottom)
49
- .append("g")
50
- .attr("transform", `translate(${margin.left},${margin.top})`);
51
-
52
- // scale the range of the data
53
- x.domain(d3.extent(data, (d) => d.key));
54
- y.domain([0, d3.max(data, (d) => d.value)]).nice();
55
-
56
- // add the valueline path.
57
- let topLine = svg.append("path")
58
- .data([data])
59
- .attr("class", "line")
60
- .attr("d", valueline)
11
+ const parseData = (data) => {
12
+ // format the data
13
+ data.forEach((d) => {
14
+ d.key = d3.isoParse(d.key)
15
+ d.value = Number(d.value)
16
+ });
61
17
 
62
- // add the area
63
- svg.append("path")
64
- .data([data])
65
- .attr("class", "area")
66
- .attr("d", area)
67
-
68
- if (showTooltip) {
69
- // tooltip
70
- let circle = svg.append("circle")
71
- .attr("class", "circle")
72
- .attr("r", 6)
73
- .style("display", "none")
74
-
75
- let tooltip = d3.select("body").append("div")
76
- .attr("id", `${container.node().id}-tooltip`)
77
- .attr("class", "chart-tooltip")
78
- .style("opacity", 0)
79
-
80
- svg
81
- .on("mouseover", () => {
82
- circle.style("display", null)
83
- tooltip.style("opacity", 1)
84
- })
85
- .on("mouseout", () => {
86
- circle.style("display", "none")
87
- tooltip.style("opacity", 0)
88
- })
89
- .on("mousemove", function() {
90
- let x0 = x.invert(d3.mouse(this)[0])
91
- let i = d3.bisector((d) => d.key).left(data, x0, 1)
92
- let d0 = data[i - 1]
93
- let d1 = data[i]
94
- let d = (x0 - d0.key > d1.key - x0) ? d1 : d0
95
-
96
- // svg position relative to document
97
- let coords = {
98
- x: window.pageXOffset + container.node().getBoundingClientRect().left,
99
- y: window.pageYOffset + container.node().getBoundingClientRect().top
100
- }
101
-
102
- let tooltipContent = `
103
- <div class="tooltip-content">
104
- ${d3.timeFormat("%e %B %Y")(d.key)}<br />
105
- ${d.value.toLocaleString()} propuestas
106
- </div>`
107
-
108
- circle.attr("transform", `translate(${x(d.key)},${y(d.value)})`)
109
- tooltip.html(tooltipContent)
110
- .style("left", `${coords.x + x(d.key)}px`)
111
- .style("top", `${coords.y + y(d.value)}px`)
112
- })
113
- }
18
+ // order by date
19
+ return data.sort((x, y) => d3.ascending(x.key, y.key))
20
+ }
114
21
 
115
- if (showAxis) {
116
- let xAxis = d3.axisBottom(x)
117
- .ticks(d3.timeMonth)
118
- .tickFormat(d3.timeFormat("%b %y"))
119
- .tickSize(-height)
120
- let yAxis = d3.axisLeft(y)
121
- .ticks(5)
122
- .tickSize(8)
123
-
124
- let _xAxis = (g) => {
125
- g.call(xAxis)
126
- g.select(".domain").remove()
127
- g.selectAll(".tick line").attr("class", "dashed")
128
- g.selectAll(".tick text").attr("y", 6)
129
- }
130
- let _yAxis = (g) => {
131
- g.call(yAxis)
132
- g.select(".domain").remove()
133
- g.select(".tick:first-of-type").remove()
134
- g.selectAll(".tick text").attr("text-anchor", "start").attr("x", 6)
135
- }
136
-
137
- // custom X-Axis
138
- svg.append("g")
139
- .attr("transform", `translate(0,${height})`)
140
- .call(_xAxis);
141
-
142
- // custom Y-Axis
143
- svg.append("g")
144
- .call(_yAxis)
145
-
146
- // last circle (current value)
147
- let g = svg.append("g")
148
- .data([data])
149
- .attr("transform", (d) => `translate(${x(d[d.length - 1].key)},${y(d[d.length - 1].value)})`)
150
-
151
- g.append("circle")
152
- .attr("class", "circle")
153
- .attr("r", 8)
154
-
155
- g.append("text")
156
- .attr("class", "sum")
157
- .attr("text-anchor", "end")
158
- .attr("dx", -8 * 2)
159
- .text((d) => d[d.length - 1].value.toLocaleString())
160
-
161
- } else {
162
- // add the title group
163
- let g = svg.append("g")
164
- .attr("text-anchor", "start")
165
- .attr("transform", `translate(${titlePadding},${titlePadding})`)
166
-
167
- g.append("text")
168
- .attr("x", 0)
169
- .attr("y", 0)
170
- .attr("class", "title")
171
- .text(title)
172
-
173
- g.append("text")
174
- .attr("x", 0)
175
- .attr("dy", titlePadding * 2)
176
- .attr("class", "sum")
177
- .text(Number(data.map((r) => r.value).reduce((a, b) => a + b, 0)).toLocaleString())
22
+ // OPTIONAL: Helper function to accumulates all data values
23
+ const aggregate = (agg) => agg.map((item, index, array) => {
24
+ if (index > 0) {
25
+ item.value += array[index - 1].value
178
26
  }
27
+ return item
28
+ })
29
+
30
+ // parse opts
31
+ let data = parseData(opts.data)
32
+ let title = opts.title
33
+ let objectName = opts.objectName || ""
34
+ let container = d3.select(opts.container)
35
+ let showAxis = opts.axis || false
36
+ let ratio = opts.ratio || (4 / 3)
37
+ let showTooltip = opts.tip !== "false"
38
+ let cumulative = opts.cumulative || false
39
+
40
+ if (cumulative) {
41
+ data = aggregate(data)
179
42
  }
180
43
 
181
- return $(".areachart:visible").each((i, container) => {
44
+ // set the dimensions and margins of the graph
45
+ let margin = {
46
+ top: 0,
47
+ right: 0,
48
+ bottom: 0,
49
+ left: 0
50
+ }
182
51
 
183
- // OPTIONAL: Helper function to preprocess the data
184
- const parseData = (data) => {
185
- // format the data
186
- data.forEach((d) => {
187
- d.key = d3.isoParse(d.key)
188
- d.value = Number(d.value)
189
- });
52
+ let width = Number(container.node().getBoundingClientRect().width) - margin.left - margin.right
53
+ let height = (width / ratio) - margin.top - margin.bottom
54
+ let titlePadding = d3.min([width / 10, 32])
55
+
56
+ // set the ranges
57
+ let x = d3.scaleTime().range([0, width]);
58
+ let y = d3.scaleLinear().range([height, 0]);
59
+
60
+ // define the area
61
+ let area = d3.area()
62
+ .x((d) => x(d.key))
63
+ .y0(height)
64
+ .y1((d) => y(d.value));
65
+
66
+ // define the line
67
+ let valueline = d3.line()
68
+ .x((d) => x(d.key))
69
+ .y((d) => y(d.value));
70
+
71
+ let svg = container.append("svg")
72
+ .attr("width", width + margin.left + margin.right)
73
+ .attr("height", height + margin.top + margin.bottom)
74
+ .append("g")
75
+ .attr("transform", `translate(${margin.left},${margin.top})`);
76
+
77
+ // scale the range of the data
78
+ x.domain(d3.extent(data, (d) => d.key));
79
+ y.domain([0, d3.max(data, (d) => d.value)]).nice();
80
+
81
+ // add the valueline path.
82
+ let topLine = svg.append("path")
83
+ .data([data])
84
+ .attr("class", "line")
85
+ .attr("d", valueline)
86
+
87
+ // add the area
88
+ svg.append("path")
89
+ .data([data])
90
+ .attr("class", "area")
91
+ .attr("d", area)
92
+
93
+ if (showTooltip) {
94
+ // tooltip
95
+ let circle = svg.append("circle")
96
+ .attr("class", "circle")
97
+ .attr("r", 6)
98
+ .style("display", "none")
99
+
100
+ let tooltip = d3.select("body").append("div")
101
+ .attr("id", `${container.node().id}-tooltip`)
102
+ .attr("class", "chart-tooltip")
103
+ .style("opacity", 0)
104
+
105
+ svg
106
+ .on("mouseover", () => {
107
+ circle.style("display", null)
108
+ tooltip.style("opacity", 1)
109
+ })
110
+ .on("mouseout", () => {
111
+ circle.style("display", "none")
112
+ tooltip.style("opacity", 0)
113
+ })
114
+ .on("mousemove", function() {
115
+ let x0 = x.invert(d3.mouse(this)[0])
116
+ let i = d3.bisector((d) => d.key).left(data, x0, 1)
117
+ let d0 = data[i - 1]
118
+ let d1 = data[i]
119
+ let d = (x0 - d0.key > d1.key - x0) ? d1 : d0
120
+
121
+ // svg position relative to document
122
+ let coords = {
123
+ x: window.pageXOffset + container.node().getBoundingClientRect().left,
124
+ y: window.pageYOffset + container.node().getBoundingClientRect().top
125
+ }
126
+
127
+ let tooltipContent = `
128
+ <div class="tooltip-content">
129
+ ${d3.timeFormat("%e %B %Y")(d.key)}<br />
130
+ ${d.value.toLocaleString()} ${objectName}
131
+ </div>`
132
+
133
+ circle.attr("transform", `translate(${x(d.key)},${y(d.value)})`)
134
+ tooltip.html(tooltipContent)
135
+ .style("left", `${coords.x + x(d.key)}px`)
136
+ .style("top", `${coords.y + y(d.value)}px`)
137
+ })
138
+ }
190
139
 
191
- // order by date
192
- return data.sort((x, y) => d3.ascending(x.key, y.key))
140
+ if (showAxis) {
141
+ let xAxis = d3.axisBottom(x)
142
+ .ticks(d3.timeMonth)
143
+ .tickFormat(d3.timeFormat("%b %y"))
144
+ .tickSize(-height)
145
+ let yAxis = d3.axisLeft(y)
146
+ .ticks(5)
147
+ .tickSize(8)
148
+
149
+ let _xAxis = (g) => {
150
+ g.call(xAxis)
151
+ g.select(".domain").remove()
152
+ g.selectAll(".tick line").attr("class", "dashed")
153
+ g.selectAll(".tick text").attr("y", 6)
193
154
  }
194
-
195
- // OPTIONAL: Helper function to accumulates all data values
196
- const aggregate = (agg) => agg.map((item, index, array) => {
197
- if (index > 0) {
198
- item.value += array[index - 1].value
199
- }
200
- return item
201
- })
202
-
203
- // If there's no data, fetch it
204
- if (!DATACHARTS || !DATACHARTS[container.dataset.metric]) {
205
- fetchDatacharts()
155
+ let _yAxis = (g) => {
156
+ g.call(yAxis)
157
+ g.select(".domain").remove()
158
+ g.select(".tick:first-of-type").remove()
159
+ g.selectAll(".tick text").attr("text-anchor", "start").attr("x", 6)
206
160
  }
207
161
 
208
- // MANDATORY: HTML must contain which metric should it display
209
- let data = DATACHARTS[container.dataset.metric].map((d) => {
210
- return { ...d }
211
- })
212
-
213
- if (data) {
214
- let dataModified = aggregate(parseData(data))
215
-
216
- areachart({
217
- container: `#${container.id}`,
218
- title: container.dataset.title,
219
- data: dataModified,
220
- axis: (container.dataset.axis === "true") || false,
221
- ratio: container.dataset.ratio.split(":").reduce((a, b) => a / b) || (4 / 3),
222
- tip: container.dataset.tip
223
- })
224
- }
225
- })
162
+ // custom X-Axis
163
+ svg.append("g")
164
+ .attr("transform", `translate(0,${height})`)
165
+ .call(_xAxis);
166
+
167
+ // custom Y-Axis
168
+ svg.append("g")
169
+ .call(_yAxis)
170
+
171
+ // last circle (current value)
172
+ let g = svg.append("g")
173
+ .data([data])
174
+ .attr("transform", (d) => `translate(${x(d[d.length - 1].key)},${y(d[d.length - 1].value)})`)
175
+
176
+ g.append("circle")
177
+ .attr("class", "circle")
178
+ .attr("r", 8)
179
+
180
+ g.append("text")
181
+ .attr("class", "sum")
182
+ .attr("text-anchor", "end")
183
+ .attr("dx", -8 * 2)
184
+ .text((d) => d[d.length - 1].value.toLocaleString())
185
+
186
+ } else {
187
+ // add the title group
188
+ let g = svg.append("g")
189
+ .attr("text-anchor", "start")
190
+ .attr("transform", `translate(${titlePadding},${titlePadding})`)
191
+
192
+ g.append("text")
193
+ .attr("x", 0)
194
+ .attr("y", 0)
195
+ .attr("class", "title")
196
+ .text(title)
197
+
198
+ g.append("text")
199
+ .attr("x", 0)
200
+ .attr("dy", titlePadding * 2)
201
+ .attr("class", "sum")
202
+ .text(data[data.length - 1].value.toLocaleString())
203
+ }
226
204
  }