Hello Jonas,

I appreciate your detailed reviews on the topic.  I'm sorry if I did
not yet address all of your issues.  Please advise if there is
anything else I may have missed.

> I guess what I'm arguing is that smooth-scrolling vs. instant 
> scrolling shouldn't be a per-element CSS property, but rather a 
> per-callsite API argument.
> 
> It seems to me that it will be the case that for a given element 
> you'll sometimes want to do smooth scrolling operations and
> sometimes instant operations.
> 
> For example in a list of emails you might want to enable 
> smooth-scrolling down 50 emails, but if additional emails come in,
> you want to be able to add to the top of the list and atomically
> "add to scroll scroll position" to compensate for the added
> elements.
> 
> I'm not sure if that means treating the current .scrollBy() and 
> .scrollLeft/.scrollTop API as instant (and make sure it applies to 
> elements in addition to windows) and adding smooth scrolling
> versions. Or if we should add wholly new API which is more explicit
> about if it intends to perform smooth vs. instant scrolling.
There is an entirely new API that allows you to be explicitly specify
if the scroll is to be smooth, instant, or to use the CSS property
value.  This was added after the original Intent To Implement email:

http://dev.w3.org/csswg/cssom-view/#extensions-to-the-window-interface
http://dev.w3.org/csswg/cssom-view/#extensions-to-the-element-interface

> 
> The only use-case I could see for the CSS property would be as a
> way to indicate if a <a href="#..."> should perform an instant or a
> smooth scroll.
The CSS "scroll-behavior" property now does this, in addition to
setting the default of "smooth" or "auto" for CSSOM-View DOM scrolling
methods.  Further discussion on the CSS property value continued here:

http://lists.w3.org/Archives/Public/www-style/2014Oct/0149.html

The CSS scroll-behavior property now has two values, "auto" and
"smooth".  "instant" was renamed to "auto", given that it selects the
default behavior of the UA which may still scroll smoothly in response
to user input such as keyboard scrolling and fling gestures.

Cheers,
  - Kearwood "Kip" Gilbert

On 2014-10-27, 10:11 PM, Jonas Sicking wrote:
> Last we talked about this, I thought that we concluded that smooth 
> scrolling wasn't so much a property of the element, but rather a 
> property of the callsite.
> 
> See my two emails to the intent to implement thread.
> 
> Did this change?
> 
> / Jonas
> 
> On Mon, Oct 27, 2014 at 1:31 PM, Kip Gilbert <kgilb...@mozilla.com>
> wrote:
>> As of October 28, 2014 I intend to turn on by default CSSOM-View 
>> Scroll-Behavior CSS Property and CSSOM-View DOM Extensions
>> related to smooth scrolling.  They have been developed behind
>> the layout.css.scroll-behavior.enabled and 
>> layout.css.scroll-behavior.property-enabled preferences.  Firefox
>> is the first UA to ship this feature.  Chrome has an
>> implementation, disabled by default.
>> 
>> Platform coverage: This will be enabled on all platforms except
>> for Fennec.  (Fennec will be enabled once the C++ based APZC 
>> implementation ships for Fennec)
>> 
>> This feature was previously discussed in this "intent to
>> implement" thread: 
>> https://groups.google.com/d/msg/mozilla.dev.platform/mrsNyaLj3Ig/jooFD8rePzAJ
>>
>>
>> 
Further discussions occurred on www-style:
>> 
>> http://lists.w3.org/Archives/Public/www-style/2014May/0255.html 
>> http://lists.w3.org/Archives/Public/www-style/2013May/0361.html 
>> http://lists.w3.org/Archives/Public/www-style/2014Oct/0014.html
>> 
>> Bugs to turn on by default:
>> 
>> Bug 1087562 - Enable CSSOM-View scroll behavior CSS property by 
>> default (Except for Fennec)
>> 
>> Bug 1087559 - Enable CSSOM-View scroll behavior DOM method
>> extensions by default (Except for Fennec)
>> 
>> Since the original intent to implement email, the specification
>> has evolved.  The CSSOM-View DOM Extensions have been changed to
>> accept dictionaries for options and the 'instant' value for
>> scroll-behavior has been changed to 'auto'.
>> 
>> Bug: 964097 - [meta] Implement CSSOM-View smooth scrolling spec
>> 
>> Link to standard:
>> 
>> http://dev.w3.org/csswg/cssom-view/#smooth-scrolling:-the-%27scroll-behavior%27-property
>>
>> 
http://dev.w3.org/csswg/cssom-view/#extensions-to-the-window-interface
>> http://dev.w3.org/csswg/cssom-view/#extensions-to-the-element-interface
>>
>>
>> 
_______________________________________________
>> dev-platform mailing list dev-platform@lists.mozilla.org 
>> https://lists.mozilla.org/listinfo/dev-platform
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to