Skip to content

Commit 0a50279

Browse files
committed
[PRAC/cont] Add :hover/scale for "arrow-icon"
Adding small effect for drop-btn "arrow-icon" (in contact row). Worth noting: - an attempt to exclude unclear flickering of drop-btn (at initial hover), by means of transform: translateZ(0). core: B-3 / JS-BL
1 parent 16ad187 commit 0a50279

File tree

2 files changed

+25
-1
lines changed

2 files changed

+25
-1
lines changed

core-courses/3-js-basic-level/practicum-js-basic-level/sb-crm-client/css/modal-add.css

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,11 @@
169169
font-size: 12px;
170170
background: transparent;
171171
outline: none;
172+
/* попытка исключить не понятные мерцания кнопки */
173+
transform: translateZ(0);
174+
/* will-change: border-color, transform, opacity, box-shadow; */
175+
/* backface-visibility: hidden; */
176+
/* -webkit-font-smoothing: antialiased; */
172177
}
173178

174179
.modal__add-body-add-contact-drop-btn:after {
@@ -183,6 +188,7 @@
183188
background-repeat: no-repeat;
184189
background-position: center;
185190
background-size: contain;
191+
transition: transform 0.1s ease;
186192
/* отработка клика и на arrow-icon */
187193
pointer-events: none;
188194
}
@@ -289,9 +295,9 @@
289295
background-repeat: no-repeat;
290296
background-position: center;
291297
background-size: contain;
298+
transition: opacity 0.2s ease;
292299
/* отработка клика и на arrow-icon */
293300
pointer-events: none;
294-
transition: opacity 0.2s ease;
295301
}
296302

297303
.modal__add-body-add-x-btn:before {
@@ -481,6 +487,14 @@
481487
background-color: var(--select-gray);
482488
}
483489

490+
.modal__add-body-add-contact-drop-btn:hover:after {
491+
transform: translateY(-50%) scale(1.2);
492+
}
493+
494+
.modal__add-body-add-contact-drop-btn.arrow-rotate:hover:after {
495+
transform: translateY(-50%) rotate(180deg) scale(1.2);
496+
}
497+
484498
.modal__add-body-add-x-btn:hover:not(:active) {
485499
border-color: var(--bootstrap-red);
486500
box-shadow: 0 0 0 .25rem rgba(220, 53, 69, .25);
Lines changed: 10 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)