HTML CODE
<button
id="scroll-top"
(click)="scrollTop()"
style="background: url('scroll.svg') center 0px no-repeat"
>
Go to Top
</button>
CSS CODE
#scroll-to-top {
display: flex;
justify-content: center;
align-items: end;
position: fixed;
width: 90px;
height: 66px;
bottom: 50px;
right: 6px;
z-index: 999;
opacity: 0;
transition: all .2s ease;
transform: translateY(100px);
border: none;
cursor: pointer;
color: green;
font-size: 12px;
}
I want to change the outline-color(when focus is on button) and text color of my button to white when the background is dark(i.e when background is having any color other than white).
I have tried using mix-blend-mode and filter properties but i am bit confused here.
NOTE: i don't want to explicitly set the outline-color and text color as white rather it should be decided dynamically based on the background color of the button