Skip to content

Conversation

@engineerfoma
Copy link
Collaborator

Выполнена верстка секции "gallery"(переименовал её из "photos")

@Pavel-Rogozhkin Pavel-Rogozhkin removed the request for review from nlog675 June 12, 2022 16:23
Copy link
Collaborator

@evgenybalagurov evgenybalagurov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Привет, Николай. Проделана огромная работа. Понравилось построение сетки grid через auto-fit. Почти не нужно будет делать адаптив. Все, что необходимо поправить в комментариях.

<section class="photos">

<section class="gallery">
<div class="gallery__block">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Предлагаю вынести текст в отдельный блок - text-block и создавать для него элементы и модификаторы в зависимости от ситуации. В своей секции feedback, я использовал элемент text-block__title для заголовка. Вместо элемента gallery__block тоже можно использовать text-block__title. И создать модификатор, например .text-block_placed_title, для задания ширины и правого padding.

<div class="gallery__block">
<h2 class="gallery__block_title">Заголовок блока с фотографиями</h2>
</div>
<div class="gallery__list">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gallery__list необходимо сделать списком ul, так будет семантичнее)

</div>
<div class="gallery__list">
<img src="./images/img-gallery-1.jpg" alt="Подготовка к пьесе #4" class="gallery__list_element">
<img src="./images/img-gallery-2.jpg" alt="Подготовка к пьесе #1" class="gallery__list_element">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

По БЭМ модификатор нельзя использовать отдельно от элемента на одном узле. Возможно имелся ввиду элемент gallery__list-element. Т.к. это элемент списка его лучше назвать gallery__item

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Не до конца понимаю, что ты имеешь ввиду, если честно. Блок gallery с модификатором list я не могу использовать?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

__list - это элемент у тебя,
_element -модификатор,
но по БЭМ одиночные модификаторы можно использовать только если они принимают бинарные значения (true, false), например _active или _visible.
Как написал Евгений тебе либо надо исправить на gallery__list-element, либо лучше на gallery__item.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gallery__item тут будет самым оптимальным решением

margin: 0 auto;
max-width: 100%;
display: grid;
grid-template-columns: repeat(auto-fit, minmax(206px, 359px));
Copy link
Collaborator

@evgenybalagurov evgenybalagurov Jun 12, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Здорово, что использовал auto-fit, адаптив почти не нужно будет делать). Можно немного его изменить, тогда на мой взгляд будет эффектнее выглядеть. Вот так: grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)) и для элемента с классом .gallery__list_element width: 100%. И margin: 0 auto; max-width: 100%; будут не нужны. Можешь оставить, как сделал, так тоже классно.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)) - поддерживаю так будет круто)
классом .gallery__list_element - изменится скорее всего, смотри комменты выше.

@@ -0,0 +1,3 @@
.gallery__list_element {

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Файл для селекторов, которые не содержат стилей создавать не нужно.
Для изображения лучше задать display: block, что-бы сделать его блочным

Copy link
Collaborator

@DmitriyMGN DmitriyMGN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Молодец! Практически нечего было писать в замечания, есть мелкие рекомендации по альтам. Так держать!

</div>
<div class="gallery__list">
<img src="./images/img-gallery-1.jpg" alt="Подготовка к пьесе #4" class="gallery__list_element">
<img src="./images/img-gallery-2.jpg" alt="Подготовка к пьесе #1" class="gallery__list_element">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gallery__item тут будет самым оптимальным решением

<img src="./images/img-gallery-5.jpg" alt="Подготовка к пьесе #5" class="gallery__list_element">
<img src="./images/img-gallery-6.jpg" alt="Подготовка к пьесе #6" class="gallery__list_element">
<img src="./images/img-gallery-7.jpg" alt="Подготовка к пьесе #7" class="gallery__list_element">
<img src="./images/img-gallery-8.jpg" alt="Подготовка к пьесе #8" class="gallery__list_element">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Посмотри пожалуйста альты к изображением, я думаю они не отражают того что происходит на картинке. По методологии альт должен отражать текстовое описание картинки в случае если она не загрузится, а так не очень понятно что все таки на ней.

</p>
</div>
<div class="footer__design">
<img src="./images/shishki.svg" alt="" class="footer__copyrights-logo">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нет альта

@Pavel-Rogozhkin Pavel-Rogozhkin removed the request for review from dimshaa June 22, 2022 06:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants