Skip to content

Commit 3ec80d3

Browse files
authored
Merge pull request #5 from aleks-yustas/master
2 parents 1a5cdec + 0056628 commit 3ec80d3

File tree

13 files changed

+101
-38
lines changed

13 files changed

+101
-38
lines changed

source/catalog.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ <h2 class="contact__title">Приглашаем к&nbsp;сотрудничест
331331
</main>
332332
<footer class="footer">
333333
<div class="footer__wrapper page__centerer">
334-
<a class="footer__item logo logo--footer" href="#" aria-label="Главная Кэт енерджи" >
334+
<a class="footer__item logo logo--footer" href="index.html" aria-label="Главная Кэт енерджи">
335335
<span class="visually-hidden">Главная Кэт энерджи</span>
336336
</a>
337337
<section class="footer__item social">

source/styles/blocks/banner.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
position: static;
4848

4949
grid-template-columns: 416px 1fr;
50-
padding-top: 7px;
50+
padding-top: 0;
5151
padding-bottom: 0;
5252
padding-left: 80px;
5353
}
@@ -161,6 +161,7 @@
161161

162162
@media (width >= #{$desktop-width}) {
163163
grid-column: 1;
164+
margin-bottom: 51px;
164165
}
165166
}
166167

source/styles/blocks/button.scss

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@
1616
cursor: pointer;
1717
outline: none;
1818

19-
&:hover,
20-
&:focus-visible {
19+
&:hover {
2120
background-color: $bg-color-accent-bright;
2221
}
2322

@@ -27,6 +26,18 @@
2726
background-color: $bg-color-accent-bright;
2827
}
2928

29+
&:focus-visible {
30+
outline: 2px solid $text-color-accent;
31+
outline-offset: 2px;
32+
}
33+
34+
@supports not selector(:focus-visible) {
35+
&:focus {
36+
outline: 2px solid $text-color-accent;
37+
outline-offset: 2px;
38+
}
39+
}
40+
3041
@supports not selector(:focus-visible) {
3142
&:focus {
3243
background-color: $bg-color-accent-bright;
@@ -37,8 +48,7 @@
3748
color: $text-color-main;
3849
background-color: $bg-color-lighten;
3950

40-
&:hover,
41-
&:focus-visible {
51+
&:hover {
4252
background-color: $bg-color-light;
4353
}
4454

@@ -47,11 +57,5 @@
4757

4858
background-color: $bg-color-light;
4959
}
50-
51-
@supports not selector(:focus-visible) {
52-
&:focus {
53-
background-color: $bg-color-light;
54-
}
55-
}
5660
}
5761
}

source/styles/blocks/card.scss

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
}
1616

1717
@media (width >= #{$desktop-width}) {
18-
padding: 77px 50px 37px 52px;
18+
padding: 77px 50px 59px 52px;
1919
}
2020

2121
&::before {
@@ -147,7 +147,7 @@
147147
.card__text {
148148
position: relative;
149149

150-
margin: 0 0 22px;
150+
margin: 0;
151151

152152
font-family: $main-font;
153153
color: $text-color-main;
@@ -157,7 +157,7 @@
157157
}
158158

159159
&:last-of-type {
160-
margin-bottom: 42px;
160+
margin-bottom: 41px;
161161
}
162162

163163
@media (width < #{$tablet-width}) {
@@ -177,11 +177,15 @@
177177
}
178178

179179
@media (#{$tablet-width} <= width < #{$desktop-width}) {
180-
margin-bottom: 33px;
180+
&:last-of-type {
181+
margin-bottom: 51px;
182+
}
181183
}
182184

183185
@media (width >= #{$desktop-width}) {
184-
margin-bottom: 7px;
186+
&:last-of-type {
187+
margin-bottom: 26px;
188+
}
185189
}
186190
}
187191

@@ -204,17 +208,26 @@
204208
transition: 0.08s linear all;
205209
outline: none;
206210

211+
&:focus-visible {
212+
outline: 2px solid $text-color-accent;
213+
outline-offset: 2px;
214+
}
215+
216+
@supports not selector(:focus-visible) {
217+
&:focus {
218+
outline: 2px solid $text-color-accent;
219+
outline-offset: 2px;
220+
}
221+
}
222+
207223
@media (width >= #{$tablet-width}) {
224+
gap: 25px;
208225
border-top: none;
209226

210227
font-size: 20px;
211228
line-height: 30px;
212229
}
213230

