We usually have a scanning box when we open the camera, and sometimes a static QR code will also add a frame for focusing and facilitating scanning. Here's how to implement a frame through CSS Effect: The code is as follows: html: <div class="img-box"> <img class="code" src="https://image-static.segmentfault.com/149/570/149570997-5b987cc928d69_articlex"> </div> css: .img-box { background: linear-gradient(#ae0000, #ae0000) left top, linear-gradient(#ae0000, #ae0000) left top, linear-gradient(#ae0000, #ae0000) right top, linear-gradient(#ae0000, #ae0000) right top, linear-gradient(#ae0000, #ae0000) right bottom, linear-gradient(#ae0000, #ae0000) right bottom, linear-gradient(#ae0000, #ae0000) left bottom, linear-gradient(#ae0000, #ae0000) left bottom; background-repeat: no-repeat; background-size: 2px 20px, 20px 2px; height: 116px; width: 116px; } .code { height: 110px; width: 110px; margin-top: 2px; margin-left:2px; border: 1px solid #ae0000; } The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. |
<<: Implementation of tomcat deployment project and integration with IDEA
Table of contents 1. When inserting or modifying ...
What is DNS The full name of DNS is Domain Name S...
Written in front Often, after we install Nginx ba...
Page turning problem scenario B and C are on the ...
At first I thought it was a speed issue, so I late...
This article example shares the specific code of ...
Now most of the Docker images are based on Debian...
Table of contents 1. Database Engine 1.1 View dat...
The floating-point types supported in MySQL are F...
Preface: When we want to clear a table, we often ...
Table of contents Overview Example Why is it need...
Table of contents Master-slave replication mechan...
The <input> tag The <input> tag is us...
There are many seemingly true "rumors" ...
This article example shares the specific code of ...