How can we improve the Microsoft Edge developer experience?

object-fit and object-position

CSS properties that control the position and size of replaced content within the content box.

http://dev.w3.org/csswg/css-images-3/#the-object-fit

4,214 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Jonathan Sampson [MSFT] shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    88 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)
      Submitting...
      • Primoz Cigler commented  ·   ·  Flag as inappropriate

        This is the 3rd most voted CSS feature here. Come on Microsoft, you can do better than 'under consideration'. Or am I wrong?

      • simon codrington commented  ·   ·  Flag as inappropriate

        Supporting the 'object-fit' and 'object-position' properties should be on a higher level of importance than what it currently is.

        Chrome and FireFox have supported this for years and even Safari at least provide basic support with 'object-fit'. IE and Edge are the only important browsers who have neglected this.

        Having the ability to position content using similar techniques that have historically been left up to 'background-image' and 'background-position' is critical (as using background properties for everything ruins accessibility).

        We could solve several issues such as galleries, sliders and other interactive media where content isn't the same size (for example a grid of 4 x 4 images could be easily displayed with 'object-fit' so that they are all outputted with the same dimensions, the content simply auto-fitting).

        I'm happy that with Edge you guys are listening to developers; Please listen to us on this and see that having this implemented is necessary

      • Anonymous commented  ·   ·  Flag as inappropriate

        The object-fit property allows me to use an IMG tag in my markup instead of a background-image in conjunction with "background-size: cover". This change is important in order for HTML documents to more correctly use IMG tags to represent pictures in the document, instead of using CSS hacks like background image to display content images. Every other browser supports this feature, and going forward I will be creating websites that rely upon it for content images. Please implement this feature so that our content images do not look BAD on Internet Explorer!

      • Mark commented  ·   ·  Flag as inappropriate

        I really don't like the terminology used on this website. When something is recommended or in draft by the W3C and you are a major browser vendor it's not "up to you to consider implementing" - you implement it. And you retrofit your older browsers where possible.

        There has been a recommendation since 2012. What is your team's priority? Is it to provide a means to consume web provided content and be a major player in this arena? If so - get with the program. Be the first to implement all W3C recommendations as soon as they are out. Be the first to retrofit older browsers when appropriate.

        Please fix this broken web experience.

      • Anonymous commented  ·   ·  Flag as inappropriate

        I want to use an img tag as the background with parallax scroll (background image isn't very performant) I want the image to fill the viewport width and height but maintain aspect ratio. Object-fit cover is a nice little css solution, alas IE and Edge don't support it : (

      • hi batsu commented  ·   ·  Flag as inappropriate

        Please implement this. You are the only major browser-vendor still lacking this crucial feature. I now have to use multiple elements with background-images, hiding them via media queries, just to get the same functionality.

      • shashi kant singh commented  ·   ·  Flag as inappropriate

        Please add the support for object-fit/object-position, Its very difficult to maintaining the images display in Edge or internet explorer.

      • Mark commented  ·   ·  Flag as inappropriate

        I'm a little on edge because of how things are worded on this website. "Consideration"? The only thing up to "consideration" are the native functionality you provide on your own. Browsers vendors need to be whipped into shape - the W3C is doing it's best to push the web forward and establish guidelines for consistent implementations. You either support the W3C or you do not. You don't get to "consider" anything about it.

      Feedback and Knowledge Base