Note that there are some explanatory texts on larger screens.

plurals
  1. POChrome renders button links completely screwed up when placed inside a paragraph
    primarykey
    data
    text
    <p>I am fairly proficient in CSS but now I am running into a very strange rendering issue in Google Chrome 9. I am trying to create some fancy looking link buttons (basically heavily styled anchors). Here is some example markup:</p> <pre><code>&lt;a href="" class="button"&gt; &lt;figure class="sprite icon icon_back"&gt;&lt;/figure&gt; Link button with icon&lt;/a&gt; </code></pre> <p>This markup may look a litte strange to you, there's a few things you should know:</p> <ul> <li>I am using HTML5's figure class to include an icon as part of the button. I have the proper reset CSS applied and Chrome can render this tag for sure.</li> <li>Instead of actually pointing to an image I am applying CSS classes to the figure element. Within the CSS I am using the spriting technique to show the correct portion of a single large sprite image. </li> </ul> <p>All of this is working fine in Firefox, and actually also in Chrome. The correct rendering can be seen in the following image:</p> <p><img src="https://i.stack.imgur.com/nrEm8.gif" alt="correct rendering"></p> <p>It renders like that in both Firefox and Chrome. Here comes the problem, if I place such a button within paragraph tags > <code>&lt;p&gt;&lt;/p&gt;</code> this is what happens in Chrome only:</p> <p><img src="https://i.stack.imgur.com/CkTAs.gif" alt="incorrect"></p> <p>Notice how the button is ripped apart? Only in Chrome and only when placed inside a paragraph. It gets even stranger: this only happens for the first button inside the paragraph, if I would place three buttons inside a paragraph, only the 1st one is screwed up.</p> <p>Your first question would probably be about the CSS. It is rather verbose so hereby a temporary link to the page in question:</p> <p>Edit: link to live page removed, was only temporary for problem inspection.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload