Bootstrap 4 从下拉按钮中删除插入符号

问题描述 投票:0回答:5
twitter-bootstrap bootstrap-4
5个回答
72
投票

只需删除

dropdown-toggle

这是一个例子: https://jsfiddle.net/ydnosrLw/


41
投票

它是用CSS完成的。做类似的事情:

.dropdown-toggle:after { content: none }

37
投票

您可以通过从元素中删除

dropdown-toggle
类来删除 Bootstrap 4 中的插入符号。所以代替这个:

<button class="btn btn-outline-secondary dropdown-toggle" ...>

您的按钮将是

<button class="btn btn-outline-secondary" ...>

这不会有任何副作用,并且它仍然可以作为下拉菜单正常运行。


8
投票

在 Bootstrap 4 中,您可以通过设置

$enable-caret
sass 变量
false
来删除插入符号表单下拉按钮。但您必须在导入 bootstrap sass 文件之前设置此变量。

// Your variable overrides
$enable-caret: false

// Bootstrap and its default variables
@import "node_modules/bootstrap/scss/bootstrap";

0
投票

我会在电话中正常使用下拉菜单,Apple rimane contornato di blu come se prende il contorno del bottone prima tu.

落下 行动 另一个动作 这里还有其他东西 questo è ili se qualcuno mi dà qualche suggerimento
© www.soinside.com 2019 - 2024. All rights reserved.