Add an enterprise policy to disable KeyboardFocusableScrollers [chromium/src : main]

0 views
Skip to first unread message

Di Zhang (Gerrit)

unread,
May 10, 2024, 12:01:12 PM5/10/24
to Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, Enterprise Policy Reviews, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
Attention needed from Mason Freed

Di Zhang voted Commit-Queue+1

Commit-Queue+1
Open in Gerrit

Related details

Attention is currently required from:
  • Mason Freed
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
Gerrit-Change-Number: 5531405
Gerrit-PatchSet: 1
Gerrit-Owner: Di Zhang <dizh...@chromium.org>
Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
Gerrit-Attention: Mason Freed <mas...@chromium.org>
Gerrit-Comment-Date: Fri, 10 May 2024 16:01:00 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Mason Freed (Gerrit)

unread,
May 10, 2024, 12:53:48 PM5/10/24
to Di Zhang, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, Enterprise Policy Reviews, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
Attention needed from Di Zhang

Mason Freed added 6 comments

Patchset-level comments
File-level comment, Patchset 3 (Latest):
Mason Freed . resolved

The code looks good, except for the case when the feature is disabled. Also the test has a few bugs.

Commit Message
Line 11, Patchset 3 (Latest):If unset, the feature should remain enabled.
Mason Freed . unresolved

nit: `the feature will be controlled by the state of the underlying runtime enabled feature.`

File chrome/browser/chrome_content_browser_client.cc
Line 2663, Patchset 3 (Latest): if (prefs->GetBoolean(
policy::policy_prefs::kKeyboardFocusableScrollersEnabled)) {
command_line->AppendSwitch(
blink::switches::kKeyboardFocusableScrollersEnabled);
}
Mason Freed . unresolved

Does this work? It seems like setting the policy to `false` (which should turn off the feature) won't do anything in this case.

File chrome/browser/policy/test/keyboard_focusable_scollers_policy_browsertest.cc
Line 39, Patchset 3 (Latest): feature_list_.InitAndDisableFeature(
blink::features::kKeyboardFocusableScrollers);
Mason Freed . unresolved

I think it'd be a good idea for this test to check both cases: when the base feature is enabled and disabled. I think (with the code as-is) it'll fail when the feature is enabled.

Line 85, Patchset 3 (Latest): EXPECT_TRUE(message_queue.WaitForMessage(&message));
Mason Freed . unresolved

no such thing

File third_party/blink/common/switches.cc
Line 126, Patchset 3 (Latest):// an nterprise policy override.
Mason Freed . unresolved

nit: `enterprise`

Open in Gerrit

Related details

