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
There is a table student in the mysql database, i...
Written in front Weibo components are component p...
Preface In fact, the humble "!" has man...
Table of contents 1. Project Environment 2. Proje...
In daily work, we may encounter a layout like thi...
1. If MySQL is not started successfully, check th...
MySQL full-text index is a special index that gen...
Serialization implementation InnoDB implements se...
1. Press win + R and type cmd to enter the DOS wi...
Table of contents getApp() Define variables at th...
(1) Introduction: clipboard.js is a lightweight J...
The syntax for an outer join is as follows: SELEC...
CSS adds scrolling to div and hides the scroll ba...
As the domestic network environment continues to ...
Table of contents 1. Introduction 2. Installation...