How to eliminate the influence of zooming in and out of elements on other elements

insert a row of 4 ICON, in the code to add the effect of hove magnification, but when one ICON is enlarged, it will affect the other, and there will be a sloshing effect, how to eliminate this effect? We have tried to adjust the space between each other through margin, but not without affecting each other.

clipboard.png

clipboard.png

                               <i class="fa fa-flag"></i>
                               <i class="fa fa-check-square-o"></i>
                                <i class="fa fa-eye"></i>
                                <i class="fa fa-edit"></i>
                            </a>

.fa-flag {margin: 5px 3px;}
.fa-flag:hover,
.fa-flag:target {color:-sharpff00ff; font-size:20px; margin: 1px 1px;}

Apr.01,2021

you can use transform to zoom in and out of the element, and the position occupied by the element does not increase after zooming in. Transform also has many useful features. For more information, please see the introduction to mdn .

transform: scale(2);

transform: rotate (360deg);-webkit-transform: rotate (360deg);


css3 transform can be solved. If compatibility is good, it is recommended to use positioning to detach it from the document stream.

Menu