vue.js 彈層

來源:互聯網
上載者:User

標籤:cli   auto   ret   padding   show   vue   color   ext   system   

 

<div class="open-box"  v-if="SystemShow" @click="ColseShow">
            <div class="open-box-content">
                <h3>系統提示</h3>
                <p>系統檢測到您是天下醫家的醫護人員
                    <br>可以通過APP進行點餐
                    <br>獲得更多優惠</p>
                <div class="open-box-btn">
                    <div class="open-box-btn-left">
                        <button>繼續使用</button>
                    </div>
                    <div class="open-box-btn-right">
                        <button>下載天下醫家</button>
                    </div>
                </div>
            </div>
        </div>

<style>

.open-box {
    position: fixed;
    background: rgba(0, 0, 0, 0.4);
    width: 100%;
    height: 100%;
    left: 0;   /**定位時需注意  不然ios找不到顯示地方**/
    top: 0;  /**定位時需注意  不然ios找不到顯示地方**/
    z-index: 100;
    color: #fff;
    text-align: center;
}

.open-box-content {
    background: #fff;
    border-radius: 3px;
    width: 305px;
    margin: 0 auto;
    margin-top: 35%;
}

.open-box-content h3 {
    width: 100%;
    color: #5089fc;
    text-align: center;
    border-bottom: solid 1px #5089fc;
    height: 55px;
    line-height: 55px;
    font-size: 21px;
}

.open-box-content p {
    width: 100%;
    text-align: center;
    line-height: 24px;
    color: #333333;
    font-size: 16px;
    margin-top: 20px;
}

.open-box-btn {
    width: 100%;
    overflow: hidden;
    padding: 25px 0 18px;
}

.open-box-btn-left {
    width: 50%;
    float: left;
}

.open-box-btn-left button {
    width: 90%;
    border-radius: 2px;
    border: none;
    background: #e6e6e6;
    color: #656565;
    height: 40px;
    line-height: 38px;
    font-size: 16px;
    outline: none;
    cursor: pointer;
}

.open-box-btn-right {
    width: 50%;
    float: right;
}

.open-box-btn-right button {
    width: 90%;
    border-radius: 2px;
    border: none;
    background: #5089fc;
    color: #ffffff;
    height: 40px;
    line-height: 38px;
    font-size: 16px;
    outline: none;
    cursor: pointer;
}

</style>

<script>
export default {
    data() {
            return {
           
                OpenAppShwo: true

            }
        },
        methods: {
          //在哪調用  就在哪@click="方法名" 
            OpenApp() {
                this.OpenAppShwo = !this.OpenAppShwo

            },
            CloseAp() {

                this.OpenAppShwo = !this.OpenAppShwo
            }
        }
}
</script>

vue.js 彈層

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.