Sha256: d6619706e2bd35c555725178dae762afb7098adc8b1b58096ea9254c716189bd

Contents?: true

Size: 1.26 KB

Versions: 35

Compression:

Stored size: 1.26 KB

Contents

.card{ class: card_classes(:content, local_assigns[:active]) }
  = link_to edit_content_path(content), class: 'card__header', data: { turbolinks: false } do
    %span.card__header-text= t('workarea.admin.content.card.title')
    = inline_svg 'workarea/admin/icons/content.svg', class: 'card__icon'

  - if local_assigns[:active].blank?
    .card__body
      - if content.blocks.active.empty?
        %p.card__empty-note= t('workarea.admin.content.card.description')
        = link_to edit_content_path(content), class: 'card__button' do
          %span.button.button--small= t('workarea.admin.content.card.blank_button')
      - else
        %ol.content-block-list
          - content.blocks.active.take(5).each do |block|
            %li.content-block-list__item
              = content_block_icon(block.icon, title: block.name, class: 'content-block-list__icon')
              %span.content-block-list__name= block.name

          - if content.blocks.length > 5
            %li.content-block-list__item.align-center
              = link_to t('workarea.admin.cards.more', amount: content.blocks.length - 5), edit_content_path(content)

        = link_to edit_content_path(content), class: 'card__button' do
          %span.button.button--small= t('workarea.admin.content.card.button')

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
workarea-admin-3.4.25 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.24 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.23 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.22 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.21 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.5.0.beta.1 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.20 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.19 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.18 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.17 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.16 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.15 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.14 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.13 app/views/workarea/admin/content/_card.html.haml
workarea-admin-3.4.12 app/views/workarea/admin/content/_card.html.haml