2017-05-07 50 views
0

我在我的第一年編程和剛剛學習Java這就是爲什麼我完全失去了CSS和需要幫助。 我想編輯該代碼(不是我)如何創建與CSS不一致的透明背景?

===== CUSTOMIZABLE COLORS ===== 
:root { 
main-color: #057F95; 
hover-color: #045B6B; 
} 


===== CUSTOMIZABLE IMAGES ===== 
IMPORTANT: EVERY URL MUST BE HTTPS:// IN ORDER TO WORK IN DISCORD 
RECOMMENDATIONS: EVERY URL AT THE BOTTOM SHOULD BE THE SAME TO MAKE THE 
tHEM MATCH. (YOUR CHOICE) 
/*Change the url in .app to change the background behind chat */ 
.app { background-image: url("https://imgur.com/RG03PyX.png") !important; 
background-size: cover !important; } 

/*Change the url in .callout-backdrop to change the background when modal pop outs happen */ 

.callout-backdrop { background-color: black !important; background-image:  url("https://imgur.com/RG03PyX.png") !important; -webkit-transition: 0.3s all  ease; -o-transition: 0.3s all ease; -moz-transition: 0.3s all ease; transition:  0.3s all ease; background-size: cover !important; -webkit-filter:  brightness(75%); } 

/*Change the urls below to change the background of a profile modal pop up  */ 

.user-popout:before { 
    background-image: url("https://imgur.com/RG03PyX.png") !important; 
    content: "";position: absolute;left: 0;top: 0;height: 100%;width:  100%;z-index: -1;background-position: 50% 50%;-webkit-filter: blur(3px);-webkit- transform: scale(1.05);transform: scale(1.05);} 

#user-profile-modal .header:before { 
    background: -webkit-linear-gradient(top, rgba(0, 0, 0, .3), rgba(0, 0,  0, 0.5)), url("https://imgur.com/RG03PyX.png") !important; 
    background: linear-gradient(to bottom, rgba(0, 0, 0, .3), rgba(0, 0, 0,  0.5)), url("https://imgur.com/RG03PyX.png") !important; 
    content: "";position: absolute;left: 0;top: 0;width: 100%;height:  100%;z-index: -1;background-position: 50% 50%;background-size: cover  !important;-webkit-filter: blur(3px);-webkit-transform: scale(1.1);transform:  scale(1.1);} 

我嘗試不同勢的東西(顏色:透明,透明度:真,RGBA(0,0,0,0.1),能見度:隱藏,不透明度:0.5,做一個透明的背景和一些其他的,但他們沒有工作。 我希望你能找到我的問題的解決方案。

回答

0

color是在元素中的文本顏色的屬性。background: transparent就是你要找的人

+0

當我插入背景:透明背景只是黑色 – Captaincardbord

0

如果你想要透明的紅色,你會想要使用background-color: rgba(255,0,0,0.3)