Skip to content

Comments

Develop#2

Open
IamMK wants to merge 31 commits intoD0man:developfrom
IamMK:develop
Open

Develop#2
IamMK wants to merge 31 commits intoD0man:developfrom
IamMK:develop

Conversation

@IamMK
Copy link

@IamMK IamMK commented Jan 16, 2019

Wszelkie informacje dodatkowe ode mnie podane w pliku README.md

Copy link
Owner

@D0man D0man left a comment

Choose a reason for hiding this comment

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

Code review, PHP nie patrzyłem i rzeczy które są mniej oczywiste też nie
, ogólnie całkiem spoko ci poszło po za nazwami klas cssow i czasem nadmiernej strukturze w htmlu.

README.md Outdated
# Academy
Projekty wykonywane przez społeczność discorda
[helloroman](https://discordapp.com/invite/VTyJc9N)
<<<<<<< HEAD
Copy link
Owner

Choose a reason for hiding this comment

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

Head wskazuje na konflikty które nie rozwiazales, generalnie staraj się zakładać nowe readme dla swojego challengach jak chcesz je pullowac bo w ogólnym będzie no bardziej ogolnie

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

index.php Outdated
</head>
<body>
<div class="container">
<div class="container__coming-soon">
Copy link
Owner

Choose a reason for hiding this comment

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

Potrzebujesz tego diva? Możesz dać tą klasę na figure, zmieniłbym też nazwę klasy bo to jest niezależny element od containera.

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

index.php Outdated
<div class="container__coming-soon">
<figure><img src="assets/coming-soon-ribbon.png" alt="Coming Soon"></figure>
</div>
<header class="header">
Copy link
Owner

Choose a reason for hiding this comment

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

Wcięcia?

Copy link
Author

Choose a reason for hiding this comment

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

Wybacz, niedopatrzenie ;)

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

index.php Outdated
<h1>CODE ACADEMY</h1>
</header>
<main class="main">
<section class="main__form">
Copy link
Owner

Choose a reason for hiding this comment

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

Jeżeli masz tylko jedna sekcję w main to nie ma potrzeby jej wypisywania zostawiasz po prostu main, nie dawaj też sekcji klasy form to mylące bo to formularz nie jest tylko sekcja który go zawiera

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

index.php Outdated
<section class="main__form">
<h2>Leave your email here</h2>
<form action="backend/mailPushing.php" method="post">
<div class="main__form--flex-column">
Copy link
Owner

Choose a reason for hiding this comment

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

Potrzebujesz tego diva? Nie mógłby ostylowac po formie wtedy też nazwienictwo klas cssow u by się bardziej kupy trzymało, jeżeli starasz się w bramie pisać to staraj się formy trzymać w oddzielnym bloku bo nie zawsze będą w mainie, flex column na pierwszy rzut oka też nie wygląda jak modyfikator a jak element layoutu i powinien być oddzielna klasa, ogólnie strasznie długie nazwy klas masz nie wystarczyłby form lub form-email żeby było jaśniej

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione, jednak to z całą świadomością pozostawiam do ponownej oceny - nie jestem pewien nazw.
Owy flex--column służy jako pośrednik w uzyskaniu napisu "Invalid email".

index.php Outdated
<h2>Leave your email here</h2>
<form action="backend/mailPushing.php" method="post">
<div class="main__form--flex-column">
<label for="mail"><?php if(isset($invalidEmail)) echo $invalidEmail['errorMessage'] ?></label>
Copy link
Owner

Choose a reason for hiding this comment

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

Przy tym jak pisałem że bonus za rozwiązanie bez jsa bardziej chodziło mi o wersję cssow tego, ale fakt o phpie nie wspomniałem sprytnie to obraziłeś.

Copy link
Author

Choose a reason for hiding this comment

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

Owy php już nie istnieje. Użycie ciastek by nie działało w deep web ;)

@@ -0,0 +1,140 @@
@import url('https://fonts.googleapis.com/css?family=Lato:300');
Copy link
Owner

