extends ../layouts/application
include ../projects/mixins
include ../layouts/mixins
include ../categories/mixins
include ../subcategories/mixins
block title
  = t['All Projects']
block content

  .content-main

    each subcategory in subcategories

      .area
        +subcategory-title-nolink(subcategory)

        .sections
          .division
            .section.free
              .pipe.positive
                = t['Free Recommendations']
                i.fa.fa-check

              each project in subcategory.projects
                +project-card-all(project)

              +filler-cards(subcategory.projects)

            - var notes = t[subcategory.slug + '-notes']
            - if (notes !== "--" && notes !== undefined)
              .section.notes
                .pipe= t.Notes
                .text-block!= notes

          if(subcategory.projectsRejected.length > 0)
            .section.prop
              .pipe.negative
                = t.Proprietary
                i.fa.fa-times
              each project in subcategory.projectsRejected
                .bar.negative
                  .label(title=project.name)
                    img.logo(src=routes.logosRejected + project.logo, alt=project.logo)
                    = project.name

              +filler-bars(subcategory.projectsRejected)
          else
            .section.prop.empty
              .pipe= t.Proprietary

  .content-side
    .section
      .pipe= t.Categories

      each subcategory in subcategories
        a.pipe.subtle(href=`#${subcategory.slug}`)= t[subcategory.name]
