What is the color code for transparency in CSS?

后端 未结 10 1877
礼貌的吻别
礼貌的吻别 2021-02-20 11:27

Can anyone tell me what is the color code for transparency in CSS like white = \"#FFFFFF\"? As I am using following code, to convert the color codes into int:

Co         


        
相关标签:
10条回答
  • 2021-02-20 12:21

    Simply choose your background color of your item and specify the opacity separatly:

    div { background-color:#000; opacity:0.8; }
    
    0 讨论(0)
  • 2021-02-20 12:24

    Simply put:

    .democlass {
        background-color: rgba(246,245,245,0);
    }
    

    That should give you a transparent background.

    0 讨论(0)
  • 2021-02-20 12:25

    Or you could just put

    background-color: rgba(0,0,0,0.0);
    

    That should solve your problem.

    0 讨论(0)
  • 2021-02-20 12:27

    In the CSS write:

    .exampleclass {
        background:#000000;
        opacity: 10; /* you can always adjust this */
    }
    
    0 讨论(0)
提交回复
热议问题