HTML / CSS - 添加抽象形状作为背景

时间:2017-06-08 19:19:42

标签: html css twitter-bootstrap

我想使用bootstrap构建类似this的东西。目前我所建立的是:

<html>
<head>
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>

    <style>

        .section-1 {
            height: 100vh;
            padding-top: 200px;
            text-align: center;
            background: "fff";
        }

        #shape {
            width: 500px;
            height: 500px;
            background: yellow;

            -webkit-clip-path: polygon(0 24%, 89% 0, 100% 40%, 55% 88%);
            clip-path: polygon(0 24%, 89% 0, 100% 40%, 55% 88%);
        }

    </style>
</head>
<body>
     <!-- Intro Section -->
    <section id="tab-1" class="section-1">
        <div class="container">
            <div class="row">
                <div class="col-md-5 col-md-offset-3">

                    <h1><b>UI & UX DESIGN STUDIO</b></h1>
                    <p class="text-right"> <b> UI/UX </b> <i>Design</i></p>
                    <p class="text-right"> <b> Brand Identity</b> <i>Design</i></p>
                    <p class="text-right"> <b> Web & Mobile</b> <i>Development</i></p>

                </div>

            </div>
        </div>
    </section>

</body>

在上面的块中,id形状是图像中的边框形状(一个没有实体)。我应该如何添加此形状作为我的内容的背景?

0 个答案:

没有答案