Skip to content

Instantly share code, notes, and snippets.

@sorentwo
Created November 1, 2011 18:36
Show Gist options
  • Save sorentwo/1331482 to your computer and use it in GitHub Desktop.
Save sorentwo/1331482 to your computer and use it in GitHub Desktop.
Velge markup overview
// This is the original input, we want it hidden
.velge-original {
display: none;
}
// This is the tag / input container
.velge {
// Tags list
ul {
// Tag item, comprised of a value and a remove link
li {
i {}
a {}
}
}
// Tag input field, this is inline with tags
input {
}
// A small trigger to toggle displaying the dropdown
button {
}
// The dropdown list, positioned directly below the input
ol {
li {}
}
}
<input class='velge-original' type='text' />
<div class='velge'>
<ul>
<li><i>internet explorer</i><a href='#'>x</a></li>
<li><i>opera</i><a href='#'>x</a></li>
</ul>
<input type='text' />
<button>v</button>
</div>
<ol>
<li>Chrome</li>
<li>Firefox</li>
<li>Safari</li>
</ol>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment