Get the App
SLTechnology News&Howtos  ›  Development  › 

How to write css transparent frame

Shulou Source: shulou.com Published: 2022-06-01 06:27:36 09月10日 Update

This article mainly explains "how to write css transparent frame". Interested friends may wish to have a look at it. The method introduced in this paper is simple, fast and practical. Now let the editor take you to learn "how to write css transparent frame"!

One: can css write a transparent frame?

In css, you can write transparent borders, the key is how to write, how to write? Transparency is also considered to be a color attribute, but there is no such value in the color attribute, but we can use div to achieve a transparent border.

Second: how to make the frame transparent by css

Using RGBA, red and green and blue as the parameter, the three percentages of red and green and blue can be set to a number between 0 and 1, but never negative. The syntax is as follows:

.div {background:rgba (200recover20050.75);}

Next, we add a style to div. First, set the top and bottom left and right borders, and set four borders to the same height and width. The code is as follows:

Div

{

Width:100px;height:100px

Border-top:10pxsolidrgba (2000.25th)

Border-right:10pxsolidrgba (2007.0,200,200,0.5)

Border-bottom:10pxsolidrgba (2000.75)

Border-left:10pxsolidrgba (200ju 200ju 200jue 1)

}

At this point, I believe you have a deeper understanding of "how to write css transparent frame". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Tags: Border content attributes color learning practical deeper same up and down left and right next three up and down between code key interest parameters at the same time practical practical Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Technology Docker Linux MariaDB Xiaomi