W3C home > Mailing lists > Public > www-style@w3.org > November 2012

Re: [css3-regions] Separating regions markup

From: Alan Stearns <stearns@adobe.com>
Date: Tue, 27 Nov 2012 15:11:18 -0800
To: www-style <www-style@w3.org>
Message-ID: <CCDA8610.1A09C%stearns@adobe.com>
Hey all,

As I mentioned last week, I've edited the sample code in Appendix A [1] in
CSS Regions to move the regions elements to a separate file using custom
elements from Web Components [2].

Bert, Håkon - does this approach satisfy your requirement for separating
content markup from layout?



[1] http://dev.w3.org/csswg/css3-regions/#intro-example-code
[2] http://dvcs.w3.org/hg/webcomponents/raw-file/tip/explainer/index.html

(previous note for more details and a wiki link)
On 11/16/12 12:37 PM, "Alan Stearns" <stearns@adobe.com> wrote:

>Hey all,
>Using HTML elements to produce the boxes for a region chain is a point of
>contention. The point made against the current version of the spec is that
>combining content and presentational code should be avoided when possible.
>At TPAC 2012, Bert mentioned [1] that using an external file to define the
>presentational boxes would be OK.
>One way to use an external file for presentational purposes is being
>defined by the Web Components [2] effort, so it may be a useful experiment
>to see how we could define regions using custom elements and/or decorators
>from Web Components. I know Bert would prefer generic XML to define a
>template, but Web Components is re-using HTML to define the template
>structure so I'm following their lead.
>I've made a wiki page [3] that takes a very simple example of region
>elements in the content markup, then moves the region elements out of the
>content markup into a separate file using either custom elements or
>decorators. With custom elements, defining a region chain becomes a matter
>of adding a link to a file and one additional attribute on an element. No
>other changes are needed in the content file. With decorators this is
>reduced to a single CSS property.
>Both of these approaches are not adding anything new - I'm just following
>what's currently proposed for both CSS Regions and Web Components (though
>custom elements are a bit further along than decorators). Given that there
>is implementation work being done on both custom elements and regions, I
>propose to edit CSS Regions Appendix A to use a custom element in the
>example, to show how one should separate content from presentation.
>[1] http://lists.w3.org/Archives/Public/www-style/2012Nov/0260.html
>[2] http://dvcs.w3.org/hg/webcomponents/raw-file/tip/explainer/index.html
>[3] http://wiki.csswg.org/spec/css3-regions/sequestering-regions
Received on Tuesday, 27 November 2012 23:14:31 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:23 UTC