Attention is currently required from:
  • Di Zhang
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 3
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Di Zhang <dizh...@chromium.org>
    Gerrit-Comment-Date: Fri, 10 May 2024 16:53:37 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Di Zhang (Gerrit)

    unread,
    May 10, 2024, 2:45:23 PM5/10/24
    to Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, Enterprise Policy Reviews, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Mason Freed

    Di Zhang voted and added 5 comments

    Votes added by Di Zhang

    Commit-Queue+1

    5 comments

    Commit Message
    Line 11, Patchset 3:If unset, the feature should remain enabled.
    Mason Freed . resolved

    nit: `the feature will be controlled by the state of the underlying runtime enabled feature.`

    Di Zhang

    Done

    File chrome/browser/chrome_content_browser_client.cc
    Line 2663, Patchset 3: if (prefs->GetBoolean(

    policy::policy_prefs::kKeyboardFocusableScrollersEnabled)) {
    command_line->AppendSwitch(
    blink::switches::kKeyboardFocusableScrollersEnabled);
    }
    Mason Freed . resolved

    Does this work? It seems like setting the policy to `false` (which should turn off the feature) won't do anything in this case.

    Di Zhang

    Fixed by adding an else case.

    File chrome/browser/policy/test/keyboard_focusable_scollers_policy_browsertest.cc
    Line 39, Patchset 3: feature_list_.InitAndDisableFeature(
    blink::features::kKeyboardFocusableScrollers);
    Mason Freed . unresolved

    I think it'd be a good idea for this test to check both cases: when the base feature is enabled and disabled. I think (with the code as-is) it'll fail when the feature is enabled.

    Di Zhang
    I agree this should be 
    ```
    feature_list_.InitAndEnableFeature(
    blink::features::kKeyboardFocusableScrollers);
    ```
    However, why should we also test for disabled case? Wouldn't all cases return false since the feature is off?
    Line 85, Patchset 3: EXPECT_TRUE(message_queue.WaitForMessage(&message));
    Mason Freed . resolved

    no such thing

    Di Zhang

    Done

    File third_party/blink/common/switches.cc
    Line 126, Patchset 3:// an nterprise policy override.
    Mason Freed . resolved

    nit: `enterprise`

    Di Zhang

    Done

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mason Freed
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 5
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Mason Freed <mas...@chromium.org>
    Gerrit-Comment-Date: Fri, 10 May 2024 18:45:14 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    Comment-In-Reply-To: Mason Freed <mas...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Mason Freed (Gerrit)

    unread,
    May 10, 2024, 6:28:36 PM5/10/24
    to Di Zhang, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, Enterprise Policy Reviews, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Di Zhang

    Mason Freed added 2 comments

    File chrome/browser/chrome_content_browser_client.cc
    Line 2663, Patchset 6 (Latest): if (prefs->GetBoolean(

    policy::policy_prefs::kKeyboardFocusableScrollersEnabled)) {
    command_line->AppendSwitch(
    blink::switches::kKeyboardFocusableScrollersEnabled);
    Mason Freed . unresolved

    But I don't think you want to do that. The point of the policy is to allow opting out. As the description of the policy says, if you set it to "true" or "unset", the feature is controlled by the underlying state of the feature. So I think you just want the else here, right?

    File chrome/browser/policy/test/keyboard_focusable_scollers_policy_browsertest.cc
    Line 39, Patchset 3: feature_list_.InitAndDisableFeature(
    blink::features::kKeyboardFocusableScrollers);
    Mason Freed . unresolved

    I think it'd be a good idea for this test to check both cases: when the base feature is enabled and disabled. I think (with the code as-is) it'll fail when the feature is enabled.

    Di Zhang
    I agree this should be 
    ```
    feature_list_.InitAndEnableFeature(
    blink::features::kKeyboardFocusableScrollers);
    ```
    However, why should we also test for disabled case? Wouldn't all cases return false since the feature is off?
    Mason Freed

    You want to check:

    1. Feature enabled, policy disabled (KFS should be disabled)
    2. Feature enabled, policy enabled or default (KFS should be enabled)
    3. Feature disabled, policy enabled or disabled or default (KFS should be disabled)

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Di Zhang
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 6
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Di Zhang <dizh...@chromium.org>
    Gerrit-Comment-Date: Fri, 10 May 2024 22:28:15 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Di Zhang <dizh...@chromium.org>
    Comment-In-Reply-To: Mason Freed <mas...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Di Zhang (Gerrit)

    unread,
    May 13, 2024, 12:49:42 PM5/13/24
    to Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, Enterprise Policy Reviews, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Mason Freed

    Di Zhang voted and added 2 comments

    Votes added by Di Zhang

    Commit-Queue+1

    2 comments

    File chrome/browser/chrome_content_browser_client.cc
    Line 2663, Patchset 6: if (prefs->GetBoolean(

    policy::policy_prefs::kKeyboardFocusableScrollersEnabled)) {
    command_line->AppendSwitch(
    blink::switches::kKeyboardFocusableScrollersEnabled);
    Mason Freed . resolved

    But I don't think you want to do that. The point of the policy is to allow opting out. As the description of the policy says, if you set it to "true" or "unset", the feature is controlled by the underlying state of the feature. So I think you just want the else here, right?

    Di Zhang

    Acknowledged

    File chrome/browser/policy/test/keyboard_focusable_scollers_policy_browsertest.cc
    Line 39, Patchset 3: feature_list_.InitAndDisableFeature(
    blink::features::kKeyboardFocusableScrollers);
    Mason Freed . resolved

    I think it'd be a good idea for this test to check both cases: when the base feature is enabled and disabled. I think (with the code as-is) it'll fail when the feature is enabled.

    Di Zhang
    I agree this should be 
    ```
    feature_list_.InitAndEnableFeature(
    blink::features::kKeyboardFocusableScrollers);
    ```
    However, why should we also test for disabled case? Wouldn't all cases return false since the feature is off?
    Mason Freed

    You want to check:

    1. Feature enabled, policy disabled (KFS should be disabled)
    2. Feature enabled, policy enabled or default (KFS should be enabled)
    3. Feature disabled, policy enabled or disabled or default (KFS should be disabled)

    Di Zhang

    Done

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mason Freed
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 7
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Mason Freed <mas...@chromium.org>
    Gerrit-Comment-Date: Mon, 13 May 2024 16:49:32 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Di Zhang (Gerrit)

    unread,
    May 13, 2024, 6:31:04 PM5/13/24
    to Enterprise Policy Reviews, Owen Min, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Colin Blundell, Enterprise Policy Reviews, Mason Freed, Owen Min and Pavel Feldman

    Di Zhang added 1 comment

    Patchset-level comments
    File-level comment, Patchset 7:
    Di Zhang . resolved

    Adding more enterprise policy reviewers, PTAL thanks.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Colin Blundell
    • Enterprise Policy Reviews
    • Mason Freed
    • Owen Min
    • Pavel Feldman
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 8
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Colin Blundell <blun...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-Reviewer: Owen Min <zm...@chromium.org>
    Gerrit-Reviewer: Pavel Feldman <pfel...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-Attention: Pavel Feldman <pfel...@chromium.org>
    Gerrit-Attention: Colin Blundell <blun...@chromium.org>
    Gerrit-Attention: Owen Min <zm...@chromium.org>
    Gerrit-Attention: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-Attention: Mason Freed <mas...@chromium.org>
    Gerrit-Comment-Date: Mon, 13 May 2024 22:30:54 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    gwsq (Gerrit)

    unread,
    May 13, 2024, 6:31:47 PM5/13/24
    to Di Zhang, Enterprise Policy Reviews, Owen Min, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Colin Blundell, Mason Freed, Owen Min and Pavel Feldman

    Message from gwsq

    Reviewer source(s):
    zm...@chromium.org is from context(chrome/enterprise/gwsq/enterprise-policy-review.gwsq)

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Colin Blundell
    • Mason Freed
    • Owen Min
    • Pavel Feldman
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
    Gerrit-Change-Number: 5531405
    Gerrit-PatchSet: 8
    Gerrit-Owner: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Colin Blundell <blun...@chromium.org>
    Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
    Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
    Gerrit-Reviewer: Owen Min <zm...@chromium.org>
    Gerrit-Reviewer: Pavel Feldman <pfel...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Pavel Feldman <pfel...@chromium.org>
    Gerrit-Attention: Colin Blundell <blun...@chromium.org>
    Gerrit-Attention: Owen Min <zm...@chromium.org>
    Gerrit-Attention: Mason Freed <mas...@chromium.org>
    Gerrit-Comment-Date: Mon, 13 May 2024 22:31:38 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Colin Blundell (Gerrit)

    unread,
    May 14, 2024, 3:40:48 AM5/14/24
    to Di Zhang, Enterprise Policy Reviews, Owen Min, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Di Zhang, Mason Freed, Owen Min and Pavel Feldman

    Colin Blundell added 1 comment

    Patchset-level comments
    File-level comment, Patchset 8 (Latest):
    Colin Blundell . resolved

    Thanks! Please ping once the other reviewers have LGTM'd as they have the expertise for the technical changes here, and then I can stamp for whatever is still needed.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Di Zhang
    Gerrit-Attention: Di Zhang <dizh...@chromium.org>
    Gerrit-Attention: Owen Min <zm...@chromium.org>
    Gerrit-Attention: Mason Freed <mas...@chromium.org>
    Gerrit-Comment-Date: Tue, 14 May 2024 07:40:39 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Owen Min (Gerrit)

    unread,
    May 14, 2024, 12:39:41 PM5/14/24
    to Di Zhang, Enterprise Policy Reviews, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Mason Freed, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
    Attention needed from Di Zhang, Mason Freed and Pavel Feldman

    Owen Min added 4 comments

    File components/policy/resources/templates/policy_definitions/Miscellaneous/KeyboardFocusableScrollersEnabled.yaml
    Line 4, Patchset 8 (Latest): This policy provides a temporary opt-out for the new keyboard focusable scrollers behavior.
    When this policy is Enabled or unset, scrollers without focusable children are keyboard-focusable by default. Further, scrollers are click-focusable and programmatically-focusable by default.
    When this policy is Disabled, scrollers will not be focusable by default.
    This policy is a temporary workaround, and will be removed in M135.
    Owen Min . unresolved

    Please add empty lines between each section.

    ```
    This policy provides ...

    When this policy is ...

    When this policy is ...

    This policy is a temporary ...

    ```

    Line 15, Patchset 8 (Latest): - caption: "Enabled: Scrollers without focusable children are keyboard-focusable by default. Scrollers are click-focusable and programmatically-focusable by default."
    Owen Min . unresolved

    You don't have to repeat yourself in the caption here for all details. Keep it short and say something like

    ```
    Scrollers are focusable

    Scrollers are not focusable

    ```

    Line 24, Patchset 8 (Latest): - chrome.*:126-
    Owen Min . unresolved

    We have passed the M126 branch point. Please merge it back to M126. In case we can't merge, please update the milestone to M127.

    File components/policy/test/data/pref_mapping/KeyboardFocusableScrollersEnabled.json
    Line 12, Patchset 8 (Latest): "policy_pref_mapping_tests": [
    Owen Min . unresolved

    Simple test can use `simple_policy_pref_mapping_test`

    You can learn more from docs/enterprise/policy_pref_mapping_test.md.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Di Zhang
    • Mason Freed
    • Pavel Feldman
    Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement is not satisfiedCode-Review
      • requirement is not satisfiedNo-Unresolved-Comments
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
      Gerrit-Change-Number: 5531405
      Gerrit-PatchSet: 8
      Gerrit-Owner: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Colin Blundell <blun...@chromium.org>
      Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
      Gerrit-Reviewer: Owen Min <zm...@chromium.org>
      Gerrit-Reviewer: Pavel Feldman <pfel...@chromium.org>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Pavel Feldman <pfel...@chromium.org>
      Gerrit-Attention: Di Zhang <dizh...@chromium.org>
      Gerrit-Attention: Mason Freed <mas...@chromium.org>
      Gerrit-Comment-Date: Tue, 14 May 2024 16:39:26 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Mason Freed (Gerrit)

      unread,
      May 14, 2024, 2:10:27 PM5/14/24
      to Di Zhang, Enterprise Policy Reviews, Owen Min, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
      Attention needed from Di Zhang and Pavel Feldman

      Mason Freed voted and added 1 comment

      Votes added by Mason Freed

      Code-Review+1

      1 comment

      Patchset-level comments
      Mason Freed . resolved

      LGTM!

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Di Zhang
      • Pavel Feldman
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement satisfiedCode-Review
      • requirement is not satisfiedNo-Unresolved-Comments
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
      Gerrit-Change-Number: 5531405
      Gerrit-PatchSet: 8
      Gerrit-Owner: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Colin Blundell <blun...@chromium.org>
      Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
      Gerrit-Reviewer: Owen Min <zm...@chromium.org>
      Gerrit-Reviewer: Pavel Feldman <pfel...@chromium.org>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Pavel Feldman <pfel...@chromium.org>
      Gerrit-Attention: Di Zhang <dizh...@chromium.org>
      Gerrit-Comment-Date: Tue, 14 May 2024 18:10:14 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Di Zhang (Gerrit)

      unread,
      May 14, 2024, 2:47:02 PM5/14/24
      to Mason Freed, Enterprise Policy Reviews, Owen Min, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
      Attention needed from Owen Min and Pavel Feldman

      Di Zhang added 4 comments

      File components/policy/resources/templates/policy_definitions/Miscellaneous/KeyboardFocusableScrollersEnabled.yaml
      Line 4, Patchset 8: This policy provides a temporary opt-out for the new keyboard focusable scrollers behavior.

      When this policy is Enabled or unset, scrollers without focusable children are keyboard-focusable by default. Further, scrollers are click-focusable and programmatically-focusable by default.
      When this policy is Disabled, scrollers will not be focusable by default.
      This policy is a temporary workaround, and will be removed in M135.
      Owen Min . resolved

      Please add empty lines between each section.

      ```
      This policy provides ...

      When this policy is ...

      When this policy is ...

      This policy is a temporary ...

      ```

      Di Zhang

      Done

      Line 15, Patchset 8: - caption: "Enabled: Scrollers without focusable children are keyboard-focusable by default. Scrollers are click-focusable and programmatically-focusable by default."
      Owen Min . resolved

      You don't have to repeat yourself in the caption here for all details. Keep it short and say something like

      ```
      Scrollers are focusable

      Scrollers are not focusable

      ```

      Di Zhang

      Done

      Line 24, Patchset 8: - chrome.*:126-
      Owen Min . resolved

      We have passed the M126 branch point. Please merge it back to M126. In case we can't merge, please update the milestone to M127.

      Di Zhang

      Updating the milestone to M127 instead.

      File components/policy/test/data/pref_mapping/KeyboardFocusableScrollersEnabled.json
      Line 12, Patchset 8: "policy_pref_mapping_tests": [
      Owen Min . resolved

      Simple test can use `simple_policy_pref_mapping_test`

      You can learn more from docs/enterprise/policy_pref_mapping_test.md.

      Di Zhang

      Done

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Owen Min
      • Pavel Feldman
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement satisfiedCode-Review
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
      Gerrit-Change-Number: 5531405
      Gerrit-PatchSet: 9
      Gerrit-Owner: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Colin Blundell <blun...@chromium.org>
      Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
      Gerrit-Reviewer: Owen Min <zm...@chromium.org>
      Gerrit-Reviewer: Pavel Feldman <pfel...@chromium.org>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Pavel Feldman <pfel...@chromium.org>
      Gerrit-Attention: Owen Min <zm...@chromium.org>
      Gerrit-Comment-Date: Tue, 14 May 2024 18:46:50 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      Comment-In-Reply-To: Owen Min <zm...@chromium.org>
      satisfied_requirement
      open
      diffy

      Owen Min (Gerrit)

      unread,
      May 14, 2024, 2:51:17 PM5/14/24
      to Di Zhang, Mason Freed, Enterprise Policy Reviews, Colin Blundell, Pavel Feldman, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
      Attention needed from Di Zhang and Pavel Feldman

      Owen Min voted Code-Review+1

      Code-Review+1
      Open in Gerrit

      Related details

      Attention is currently required from:
      • Di Zhang
      • Pavel Feldman
      Gerrit-Attention: Di Zhang <dizh...@chromium.org>
      Gerrit-Comment-Date: Tue, 14 May 2024 18:51:04 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      Di Zhang (Gerrit)

      unread,
      May 14, 2024, 4:03:39 PM5/14/24
      to Jeremy Roman, Owen Min, Mason Freed, Enterprise Policy Reviews, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
      Attention needed from Jeremy Roman

      Di Zhang voted and added 2 comments

      Votes added by Di Zhang

      Commit-Queue+1

      2 comments

      Patchset-level comments
      File-level comment, Patchset 9 (Latest):
      Di Zhang . resolved

      Updated the reviewers given current LGTM, PTAL thanks!

      File-level comment, Patchset 9 (Latest):
      Di Zhang . resolved

      Updating reviewers.

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Jeremy Roman
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement satisfiedCode-Review
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
      Gerrit-Change-Number: 5531405
      Gerrit-PatchSet: 9
      Gerrit-Owner: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
      Gerrit-Reviewer: Jeremy Roman <jbr...@chromium.org>
      Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
      Gerrit-Reviewer: Owen Min <zm...@chromium.org>
      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
      Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Jeremy Roman <jbr...@chromium.org>
      Gerrit-Comment-Date: Tue, 14 May 2024 20:03:25 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      Jeremy Roman (Gerrit)

      unread,
      May 14, 2024, 9:44:17 PM5/14/24
      to Di Zhang, Jeremy Roman, Owen Min, Mason Freed, Enterprise Policy Reviews, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org
      Attention needed from Di Zhang

      Jeremy Roman voted and added 2 comments

      Votes added by Jeremy Roman

      Code-Review+1

      2 comments

      Commit Message
      Line 18, Patchset 9 (Latest):Bug: 40113891
      Bug: 336490037
      Bug: 337158524
      Jeremy Roman . unresolved

      I think these are normally written on one line, separated by commas.

      ```suggestion
      Bug: 40113891,336490037,337158524
      ```

      Not sure whether tools process this form correctly or not.

      File third_party/blink/common/switches.cc
      Line 128, Patchset 9 (Latest): "keyboard-focusable-scrollers-enabled";
      Jeremy Roman . unresolved

      nit: usually these are named `enable-foo` and `disable-foo`; is there a reason to deviate here?

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Di Zhang
      Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement satisfiedCode-Review
        • requirement is not satisfiedNo-Unresolved-Comments
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
        Gerrit-Change-Number: 5531405
        Gerrit-PatchSet: 9
        Gerrit-Owner: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Jeremy Roman <jbr...@chromium.org>
        Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
        Gerrit-Reviewer: Owen Min <zm...@chromium.org>
        Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
        Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
        Gerrit-CC: gwsq
        Gerrit-Attention: Di Zhang <dizh...@chromium.org>
        Gerrit-Comment-Date: Wed, 15 May 2024 01:44:03 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Di Zhang (Gerrit)

        unread,
        May 14, 2024, 10:42:19 PM5/14/24
        to Jeremy Roman, Owen Min, Mason Freed, Enterprise Policy Reviews, Tricium, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org

        Di Zhang voted and added 2 comments

        Votes added by Di Zhang

        Commit-Queue+2

        2 comments

        Commit Message
        Line 18, Patchset 9:Bug: 40113891
        Bug: 336490037
        Bug: 337158524
        Jeremy Roman . resolved

        I think these are normally written on one line, separated by commas.

        ```suggestion
        Bug: 40113891,336490037,337158524
        ```

        Not sure whether tools process this form correctly or not.

        Di Zhang
        File third_party/blink/common/switches.cc
        Line 128, Patchset 9: "keyboard-focusable-scrollers-enabled";
        Jeremy Roman . resolved

        nit: usually these are named `enable-foo` and `disable-foo`; is there a reason to deviate here?

        Di Zhang

        We have a few Blink Features that use the format `kFeatureEnabled`, for example `kMutationEventsEnabled`. For this case, we chose to use `opt-out` instead so it can match origin trial feature KeyboardFocusableScrollersOptOut.

        Open in Gerrit

        Related details

        Attention set is empty
        Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement satisfiedCode-Review
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
        Gerrit-Change-Number: 5531405
        Gerrit-PatchSet: 10
        Gerrit-Owner: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Jeremy Roman <jbr...@chromium.org>
        Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
        Gerrit-Reviewer: Owen Min <zm...@chromium.org>
        Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
        Gerrit-CC: Enterprise Policy Reviews <enterprise-p...@google.com>
        Gerrit-CC: gwsq
        Gerrit-Comment-Date: Wed, 15 May 2024 02:42:06 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: Yes
        Comment-In-Reply-To: Jeremy Roman <jbr...@chromium.org>
        satisfied_requirement
        open
        diffy

        Chromium LUCI CQ (Gerrit)

        unread,
        May 14, 2024, 10:49:08 PM5/14/24
        to Di Zhang, Jeremy Roman, Owen Min, Mason Freed, Enterprise Policy Reviews, Tricium, Chromium Metrics Reviews, chromium...@chromium.org, asvitkine...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, blundell+...@chromium.org, jmedle...@chromium.org, kinuko...@chromium.org

        Chromium LUCI CQ submitted the change with unreviewed changes

        Unreviewed changes

        9 is the latest approved patch-set.
        No files were changed between the latest approved patch-set and the submitted one.

        Change information

        Commit message:
        Add an enterprise policy to disable KeyboardFocusableScrollers

        This policy, when disabled, will revert to previous behavior when
        scrollers are not focusable by default. If unset, the feature will be

        controlled by the state of the underlying runtime enabled feature.

        This feature broke a website's focus logic during Finch experiment.
        Out of caution, I would like to add an enterprise policy to help
        existing users to adapt to the new changes.
        Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
        Bug: 40113891,336490037,337158524
        Reviewed-by: Owen Min <zm...@chromium.org>
        Commit-Queue: Di Zhang <dizh...@chromium.org>
        Reviewed-by: Jeremy Roman <jbr...@chromium.org>
        Reviewed-by: Mason Freed <mas...@chromium.org>
        Cr-Commit-Position: refs/heads/main@{#1301061}
        Files:
        • M chrome/browser/chrome_content_browser_client.cc
        • M chrome/browser/policy/BUILD.gn
        • M chrome/browser/policy/configuration_policy_handler_list_factory.cc
        • A chrome/browser/policy/test/keyboard_focusable_scollers_policy_browsertest.cc
        • M components/policy/core/common/policy_pref_names.cc
        • M components/policy/core/common/policy_pref_names.h
        • M components/policy/resources/templates/policies.yaml
        • A components/policy/resources/templates/policy_definitions/Miscellaneous/KeyboardFocusableScrollersEnabled.yaml
        • A components/policy/test/data/pref_mapping/KeyboardFocusableScrollersEnabled.json
        • M content/child/runtime_features.cc
        • M testing/variations/fieldtrial_testing_config.json
        • M third_party/blink/common/switches.cc
        • M third_party/blink/public/common/switches.h
        • M third_party/blink/renderer/platform/runtime_enabled_features.json5
        • M tools/metrics/histograms/metadata/enterprise/enums.xml
        Change size: M
        Delta: 15 files changed, 237 insertions(+), 1 deletion(-)
        Branch: refs/heads/main
        Submit Requirements:
        • requirement satisfiedCode-Review: +1 by Mason Freed, +1 by Owen Min, +1 by Jeremy Roman
        Open in Gerrit
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: merged
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I7d001326dadb1a251d9c4df198109d99c01815c5
        Gerrit-Change-Number: 5531405
        Gerrit-PatchSet: 11
        Gerrit-Owner: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
        Gerrit-Reviewer: Di Zhang <dizh...@chromium.org>
        Gerrit-Reviewer: Jeremy Roman <jbr...@chromium.org>
        Gerrit-Reviewer: Mason Freed <mas...@chromium.org>
        Gerrit-Reviewer: Owen Min <zm...@chromium.org>
        open
        diffy
        satisfied_requirement
        Reply all
        Reply to author
        Forward
        0 new messages