diff --git a/app/assets/fonts/icons.eot b/app/assets/fonts/icons.eot index eb4fafebe..2c00f1f5b 100644 Binary files a/app/assets/fonts/icons.eot and b/app/assets/fonts/icons.eot differ diff --git a/app/assets/fonts/icons.svg b/app/assets/fonts/icons.svg index e3cab14f4..2f04723b8 100644 --- a/app/assets/fonts/icons.svg +++ b/app/assets/fonts/icons.svg @@ -20,11 +20,13 @@ - + + + diff --git a/app/assets/fonts/icons.ttf b/app/assets/fonts/icons.ttf index 98f7a4d84..808c75487 100644 Binary files a/app/assets/fonts/icons.ttf and b/app/assets/fonts/icons.ttf differ diff --git a/app/assets/fonts/icons.woff b/app/assets/fonts/icons.woff index 930c0a6dd..cc9c32cdf 100644 Binary files a/app/assets/fonts/icons.woff and b/app/assets/fonts/icons.woff differ diff --git a/app/assets/stylesheets/admin.scss b/app/assets/stylesheets/admin.scss index bf9d7dd22..7e6096bc3 100644 --- a/app/assets/stylesheets/admin.scss +++ b/app/assets/stylesheets/admin.scss @@ -149,6 +149,20 @@ body.admin { } } +.verified { + color: $check; +} + +.verified a { + border-bottom: 1px dotted $check; + color: $check; + font-size: rem-calc(12); +} + +.rejected { + color: #F04124; +} + .level { font-size: rem-calc(12); } @@ -161,6 +175,10 @@ body.admin { padding: rem-calc(6) rem-calc(12); } +.button.tiny.success { + margin-left: rem-calc(12); +} + // 04. Stats // - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/app/assets/stylesheets/debates.scss b/app/assets/stylesheets/debates.scss index 5ca0559ec..dd29774a5 100644 --- a/app/assets/stylesheets/debates.scss +++ b/app/assets/stylesheets/debates.scss @@ -163,7 +163,7 @@ padding-top: 0; } - .icon-comment-quotes { + .icon-debates { color: $debates; font-size: rem-calc(36); line-height: $line-height; @@ -191,7 +191,7 @@ font-weight: lighter; margin-bottom: 0; - .icon-chat-bubble-two { + .icon-comments { font-size: rem-calc(16); vertical-align: top; } @@ -280,7 +280,7 @@ } } - .icon-comment-quotes { + .icon-debates { font-size: rem-calc(18); left: rem-calc(60); top: 0; @@ -450,7 +450,7 @@ margin-bottom: rem-calc(24); } - .icon-comment-quotes { + .icon-debates { color: $debates; font-size: rem-calc(60); line-height: $line-height; diff --git a/app/assets/stylesheets/icons.scss b/app/assets/stylesheets/icons.scss index b462adac9..ac6bb9dab 100644 --- a/app/assets/stylesheets/icons.scss +++ b/app/assets/stylesheets/icons.scss @@ -49,7 +49,7 @@ .icon-angle-up:before { content: "d"; } -.icon-chat-bubble-two:before { +.icon-comments:before { content: "e"; } .icon-twitter:before { @@ -58,7 +58,7 @@ .icon-calendar:before { content: "g"; } -.icon-comment-quotes:before { +.icon-debates:before { content: "i"; } .icon-unlike:before { @@ -76,9 +76,6 @@ .icon-star:before { content: "n"; } -.icon-eye:before { - content: "p"; -} .icon-user:before { content: "o"; } @@ -97,3 +94,12 @@ .icon-deleted:before { content: "t"; } +.icon-tag:before { + content: "u"; +} +.icon-eye:before { + content: "p"; +} +.icon-x:before { + content: "v"; +} diff --git a/app/assets/stylesheets/participacion.scss b/app/assets/stylesheets/participacion.scss index eb512ad3f..e6aea4db2 100644 --- a/app/assets/stylesheets/participacion.scss +++ b/app/assets/stylesheets/participacion.scss @@ -13,6 +13,7 @@ // 11. Filters // 12. Official levels // 13. Pagination +// 14. Tables // // 01. Variables @@ -126,6 +127,29 @@ h1, h2, h3, h4, h5, h6 { } } +.sub-nav { + background-color: #f2f2f2; + border-radius: rem-calc(3); + padding: rem-calc(10) rem-calc(10) rem-calc(10) 0; + margin: rem-calc(12) 0; +} + +.sub-nav dt, .sub-nav dd, .sub-nav li { + + &.active { + background: #008CBA; + border-radius: rem-calc(3); + color: white; + cursor: default; + font-weight: normal; + padding: 0.16667rem 0.88889rem; + + a:hover { + color: #737373; + } + } +} + // 04. Header // - - - - - - - - - - - - - - - - - - - - - - - - - @@ -614,7 +638,7 @@ form { margin-bottom: rem-calc(24); } - .icon-comment-quotes { + .icon-debates { color: $debates; font-size: rem-calc(60); line-height: $line-height; @@ -762,3 +786,30 @@ ul.pagination { color: $text-medium; } } + +// 14. Tables +// - - - - - - - - - - - - - - - - - - - - - - - - - + +table { + border-collapse: collapse; + border-spacing: 0; + width: 100%; + + tr { + + td { + line-height: $line-height; + padding: rem-calc(12) rem-calc(6); + } + + &:nth-child(odd) { + background: #F0F2F6; + } + } + + .button { + margin: 0; + } +} + + diff --git a/app/views/admin/_menu.html.erb b/app/views/admin/_menu.html.erb index bc2d459e2..a76ecfe0f 100644 --- a/app/views/admin/_menu.html.erb +++ b/app/views/admin/_menu.html.erb @@ -4,59 +4,59 @@ <%= t("admin.dashboard.index.title") %> -
  • > +
  • > <%= link_to admin_tags_path do %> - - <%= t('admin.menu.debate_topics') %> + + <%= t("admin.menu.debate_topics") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_debates_path do %> - - <%= t('admin.menu.hidden_debates') %> + + <%= t("admin.menu.hidden_debates") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_comments_path do %> - - <%= t('admin.menu.hidden_comments') %> + + <%= t("admin.menu.hidden_comments") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_users_path do %> - - <%= t('admin.menu.hidden_users') %> + + <%= t("admin.menu.hidden_users") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_organizations_path do %> - - <%= t('admin.menu.organizations') %> + + <%= t("admin.menu.organizations") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_officials_path do %> - <%= t('admin.menu.officials') %> + <%= t("admin.menu.officials") %> <% end %>
  • -
  • > +
  • > <%= link_to admin_settings_path do %> - <%= t('admin.menu.settings') %> + <%= t("admin.menu.settings") %> <% end %>
  • -
  • > +
  • > <%= link_to stats_path do %> - <%= t('admin.menu.stats') %> + <%= t("admin.menu.stats") %> <% end %>
  • diff --git a/app/views/admin/comments/index.html.erb b/app/views/admin/comments/index.html.erb index 5a0b8f967..87b25680d 100644 --- a/app/views/admin/comments/index.html.erb +++ b/app/views/admin/comments/index.html.erb @@ -1,18 +1,33 @@

    <%= t("admin.comments.index.title") %>

    + + + +

    <%= page_entries_info @comments %>

      <% @comments.each do |comment| %>
    • -
      +
      <%= comment.body %> + + <%= link_to t("admin.comments.index.show_debate"), "#" %> +
      -
      +
      + + <%= link_to t("admin.actions.archive"), "#", class: "button radius tiny warning" %> + <%= link_to t("admin.actions.restore"), restore_admin_comment_path(comment), method: :put, data: { confirm: t("admin.actions.confirm") }, - class: "button radius small success right" %> + class: "button radius tiny success" %>
    • diff --git a/app/views/admin/debates/index.html.erb b/app/views/admin/debates/index.html.erb index 710f6ebd6..dbd85a46f 100644 --- a/app/views/admin/debates/index.html.erb +++ b/app/views/admin/debates/index.html.erb @@ -1,5 +1,14 @@

      <%= t("admin.debates.index.title") %>

      + + + +

      <%= page_entries_info @debates %>

        @@ -10,6 +19,10 @@ <%= link_to t("admin.actions.restore"), restore_admin_debate_path(debate), method: :put, data: { confirm: t("admin.actions.confirm") }, class: "button radius tiny success right" %> + + + <%= link_to t("admin.actions.archive"), "#", class: "button radius tiny warning right" %> + <% end %>
      diff --git a/app/views/admin/organizations/index.html.erb b/app/views/admin/organizations/index.html.erb index 425bee1f7..df003e6f8 100644 --- a/app/views/admin/organizations/index.html.erb +++ b/app/views/admin/organizations/index.html.erb @@ -1,17 +1,30 @@ -

      <%= t('admin.organizations.index.title') %>

      +

      <%= t("admin.organizations.index.title") %>

      -

      - <%= t('admin.organizations.index.filter') %>: + +<%= form_for(User.new, url: search_admin_officials_path, as: :user, method: :get) do |f| %> +

      +
      + <%= text_field_tag :email, "", placeholder: t("admin.officials.index.search_email_placeholder") %> +
      +
      + <%= f.submit t("admin.officials.index.search"), class: "button radius success" %> +
      +
      +<% end %> + + +

      <%= page_entries_info @organizations %>

      @@ -21,23 +34,38 @@ <%= organization.name %> <%= organization.email %> <%= organization.phone_number %> + + Colectivo + <% if organization.verified? %> - <%= t('admin.organizations.index.verified') %> - <% end %> - <% if can? :verify, organization %> - <%= link_to t('admin.organizations.index.verify'), - verify_admin_organization_path(organization, request.query_parameters), - method: :put - %> + + + <%= t("admin.organizations.index.verified") %> <% end %> <% if organization.rejected? %> - <%= t('admin.organizations.index.rejected') %> + + + <%= t("admin.organizations.index.rejected") %> + + <% end %> + + + <%= link_to t("admin.organizations.index.edit"), "", class: "button radius tiny secondary" %> + + + <% if can? :verify, organization %> + + <%= link_to t("admin.organizations.index.verify"), + verify_admin_organization_path(organization, request.query_parameters), + method: :put, class: "button radius tiny success" + %> + <% end %> <% if can? :reject, organization %> - <%= link_to t('admin.organizations.index.reject'), + <%= link_to t("admin.organizations.index.reject"), reject_admin_organization_path(organization, request.query_parameters), - method: :put + method: :put, class: "button radius tiny alert" %> <% end %> diff --git a/app/views/debates/_debate.html.erb b/app/views/debates/_debate.html.erb index 56a5127c5..4dd866df2 100644 --- a/app/views/debates/_debate.html.erb +++ b/app/views/debates/_debate.html.erb @@ -5,10 +5,10 @@
      <%= t("debates.debate.debate") %> - +

      <%= link_to debate.title, debate %>

      -   +   <%= link_to t("debates.debate.comments", count: debate.comment_threads.count), debate_path(debate, anchor: "comments") %>

      diff --git a/app/views/debates/new.html.erb b/app/views/debates/new.html.erb index c341d178d..7987265bd 100644 --- a/app/views/debates/new.html.erb +++ b/app/views/debates/new.html.erb @@ -10,7 +10,7 @@
      - +

      <%= t("debates.new.recommendations_title") %>

      • <%= t("debates.new.recommendation_one") %>
      • diff --git a/app/views/debates/show.html.erb b/app/views/debates/show.html.erb index d27edde49..1475e95a8 100644 --- a/app/views/debates/show.html.erb +++ b/app/views/debates/show.html.erb @@ -39,7 +39,7 @@  •  <%= l @debate.created_at.to_date %>  •  -   +   <%= link_to t("debates.show.comments", count: @debate.comment_threads.count), "#comments" %>
      diff --git a/app/views/welcome/_featured_debate.html.erb b/app/views/welcome/_featured_debate.html.erb index a1992e337..11cb3b733 100644 --- a/app/views/welcome/_featured_debate.html.erb +++ b/app/views/welcome/_featured_debate.html.erb @@ -4,10 +4,10 @@
      <%= t("debates.debate.debate") %> - +

      <%= link_to featured_debate.title, featured_debate %>

      -   +   <%= link_to t("debates.show.comments", count: featured_debate.comment_threads.count), debate_path(featured_debate, anchor: "comments") %>

      diff --git a/config/locales/admin.en.yml b/config/locales/admin.en.yml index cdf6774db..971699c0b 100644 --- a/config/locales/admin.en.yml +++ b/config/locales/admin.en.yml @@ -25,6 +25,7 @@ en: verified: Verified rejected: Rejected filter: Filter + edit: Edit filters: all: All pending: Pending @@ -35,6 +36,7 @@ en: hide_author: Ban author restore: Restore confirm: 'Are you sure?' + archive: Archive tags: index: title: 'Debate topics' @@ -46,15 +48,26 @@ en: comments: index: title: Hidden comments + show_debate: Show debate + filter: Filter restore: success: The comment has been restored + filters: + all: All + pending: Pending + archived: Archived debates: index: title: Hidden debates + filter: Filter show: back: Back restore: success: The debate has been restored + filters: + all: All + pending: Pending + archived: Archived users: index: title: Banned users diff --git a/config/locales/admin.es.yml b/config/locales/admin.es.yml index 02f0ef65a..3c264447f 100644 --- a/config/locales/admin.es.yml +++ b/config/locales/admin.es.yml @@ -25,6 +25,7 @@ es: verified: Verificada rejected: Rechazada filter: Filtro + edit: Editar filters: all: Todas pending: Pendientes @@ -35,26 +36,38 @@ es: hide_author: Bloquear al autor restore: Volver a mostrar confirm: '¿Estás seguro?' + archive: Archivar tags: index: title: 'Temas de debate' add_tag: 'Añade un nuevo tema de debate' - mark_as_featured: 'Proponer etiqueta al crear debate' + mark_as_featured: 'Proponer tema al crear debate' name: placeholder: 'Escribe el nombre del tema' destroy: Elimina la etiqueta comments: index: title: Comentarios ocultos + show_debate: Ver debate + filter: Filtro restore: success: El comentario ha sido permitido + filters: + all: Todos + pending: Pendientes + archived: Archivados debates: index: title: Debates ocultos + filter: Filtro show: back: Volver restore: success: El debate ha sido permitido + filters: + all: Todos + pending: Pendientes + archived: Archivados users: index: title: Usuarios bloqueados