css3

Tab system with pure CSS, anchor avoids the propagation to label

梦想与她 提交于 2020-01-01 16:53:05
问题 I'm making a tab system only with CSS using :target and :checked pseudoclasses, but I have an anchor inside the label, and the label doesn't trigger the :checked . If you click in the anchor, the :checked doesn't trigger because the click is in the <a> tag, but is inside a <label> that must trigger the radio button. If you click on the border of the tab, you'll see how it triggers the :checked , but not the anchor, so the :target can't be triggered. Here you are my code, more understandable

Animating SVG paths with discontinuous parts

怎甘沉沦 提交于 2020-01-01 16:48:23
问题 In the left example the path is continuous (i.e. no m commands), hence the segments of the path are drawn one after another. In the right example the path is discontinuous (i.e. containing m commands), which causes all segments to be drawn at once. How can I make the segments in the right example be drawn one after another? That is, the second stroke starting only when the topmost stroke is finished instead of both starting simultaneously. <svg width="220px" height="100px" viewBox="-10 -10

Animating SVG paths with discontinuous parts

房东的猫 提交于 2020-01-01 16:47:10
问题 In the left example the path is continuous (i.e. no m commands), hence the segments of the path are drawn one after another. In the right example the path is discontinuous (i.e. containing m commands), which causes all segments to be drawn at once. How can I make the segments in the right example be drawn one after another? That is, the second stroke starting only when the topmost stroke is finished instead of both starting simultaneously. <svg width="220px" height="100px" viewBox="-10 -10

Text-overflow: ellipsis jumps behind text on Android

谁都会走 提交于 2020-01-01 16:02:19
问题 im trying to ellipsis a h2 tag with text-overflow. It works fine i all browsers but on Android. The three dots jumps behind the clipped text so you can't actually see the ellipsis. The css for the h2 is: h2 { font-size: 20px; display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; width: 40%; } I have a lot of other styles but can't figure out what will affect this. I did a dummy test which works fine, so i was wondering if someone experienced this behaviour before?

How do I simplify this header with lines on the side, so that it doesn't need css3 background properties?

二次信任 提交于 2020-01-01 15:07:01
问题 I have a css class for centering a heading, and adding vertically centered lines on either side. Problem is, it uses css3 background properties, and not every browser supports those. So I'd like to simplify this for cross browser compatibility, but am not sure how to do that. Is there a simpler way to achieve this, without the css3 background (and without adding any extra elements or static heights/widths )? demo here .section-heading { display: table; white-space: nowrap; } .section-heading

CSS Responsive Design Break Points

五迷三道 提交于 2020-01-01 14:19:28
问题 I'm using Break points at 768 480 & 225. Is this sufficient for my responsive design or is more recommended. 768 + | Computer 480 - 768 | Tablet 225 - 480 | Smart Phone 225 < | Phone / Min Browser 回答1: I wouldn't even worry about trying to design for types of displays, there are too many resolutions to possibly make decisions based on that. Instead, just start with your maximum resolution on your display, and slowly shrink the browser window until you find the natural breakpoints for your

Is it possible to get the target calculated css property value during a css3 transition in Javascript?

荒凉一梦 提交于 2020-01-01 12:07:10
问题 Is it possible to get the target (final) calculated css property value during a css3 transition in Javascript? I found this answer: Is it possible to get the target css property value during a css3 transition in Javascript? So, I can get it as document.getElementById('transition_div').style.width BUT this works only when target css property is specified in css. I need get target property value which is calculated dynamicaly - not specified in CSS. HTML: <table> <tr> <td id="cell-1">CELL 1</td

Why does a button element's height not match that of a sibling input element with same height properties?

偶尔善良 提交于 2020-01-01 12:05:02
问题 I have the following: <div style="border:solid 1px gray; height:22px; line-height:22px; display:inline-block;">Div</div> <input style="border:solid 1px gray; height:22px; line-height:22px; vertical-align:top;" type="text"> <button style="border:solid 1px gray; height:22px; line-height:22px; vertical-align:top;">Button</button> As you can see in this jsFiddle, Why is the button element 1px shorter than the rest? in Chrome and firefox. 回答1: It has to do with the way the browser implements the

Create a button with double arrows at the end

泄露秘密 提交于 2020-01-01 11:59:11
问题 I'm trying to achieve this effect for a button: I've been battling it for a couple hours and the best I could come up with was this CodePen. <a href="#" class="btn-wrap"> <span class="btn btn-primary">See the Proof</span> </a> .btn { border: 0; border-radius: 0; font-weight: 300; font-size: 20px; text-transform: uppercase; } .btn-primary { position: relative; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; transition: all .2s ease; } .btn-primary:before, .btn-primary:after {

JavaScript Image zoom with CSS3 Transforms, How to calculate Origin? (with example)

不打扰是莪最后的温柔 提交于 2020-01-01 11:58:07
问题 I'm trying to implement an image zoom effect, a bit like how the zoom works with Google Maps, but with a grid of fix position images. I've uploaded an example of what I have so far here: http://www.dominicpettifer.co.uk/Files/MosaicZoom.html (uses CSS3 transforms so only works with Firefox, Opera, Chrome or Safari) Use your mouse wheel to zoom in/out. The HTML source is basically an outer div with an inner-div, and that inner-div contains 16 images arranged using absolute position. It's going