W3C home > Mailing lists > Public > public-digipub@w3.org > August 2015

Re: Cross-References in GCPM (was: CSS Pages and Pagination)

From: Sanders Kleinfeld <sanders@oreilly.com>
Date: Mon, 10 Aug 2015 18:21:15 -0400
Message-ID: <CAD1Cp0u8u-bwLHcecZCi2nssoJaeRKdAwLUpKM_U69QTYtPQEw@mail.gmail.com>
To: Dave Cramer <dauwhe@gmail.com>
Cc: HÃ¥kon Wium Lie <howcome@opera.com>, Daniel Glazman <daniel.glazman@disruptive-innovations.com>, public-digipub <public-digipub@w3.org>
Thanks for surfacing this, Dave!

On Mon, Aug 10, 2015 at 12:52 PM, Dave Cramer <dauwhe@gmail.com> wrote:
>
> I found a proposal that might also satisfy the use case [1]:
>
> a[href] {
>   // Use x-target-is as a switch for which link text to use
>   content: x-target-is(attr(href), 'figure') 'See Figure';
>   // Link to a section WITHOUT a title
>   content: x-target-is(attr(href), 'section:not(:has(>.title))')
>            'See ' target-text(attr(href), content(before));
>   // Link to a section **with** a title
>   content: x-target-is(attr(href), 'section:has(>.title)')
>            'See ' target-text(attr(href), content(before))
>            target-text(attr(href), content('> .title'));
> }

Yes, this would also satisfy my use case :)
>
>
> Dave
>
>
> [1] http://philschatz.com/css-polyfills.js/#section-target-counters
>
Received on Monday, 10 August 2015 22:21:44 UTC

This archive was generated by hypermail 2.3.1 : Monday, 10 August 2015 22:21:44 UTC