Answer the question
In order to leave comments, you need to log in
How to change stroke of svg icon when hovering over parent block?
How to change color of svg icon when hovering over parent block? I am writing with sass.
<div class="subject">
<div class="subject-image">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0)">
<path d="M19 6.00001H14.321C13.9224 5.71592 13.4744 5.50839 13 5.38801V5.00001L16.53 3.34801C16.6747 3.25832 16.7941 3.13318 16.8769 2.98443C16.9598 2.83568 17.0032 2.66825 17.0032 2.49801C17.0032 2.32776 16.9598 2.16033 16.8769 2.01158C16.7941 1.86283 16.6747 1.73769 16.53 1.64801L13.33 0.148006C13.0802 0.0312575 12.8049 -0.0204779 12.5297 -0.0023985C12.2545 0.0156809 11.9883 0.102989 11.7559 0.251422C11.5235 0.399855 11.3323 0.604601 11.2002 0.846656C11.068 1.08871 10.9992 1.36023 11 1.63601V5.38801C10.5258 5.50822 10.0782 5.71577 9.68 6.00001H5C3.67441 6.00159 2.40356 6.52889 1.46622 7.46623C0.528882 8.40356 0.00158786 9.67441 0 11L0 21C0 21.7957 0.31607 22.5587 0.87868 23.1213C1.44129 23.6839 2.20435 24 3 24H21C21.7956 24 22.5587 23.6839 23.1213 23.1213C23.6839 22.5587 24 21.7957 24 21V11C23.9984 9.67441 23.4711 8.40356 22.5338 7.46623C21.5964 6.52889 20.3256 6.00159 19 6.00001ZM21.816 10H19.657C18.8618 9.99798 18.0995 9.68208 17.536 9.12101L16.414 8.00001H19C19.6183 8.00257 20.2206 8.19609 20.7247 8.55409C21.2288 8.9121 21.6099 9.4171 21.816 10ZM5 8.00001H7.586L6.464 9.12101C5.90047 9.68208 5.13821 9.99798 4.343 10H2.184C2.39008 9.4171 2.77123 8.9121 3.2753 8.55409C3.77937 8.19609 4.38174 8.00257 5 8.00001ZM13 22H11V19C11 18.7348 11.1054 18.4804 11.2929 18.2929C11.4804 18.1054 11.7348 18 12 18C12.2652 18 12.5196 18.1054 12.7071 18.2929C12.8946 18.4804 13 18.7348 13 19V22ZM21 22H15V19C15 18.2044 14.6839 17.4413 14.1213 16.8787C13.5587 16.3161 12.7956 16 12 16C11.2044 16 10.4413 16.3161 9.87868 16.8787C9.31607 17.4413 9 18.2044 9 19V22H3C2.73478 22 2.48043 21.8946 2.29289 21.7071C2.10536 21.5196 2 21.2652 2 21V12H4.343C4.99982 12.0016 5.65043 11.873 6.25721 11.6215C6.86398 11.37 7.41487 11.0008 7.878 10.535L10.586 7.82801C10.9611 7.45306 11.4697 7.24243 12 7.24243C12.5303 7.24243 13.0389 7.45306 13.414 7.82801L16.122 10.535C16.5851 11.0008 17.136 11.37 17.7428 11.6215C18.3496 11.873 19.0002 12.0016 19.657 12H22V21C22 21.2652 21.8946 21.5196 21.7071 21.7071C21.5196 21.8946 21.2652 22 21 22ZM7 15C7 15.2652 6.89464 15.5196 6.70711 15.7071C6.51957 15.8946 6.26522 16 6 16H5C4.73478 16 4.48043 15.8946 4.29289 15.7071C4.10536 15.5196 4 15.2652 4 15C4 14.7348 4.10536 14.4804 4.29289 14.2929C4.48043 14.1054 4.73478 14 5 14H6C6.26522 14 6.51957 14.1054 6.70711 14.2929C6.89464 14.4804 7 14.7348 7 15ZM7 19C7 19.2652 6.89464 19.5196 6.70711 19.7071C6.51957 19.8946 6.26522 20 6 20H5C4.73478 20 4.48043 19.8946 4.29289 19.7071C4.10536 19.5196 4 19.2652 4 19C4 18.7348 4.10536 18.4804 4.29289 18.2929C4.48043 18.1054 4.73478 18 5 18H6C6.26522 18 6.51957 18.1054 6.70711 18.2929C6.89464 18.4804 7 18.7348 7 19ZM20 15C20 15.2652 19.8946 15.5196 19.7071 15.7071C19.5196 15.8946 19.2652 16 19 16H18C17.7348 16 17.4804 15.8946 17.2929 15.7071C17.1054 15.5196 17 15.2652 17 15C17 14.7348 17.1054 14.4804 17.2929 14.2929C17.4804 14.1054 17.7348 14 18 14H19C19.2652 14 19.5196 14.1054 19.7071 14.2929C19.8946 14.4804 20 14.7348 20 15ZM20 19C20 19.2652 19.8946 19.5196 19.7071 19.7071C19.5196 19.8946 19.2652 20 19 20H18C17.7348 20 17.4804 19.8946 17.2929 19.7071C17.1054 19.5196 17 19.2652 17 19C17 18.7348 17.1054 18.4804 17.2929 18.2929C17.4804 18.1054 17.7348 18 18 18H19C19.2652 18 19.5196 18.1054 19.7071 18.2929C19.8946 18.4804 20 18.7348 20 19ZM14 12C14 12.3956 13.8827 12.7822 13.6629 13.1111C13.4432 13.44 13.1308 13.6964 12.7654 13.8478C12.3999 13.9991 11.9978 14.0387 11.6098 13.9616C11.2219 13.8844 10.8655 13.6939 10.5858 13.4142C10.3061 13.1345 10.1156 12.7781 10.0384 12.3902C9.96126 12.0022 10.0009 11.6001 10.1522 11.2346C10.3036 10.8692 10.56 10.5568 10.8889 10.3371C11.2178 10.1173 11.6044 10 12 10C12.5304 10 13.0391 10.2107 13.4142 10.5858C13.7893 10.9609 14 11.4696 14 12Z" fill="#111238"/>
</g>
<defs>
<clipPath id="clip0">
<rect width="24" height="24" fill="white"/>
</clipPath>
</defs>
</svg>
</div>
<p class="specification">Образование</p>
.subject
background: #F2F3F6
border-radius: 10px
text-align: center
width: 166px
&:hover
background: #1A75E8
color: #ffff
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question