← Back to team overview

mahara-contributors team mailing list archive

[Bug 1419532] Re: Add "width" and "Height" attributes to <img> tag in image blocks so they'll flow to the right size immediately

 

Never mind, if I do it with just the <img> height and with tags, then it
does indeed immediately load up a placeholder for the image. BUT this
placeholder has its width squished by the CSS "width: 98%" we put on the
img in the image block, and the height remains the original, which
distorts the image.

I can tell CSS to retain the original image proportions by adding
"height: auto;". But if I do this, then there is no layout speed
improvement. The image's height remains 0 until the image actually
loads.

So it looks like there's no benefit to be gleaned here.

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1419532

Title:
  Add "width" and "Height" attributes to <img> tag in image blocks so
  they'll flow to the right size immediately

Status in Mahara ePortfolio:
  Won't Fix

Bug description:
  We should add "width" and "Height" attributes to the <img> tags
  generated by image blocks, so that the browser will render the image
  placeholder as the correct size even before the image finishes
  loading. This should help the page to feel like it's loading up more
  quickly.

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1419532/+subscriptions


References