Sha256: 15e25e5c6ef2f88477f539c17d3b435fbef916bb8f287647ff00add89a9fc6b8

Contents?: true

Size: 1.37 KB

Versions: 3

Compression:

Stored size: 1.37 KB

Contents

- if product.has_reviews?
  #reviews.reviews
    %h2.reviews__count= t('workarea.storefront.reviews.reviews', count: product.reviews.length)

    .reviews__header
      .reviews__write-action= link_to t('workarea.storefront.reviews.write_a_review'), new_product_review_path(product), class: 'button', data: { dialog_button: '' }
      - if display_purchase_requirement_message
        %span.reviews__write-purchase-requirement= t('workarea.storefront.reviews.purchase_requirement')

    %ol.reviews__review-group
      - product.reviews.each do |review|
        %li.reviews__review{ itemprop: 'review', itemscope: true, itemtype: 'http://schema.org/Review', data: { product_review_section_entry: { rating: review.rating.to_f, createdAt: review.created_at.to_i }.to_json } }
          = rating_stars(review.rating)

          %h3.reviews__review-title{ itemprop: 'name' }= review.title
          %p.reviews__review-body{ itemprop: 'reviewBody' }= review.body
          .reviews__review-meta
            %p.reviews__review-author{ itemprop: 'author', itemscope: true, itemtype: 'http://schema.org/Person' }
              %span{ itemprop: 'name' }= review.user_info
            - if review.verified?
              %p.reviews__review-verified= t('workarea.storefront.reviews.verified_purchaser')
            %p.reviews__review-date= local_time(review.created_at, format: :long, itemprop: 'datePublished')

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
workarea-nvy_theme-1.1.4 app/views/workarea/storefront/products/_reviews.html.haml
workarea-nvy_theme-1.1.3 app/views/workarea/storefront/products/_reviews.html.haml
workarea-nvy_theme-1.1.2 app/views/workarea/storefront/products/_reviews.html.haml