2017-05-12 182 views
-5

我怎樣才能讓CSS這樣的,如下圖:我怎樣才能讓CSS曲線和按鈕的下方

enter image description here

<div class="logo"> 
    <img src="assets/logo/1.jpg"/> 
</div> 
<div class="btn"> 
    <button>First</button> 
    <button>First</button> 
    <button>First</button> 
    <button>First</button> 
</div> 
+0

#2是不是把別人爲你做。嘗試自己做,並分享你的代碼。 – Petroff

+0

你究竟想要拉開什麼 - 中間有按鈕的曲線?你有嘗試過什麼嗎?我沒有看到你的任何CSS。 –

+0

使用svg進行圓角效果 –

回答

0

你可以做到這一點與生成的內容。

我已經創建了一個例子給你

.container { 
 
    width: 500px; 
 
} 
 

 
.logo { 
 
    position: relative; 
 
    overflow: hidden; 
 
    z-index: 1; 
 
} 
 
.logo:after { 
 
    content: ""; 
 
    width: 300%; 
 
    height: 500px; 
 
    background-color: gray; 
 
    position: absolute; 
 
    bottom: -96%; 
 
    left: -100%; 
 
    z-index: 2; 
 
    border-radius: 50%; 
 
} 
 

 
.btn { 
 
    background-color: gray; 
 
    padding: 20px; 
 
}
<div class="container"> 
 
<div class="logo"> 
 
    <img src="https://placeimg.com/640/480/any"/> 
 
</div> 
 
    <div class="btn"> 
 
    <button>First</button> 
 
    <button>First</button> 
 
    <button>First</button> 
 
    <button>First</button> 
 
</div> 
 
</div>

和一支筆:https://codepen.io/faw/pen/XRqdOq