Choose a reason for hiding this comment

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

Lepiej nie importować czcionek za pomocą cssa

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

top: 0;
}

.container__coming-soon figure{
Copy link
Owner

Choose a reason for hiding this comment

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

Staraj się nie stylowac po tagach tym bardziej że możesz to połączyć z klasą wyżej w ogóle dość często powtarzasz margin 0 może lepiej to dać w * i stworzyć Simple reset

Copy link
Author

Choose a reason for hiding this comment

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

Z jednej strony lepiej. Jednak strona była tworzona na defaultowych marginach i paddingach, które mają dużą tutaj przewagę. Póki co zostawiam.

Copy link
Author

Choose a reason for hiding this comment

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

Co do stylowania po tagach poprawione ;)


.header figure{
/* width: 100vw; */
object-fit: cover;
Copy link
Owner

Choose a reason for hiding this comment

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

To jest potrzebne?

Copy link
Author

Choose a reason for hiding this comment

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

Poprawione. Wiadomość wysyłam w celu zapamiętania co do poprawy :)

@mateuszszmytko
Copy link

mateuszszmytko commented Jan 19, 2019

  1. Zazwyczaj nie pisze się słów wielkimi literami (CODE ACADEMY), użyj text-transform: uppercase tak by tylko wizualnie były wielkie.
  2. BEMa używaj tylko do wiązania elementów, które są częścią jednej całości. Czyli np. .header__logo nie powinno być zależne od .header. (Mógłbyś dać logo do footera i też powinno wyglądać tak samo, a nie byłoby częścią header)
    Tak samo z .main__form (ten form mógłby być poza main, np. w footerze i to nie powinno wpłynąc na jego styl).
  3. BEM to zawsze BLOK__ELEMENT--MODYFIKATOR, dlatego nigdy nie może być dwóch ELEMENT (np. header__logo__inner), jeśli już bardzo nie masz pomysłu na nazwę to wtedy łącz kolejne wyrazy używając -. Czyli header__logo-inner. Dzięki temu jest BLOK - header i ELEMENT - logo-inner. (już nie wspominając, że logo nie powinien być powiązany z header)
  4. Modyfikator (u ciebie form--email) nigdy nie może być użyty bez klasy którą się modyfikuje. Czyli jeśli piszesz form--email, to według BEM jest to edycja form, a nie jego "dziecko".
  5. LABEL nie może być pusty, ani nie może go nie być. Możemy dać mu content i go ukryć poprzez visibility: hidden

Moja propozycja (zawartość body)

<main class="page-content"> <!-- tutaj twój .container -->
    <header>
        <figure class="coming-soon">
            <img src="assets/coming-soon-ribbon.png" alt="Coming Soon">
        </figure>
        <figure class="logo">
            <img src="assets/undraw_developer_activity_bv83.svg" alt>
        </figure>
        <h1 class="page-title">Code Academy</h1>
    </header>
    <section class="contact-section">
        <h2 class="contact-section__title">Leave your email here</h2>
        <form action="#" class="contact-section__form form form--inline"> <!-- .contact-section__form dla stylowania zależnego od miejsca, czyli np margin. .form po prostu dla ostylowania formularza, .form--inline modyfikator sprawiający, że pola formularza są obok siebie -->
            <div class="form__group">
                <label for="mail">Your email</label>
                <input type="email" name="mail">
            </div>
            <div class="form__group">
                <button type="submit" class="btn">Get early access</button>
            </div>
        </form>
    </section>
    <footer class="footer">
        <p class="footer__text">MK&copy; 2019.</p>
        <p class="footer__text">Made with <img src="assets/love.png" alt="love"> in Poland</p>
        <p class="footer__text">We are using cookies to improve your experience.</p>
    </footer>
</main>

@IamMK
Copy link
Author

IamMK commented Jan 19, 2019

@mateuszszmytko poprawione

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.

3 participants