Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[css-overflow-4] Can we add ::nth-page() pseudo-element? #3017

Closed
ghost opened this issue Aug 14, 2018 · 8 comments
Closed

[css-overflow-4] Can we add ::nth-page() pseudo-element? #3017

ghost opened this issue Aug 14, 2018 · 8 comments
Assignees
Labels
Closed Deferred Closed Rejected as Invalid Commenter Satisfied Commenter has indicated satisfaction with the resolution / edits. css-overflow-4

Comments

@ghost
Copy link

ghost commented Aug 14, 2018

In https://drafts.csswg.org/css-overflow-4/#paginated-overflow I think we need style regarding different page (such as ::nth-fragment at https://drafts.csswg.org/css-overflow-4/#fragment-pseudo-element).

The use case is in some digital book (epub) which is rendered with pagination publisher wanted to use different background image at left and right page (or say odd or even page). I remember saw something like nth-column somewhere but that would limit pagination have to be implemented with multi-columns.

@astearns
Copy link
Member

That's covered in paged media

https://drafts.csswg.org/css-page-3/#spread-pseudos

@ghost
Copy link
Author

ghost commented Aug 14, 2018

Thanks @astearns But it's digital book not printed book. And this is for the case that in case publisher or reading system need to use css-overflow-4 paginated-overflow to implement pagination on screen (say mobile, or desktop). So, IMP it's not exactly paged media.

@astearns astearns reopened this Aug 14, 2018
@astearns
Copy link
Member

Fair enough. My first thought would be that reading systems should probably implement paged media concepts that are relevant (rather than inventing new things for not-printed instances).

@ghost
Copy link
Author

ghost commented Aug 14, 2018

Yes I can understand. It was my first thought too. Currently for reading system there are some difficulty to use page media implement pagination. 1st thing is page media is not implemented enough yet in UA that reading system (which is based on UA) can use. And this is why reading systems were keeping trying to find css alternative way to implement pagination. 2nd thing is paged media seems more friendly to printing html (correct me if I am wrong) and might not actually can be adapted to digital book well, for example I remember some UA disabled javascript for @page (Maybe that's outdated, correct me if I am wrong here as well) but digital book is more like web page but paginated (with animation, javascript, video, audio, tts, and we also need to make it possible to switching between paginated mode and scroll mode. etc).

But yes, welcome any suggestion about how to resolve pagination for digital reading.

@frivoal
Copy link
Collaborator

frivoal commented Aug 14, 2018

I think the paginated overflow defined in css-overflow-4 is not sufficiently well defined yet to be sure exactly how all the constructs of paged media apply to it, and what needs to be added. It is possible that a new selector may be in order, but I think we're not there yet.

In the meanwhile, the features of css paged media are meant to be used in print as well as for digital books. The fact that they are not as implemented as we'd like is unfortunate, but we cannot fix the fact that features that are defined are not implemented by defining more features, which initially won't be implemented either.

@ghost
Copy link
Author

ghost commented Aug 15, 2018

Yes I can understand why don't want to invent new feature if seems unnecessary. But now seems we have a dead loop here. Reading System (RS) needs pagination, but since paged media is not useful yet RS has to try alternative CSS => Then RS needs alternative CSS to be improved to fit better for pagination => CSS said no you are supposed to use paged media.

@ghost
Copy link
Author

ghost commented Aug 15, 2018

Ok, lemme close this for now. The thing is if there is anything we can do to resolve this dead loop I would very like to try however I can not see any way yet. Would like to have any suggestion.

@ghost ghost closed this as completed Aug 15, 2018
@frivoal
Copy link
Collaborator

frivoal commented Aug 15, 2018

Ok, lemme close this for now.

Thanks.

seems we have a dead loop here

We have a problem, but not really a loop. Yes, we won't have a solution until Reading systems implement the feature, but we cannot fix that by defining a different feature to solve the same problem.

What needs to happen is for the feature to be implemented, and you need to convince implementers of that (or to be an implementer). Adding things to a spec does not solve that.

Alternatively, someone could try to make a convincing case that the feature as defined now should not be implemented, should be dropped from the spec, and should be replaced by something else. But we should not be adding multiple solutions to the same problem in the hope that one will be implemented.

@frivoal frivoal self-assigned this Aug 15, 2018
@frivoal frivoal added css-overflow-4 Closed Rejected as Invalid Closed Deferred Commenter Satisfied Commenter has indicated satisfaction with the resolution / edits. labels Aug 15, 2018
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Closed Deferred Closed Rejected as Invalid Commenter Satisfied Commenter has indicated satisfaction with the resolution / edits. css-overflow-4
Projects
None yet
Development

No branches or pull requests

2 participants