- objective-c - iOS 5 : Can you override UIAppearance customisations in specific classes?
- iphone - 如何将 CGFontRef 转换为 UIFont?
- ios - 以编程方式关闭标记的信息窗口 google maps iOS
- ios - Xcode 5 - 尝试验证存档时出现 "No application records were found"
如何防止 Typeahead.js 拆分我的 Twitter Bootstrap 3 输入组?每当我将 Typeahead javascript 指向属于输入组的文本区域时,连接的文本区域和提交按钮就会停止连接。这只是 Typeahead 中的一个错误,还是有解决方法?
不加载 Typeahead.JS:
使用 Typeahead.JS:
我的原始 HTML:
<div class="col-sm-4 hidden-xs">
<form class="navbar-form" role="search">
<div class="input-group">
<input type="text" id="tags" class="form-control" name="q">
<div class="input-group-btn">
<button class="btn btn-default" type="submit">Search</button>
</div>
</div>
</form>
</div>
这是 Typeahead 对这个 HTML 所做的:
<div class="col-sm-4 hidden-xs">
<form class="navbar-form" role="search">
<div class="input-group">
<span class="twitter-typeahead" style="position: relative; display: inline-block;">
<input type="text" class="form-control tt-hint" disabled="" autocomplete="off" spellcheck="false" style="position: absolute; top: 0px; left: 0px; border-color: transparent; box-shadow: none; background-attachment: scroll; background-clip: border-box; background-color: rgb(255, 255, 255); background-image: none; background-origin: padding-box; background-size: auto; background-position: 0% 0%; background-repeat: repeat repeat;">
<input type="text" id="tags" class="form-control tt-input" name="q" autocomplete="off" spellcheck="false" dir="auto" style="position: relative; vertical-align: top; background-color: transparent;">
<pre aria-hidden="true" style="position: absolute; visibility: hidden; white-space: nowrap; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; font-style: normal; font-variant: normal; font-weight: 400; word-spacing: 0px; letter-spacing: 0px; text-indent: 0px; text-rendering: auto; text-transform: none;">
</pre>
<span class="tt-dropdown-menu" style="position: absolute; top: 100%; left: 0px; z-index: 100; display: none;"><div class="tt-dataset-0"></div>
</span>
</span>
<div class="input-group-btn">
<button class="btn btn-default" type="submit">Search</button>
</div>
</div>
</form>
</div>
最佳答案
.twitter-typeahead{ float:left; width:100%}
关于javascript - Typeahead.js 干扰 Bootstrap 输入组,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22276536/
这是我的 + 部分: function insert(){ var linkElement = document.getElementById("BackButton"); var linkEl
我有两辆 buggy 在轨道上移动,它们都使用超声波测量模块来检测路径中的障碍物,并由 Arduino 微 Controller 控制。两个超声波传感器以相同的频率工作,并且这个频率不能改变。两个超声
希望能快速解决这个问题。我有一个用文件位置替换特定值的脚本。不幸的是,该位置似乎经常包含\n 或 n\(因为当前目录位于临时文件夹中),导致该行中断或从该行中完全删除自身,从而使文件夹位置无效。 临时
我使用的是 Mac OSX 10.10.1。我通常使用brew或pip来安装所有东西。我注意到我的 virtualenv 总是抓取我本地安装的所有 Python 包。我通过删除我的 $PYTHONPA
我正在尝试使用 str_replace 将两个字母的语言缩写转换为完整的单词。我遇到的问题是它们在回显时会相互影响。 $lang = str_replace("en", "English", $lan
我已经创建了用于结束通话的 aidl 文件 ITelephony.aidl。现在,在通话结束之前,我需要生成正在进行的通话中的语音,以便听众认为接下来的工作有问题。我尝试通过三种方式自己解决这个问题:
使用这个查询,我得到了我需要的每个客户下的订单数量的结果。但是,当我在 SELECT 字段中使用 SUM(OrderLine.ActualPrice) 并使用内部联接将 Order 表链接到包含价格的
在 Spring Boot 应用程序中,仅使用注释,我想实现安全性 我已将 @EnableGlobalMethodSecurity(jsr360Enabled=true) 添加到配置类。该类还有一个
我一直在 Linux 下开发一个多线程程序,对信号处理有特殊要求。例如,我需要程序打印单个 Ctrl-C 输入的统计信息。 我使用 pthread_sigmask 和 sigwait 实现了这一点,即
作为我第一次涉足 Dynamic Scala 领域,我想我会尝试通过 applyDynamic 访问 bean 属性。 我的第一个非常粗略的剪裁是 trait BeanProperties ext
我知道这是一个令人沮丧的话题,但我尝试遵循文档和其他类似的帖子。 我的问题是,除非重新加载页面,否则 JS 将无法工作。 我有以下 JS: $(function() { $('a.form-sho
我正在使用 JQuery Ajax 从服务器获取脚本。 $.ajax({ url: src, type: "GET", dataType: "script", time
我正在尝试根据每个产品的选定数量分别输出计算价格。我尝试复制代码并重命名所有变量,但输出是由各种增加/减少按钮触发的。 这是目前的代码: $(".incr-btn_mobile").on("click
这个问题在这里已经有了答案: 关闭 10 年前。 Possible Duplicate: jQuery in Greasemonkey 1.0 conflicts with websites usi
我在一个 iOS 应用程序 (Obj-C) 中有一个 View ,它在中心有一个 ImageView ,紧接着在其下方有一个 slider 。 ImageView 显示专辑封面, slider 可用于
我有一个 View Controller ,将 UITapGestureRecognizer 附加到它的主 UIView,并使用户能够点击屏幕以使状态、导航和工具栏重新出现/消失(如照片应用程序)。我
我正在尝试在我的应用程序中设置 log4j,但我的一个第三方 JAR 似乎以某种方式不断将我的日志级别设置为“关闭”。它仅在执行该库中的代码时发生。我不知道它是如何做到这一点的,因为我没有使用它知道名
我有一个 UIScrollView,其框架与包含的 View Controller 相同。 当 ScrollView 的缩放比例大于 1 时,从屏幕左侧 50% 开始从左向右滑动会导致 interac
我是网页设计的新手,最近接触了 Bootstrap。我最近也开始使用 Codepen。在 Codepen 中完成一个元素后,我将代码从那里复制并粘贴到 Sublime 中,无论出于何种原因,它更改了我
关闭。这个问题需要debugging details .它目前不接受答案。 编辑问题以包含 desired behavior, a specific problem or error, and t
我是一名优秀的程序员,十分优秀!