-
Notifications
You must be signed in to change notification settings - Fork 717
[scroll-animation-1] Define scroll linked animation behavior in printing documents #8226
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
Comments
When printing I would assume there is no scroll estate, so the logic from #7778 (comment) would apply in that case. |
@bramus what do you mean by "no scroll estate"? IIRC Chrome does preserve each scroll position for sub scroll containers in printing document. |
I suppose you meant for the root scroll container cases? |
There is still a spec issue about printing for scroll animations, w3c/csswg-drafts#8226, so I think moving all of them into a separate folder makes us easier to address. Differential Revision: https://phabricator.services.mozilla.com/D164860 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1774505 gecko-commit: 9199e7f4539e7f1f24c156b8f07e20bd3f9275bf gecko-reviewers: hiro
…lder. r=hiro There is still a spec issue about printing for scroll animations, w3c/csswg-drafts#8226, so I think moving all of them into a separate folder makes us easier to address. Differential Revision: https://phabricator.services.mozilla.com/D164860
There is still a spec issue about printing for scroll animations, w3c/csswg-drafts#8226, so I think moving all of them into a separate folder makes us easier to address. Differential Revision: https://phabricator.services.mozilla.com/D164860 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1774505 gecko-commit: 9199e7f4539e7f1f24c156b8f07e20bd3f9275bf gecko-reviewers: hiro
Definitely for the root scroller as printing is paged media without a viewport. For non-root scrollers I hadn’t really checked what printing does. In Chrome it prints the contents at the current scroll position like you mentioned. With that given, it makes sense to print the scroll-linked element at a certain position. Maybe the progression of the animation could be snapshotted and then be re-applied when printing? E.g. say you’ve scrolled halfway and the scroll-linked animation is at 50% because of that. When printing, then use that 50% as the animation progress instead of trying to recalc the whole lot based on the printed box’s size. |
…lder. r=hiro There is still a spec issue about printing for scroll animations, w3c/csswg-drafts#8226, so I think moving all of them into a separate folder makes us easier to address. Differential Revision: https://phabricator.services.mozilla.com/D164860
I think the most natural thing to do is treat the root as a scroller that is fully in view with no overscroll, and inner scrollers as their current position, which is the original position put forward by @hiikezoe and clarified by @bramus for what that means #8226 (comment) |
The CSS Working Group just discussed
The full IRC log of that discussion<TabAtkins> flackr: When you print a doc, we need to define what the animation value from SLA is<TabAtkins> flackr: I think there's two possible choices. <TabAtkins> flackr: I think makes the most sense is to treat the root as a scroller that's fully in view - scrollport is size of scrollable area <TabAtkins> flackr: This means many animatinos wouldn't have a time value, so they'd be skipped <florian> q+ <TabAtkins> flackr: Other option is we treat one page as the scrollport, and presumably the scroll position is zero <astearns> ack florian <TabAtkins> florian: I'm not on top of things wrt animations, but wanted to point out that while it's not common, print and paged can be different - you can have scrollable things in a page in ebook, for example <fantasai> TabAtkins: I think this question is for the root scroller though <fantasai> TabAtkins: which is basically the same problem for paged and print <TabAtkins> flackr: other scrollers are fine, they can compute their time. this is just the root scroller <TabAtkins> flackr: it just doesn't really have a scroll position <TabAtkins> fantasai: Can you explain more? say i have a root backgroudn animation from green to red as it goes 0%-100%. what happens when I print? <TabAtkins> flackr: The scroll animation is considered inactive since there is no scrollable overflow, so it's not applied. <TabAtkins> fantasai: That makes sense, I think that's the right thing to do. <TabAtkins> astearns: So proposed resolution is that, for printing/paged purposes, we treat root as fully in view with no scrollable overflow <TabAtkins> fantasai: scroll timeline is inactive on the root, maybe clearer to state directly <TabAtkins> RESOLVED: for printing/paged, root is considered fully in view (scroll timelines on it are inactive) |
I believe the required changes for this issue are all landed with c6c8598. |
What most of users expect in printing documents is, I think, printing out the document as it is when the user printed out.
So basically any scroll linked animations should be output as it is, other then animations tied to the root scroll container in the top level document because there's not scroll position for the root scroller I think.
That's said, it's just my opinion. The spec needs to clarify it.
The text was updated successfully, but these errors were encountered: