具有输入元素的Foundation 6下拉菜单

时间:2018-11-23 17:13:17

标签: zurb-foundation

我试图在下拉菜单中进行输入,但是一旦单击输入,整个菜单就会隐藏,如何实现这种行为? 这是原始示例之一的codepen,仅添加了输入:

<input />

https://codepen.io/anon/pen/RqyroK

1 个答案:

答案 0 :(得分:0)

要实现所需的功能,可以更改此行:

<div class="col-sm-4" class="text-center"> <p v-html="mensagem"></p> <button class="btn btn-primary" @click="escolhe('pedra')">Pedra</button> <button class="btn btn-primary" @click="escolhe('papel')">Papel</button> <button class="btn btn-primary" @click="escolhe('tesoura')">Tesoura</button> <div class = "row"> <div class = "column-sm-12" class="text-center"> <button class="btn btn-danger" @click="reset()">Reiniciar</button> </div> </div> </div>

对此:

<ul class="dropdown menu" data-dropdown-menu>

有关所有下拉插件选项的说明,请 here