How to design aggregations filter in css for week, month?
Tags: html,css
Problem :
I want to design aggregation filter for week, month,etc. like following image. Please see the image, I want to design same-way
Image:image for which I want to design css
Please see the demo for DEMO
<style type="text/css">
.tag {
/*display: block;*/
border: 1px solid #4f9f4f;
padding: 6px 12px;
font: 12px/17px 'OpenSansLight';
color: #4f9f4f;
text-decoration: none;
}
.tag-leftmost {
border: 1px solid #4f9f4f;
border-bottom-left-radius: 20px;
border-top-left-radius: 20px;
padding: 6px 12px;
font: 12px/17px 'OpenSansLight';
color: #4f9f4f;
text-decoration: none;
}
.tag-rightmost {
border: 1px solid #4f9f4f;
border-bottom-right-radius: 20px;
border-top-right-radius: 20px;
padding: 6px 12px;
font: 12px/17px 'OpenSansLight';
color: #4f9f4f;
text-decoration: none;
}
.tag-center tag{
}
</style>
<div class="col-md-12 col-sm-12">
<a title="week? category" ng-model="today_placement" class="tag-leftmost">Today</a>
<a title="week? category" ng-model="week_placement" class="tag">week</a>
<a title="week? category" ng-model="month_placement" class="tag">month</a>
<a title="week? category" ng-model="year_placement" class="tag-rightmost">year</a>
</div>
Solution :
Try using CSS triangles hack to make that arrow. Check .tag:hover:after
.wrapper {
border: 1px solid #4f9f4f;
border-radius: 20px;
padding: 0 14px;
float: left;
}
.tag {
padding: 6px 12px;
font: 12px/17px'OpenSansLight';
color: #4f9f4f;
text-decoration: none;
/* ADDED for :after */
position: relative;
float: left;
}
.tag:not(:first-child):not(:last-child) {
border-radius: 0;
border-left: 1px solid #4f9f4f;
border-right: 1px solid #4f9f4f;
}
.tag:hover {
background-color: red;
border-color: red;
}
.tag:hover:after {
content: '';
width: 0;
height: 0;
border: 5px solid transparent;
border-bottom-color: red;
position: absolute;
display: block;
left: 50%;
top: -10px;
margin-left: -5px;
}
<div class="wrapper col-md-12 col-sm-12">
<a title="week? category" class="tag">week</a>
<a title="week? category" class="tag">week</a>
<a title="week? category" class="tag">week</a>
</div>
CSS Howto..
You can differentiate the <img> tags via: li.leaf > img { background: url("/images/leaf_bg.png"); } li.leafhidden > img { background: url("/images/leaf_hidden_bg.png"); } ...
If for some reason Nick's answer doesn't work for you, here's an alternative approach: Put the image and the video in a relatively positioned parent element. Use position: absolute on...
You can't do this only with CSS. You'll need Javascript because the selected option of your select is not a sibling of your input-box in the DOM : <select name="mySelect"...
I don’t think you can put generated content inside a <select> element. Form controls are generally rendered by the operating system rather than the browser, or at least aren’t rendered...
I do something similar with RowDataBound: if (e.Row.RowType == DataControlRowType.DataRow) { // Check the XXXX column - if empty, the YYYY needs highlighting! if (e.Row.Cells[6].Text == " ") { e.Row.CssClass =...
Using CSS only: Right/Left Flippiing: Working Fiddle .Container { height: 200px; overflow-x: auto; } .Content { height: 300px; } .Flipped { direction: rtl; } .Content { direction: ltr; } Top/Bottom...
Since you requested only HTML and CSS, I changed the markup in order to obtain what you intend. The lack of parent selector in CSS turn your request impossible for...
Here is a guide to responsive layouts and another to some responsive frameworks you might consider using to achieve what you need to. Generally it's good ettiqute on the stack...
on the css of <img> tag use this { float:left; } or in html try this one. <img style="float:left;"> ...
Try adding these rules: .cities-main{ padding: 0; text-align: center; } .cities-main > li:last-child{ margin-right: 0; } By doing so, the last link won’t break into a new line due to...
You should have access to a .css CSS file. That is the 'Styles' for your site. (.html is the markup/content`) etc. ~ If you can find a place that has...
Your generated datagrid would have to have no spacing between columns. the first column would need the left side of the rounded image the columns in between would need the...
You could use this inview plugin: https://remysharp.com/2009/01/26/element-in-view-event-plugin Then you could start the animation as soon as the section where the animation is supposed to appear, is visible.
update: This is an old answer, nowadays you want to go with an embedded browser in your app (*webkit projects etc.), but at the time of writing, no such technology...
I guess this is what you were asking for. Check out this fiddle Here is the code The HTML is the same. The CSS ul { list-style: disc inside none;...
Try this way $(document).ready(function(){ var ac = $("#ac").text().split(' '); $("#ac").text(ac[0]) }) ...
Add position:relative; to the div.slide, and add position:absolute; to the div.innerText in CSS. That should fix the problem. Edit: Actually, I tried modifying the original sample code. Simply adding another...
Override WebChromeClient and WebViewClient... Damn that was hidden. I actually had to dig up a bit to find this out. WebView webView = (WebView)findViewById(R.id.myWebView); WebChromeClient myWebChromeClient = new WebChromeClient(){ @Override...
In order to keep everything in scale when resizing the browser window you should use percentage values for both the size and position of the overlays. In your case everything...
As near as I can tell, secondary class definition is confusing IE7. I'm guessing it is acting on the TH first, then since that is gone, the colgroup rule-hide class...
The CSS 3 pseudo class for excluding elements is :not. To exclude all elements matching #classic, but keep the rest, use * :not(#classic) { /* your definitions here */ }...
Change this style: .sa-answer, .sa-score, .sa-review, .sa-report { display: inline; } … to this: .sa-answer, .sa-score, .sa-review, .sa-report { display: inline-block; } You'll also probably want to add text-align: center;...
Try with : visibility: hidden ;)
No, its not possible with css, you will to manipulate images using javascript. Have a look at jquery and the plugins available, ou may find something that can style up...
By my understanding, you'll most likely lose colour information by converting it from 6-digit to 3-digit, so you'll need to specify what conversion you want. Examples would be good. Nonetheless,...
You can't achieve that using CSS alone. You would need to use Javascript to update a boolean variable that holds the state of the button: pressed or released and change...
HTML a linear data structure, but your graph you are trying to recreate isn't linear. While it is possible, it's not necessarily trivial. You should avoid using float, because nested...
you can use a simple css if its a link a:visited{ display: none; } other wise a good jquery $('button').click( function(){ $(this).toggle() )); and with javascript <input type='button' onclick='hide(this);' />...
You set the background image on an i element the same way that you set it on any other element: Use the background-image property Ensure the element has an area...
If you want to achieve this with only using CSS, I'd recommend to use a parent container .container{ width:1024px; margin:0 auto; height:440px; } Here is a sample JSFiddle At this...