|
Title: I have a window component requirement Post by: fengdie on September 06, 2018, 10:59:28 PM 我想要实现窗口,最大化、最小化、还原、关闭等操作。jquery版有。vue版是否考虑支持
I want to implement window, maximize, minimize, restore, close, etc. The jquery version has. Does the vue version consider support? 我尝试在对话框组件中,使用slot来操作。但是会出现两个panel-tool元素 I tried to use time slots in the dialog component,But there will be two panel-tool elements Code: <Dialog ref="d1" :title="'Basic Dialog'" :dialogStyle="{width:'400px',height:'200px'}" :draggable="true" :resizable="true" > <template slot="header"> <div class="panel-title"> 窗口标题 </div> <div class="panel-tool"> <a href="javascript:;" class="panel-tool-min"></a> <a href="javascript:;" class="panel-tool-max"></a> </div> </template> <p>内容</p> </Dialog> Title: Re: I have a window component requirement Post by: jarry on September 06, 2018, 11:44:47 PM This code works fine.
Code: <Dialog ref="d1" :draggable="true" :dialogStyle="dialogStyle"> <template slot="header"> <div class="panel-title">header</div> <div class="panel-tool" style="right:20px"> <a href="javascript:;" class="panel-tool-min"></a> <a href="javascript:;" class="panel-tool-max" @click="max()"></a> </div> </template> </Dialog> |