Div can input content without using input as an input box to block the automatic input style

Div can input content without using input as an input box to block the automatic input style
Today I designed a dynamic window style for publishing, and found that the style automatically added by the browser when the mouse clicks on the input is inconsistent with the overall style of the website. Although this intelligent function of the browser is very advanced, it sometimes inevitably affects the overall consistency of the design.

Then I thought about whether it would be possible to not use input as an input box, so I changed it to

Copy code
The code is as follows:

<div class="content" contenteditable="true"></div>

I thought I could avoid the "smart" function of the browser, but the browser was too smart and the effect was exactly the same. I could only go to Baidu, and later I found that my CSS was not well prepared. Poor me (self-examination in progress)

There is such a property in css

Copy code
The code is as follows:

.content{outline:none;}

And this is something that CSS3 has already had, but I...

<<:  About if contains comma expression in JavaScript

>>:  mysql startup failure problem and scenario analysis

Recommend

About the problem of running git programs in jenkins deployed by docker

1. First, an error message is reported when assoc...

Vue realizes the logistics timeline effect

This article example shares the specific code of ...

Why do code standards require SQL statements not to have too many joins?

Free points Interviewer : Have you ever used Linu...

Summary of pitfalls of using nginx as a reverse proxy for grpc

background As we all know, nginx is a high-perfor...

A brief discussion on two current limiting methods in Nginx

The load is generally estimated during system des...

Detailed explanation of asynchronous programming knowledge points in nodejs

Introduction Because JavaScript is single-threade...

Linux checkup, understand your Linux status (network IO, disk, CPU, memory)

Table of contents 1. Core commands 2. Common comm...

Detailed explanation of how to view the number of MySQL server threads

This article uses an example to describe how to v...

A brief introduction to the command line tool mycli for operating MySQL database

GitHub has all kinds of magic tools. Today I foun...

Use of Linux watch command

1. Command Introduction The watch command execute...

js realizes the image cutting function

This article example shares the specific code of ...

HTML+CSS merge table border sample code

When we add borders to table and td tags, double ...

How to completely uninstall Docker Toolbox

Docker Toolbox is a solution for installing Docke...

React implements the addition, deletion, modification and query of todolist

Table of contents Take todolist as an example The...