decidim-design 0.28.0.rc4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (80) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +29 -0
  3. data/Rakefile +3 -0
  4. data/app/controllers/concerns/decidim/design/has_templates.rb +20 -0
  5. data/app/controllers/decidim/design/application_controller.rb +28 -0
  6. data/app/controllers/decidim/design/components_controller.rb +21 -0
  7. data/app/controllers/decidim/design/foundations_controller.rb +14 -0
  8. data/app/controllers/decidim/design/home_controller.rb +11 -0
  9. data/app/helpers/decidim/design/activities_helper.rb +65 -0
  10. data/app/helpers/decidim/design/address_helper.rb +59 -0
  11. data/app/helpers/decidim/design/announcement_helper.rb +73 -0
  12. data/app/helpers/decidim/design/application_helper.rb +100 -0
  13. data/app/helpers/decidim/design/author_helper.rb +91 -0
  14. data/app/helpers/decidim/design/buttons_helper.rb +148 -0
  15. data/app/helpers/decidim/design/cards_helper.rb +195 -0
  16. data/app/helpers/decidim/design/colors_helper.rb +96 -0
  17. data/app/helpers/decidim/design/follow_helper.rb +42 -0
  18. data/app/helpers/decidim/design/iconography_helper.rb +72 -0
  19. data/app/helpers/decidim/design/report_helper.rb +38 -0
  20. data/app/helpers/decidim/design/share_helper.rb +38 -0
  21. data/app/helpers/decidim/design/tab_panels_helper.rb +103 -0
  22. data/app/helpers/decidim/design/typography_helper.rb +112 -0
  23. data/app/packs/entrypoints/decidim_design.js +2 -0
  24. data/app/packs/stylesheets/design.scss +121 -0
  25. data/app/views/decidim/design/components/accordions.html.erb +66 -0
  26. data/app/views/decidim/design/components/activities/_static-activities.html.erb +79 -0
  27. data/app/views/decidim/design/components/activities/_static-activity.html.erb +56 -0
  28. data/app/views/decidim/design/components/activities.html.erb +11 -0
  29. data/app/views/decidim/design/components/address/_static-address-online.html.erb +9 -0
  30. data/app/views/decidim/design/components/address/_static-address-person.html.erb +8 -0
  31. data/app/views/decidim/design/components/address.html.erb +11 -0
  32. data/app/views/decidim/design/components/announcement.html.erb +11 -0
  33. data/app/views/decidim/design/components/author/_static-avatar.html.erb +38 -0
  34. data/app/views/decidim/design/components/author/_static-compact.html.erb +46 -0
  35. data/app/views/decidim/design/components/author/_static-default.html.erb +35 -0
  36. data/app/views/decidim/design/components/author.html.erb +11 -0
  37. data/app/views/decidim/design/components/buttons.html.erb +15 -0
  38. data/app/views/decidim/design/components/cards/_static-card-g-highlight.html.erb +18 -0
  39. data/app/views/decidim/design/components/cards/_static-card-g-metadata-2.html.erb +17 -0
  40. data/app/views/decidim/design/components/cards/_static-card-g-metadata.html.erb +14 -0
  41. data/app/views/decidim/design/components/cards/_static-card-g.html.erb +17 -0
  42. data/app/views/decidim/design/components/cards/_static-card-l-description.html.erb +28 -0
  43. data/app/views/decidim/design/components/cards/_static-card-l-extra-data-2.html.erb +31 -0
  44. data/app/views/decidim/design/components/cards/_static-card-l-extra-data.html.erb +16 -0
  45. data/app/views/decidim/design/components/cards/_static-card-l-image.html.erb +66 -0
  46. data/app/views/decidim/design/components/cards/_static-card-l-meetings.html.erb +30 -0
  47. data/app/views/decidim/design/components/cards/_static-card-l.html.erb +60 -0
  48. data/app/views/decidim/design/components/cards/_static-card-s.html.erb +15 -0
  49. data/app/views/decidim/design/components/cards.html.erb +11 -0
  50. data/app/views/decidim/design/components/dialogs.html.erb +89 -0
  51. data/app/views/decidim/design/components/dropdowns.html.erb +64 -0
  52. data/app/views/decidim/design/components/follow/_static-follow-default.html.erb +4 -0
  53. data/app/views/decidim/design/components/follow/_static-follow-unfollow.html.erb +4 -0
  54. data/app/views/decidim/design/components/follow.html.erb +11 -0
  55. data/app/views/decidim/design/components/forms.html.erb +235 -0
  56. data/app/views/decidim/design/components/report/_static-report.html.erb +34 -0
  57. data/app/views/decidim/design/components/report.html.erb +11 -0
  58. data/app/views/decidim/design/components/share.html.erb +11 -0
  59. data/app/views/decidim/design/components/tab_panels.html.erb +11 -0
  60. data/app/views/decidim/design/foundations/accessibility.html.erb +99 -0
  61. data/app/views/decidim/design/foundations/color/_table.html.erb +26 -0
  62. data/app/views/decidim/design/foundations/color.html.erb +16 -0
  63. data/app/views/decidim/design/foundations/iconography/_icons.html.erb +8 -0
  64. data/app/views/decidim/design/foundations/iconography.html.erb +16 -0
  65. data/app/views/decidim/design/foundations/layout.html.erb +128 -0
  66. data/app/views/decidim/design/foundations/typography.html.erb +15 -0
  67. data/app/views/decidim/design/home/index.html.erb +17 -0
  68. data/app/views/decidim/design/shared/_card_grid.html.erb +3 -0
  69. data/app/views/decidim/design/shared/_cell_snippet.html.erb +6 -0
  70. data/app/views/decidim/design/shared/_sections.html.erb +9 -0
  71. data/app/views/decidim/design/shared/_table.html.erb +12 -0
  72. data/app/views/layouts/decidim/design/_head.html.erb +5 -0
  73. data/app/views/layouts/decidim/design/_layout.html.erb +86 -0
  74. data/app/views/layouts/decidim/design/application.html.erb +15 -0
  75. data/config/assets.rb +8 -0
  76. data/config/routes.rb +10 -0
  77. data/lib/decidim/design/engine.rb +35 -0
  78. data/lib/decidim/design/version.rb +9 -0
  79. data/lib/decidim/design.rb +10 -0
  80. metadata +154 -0
