Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add task solution #4492

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

add task solution #4492

wants to merge 1 commit into from

Conversation

osidanych
Copy link

  • DEMO LINK
  • TEST REPORT LINK
  • Icon implemented using background-image CSS property
  • Inputs are written inside of 'form' tag with correctly passed attributes
  • All Typical Mistakes from BEM lesson theory are checked.
  • Code follows all the Code Style Rules ❗️

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

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

Great job addressing the CSS issues! 👍 Remember, it's all about making your code more maintainable and scalable. Keep up the good work, and always aim for best practices like using fallback fonts and proper attribute formatting. Your effort is paying off! 😊

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

class="search-bar__input search-bar__input--big"
type="text"
data-qa="keypress"
placeholder="Try “Los Angeles“"

Choose a reason for hiding this comment

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

Keep your attributes correctly formatted. For the <input> element with multiple attributes, each attribute should start on a new line with a 2-space indentation relative to the tag. The closing bracket should be on the same level as the opening one.

class="search-bar__input search-bar__input--small"
type="text"
data-qa="hover"
placeholder="Try “Los Angeles“"

Choose a reason for hiding this comment

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

Keep your attributes correctly formatted. For the <input> element with multiple attributes, each attribute should start on a new line with a 2-space indentation relative to the tag. The closing bracket should be on the same level as the opening one.

Comment on lines +20 to +29
<form
class="search-bar search-bar--big"
data-qa="big"
>
<input
class="search-bar__input search-bar__input--big"
type="text"
data-qa="keypress"
placeholder="Try “Los Angeles“"
/>

Choose a reason for hiding this comment

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

Add empty lines between multiline sibling blocks of HTML to add some "air" and simplify reading. There should be an empty line separating the two <form> elements.

}

body {
font-family: Avenir, sans-serif;

Choose a reason for hiding this comment

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

Remember to use fallback fonts - alternative font-family in case the main one doesn't work. For instance, you could use 'font-family: Avenir, Arial, sans-serif;'

Comment on lines +20 to +27
.search-bar {
width: 100%;
border: 1px solid #e1e7ed;
border-radius: 4px;
box-shadow: 0 1px 8px 0 #3d4e611a;
margin-top: 20px;
box-sizing: border-box;
}

Choose a reason for hiding this comment

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

Don't fix container size (if there is no such a requirement). The width is set to 100% which is good, but ensure that the container's size is flexible enough to accommodate various content sizes.

border: 1px solid #e1e7ed;
border-radius: 4px;
box-shadow: 0 1px 8px 0 #3d4e611a;
margin-top: 20px;

Choose a reason for hiding this comment

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

Be consistent with your margins (Add only top or bottom, but not both). In this case, only 'margin-top' is used which is good.

Comment on lines +29 to +40
.search-bar__logo {
width: 19px;
height: 19px;
top: 25px;
padding-left: 26px;
}

.search-bar__logo--small {
width: 11px;
height: 11px;
top: 15px;
padding-left: 13px;

Choose a reason for hiding this comment

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

Don't use tag names for styling (except 'html' and 'body'). It is recommended to use classes for styling. If '.search-bar__logo' and '.search-bar__logo--small' are meant to style 'img' tags, consider adding a class to the 'img' tags instead.

.search-bar__input {
box-sizing: border-box;
width: 100%;
background-image: url('./images/Search.svg');

Choose a reason for hiding this comment

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

It's a good practice to use relative paths for images that consider the current file's location. Ensure that the path './images/Search.svg' is correct relative to the CSS file location.

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.

2 participants