From c1feba029950e631876eb46c9c58facd9595c563 Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Fri, 30 Apr 2021 23:28:08 -0400 Subject: [PATCH 1/8] Adding mousemove and pointermove after mousedown and pointerdown to be excluding inputs Right now, the mousemove and pointermove events are not excluding inputs, but we want to set the mousemove and pointerdown events to be excluding inputs when they trigger dragging element around or resizing elements but not scrolling. These mousemove or pointermove events fired after mousedown or pointerdown event, but without pointercancel event will make dragging or resizing happen. --- index.bs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/index.bs b/index.bs index b989a8a..aaec0ed 100644 --- a/index.bs +++ b/index.bs @@ -413,9 +413,12 @@ The user agent may delay the reporting of layout shifts after a until such time as it is known that the event does not begin a fling or scroll gesture. -The mousemove and -pointermove -events are also not excluding inputs. +The mousemove events after the +mousedown event and the +pointermove events after +the pointerdown event, +which trigger dragging elements around or resizing elements but not scrolling, should be excluding +inputs. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From eb02c4fb585644f660570bf91b9ac88208f080cd Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Mon, 3 May 2021 15:46:57 -0400 Subject: [PATCH 2/8] pointercancel event not excluding input --- index.bs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/index.bs b/index.bs index aaec0ed..4678fd0 100644 --- a/index.bs +++ b/index.bs @@ -416,9 +416,11 @@ gesture. The mousemove events after the mousedown event and the pointermove events after -the pointerdown event, -which trigger dragging elements around or resizing elements but not scrolling, should be excluding -inputs. +the pointerdown event +with no pointercancel +event fired, which trigger dragging elements around or resizing elements but not scrolling, should be excluding inputs. +The pointercancel event is +fired when touch scroll starts, so it is not an excluding input. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From 595e54e7b3fcb8f476eed0eb4cd211a50976fa6e Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Wed, 2 Jun 2021 03:56:13 -0400 Subject: [PATCH 3/8] Update index.bs --- index.bs | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/index.bs b/index.bs index 4678fd0..5171737 100644 --- a/index.bs +++ b/index.bs @@ -413,14 +413,17 @@ The user agent may delay the reporting of layout shifts after a until such time as it is known that the event does not begin a fling or scroll gesture. -The mousemove events after the -mousedown event and the -pointermove events after -the pointerdown event -with no pointercancel -event fired, which trigger dragging elements around or resizing elements but not scrolling, should be excluding inputs. -The pointercancel event is -fired when touch scroll starts, so it is not an excluding input. +All the pointermove events after +the pointerdown event are not excluding inputs, +but the follow-up pointerup event +without seeing any pointercancel event +is an excluding input. The pointercancel event +is fired when the touch scroll starts, so it is not an excluding input. + +All the mousemove events between +a mousedown event and a +mouseup event and the +mouseup event should be excluding inputs. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From 2b392a3ae7aed061966e7c54e9ac03989581a94f Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Wed, 9 Jun 2021 19:12:14 -0400 Subject: [PATCH 4/8] Update index.bs --- index.bs | 37 +++++++++++++++++++++---------------- 1 file changed, 21 insertions(+), 16 deletions(-) diff --git a/index.bs b/index.bs index 5171737..a56d0c4 100644 --- a/index.bs +++ b/index.bs @@ -408,22 +408,27 @@ Excluding inputs generally include However, an event whose only effect is to begin or update a fling or scroll gesture is not an excluding input. -The user agent may delay the reporting of layout shifts after a -pointerdown event -until such time as it is known that the event does not begin a fling or scroll -gesture. - -All the pointermove events after -the pointerdown event are not excluding inputs, -but the follow-up pointerup event -without seeing any pointercancel event -is an excluding input. The pointercancel event -is fired when the touch scroll starts, so it is not an excluding input. - -All the mousemove events between -a mousedown event and a -mouseup event and the -mouseup event should be excluding inputs. +The user agent buffers the layout shifts of +pointermove events after a +pointerdown event and +mousemove events after a +mousedown event until a +pointerup event and a +mouseup event is received, which turn into touch and mouse drag actions. +These pointermove events, +mousemove events, +pointerup event and +mouseup event are all excluding inputs. +However, if a pointercancel event +is received instead, which means a fling or scroll is happending, the accumulate layout shifts score of the previous +pointermove events are reported, and these +pointermove events and the +pointercancel event are not excluding inputs. + +The mousemove and +pointermove events without seeing any +mousedown event and +pointerdown event before are also not excluding inputs. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From cef43ed0aa5c4fba7da34bfc097130162fd6c2bb Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Wed, 9 Jun 2021 19:17:33 -0400 Subject: [PATCH 5/8] Update index.bs --- index.bs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.bs b/index.bs index a56d0c4..a96464a 100644 --- a/index.bs +++ b/index.bs @@ -414,7 +414,7 @@ The user agent buffers the layout shifts of mousemove events after a mousedown event until a pointerup event and a -mouseup event is received, which turn into touch and mouse drag actions. +mouseup event are received, which turn into touch and mouse drag actions. These pointermove events, mousemove events, pointerup event and @@ -428,7 +428,7 @@ is received instead, which means a fling or scroll is happending, the accumulate The mousemove and pointermove events without seeing any mousedown event and -pointerdown event before are also not excluding inputs. +pointerdown event before are not excluding inputs. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From 5ff58c2a99fbd92078d8fb8c78d7c68cde796853 Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Thu, 15 Jul 2021 00:27:45 -0400 Subject: [PATCH 6/8] Update index.bs --- index.bs | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/index.bs b/index.bs index a96464a..c332c5a 100644 --- a/index.bs +++ b/index.bs @@ -408,27 +408,18 @@ Excluding inputs generally include However, an event whose only effect is to begin or update a fling or scroll gesture is not an excluding input. -The user agent buffers the layout shifts of -pointermove events after a -pointerdown event and -mousemove events after a +The user agent may delay the reporting of layout shifts after a +pointerdown event or a mousedown event until a -pointerup event and a +pointerup event or a mouseup event are received, which turn into touch and mouse drag actions. These pointermove events, mousemove events, pointerup event and mouseup event are all excluding inputs. However, if a pointercancel event -is received instead, which means a fling or scroll is happending, the accumulate layout shifts score of the previous -pointermove events are reported, and these -pointermove events and the -pointercancel event are not excluding inputs. - -The mousemove and -pointermove events without seeing any -mousedown event and -pointerdown event before are not excluding inputs. +is received instead, which means a fling or scroll is happening, the +pointercancel event is not an excluding input. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From d73ca606ca3e3dd1ed306b6ec7f63578ccb9d910 Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Fri, 16 Jul 2021 01:34:12 -0400 Subject: [PATCH 7/8] Update index.bs --- index.bs | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/index.bs b/index.bs index c332c5a..372381f 100644 --- a/index.bs +++ b/index.bs @@ -408,18 +408,14 @@ Excluding inputs generally include However, an event whose only effect is to begin or update a fling or scroll gesture is not an excluding input. -The user agent may delay the reporting of layout shifts after a -pointerdown event or a -mousedown event until a -pointerup event or a -mouseup event are received, which turn into touch and mouse drag actions. -These pointermove events, -mousemove events, -pointerup event and -mouseup event are all excluding inputs. -However, if a pointercancel event -is received instead, which means a fling or scroll is happening, the -pointercancel event is not an excluding input. +* When a pointerdown event or +a mousedown event is received, the +user agent starts buffering the layout shifts. +* When a pointercancel event +is received, all the accumulated layout shift score in the buffer is reported, and it is not an excluding input. +* When a pointerup event or a +mouseup event is received, the buffer is reset and +the layout shift score is not reported. They are excluding inputs. {{LayoutShift}} interface {#sec-layout-shift} ======================================= From 4df957a9bcaf3c855712c35f9d79899e32377284 Mon Sep 17 00:00:00 2001 From: Lan Wei Date: Fri, 16 Jul 2021 18:29:32 -0400 Subject: [PATCH 8/8] Update index.bs --- index.bs | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/index.bs b/index.bs index 372381f..f4fa715 100644 --- a/index.bs +++ b/index.bs @@ -409,13 +409,15 @@ However, an event whose only effect is to begin or update a fling or scroll gesture is not an excluding input. * When a pointerdown event or -a mousedown event is received, the -user agent starts buffering the layout shifts. + a mousedown event is received, the + user agent starts buffering the layout shifts. * When a pointercancel event -is received, all the accumulated layout shift score in the buffer is reported, and it is not an excluding input. + is received, all the accumulated layout shift score in the buffer is reported, and it is not an excluding input. * When a pointerup event or a -mouseup event is received, the buffer is reset and -the layout shift score is not reported. They are excluding inputs. + mouseup event is received, the buffer is reset. + The pointerup or + mouseup event is considered an excluding input + and then the layout shifts are reported with no score change. {{LayoutShift}} interface {#sec-layout-shift} =======================================