@@ -0,0 +1,15 @@
1
+ <% content_for :heading do %>
2
+ Buttons
3
+ <% end %>
4
+
5
+ <% content_for :description do %>
6
+ Buttons are built using different combinations of CSS classes: the <code>button</code> class, a size and a color.
7
+ <% end %>
8
+
9
+ <% content_for :toc do %>
10
+ <% buttons_sections.each do |section| %>
11
+ <%= link_to(section_text(section), "##{section[:id]}") %>
12
+ <% end %>
13
+ <% end %>
14
+
15
+ <%= render partial: "decidim/design/shared/sections", locals: { sections: buttons_sections } %>
@@ -0,0 +1,18 @@
1
+ <a class="card__highlight" id="participatory_process_highlight_1" href="#">
2
+ <div class="card__highlight-img">
3
+ <img alt="Imagen para los medios: Sequi impedit dolores sunt ad." src="/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBDZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--27708e9cb6acd3d8911e959ba1338519589fcb30/hero_image.jpeg">
4
+ </div>
5
+ <div class="card__highlight-text">
6
+ <h3 class="h3 text-secondary">Sequi impedit dolores sunt ad.</h3>
7
+ Minima aut incidunt.
8
+ <div class="card__highlight-metadata">
9
+ <span>
10
+ <span class="card__grid-loader" style="--value:0.7542662116040956;"></span>queda aproximadamente 2 meses
11
+ </span>
12
+ <span>
13
+ <%= icon("direction-line") %>
14
+ Expedita vel.
15
+ </span>
16
+ </div>
17
+ </div>
18
+ </a>
@@ -0,0 +1,17 @@
1
+ <a class="card__grid" id="participatory_process_2" href="#">
2
+ <div class="card__grid-img">
3
+ <img alt="Media picture: Ut vel architecto hic tempore." src="/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBQdz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--051324c06b42809063d50b326d116e0339d96aab/hero_image.jpeg">
4
+ </div>
5
+ <div class="card__grid-text">
6
+ <h3 class="h4 text-secondary">Ut vel architecto hic tempore.</h3>
7
+ <div class="card__grid-metadata">
8
+ <span>
9
+ <span class="card__grid-loader" style="--value:0.7706484641638225;"></span>about 2 months remaining
10
+ </span>
11
+ <span>
12
+ <%= icon("direction-line") %>
13
+ Sit.
14
+ </span>
15
+ </div>
16
+ </div>
17
+ </a>
@@ -0,0 +1,14 @@
1
+ <a class="card__grid" id="conference_2" href="#">
2
+ <div class="card__grid-img">
3
+ <img alt="Media picture: Enim earum quos rerum et." src="/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBc0lCIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--f9dcdd2b5fa8a4c7c371725abbec4b531a241788/hero_image.jpeg">
4
+ </div>
5
+ <div class="card__grid-text">
6
+ <h3 class="h4 text-secondary">Enim earum quos rerum et.</h3>
7
+ <div class="card__grid-metadata">
8
+ <span>
9
+ <%= icon("calendar-line") %>
10
+ 05 Oct → 05 Dec
11
+ </span>
12
+ </div>
13
+ </div>
14
+ </a>
@@ -0,0 +1,17 @@
1
+ <a class="card__grid" id="participatory_process_1" href="#">
2
+ <div class="card__grid-img">
3
+ <img alt="Media picture: Sequi impedit dolores sunt ad." src="/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBDZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--27708e9cb6acd3d8911e959ba1338519589fcb30/hero_image.jpeg">
4
+ </div>
5
+ <div class="card__grid-text">
6
+ <h3 class="h4 text-secondary">Sequi impedit dolores sunt ad.</h3>
7
+ <div class="card__grid-metadata">
8
+ <span>
9
+ <span class="card__grid-loader" style="--value:0.7706484641638225;"></span>about 2 months remaining
10
+ </span>
11
+ <span>
12
+ <%= icon("direction-line") %>
13
+ Expedita vel.
14
+ </span>
15
+ </div>
16
+ </div>
17
+ </a>
@@ -0,0 +1,28 @@
1
+ <a class="card__list" id="debates__debate_18" href="#">
2
+ <div class="card__list-content">
3
+ <div class="h4 card__list-title">
4
+ Magni cupiditate.
5
+ </div>
6
+ <div class="card__list-text">
7
+ <p>Et eum doloribus. Iste est ipsa. Est alias ea.</p>
8
+ </div>
9
+ <div class="card__list-metadata">
10
+ <span>
11
+ <%= icon("time-line") %>
12
+ Open debate
13
+ </span>
14
+ <span data-comments-count="">
15
+ <%= icon("wechat-line") %>
16
+ 0
17
+ </span>
18
+ <span data-endorsements-count="">
19
+ <%= icon("like") %>
20
+ 0
21
+ </span>
22
+ <span>
23
+ <%= icon("price-tag-3-line") %>
24
+ Quaerat perspiciatis sequi deleniti consectetur.
25
+ </span>
26
+ </div>
27
+ </div>
28
+ </a>
@@ -0,0 +1,31 @@
1
+ <%= append_stylesheet_pack_tag "decidim_budgets" %>
2
+
3
+ <div class="budget-list">
4
+ <div class="project-item" id="project-1-item">
5
+ <div class="card__list">
6
+ <a class="card__list-content" href="#">
7
+ <div class="h4 card__list-title">
8
+ Sed harum.
9
+ </div>
10
+ <div class="card__list-metadata">
11
+ <span>
12
+ <%= icon("price-tag-3-line") %>
13
+ Occaecati veritatis nesciunt fugiat aut.
14
+ </span>
15
+ </div>
16
+ </a>
17
+ </div>
18
+ <div class="budget__card__list-project">
19
+ <span class="budget__card__list-project__amount">
20
+ €15,233,687
21
+ </span>
22
+ <form class="button_to" method="post" action="/processes/corpse-curriculum/f/4/budgets/1/order/line_item?project_id=1&amp;show_only_added=false" data-remote="true">
23
+ <button class="button w-full hollow button__transparent-secondary button__sm budget-list__action" id="project-vote-button-1" data-add="true" data-disable="true" data-budget="15233687" data-allocation="15233687" data-redirect-url="/processes/corpse-curriculum/f/4/budgets/1/projects/1" title="Add project Sed harum. to your vote." type="submit">
24
+ Add
25
+ <%= icon("add-fill") %>
26
+ </button>
27
+ <input type="hidden" name="authenticity_token" value="pm2aa6Q12U56FRLuwBjfFxGA0yxN0ETuJtgbaAq1rwpQziebMK_OBdVFgCumlN0MC7vy8IpsS93kHFpd2EWbOg" autocomplete="off">
28
+ </form>
29
+ </div>
30
+ </div>
31
+ </div>
@@ -0,0 +1,16 @@
1
+ <%= append_stylesheet_pack_tag "decidim_accountability" %>
2
+
3
+ <a class="card__list" id="accountability__result_101" href="#">
4
+ <div class="card__list-content">
5
+ <div class="h4 card__list-title">
6
+ Explicabo et.
7
+ </div>
8
+ <div class="card__list-metadata">
9
+ <span>
10
+ <%= icon("price-tag-3-line") %>
11
+ Sint aut neque debitis id.
12
+ </span>
13
+ </div>
14
+ </div>
15
+ <div class="accountability__progress">78%</div>
16
+ </a>
@@ -0,0 +1,66 @@
1
+ <a class="card__list" id="blogs__post_6" href="#">
2
+ <div class="card__list-image">
3
+ <img class="w-full h-full object-cover" src="/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBc0lCIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--f9dcdd2b5fa8a4c7c371725abbec4b531a241788/hero_image.jpeg" alt="hero_image">
4
+ </div>
5
+ <div class="card__list-content">
6
+ <div class="h4 card__list-title">
7
+ With images
8
+ </div>
9
+ <div class="card__list-text">
10
+ <div class="rich-text-display">Provident eum nobis. Voluptates ratione consequatur. Velit consectetur dolor. Quibusdam alias culpa. Placeat dolorem similique. Et eos ex. Distinctio temporibus culpa. Autem accusamus omnis. Temporibus aperiam officiis. Deleniti vel officiis. Voluptas non temporibus. Aspernatur eos et. Corporis aliquam sint. Eos ut et. Fuga eveniet cum. Error quis architecto. Sed alias est. Molestias at veniam. Culpa unde nesciunt. Fuga voluptatem pariatur.</div>
11
+ </div>
12
+ <div class="card__list-metadata">
13
+ <span>
14
+ <!-- linthtml-disable -->
15
+ <div class="author" data-author="">
16
+ <div class="author__container has-tip" data-tooltip="<div class=&quot;author__tooltip bottom&quot; role=&quot;tooltip&quot;>
17
+ <div class=&quot;author__container&quot;>
18
+ <span class=&quot;author__avatar-container&quot;>
19
+ <img alt=&quot;Avatar: Terica MacGyver Sr.&quot; class=&quot;author__avatar&quot; src=&quot;<%= asset_pack_path("media/images/default-avatar.svg") %>&quot; />
20
+ </span>
21
+ <div>
22
+ <span class=&quot;author__name&quot;>Terica MacGyver Sr.</span>
23
+ <span class=&quot;text-md&quot;>@elina</span>
24
+ </div>
25
+ </div>
26
+ <div class=&quot;author__tooltip-links&quot;>
27
+ <a href=&quot;/profiles/elina/followers&quot;>
28
+ <span id=&quot;followers_count_user_16&quot;>0</span> Followers
29
+ </a>
30
+ <a href=&quot;/profiles/elina/following&quot;>
31
+ 2 Follows
32
+ </a>
33
+ </div>
34
+ <a class=&quot;button button__sm button__transparent&quot; href=&quot;/conversations/new?recipient_id=16&quot;>
35
+ <span>Send private message</span>
36
+ <svg width=&quot;1em&quot; height=&quot;1em&quot; role=&quot;img&quot; aria-hidden=&quot;true&quot;><use href=&quot;<%= "#{asset_pack_path("media/images/remixicon.symbol.svg")}#ri-mail-send-line" %>&quot; tabindex=&quot;-1&quot;></use></svg>
37
+ </a>
38
+ <a class=&quot;button button__sm button__transparent&quot; title=&quot;Follow&quot; id=&quot;follow_user_16&quot; data-remote=&quot;true&quot; rel=&quot;nofollow&quot; data-method=&quot;post&quot; href=&quot;/follow?follow%5Bbutton_classes%5D=button+button__sm+button__transparent&amp;follow%5Bfollowable_gid%5D=BAh7CEkiCGdpZAY6BkVUSSIzZ2lkOi8vZGVjaWRpbS1kZXZlbG9wbWVudC1hcHAvRGVjaWRpbTo6VXNlci8xNgY7AFRJIgxwdXJwb3NlBjsAVEkiDGRlZmF1bHQGOwBUSSIPZXhwaXJlc19hdAY7AFRJIh0yMDIzLTExLTE5VDE0OjMzOjEzLjIwMFoGOwBU--7f5a417635cb6014539ff6341140054f59ef9773&quot;>
39
+ <span class=&quot;&quot;>Follow</span>
40
+ <svg width=&quot;1em&quot; height=&quot;1em&quot; role=&quot;img&quot; aria-hidden=&quot;true&quot;><use href=&quot;<%= "#{asset_pack_path("media/images/remixicon.symbol.svg")}#ri-notification-3-line" %>&quot; tabindex=&quot;-1&quot;></use></svg>
41
+ </a>
42
+ </div>
43
+ " aria-describedby="5filn3-tooltip" data-yeti-box="5filn3-tooltip" data-toggle="5filn3-tooltip" data-resize="5filn3-tooltip" id="toggle-0rsefa" aria-controls="5filn3-tooltip">
44
+ <span class="author__avatar-container">
45
+ <img alt="Avatar: Terica MacGyver Sr." class="author__avatar" src="<%= asset_pack_path("media/images/default-avatar.svg") %>">
46
+ </span>
47
+ <span class="author__name">Terica MacGyver Sr.</span>
48
+ </div>
49
+ </div>
50
+ <!-- linthtml-enable -->
51
+ </span>
52
+ <span>
53
+ <%= icon("calendar-todo-line") %>
54
+ 05 Oct 2023
55
+ </span>
56
+ <span data-comments-count="">
57
+ <%= icon("wechat-line") %>
58
+ 2
59
+ </span>
60
+ <span data-endorsements-count="">
61
+ <%= icon("like") %>
62
+ 0
63
+ </span>
64
+ </div>
65
+ </div>
66
+ </a>
@@ -0,0 +1,30 @@
1
+ <a class="card__list card__calendar-list__reset" id="meetings__meeting_52" href="#">
2
+ <time class="card__calendar" datetime="2023-10-07T00:00:00Z">
3
+ <div class="card__calendar-month">Oct</div>
4
+ <div class="card__calendar-day">07</div>
5
+ <div class="card__calendar-time">00:00</div>
6
+ </time>
7
+ <div class="card__list-content">
8
+ <h3 class="h4 card__list-title">
9
+ Sed ratione.
10
+ </h3>
11
+ <div class="card__list-metadata">
12
+ <span>
13
+ <%= icon("home-wifi-line") %>
14
+ Hybrid
15
+ </span>
16
+ <span>
17
+ <%= icon("time-line") %>
18
+ 16d
19
+ </span>
20
+ <span data-comments-count="">
21
+ <%= icon("wechat-line") %>
22
+ 0
23
+ </span>
24
+ <span>
25
+ <%= icon("price-tag-3-line") %>
26
+ Praesentium nam delectus in numquam.
27
+ </span>
28
+ </div>
29
+ </div>
30
+ </a>
@@ -0,0 +1,60 @@
1
+ <a class="card__list" id="proposals__proposal_4" href="#">
2
+ <div class="card__list-content">
3
+ <div class="h4 card__list-title">
4
+ Quae reiciendis. Et.
5
+ </div>
6
+ <div class="card__list-metadata">
7
+ <span>
8
+ <!-- linthtml-disable -->
9
+ <div class="author" data-author="">
10
+ <div class="author__container has-tip" data-tooltip="<div class=&quot;author__tooltip bottom&quot; role=&quot;tooltip&quot;>
11
+ <div class=&quot;author__container&quot;>
12
+ <span class=&quot;author__avatar-container&quot;>
13
+ <img alt=&quot;Avatar: Tammy Lesch VM&quot; class=&quot;author__avatar&quot; src=&quot;<%= asset_pack_path("media/images/default-avatar.svg") %>&quot; />
14
+ </span>
15
+ <div>
16
+ <span class=&quot;author__name&quot;>Tammy Lesch VM</span>
17
+ <span class=&quot;text-md&quot;>@gia</span>
18
+ </div>
19
+ </div>
20
+ <div class=&quot;author__tooltip-links&quot;>
21
+ <a href=&quot;/profiles/gia/followers&quot;>
22
+ <span id=&quot;followers_count_user_group_24&quot;>0</span> Followers
23
+ </a>
24
+ </div>
25
+ <a class=&quot;button button__sm button__transparent&quot; href=&quot;/users/sign_in&quot;>
26
+ <span>Send private message</span>
27
+ <svg width=&quot;1em&quot; height=&quot;1em&quot; role=&quot;img&quot; aria-hidden=&quot;true&quot;><use href=&quot;<%= "#{asset_pack_path("media/images/remixicon.symbol.svg")}#ri-mail-send-line" %>&quot; tabindex=&quot;-1&quot;></use></svg>
28
+ </a>
29
+ <form class=&quot;button_to&quot; method=&quot;post&quot; action=&quot;#&quot;><button class=&quot;button button__sm button__transparent&quot; title=&quot;Please log in before performing this action&quot; aria-haspopup=&quot;true&quot; id=&quot;follow_user_group_24&quot; data-dialog-open=&quot;loginModal&quot; type=&quot;submit&quot;>
30
+ <span class=&quot;&quot;>Follow</span>
31
+ <svg width=&quot;1em&quot; height=&quot;1em&quot; role=&quot;img&quot; aria-hidden=&quot;true&quot;><use href=&quot;<%= "#{asset_pack_path("media/images/remixicon.symbol.svg")}#ri-notification-3-line" %>&quot; tabindex=&quot;-1&quot;></use></svg>
32
+ </button><input type=&quot;hidden&quot; name=&quot;authenticity_token&quot; value=&quot;lS3Qr0rPEGR-g40UKR1aXFG0ekPAg3vX75katkSHYSttywRbOAj5EvsNAWZ91bMhwstNuRYPuhbLQE-AvlAs6w&quot; autocomplete=&quot;off&quot; /><input type=&quot;hidden&quot; name=&quot;follow[button_classes]&quot; value=&quot;button button__sm button__transparent&quot; autocomplete=&quot;off&quot; /><input type=&quot;hidden&quot; name=&quot;follow[followable_gid]&quot; value=&quot;BAh7CEkiCGdpZAY6BkVUSSI4Z2lkOi8vZGVjaWRpbS1kZXZlbG9wbWVudC1hcHAvRGVjaWRpbTo6VXNlckdyb3VwLzI0BjsAVEkiDHB1cnBvc2UGOwBUSSIMZGVmYXVsdAY7AFRJIg9leHBpcmVzX2F0BjsAVEkiHTIwMjMtMTEtMTlUMDc6MDg6NDAuNDU3WgY7AFQ=--a0875a4b535cbc4218f1e0707cc6ea2148e213f3&quot; autocomplete=&quot;off&quot; /></form>
33
+ </div>
34
+ " aria-describedby="t17dfd-tooltip" data-yeti-box="t17dfd-tooltip" data-toggle="t17dfd-tooltip" data-resize="t17dfd-tooltip" id="toggle-2k3n55" aria-controls="t17dfd-tooltip">
35
+ <span class="author__avatar-container">
36
+ <img alt="Avatar: Tammy Lesch VM" class="author__avatar" src="<%= asset_pack_path("media/images/default-avatar.svg") %>">
37
+ </span>
38
+ <span class="author__name">Tammy Lesch VM</span>
39
+ </div>
40
+ </div>
41
+ <!-- linthtml-enable -->
42
+ </span>
43
+ <span data-comments-count="">
44
+ <%= icon("wechat-line") %>
45
+ 0
46
+ </span>
47
+ <span data-endorsements-count="">
48
+ <%= icon("like") %>
49
+ 0
50
+ </span>
51
+ <span>
52
+ <span class="label warning">Evaluating</span>
53
+ </span>
54
+ <span>
55
+ <%= icon("question-line") %>
56
+ Amendment
57
+ </span>
58
+ </div>
59
+ </div>
60
+ </a>
@@ -0,0 +1,15 @@
1
+ <a class="card__search" id="assembly_3" href="#">
2
+ <h3 class="h4 card__search-title">
3
+ Blanditiis nulla quis enim consequatur.
4
+ </h3>
5
+ <div class="card__search-metadata">
6
+ <span>
7
+ <%= icon("government-line") %>
8
+ 1 assembly
9
+ </span>
10
+ <span>
11
+ <%= icon("group-2-line") %>
12
+ ipsum
13
+ </span>
14
+ </div>
15
+ </a>
@@ -0,0 +1,11 @@
1
+ <% content_for :heading do %>
2
+ Cards
3
+ <% end %>
4
+
5
+ <% content_for :toc do %>
6
+ <% cards_sections.each do |section| %>
7
+ <%= link_to(section_text(section), "##{section[:id]}") %>
8
+ <% end %>
9
+ <% end %>
10
+
11
+ <%= render partial: "decidim/design/shared/sections", locals: { sections: cards_sections } %>
@@ -0,0 +1,89 @@
1
+ <% content_for :heading do %>
2
+ Dialogs
3
+ <% end %>
4
+
5
+ <% content_for :description do %>
6
+ Dialogs are a javascript feature available thanks to an external library called <a href="https://github.com/jonathanlevaillant/a11y-dialog-component" target="_blank" rel="noopener noreferrer">a11y-dialog-component</a>.
7
+ <% end %>
8
+
9
+ <% content_for :toc do %>
10
+ <a href="#example">Demo</a>
11
+ <a href="#usage">Usage</a>
12
+ <a href="#html">HTML tips</a>
13
+ <% end %>
14
+
15
+ <section id="demo" class="design__section">
16
+ <h2>Demo</h2>
17
+
18
+ <p>The dialogs, or modal components, are implemented thorugh the rails helper <code>decidim_modal</code>. </p>
19
+
20
+ <button data-dialog-open="example" class="button button__lg button__secondary">
21
+ Show modal
22
+ </button>
23
+
24
+ <%= decidim_modal id: "example" do %>
25
+ I am a modal
26
+ <% end %>
27
+ </section>
28
+
29
+ <section id="usage" class="design__section">
30
+ <h2>Usage</h2>
31
+
32
+ <p>An dialog requires two elements:</p>
33
+
34
+ <p>1. A user actionable element, with the data-attribute <code>data-dialog-open="example"</code>, where example is the <code>id</code> of the modal.</p>
35
+
36
+ <p>2. A modal element, whose <code>id</code> matches the data-target value the trigger refers to.</p>
37
+
38
+ <div class="design__section-snippet" style="margin-top: inherit;">
39
+ <p>Source code on GitHub: <%= link_to("decidim-core/app/packs/src/decidim/a11y.js", "https://github.com/decidim/decidim/blob/develop/decidim-core/app/packs/src/decidim/a11y.js", target: "_blank", rel: "noopener noreferrer") %></p>
40
+
41
+ <code>
42
+ <textarea rows="7">
43
+ &lt;button data-dialog-open=&quot;example&quot; class=&quot;button button__lg button__secondary&quot;&gt;
44
+ Show modal
45
+ &lt;/button&gt;
46
+
47
+ &#60;%= decidim_modal id: "example" do %&#62;
48
+ I am a modal
49
+ &#60;% end %&#62;
50
+ </textarea>
51
+ </code>
52
+ </div>
53
+ </section>
54
+
55
+ <section id="html" class="design__section">
56
+ <h2>HTML tips</h2>
57
+
58
+ <p>In order to display a complex modal, matching up the styles, do the following markup:</p>
59
+
60
+ <p>Pay attention to the <i>data-attributes</i> and the <i>ids</i>. For instance, the <code>[data-dialog-title]</code>'s id starts with <i>dialog-title</i> plus the <i>modal id</i>.</p>
61
+
62
+ <div class="design__section-snippet" style="margin-top: inherit;">
63
+ <code>
64
+ <textarea rows="20">
65
+ &#60;%= decidim_modal id: "example" do %&#62;
66
+ <div data-dialog-container>
67
+ &#60;%= icon "icon_identificator" %&#62; // ... pick a desired icon
68
+ <h3 id="dialog-title-example" tabindex="-1" data-dialog-title>
69
+ Modal title
70
+ </h3>
71
+ <div>
72
+ <p id="dialog-desc-example">
73
+ Modal description (optional)
74
+ </p>
75
+
76
+ // ... add more HTML
77
+ </div>
78
+ </div>
79
+ <div data-dialog-actions>
80
+ <button data-dialog-close="example">
81
+ Close modal
82
+ </button>
83
+ // ... add more buttons
84
+ </div>
85
+ &#60;% end %&#62;
86
+ </textarea>
87
+ </code>
88
+ </div>
89
+ </section>
@@ -0,0 +1,64 @@
1
+ <% content_for :heading do %>
2
+ Dropdowns
3
+ <% end %>
4
+
5
+ <% content_for :description do %>
6
+ Dropdowns are a javascript feature available thanks to an external library called <a href="https://github.com/jonathanlevaillant/a11y-dropdown-component" target="_blank" rel="noopener noreferrer">a11y-dropdown-component</a>.
7
+ <% end %>
8
+
9
+ <% content_for :toc do %>
10
+ <a href="#example">Demo</a>
11
+ <a href="#usage">Usage</a>
12
+ <% end %>
13
+
14
+ <section id="demo" class="design__section">
15
+ <h2>Demo</h2>
16
+
17
+ <p>The dropdowns are used along the application in order to collapse large, easy-readable menus for desktop devices, but too wordy for mobile devices.</p>
18
+
19
+ <p>This javascript feature is enhanced with a small css, through the naming: the hideable content MUST HAVE an <code>id</code> starting with <i>dropdown-menu</i>.</p>
20
+
21
+ <p>The following example will not be noticeable in desktop, but mobile:</p>
22
+
23
+ <button id="dropdown-trigger-element" data-component="dropdown" data-target="dropdown-menu-element" data-auto-close="true">
24
+ <span><%= t("decidim.searches.filters.jump_to") %></span>
25
+ <%= icon "arrow-down-s-line" %>
26
+ <%= icon "arrow-up-s-line" %>
27
+ </button>
28
+
29
+ <ul id="dropdown-menu-element">
30
+ <% 3.times do |item| %>
31
+ <li class="p-2 text-gray-2">
32
+ Item <%= item %>
33
+ </li>
34
+ <% end %>
35
+ </ul>
36
+ </section>
37
+
38
+ <section id="usage" class="design__section">
39
+ <h2>Usage</h2>
40
+
41
+ <p>An dropdown requires two elements:</p>
42
+
43
+ <p>1. A user actionable element, with the data-attributes <code>data-component="dropdown" data-target="dropdown-menu-element"</code>.</p>
44
+
45
+ <p>2. A hideable element, whose <code>id</code> matches the data-target value the trigger refers to.</p>
46
+
47
+ <div class="design__section-snippet" style="margin-top: inherit;">
48
+ <p>Source code on GitHub: <%= link_to("decidim-core/app/packs/src/decidim/a11y.js", "https://github.com/decidim/decidim/blob/develop/decidim-core/app/packs/src/decidim/a11y.js", target: "_blank", rel: "noopener noreferrer") %></p>
49
+
50
+ <code>
51
+ <textarea rows="8">
52
+ &lt;button id=&quot;dropdown-trigger-element&quot; data-component=&quot;dropdown&quot; data-target=&quot;dropdown-menu-element&quot;&gt;
53
+ Trigger
54
+ &lt;/button&gt;
55
+
56
+ &lt;ul id=&quot;dropdown-menu-element&quot;&gt;
57
+ &lt;li&gt;Item&lt;/li&gt;
58
+ &lt;li&gt;Item&lt;/li&gt;
59
+ &lt;li&gt;Item&lt;/li&gt;
60
+ &lt;/ul&gt;
61
+ </textarea>
62
+ </code>
63
+ </div>
64
+ </section>
@@ -0,0 +1,4 @@
1
+ <a class="button button__sm button__text-secondary only:m-auto" title="Seguir" id="follow_meeting_1821" data-remote="true" rel="nofollow" data-method="post" href="#">
2
+ <span class="">Follow</span>
3
+ <%= icon("notification-3-line") %>
4
+ </a>
@@ -0,0 +1,4 @@
1
+ <a class="button button__sm button__text-secondary only:m-auto" title="Stop following" id="follow_meeting_1821" data-remote="true" rel="nofollow" data-method="delete" href="#">
2
+ <span class="">Stop following</span>
3
+ <%= icon("notification-3-fill") %>
4
+ </a>
@@ -0,0 +1,11 @@
1
+ <% content_for :heading do %>
2
+ Follow
3
+ <% end %>
4
+
5
+ <% content_for :toc do %>
6
+ <% follow_sections.each do |section| %>
7
+ <%= link_to(section_text(section), "##{section[:id]}") %>
8
+ <% end %>
9
+ <% end %>
10
+
11
+ <%= render partial: "decidim/design/shared/sections", locals: { sections: follow_sections } %>