css3

Is it possible to set perspective-origin on elements that are transformed with transform: perspective()?

巧了我就是萌 提交于 2020-01-07 04:25:11
问题 TL;DR: Is it possible to set the vanishing point ( perspective-origin ) for an element that is given perspective directly via transform: perspective() , as opposed to inheriting it from a parent via perspective: ? You can see an example at http://jsbin.com/fevik/2/edit. In the second set of elements, I would like each element to have its own vanishing point that I can specify. Discussion: It's easy to set the vanishing point ( perspective-origin ) for elements that are 3D-positioned by their

Position this div in the center of it's container?

孤人 提交于 2020-01-07 04:17:08
问题 Before you attempt to solve this please carefully read the constraints I'm dealing with. Constraints .pictureContainer needs to remain position: relative (because I have a hover menu that positions absolutely relative to it.) The image could be smaller than 80% of #slide in which case it still must align in the center. What this translates to? You can't simply do a margin: 0 10% because yes that would center this specific case, but it will not satisfy the case where the image is smaller than

Translating an absolutely positioned div

走远了吗. 提交于 2020-01-07 03:56:05
问题 I have this position in this ways, the problem is translating each divs based on what i have. the css is like: .col-md-12 { display: flex; flex-wrap: wrap; } .col-md-12 input:checked + label { color: red; } .col-md-12 input:checked + label + div.slider { color: red; } .col-md-12 div.slide-1 { left: -100%; } .col-md-12 div.slide-2 { left: 0%; } .col-md-12 div.slide-3 { left: 100%; } .col-md-12 input { flex-basis: 3%; margin-right: 27%; order: 1; } .col-md-12 label { flex-basis: 30%; margin-top

jQuery UI make the effect less abrupt and jerky

随声附和 提交于 2020-01-07 03:39:22
问题 I have a little toggle sidebar that I am using jQuery UI. The problem is it is very jerky behavior. Anyway to may it look like a smooth scroll left/right? I am trying to get the outer shell to slide smoothly like the inner container slides. Currently it is snapping once the inner div is finished easing. $(".snapper").click(function() { $(".sidebar-wrapper").toggle("slide", { direction: "right" }, 1000); $("#sidebar").css("width" , "auto"); }); Online Example. http://frontendtrends.com/sidebar

css / html - spread child divs across parent div

允我心安 提交于 2020-01-07 03:38:07
问题 My issue is that I have a div (id=service-section-container) which contains 3 divs (class=service-section) which are shifted to the left of their parent div. I haven't found an efficient way to center the group of child divs using margins as using pixels would have a different result of different screens where as percentage didn't do the trick. It's probably a simple fix which I couldn't solve with my lack of experience, hence why I'd really appreciate your help. Example can be found at the

how to test site in motorola g in chrome emulator?

帅比萌擦擦* 提交于 2020-01-07 03:04:46
问题 I am testing my site in all the mobile emulator in chrome. Here moto g emulator is not available. My testing team is saying issue in the moto g. Can some one help how to test for motorola. Thanks in advance. 回答1: The only thing the "emulator" does is emulating screen resolution and pixel dimensions. Customize the screen settings: Click the values and adjust them. The Moto G has a reolution of 720 x 1280 pixels and set the pixel dimension to 2 or 3. Custom Device You can add a custom device if

how to test site in motorola g in chrome emulator?

拜拜、爱过 提交于 2020-01-07 03:04:27
问题 I am testing my site in all the mobile emulator in chrome. Here moto g emulator is not available. My testing team is saying issue in the moto g. Can some one help how to test for motorola. Thanks in advance. 回答1: The only thing the "emulator" does is emulating screen resolution and pixel dimensions. Customize the screen settings: Click the values and adjust them. The Moto G has a reolution of 720 x 1280 pixels and set the pixel dimension to 2 or 3. Custom Device You can add a custom device if

set size content editable div based on the text inside this

橙三吉。 提交于 2020-01-07 02:57:27
问题 I need to set the size of content editable div same as the text inside it .Please see this js fiddle https://jsfiddle.net/felixtm/jaboLc3u/7/ $(".new-div").css("width",'auto'); } , stop: function() { $(".new-div").css("width",'auto'); } }); $(document).on("click",".closeButton",function(){ $(this).closest('div').remove(); }); $(".new-div").on("click", function(){ var uscontent= $(".new-div").text(); if(uscontent.trim()==="message"){ $(".new-div").text(''); } }); $("#font-size").on("change"

Grayscale hover effect slow in FF, fast in Chrome, IE and others

守給你的承諾、 提交于 2020-01-07 02:31:26
问题 Not sure what is going on. The hover effect on the page below is very slow to respond in Firefox. When you scroll, the page is not smooth either. This particular page runs smoothly in other current browsers. The site is very fast so I am not sure what to think. http://thebc.co/our-work 来源: https://stackoverflow.com/questions/13304218/grayscale-hover-effect-slow-in-ff-fast-in-chrome-ie-and-others

Grayscale hover effect slow in FF, fast in Chrome, IE and others

妖精的绣舞 提交于 2020-01-07 02:31:06
问题 Not sure what is going on. The hover effect on the page below is very slow to respond in Firefox. When you scroll, the page is not smooth either. This particular page runs smoothly in other current browsers. The site is very fast so I am not sure what to think. http://thebc.co/our-work 来源: https://stackoverflow.com/questions/13304218/grayscale-hover-effect-slow-in-ff-fast-in-chrome-ie-and-others