Here's the code at codepen: https://codepen.io/anon/pen/gGjyNz
What I am trying is to put blue or green lines under background (gray). As you see, if I set
`<li class=''>Launch</li>`
to
`<li class='visited'>Launch</li>`
what happens is that it covers the whole gray line completely, while I want it cover, but nicely, with box-radius working. Otherwise it is clumsy and has sharp edges.
UPDATE: I want background to cover blue or green, so when gray turns blue or green, it also inherits gray's, with fancy box-radius, etc.
On line 19 of your css there is a class I added the property z-index to:
ul.checkout-bar li
as
z-index: 100000;
It's so high because that bar is currently set to 99999.
To fix the ending, add:
border-radius: 15px;
after line 165 in your css. The :after never received that property to become curved
Related
I'm trying to achieve the underline for all parts of my button. I tried using -webkit-box-decoration-break property, it didn't work.
Both first line (New Delhi,) and last line (India) should have underline. Since it's due to break in the box, I tried the box-decoration-break property, but it didn't work out. Please guide me where I am going wrong.
The only thing you can do is use text-decoration: underline. Think of a button and the text inside it as a box. The line you are trying to draw will always be at the sides of that rectangle. When the text is wrapped (e.g., because the box is not wide enough), the rectangle just increases in height and keeps drawing the line at the bottom. Have a look at this Mozilla doc about CSS text-decoration or this Mozilla doc about CSS border.
You can add border-bottom : 1px solid #cccccc;. and if it's too close to your element (e.g. button) you can add padding-bottom : 5px to solve your issue.
I am trying to inherit the background of breadcrumbs element from the father div through its CSS configuration but I fail.
I was trying to set its CSS to background: transparent or inherit but it fails.
here is a link where this issue happens - the breadcrumbs has grey background while I want it to be white as the reset of the page.
Link to the problematic page: http://doitonlinediy.com/?s=page
Any thoughts/idea why I fail to set it ?
The background color is displayed is set into the body's css
#body {
background-color: #e1dedf;
}
Remove it or replace it and set the background color on your breadcrumb only
while strolling on your website sample I found out that whenever you set your breadcrumb background color to inherit parent's background style it always gives you the grey color. That's because of your body css background.
body.custom-background {
background-color: #e1dedf;
}
Try to change the background and you're good to go.
Your problem is the
body.custom-background
u can do something transparent by using RGBa, Like this..
h1 {color: rgba(123, 88, 9, 0.5);}
the value(123, 88, 9) are using for color, and the value (0.5) is using for transfarent..
Is it possible to program CSS's background with raw values for both its background background-color shorthand? I.e., body { background: white rgb(0, 255, 127) }
I was able to use a clever hack, which was use a 1x1 white pixel, background.png, i.e., body { background: url("background.png") rgb(0, 255, 127) }
And I think I can put a raw data:image/png;base64, but when I uploaded the same 1x1 white pixel online, it generated like a 500 character code, which seems insane for a 1x1 white pixel.
Is there another method to achieve the same effect using just background? The effect being a white foreground and green background. Demo live at (zaydek.github.io). To see effect, drag up and down on the webpage.
I know I can do so with divs, etc., but I am curious about just CSS properties on one element, i.e., body or a combination of html and body. Thanks.
Found a viable anwser at http://proger.i-forge.net/Компьютер/[20121112]%20The%20smallest%20transparent%20pixel.html
The winner is 1-color GIF – 35 bytes. Data URI for white 1×1 image:
data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAAAAAQABAAACAkQBADs=
input[type="text"], input[type="password"]{
opacity:0.5;
}
This fades both - input body and border. I don't want border transparent, just body, so the underlying image is visible. User-text inside the input should not be transparent, of course.
input [type="submit"]{
margin-left:50px; // here nothing works at all.
}
The opacity property influences the opacity of the whole element. Your question is bit vague, but I assume that you want to have a semi-transparent background, while the content and borders shouldn't have transparency.
To do so, you need to set a semi-transparent background to the element. This is called alpha-transparency, as a fourth color channel - the alpha channel - is used to store the transparency information (usually in an image like a PNG).
In modern browsers you could use the rgba() value for the background property:
/* semi-transparent white background */
background: rgba( 255, 255, 255, .5 );
In MS IE you could use a gradient filter, which supports ARGB colors since MS IE 5. Just fade from a color to itself: (be aware, that the alpha channel comes first and all four color values are noted as two-digit hexadecimals)
/* the same for IE 7+8, should get included in a separate MS IE specific stylesheet */
background: none;
zoom: 1;
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr=#E5FFFFFF, endColorstr=#E5FFFFFF );
-ms-filter: progid:DXImageTransform.Microsoft.gradient( startColorstr=#E5FFFFFF, endColorstr=#E5FFFFFF );
Opacity works on the whole text input including the text inside it. So your code won't work.
Option 1) Can you use CSS3? If so, use (with the color you want, of course):
background-color: rgba(255,0,0,0.5);
Option 2) You can set the background of the Input as the image you want to see.
Option 3) You can set the background as a semi-transparent solid color image (.gif/.png, which can be 1x1 in size and repeated in X and Y).
For the submit, you need to get rid of the space in your selector:
input[type="submit"]{
margin-left:50px;
}
And you can't specify what parts of the element you want to make transparent with opacity. It applies to err'thang. There might be 'hacks' of sorts to achieve what you want, such as using a wrapping div to create the border.
How to do the arrows shown in this screenshot:
http://i.stack.imgur.com/odpCG.png
(Forget the gradients.)
I can do a single image containing the arrow, but I also need the elements to the left and right change colors.
It's possible with the use of pseudo elements. Chris Coyier explains here: http://css-tricks.com/triangle-breadcrumbs/
If you worried about supporting older versions of IE, then you can use IE8.js (or IE9.js): http://code.google.com/p/ie7-js/
You can use PNGs with transparency, you will need only one arrow per color.
Images is it, you can create a sprite with a bunch of options and dynamically switch or change on hover.
You could have an transparent image for the following conditions:
light blue forward arrow
light blue back
dark blue forward arrow
dark blue back
grey forward arrow
grey back
Then in the CSS you could use something like the following to get it to work:
.completed:after{ content: url(../images/lightblueforward.png); padding: 5px}
.completed:before{ content: url(../images/lightblueback.png); padding: -5px}
.current:after{...}
.current:before{...}
.notcompleted:after {...}
.notcompleted:before {...}
Haven't tried this, so you'll have to experiment. You will have to mess around with the paddings/margin on those elements to get to line up correctly.