Commit 2e5525d5961a10f8bb7e57fddb0c22db98f082d8
Merge remote-tracking branch 'origin/master'
Showing
3 changed files
with
56 additions
and
22 deletions
Show diff stats
frontend/views/site/comments.php
| @@ -14,7 +14,9 @@ | @@ -14,7 +14,9 @@ | ||
| 14 | <div class="container"> | 14 | <div class="container"> |
| 15 | <div class="row"> | 15 | <div class="row"> |
| 16 | <div class="col-md-12"> | 16 | <div class="col-md-12"> |
| 17 | - <h4 class="text-uppercase title-comment">Оставить отзыв</h4> | 17 | + <div class="heading"> |
| 18 | + <h2>Отзывы</h2> | ||
| 19 | + </div> | ||
| 18 | <?php | 20 | <?php |
| 19 | echo CommentWidget::widget( | 21 | echo CommentWidget::widget( |
| 20 | [ | 22 | [ |
| @@ -22,7 +24,7 @@ | @@ -22,7 +24,7 @@ | ||
| 22 | 'display_name' => 'name', | 24 | 'display_name' => 'name', |
| 23 | 'entityIdAttribute' => 'id', | 25 | 'entityIdAttribute' => 'id', |
| 24 | 'reply' => true, | 26 | 'reply' => true, |
| 25 | - 'layout' => "{form}<div class='comments-border'></div><h4 class='text-uppercase title-comment'>Отзывы</h4>{list} {reply_form}", | 27 | + 'layout' => "{list} {reply_form}<div class='comments-border'></div><h4 class='text-uppercase title-comment'>Оставить отзыв</h4>{form}", |
| 26 | 'delete' => false, | 28 | 'delete' => false, |
| 27 | 'more' => [ | 29 | 'more' => [ |
| 28 | 'show_' => true, | 30 | 'show_' => true, |
frontend/views/site/gallery.php
| @@ -13,26 +13,36 @@ | @@ -13,26 +13,36 @@ | ||
| 13 | 13 | ||
| 14 | ?> | 14 | ?> |
| 15 | 15 | ||
| 16 | - | ||
| 17 | -<div class="my-gallery" itemscope itemtype="http://schema.org/ImageGallery"> | ||
| 18 | - <?php foreach ($images as $image) { | ||
| 19 | - if (file_exists(\Yii::getAlias('@storage/' . $image->id . '_' . $image->fileHash . '.' . $image->extension))) { | ||
| 20 | - ?> | ||
| 21 | - <figure class="reviews_gallery"> | ||
| 22 | - <a href="<?= $image->getUrl() ?>" itemprop="contentUrl" data-size="<?= getimagesize( | ||
| 23 | - $image->getPath() | ||
| 24 | - )[ 0 ] . 'x' . getimagesize( | ||
| 25 | - $image->getPath() | ||
| 26 | - )[ 1 ] ?>"> | ||
| 27 | - <img src="<?= ImageHelper::set($image->getPath()) | ||
| 28 | - ->cropResize(500, 325) | ||
| 29 | - ->render() ?>" itemprop="thumbnail" alt=""/> | ||
| 30 | - </a> | ||
| 31 | - </figure> | ||
| 32 | - <?php | ||
| 33 | - } | ||
| 34 | - } | ||
| 35 | - ?> | 16 | +<div id="content"> |
| 17 | + <div class="container"> | ||
| 18 | + <div class="row"> | ||
| 19 | + <div class="col-md-12"> | ||
| 20 | + <div class="heading"> | ||
| 21 | + <h2>Галерея</h2> | ||
| 22 | + </div> | ||
| 23 | + <div class="my-gallery" itemscope itemtype="http://schema.org/ImageGallery"> | ||
| 24 | + <?php foreach ($images as $image) { | ||
| 25 | + if (file_exists(\Yii::getAlias('@storage/' . $image->id . '_' . $image->fileHash . '.' . $image->extension))) { | ||
| 26 | + ?> | ||
| 27 | + <figure class="reviews_gallery"> | ||
| 28 | + <a href="<?= $image->getUrl() ?>" itemprop="contentUrl" data-size="<?= getimagesize( | ||
| 29 | + $image->getPath() | ||
| 30 | + )[ 0 ] . 'x' . getimagesize( | ||
| 31 | + $image->getPath() | ||
| 32 | + )[ 1 ] ?>"> | ||
| 33 | + <img src="<?= ImageHelper::set($image->getPath()) | ||
| 34 | + ->cropResize(500, 325) | ||
| 35 | + ->render() ?>" itemprop="thumbnail" alt=""/> | ||
| 36 | + </a> | ||
| 37 | + </figure> | ||
| 38 | + <?php | ||
| 39 | + } | ||
| 40 | + } | ||
| 41 | + ?> | ||
| 42 | + </div> | ||
| 43 | + </div> | ||
| 44 | + </div> | ||
| 45 | + </div> | ||
| 36 | </div> | 46 | </div> |
| 37 | 47 | ||
| 38 | <div class="pswp" tabindex="-1" role="dialog" aria-hidden="true"> | 48 | <div class="pswp" tabindex="-1" role="dialog" aria-hidden="true"> |
frontend/web/css/custom.css
| @@ -342,4 +342,26 @@ input[type="text"].form-control{ | @@ -342,4 +342,26 @@ input[type="text"].form-control{ | ||
| 342 | } | 342 | } |
| 343 | .artbox_list_container #list-view{ | 343 | .artbox_list_container #list-view{ |
| 344 | padding-top:40px; | 344 | padding-top:40px; |
| 345 | +} | ||
| 346 | +figure.reviews_gallery { | ||
| 347 | + width: 33.333%; | ||
| 348 | + float: left; | ||
| 349 | + padding: 10px; | ||
| 350 | +} | ||
| 351 | +.reviews_gallery img { | ||
| 352 | + width: 100%; | ||
| 353 | + height: 100%; | ||
| 354 | +} | ||
| 355 | +.reviews_gallery:last-child img{ | ||
| 356 | + margin-bottom:60px; | ||
| 357 | +} | ||
| 358 | +@media ( max-width: 690px ) { | ||
| 359 | + figure.reviews_gallery{ | ||
| 360 | + width:50%; | ||
| 361 | + } | ||
| 362 | +} | ||
| 363 | +@media ( max-width: 380px ) { | ||
| 364 | + figure.reviews_gallery{ | ||
| 365 | + width:100%; | ||
| 366 | + } | ||
| 345 | } | 367 | } |
| 346 | \ No newline at end of file | 368 | \ No newline at end of file |