Im ayant un problème en utilisant les typeahead.js, un nouveau plug-in de Twitter, vous pouvez voir un exemple de la façon dont ce plugin est censé regarder: http://twitter.github.com/typeahead.js/examples/de mise en œuvre de problème CSS
Vous pouvez voir ma mise en œuvre ici: http://mypcisbroke.co.uk/problem/
Mes questions
- La zone de texte devrait changer de blanc sur mise au point (cela a fonctionné avant l'installation du plug-in)
- Suggestions qui autocomplete en zone de texte devrait être dans une couleur plus claire
Voici mon site css
.navbar .top-search form { margin: 0 10px 0 0; padding-top: 5px; position: relative; }
.navbar .top-search input, .navbar .top-search button { -webkit-transition: all 200ms ease-in-out; -moz-transition: all 200ms ease-in-out; -o-transition: all 200ms ease-in-out; transition: all 200ms ease-in-out; }
.navbar .top-search input { padding: 2px 24px 2px 10px; border: none; margin: 0; width: 150px; background: #999; -webkit-border-radius: 20px; moz-border-radius: 20px; -ms-border-radius: 20px; border-radius: 20px; }
.navbar .top-search input:focus { background: #f5f5f5; -webkit-box-shadow: none; -moz-box-shadow: none; -ms-box-shadow: none; box-shadow: none; }
.navbar .top-search button { opacity: .6; position: absolute; right: 7px; top: 9px; padding: 0; margin: 0; line-height: 12px; background: none; border: none; -webkit-box-shadow: none; -moz-box-shadow: none; -ms-box-shadow: none; box-shadow: none; }
.navbar .top-search input:focus + button { opacity: 1 }
Ceci est le style de typeahead
.typeahead,
.tt-query,
.tt-hint {
width: 396px;
height: 30px;
padding: 8px 12px;
font-size: 24px;
line-height: 30px;
border: 2px solid #ccc;
-webkit-border-radius: 8px;
-moz-border-radius: 8px;
border-radius: 8px;
outline: none;
}
.typeahead:focus {
border: 2px solid #0097cf;
}
.tt-query {
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
.tt-hint {
color: #999
}
Toute aide sur ce serait vraiment apprécié.
Merci
'! Important' devrait être utilisé très rarement –
Presque là, après avoir ajouté important, il cache les suggestions? La prise semble créer une zone de texte transparente les uns sur les autres, c'est pourquoi la mise au point est techniquement encore sur l'autre droite? – amof
Regardez ma réponse, je pense qu'il va résoudre le problème des suggestions transparentes –