This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 26264 - The <wbr> style should be along the lines of wbr::after { content: '\200B'; white-space: normal; }.
Summary: The <wbr> style should be along the lines of wbr::after { content: '\200B'; w...
Status: NEW
Alias: None
Product: CSS
Classification: Unclassified
Component: Display (show other bugs)
Version: unspecified
Hardware: Other other
: P3 normal
Target Milestone: ---
Assignee: Tab Atkins Jr.
QA Contact: public-css-bugzilla
URL: http://www.whatwg.org/specs/web-apps/...
Whiteboard: whatwg-resolved
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-04 08:31 UTC by contributor
Modified: 2017-01-24 21:03 UTC (History)
8 users (show)

See Also:


Attachments

Description contributor 2014-07-04 08:31:04 UTC
Specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/rendering.html
Multipage: http://www.whatwg.org/C#br-wbr-content
Complete: http://www.whatwg.org/c#br-wbr-content
Referrer: http://www.whatwg.org/specs/web-apps/current-work/multipage/index.html

Comment:
The <wbr> style should be along the lines of wbr::after { content: '\200B';
white-space: normal; }.

http://www.w3.org/TR/CSS21/generate.html#propdef-content says 'content' only
applies to the ::before and ::after pseudo-elements, so the current style has
no effect, and putting the 'white-space' property directly on the <wbr> would
establish the interaction with whitespace-affecting styles and elements other
than <nobr>.

Chrome and Safari currently implement a behavior like my suggestion; Firefox
does not.

Posted from: 173.228.80.34
User agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.3 Safari/537.36
Comment 1 Ian 'Hixie' Hickson 2014-07-07 21:50:26 UTC
'content' will apply to elements directly in due course. We're just a bit ahead of CSS right now.
Comment 2 Ian 'Hixie' Hickson 2014-07-30 05:57:20 UTC
Though maybe we should do <wbr> similar to <br>, with a special 'display-something' value, to make the styling more efficient...
Comment 3 Ian 'Hixie' Hickson 2014-09-08 21:53:57 UTC
dbaron, Tab: since <br> is now defined as "display-outside: newline", should <wbr> be similarly defined ("display-outside: break-opportunity" or something)? Or should we continue to define it as "wbr { content: '\200B'; }" ?
Comment 4 Ian 'Hixie' Hickson 2014-09-19 21:40:47 UTC
I've made it be "display-outside: break-opportunity". Reassigning to Tab for the CSS side.
Comment 5 contributor 2014-09-19 21:41:24 UTC
Checked in as WHATWG revision r8798.
Check-in comment: Get HTML ahead of CSS for the definition of 'wbr'.
https://html5.org/tools/web-apps-tracker?from=8797&to=8798
Comment 6 fantasai 2017-01-24 19:32:50 UTC
The CSSWG believes that 
  wbr { all: reset !important; display: contents !important; content: "\200B" !important; }
should be sufficient to address this issue and address all concerns, and has therefore declined to add a new display type for this element. Please follow up on https://github.com/w3c/csswg-drafts/issues/610 if you believe this is not the case. Thanks~
Comment 7 fantasai 2017-01-24 19:36:47 UTC
Sorry, that should be s/reset/unset/
  https://www.w3.org/TR/css-cascade/#inherit-initial
Comment 8 Simon Pieters 2017-01-24 21:03:35 UTC
Thanks, filed https://github.com/whatwg/html/issues/2291 to track this for HTML.