skyderby/skyderby

View on GitHub
app/views/profiles/index.html.haml

Summary

Maintainability
Test Coverage
.container
  .page-header
    %h1
      Профили

  .content-block
    .index-search__container{'data-controller': 'index-search'}
      %span.index-search__icon
        %i.fas.fa-search
      %input.index-search__input{name: 'search',
                                 data: { remote: true, url: profiles_path },
                                 placeholder: 'Type to search',
                                 value: params[:search],
                                 'data-action': 'input->index-search#perform'}

    %table.table.profiles__table
      %thead
        %th
        %th #
        %th= t 'activerecord.attributes.profile.name'
        %th= t 'activerecord.attributes.profile.country'
        %th
        %th
        %th
      %tbody
        = render @profiles

  .profiles__pagination.text-center.top-buffer
    = will_paginate(@profiles, renderer: BootstrapPagination::Rails)