214-
@media (width >= #{$desktop-width}) {
215-
gap: 25px;
216-
}
217-
218231
&:active {
219232
opacity: 0.3;
220233
}

source/styles/blocks/catalog-item.scss

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@
6767
}
6868

6969
.catalog-item__image {
70+
--outline-offset: -4px;
71+
7072
grid-column: 1 / 2;
7173
grid-row: 1 / 3;
7274
display: flex;
@@ -90,6 +92,8 @@
9092
}
9193

9294
.catalog-item__link {
95+
--outline-offset: 2px;
96+
9397
color: inherit;
9498
text-decoration: none;
9599
}
@@ -98,18 +102,23 @@
98102
.catalog-item__link {
99103
outline: none;
100104

101-
&:hover,
102-
&:focus-visible {
105+
&:hover {
103106
opacity: 0.8;
104107
}
105108

106109
&:active {
107110
opacity: 0.6;
108111
}
109112

113+
&:focus-visible {
114+
outline: 2px solid $text-color-accent;
115+
outline-offset: var(--outline-offset);
116+
}
117+
110118
@supports not selector(:focus-visible) {
111119
&:focus {
112-
opacity: 0.8;
120+
outline: 2px solid $text-color-accent;
121+
outline-offset: var(--outline-offset);
113122
}
114123
}
115124
}

source/styles/blocks/creators.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
color: $text-color-main;
88
text-decoration: none;
9+
outline: none;
910

1011
@media (width >= #{$tablet-width}) {
1112
justify-content: flex-end;

source/styles/blocks/footer.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.footer {
2-
padding-block: 40px;
2+
padding-block: 39px;
33

44
background-color: $bg-color-lighten;
55

source/styles/blocks/header.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
@media (width >= #{$desktop-width}) {
1313
grid-template-columns: 202px 1fr 50%;
14-
padding: 55px 0 30px;
14+
padding: 55px 0 27px;
1515
}
1616
}
1717

source/styles/blocks/logo.scss

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,18 @@
77
pointer-events: none;
88
}
99

10+
&:focus-visible {
11+
outline: 2px solid $text-color-accent;
12+
outline-offset: 2px;
13+
}
14+
15+
@supports not selector(:focus-visible) {
16+
&:focus {
17+
outline: 2px solid $text-color-accent;
18+
outline-offset: 2px;
19+
}
20+
}
21+
1022
&--main {
1123
grid-template-columns: 1fr 101px 1fr;
1224
align-items: center;
@@ -27,20 +39,13 @@
2739
height: 60px;
2840
}
2941

30-
&:hover,
31-
&:focus-visible {
42+
&:hover {
3243
opacity: 0.8;
3344
}
3445

3546
&:active {
3647
opacity: 0.6;
3748
}
38-
39-
@supports not selector(:focus-visible) {
40-
&:focus {
41-
opacity: 0.8;
42-
}
43-
}
4449
}
4550

4651
&--footer {
@@ -49,6 +54,10 @@
4954
grid-template-columns: 1fr;
5055
padding: 0;
5156

57+
&:focus-visible::before {
58+
background-color: #3e3e3e;
59+
}
60+
5261
@supports not selector(:focus-visible) {
5362
&:focus::before {
5463
background-color: #3e3e3e;
@@ -59,6 +68,7 @@
5968
--mask-position: start;
6069

6170
justify-content: flex-start;
71+
width: fit-content;
6272
padding: 0;
6373

6474
text-align: left;

source/styles/blocks/nav.scss

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,7 @@
170170
margin-right: 20px;
171171
border-radius: 0;
172172
border: none;
173+
outline: none;
173174

174175
background-color: $bg-color-main;
175176
cursor: pointer;
@@ -178,6 +179,18 @@
178179
display: none;
179180
}
180181

182+
&:focus-visible {
183+
outline: 2px solid $text-color-accent;
184+
outline-offset: 2px;
185+
}
186+
187+
@supports not selector(:focus-visible) {
188+
&:focus {
189+
outline: 2px solid $text-color-accent;
190+
outline-offset: 2px;
191+
}
192+
}
193+
181194
&::before {
182195
content: "";
183196

0 commit comments

Comments
 (0)