New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 893626 link

Starred by 1 user

Issue metadata

Status: Started
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 3
Type: Feature

Blocked on:
issue 889229

Blocking:
issue 892725



Sign in to add a comment

App menu: implement 'Managed by' footnote message

Project Member Reported by nicolaso@chromium.org, Oct 9

Issue description

Per the UI proposal [1], we want a footnote in the App Menu that displays a message if the user has any policies set.

This will help improve transparency for our enterprise users.

[1] https://docs.google.com/presentation/d/1Q6Pn0YB1UgH1QKiSMQadTjStMMXKVoH60nb9QN3ee1o/edit
 
Project Member

Comment 1 by bugdroid1@chromium.org, Oct 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f

commit f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f
Author: Nicolas Ouellet-payeur <nicolaso@chromium.org>
Date: Thu Oct 18 19:34:09 2018

Add BrowserPolicyConnector::HasMachineLevelPolicies()

It returns true when there are any policies at the machine level,
whether that's from a platform provider, or from cloud policies.

Bug: 893626, 893628
Change-Id: I6e90ff54ee400a82df04c2f671d408d04b3e3bc5
Reviewed-on: https://chromium-review.googlesource.com/c/1269764
Commit-Queue: Nicolas Ouellet-Payeur <nicolaso@chromium.org>
Reviewed-by: Maksim Ivanov <emaxx@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600866}
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/browser/chromeos/policy/browser_policy_connector_chromeos.cc
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/browser/policy/chrome_browser_policy_connector.cc
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/browser/policy/chrome_browser_policy_connector.h
[add] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/browser/policy/chrome_browser_policy_connector_unittest.cc
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/chrome/test/BUILD.gn
[modify] https://crrev.com/f4d54fcbe0fd1022dbf9dd7606da9387d640bd5f/components/policy/core/browser/browser_policy_connector.h

Project Member

Comment 2 by bugdroid1@chromium.org, Nov 5

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/82eb65bb8501adff6e263d2531a86ab642fa1251

commit 82eb65bb8501adff6e263d2531a86ab642fa1251
Author: Nicolas Ouellet-payeur <nicolaso@chromium.org>
Date: Mon Nov 05 16:49:27 2018

Add a footnote to the App Menu for enterprise users

As this is work-in-progress, it is behind a new feature flag.

Users that are managed (e.g. because they have policies set) will have a
message show up at the bottom of Chrome's App Menu. Clicking that
message redirects to a help center article, describing how to find out
whether your computer is managed.

Bug: 893626
Change-Id: Ie073c2f5d21db235736bc3dcf51005a4123d59b0
Reviewed-on: https://chromium-review.googlesource.com/c/1297072
Reviewed-by: Michael Wasserman <msw@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: Maksim Ivanov <emaxx@chromium.org>
Reviewed-by: Dominick Ng <dominickn@chromium.org>
Reviewed-by: Greg Thompson <grt@chromium.org>
Commit-Queue: Nicolas Ouellet-Payeur <nicolaso@chromium.org>
Cr-Commit-Position: refs/heads/master@{#605357}
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ash/public/cpp/menu_struct_mojom_traits.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ash/public/cpp/menu_utils.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/app/chrome_command_ids.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/app/generated_resources.grd
[add] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/app/generated_resources_grd/IDS_MANAGED_BY_ORG.png.sha1
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/about_flags.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/flag_descriptions.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/flag_descriptions.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/BUILD.gn
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/browser_command_controller.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/libgtkui/native_theme_gtk.cc
[add] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/managed_ui.cc
[add] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/managed_ui.h
[add] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/managed_ui_browsertest.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/browser/ui/toolbar/app_menu_model.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/common/chrome_features.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/common/chrome_features.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/common/url_constants.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/common/url_constants.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/chrome/test/BUILD.gn
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/tools/metrics/histograms/enums.xml
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/base/models/menu_model.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/base/models/simple_menu_model.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/base/models/simple_menu_model.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/native_theme/common_theme.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/native_theme/native_theme.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/native_theme/native_theme_dark_aura.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/BUILD.gn
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_delegate.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_delegate.h
[delete] https://crrev.com/523e9b8e56a22808d4b60227fa653a8f30ffc1f1/ui/views/controls/menu/menu_footnote_unittest.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_item_view.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_item_view.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_model_adapter.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_model_adapter_unittest.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_scroll_view_container.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/menu_scroll_view_container.h
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/submenu_view.cc
[modify] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/submenu_view.h
[add] https://crrev.com/82eb65bb8501adff6e263d2531a86ab642fa1251/ui/views/controls/menu/submenu_view_unittest.cc

Couple of notes on the implementation

1. Increase the height of the row
2. Rounded corners for the overflow menu on Mac.
3. "organization" vs "Organization"

Attaching spec

Also tried checking this out in Canary on Windows, but was not able to see the change? 
Also tried checking out demo on Canary on Windows, but this message didn't show up?
Managed by_spec.png
42.8 KB View Download
Current.png
199 KB View Download
Also height of the row is 40px
Thanks for sharing the spec. I'll update the alignment to better match the spec, and fix the rounded corners on Mac.

As for Windows, I couldn't reproduce your issue on Canary 72.0.3622.0. Did you enable the 'show-managed-ui' flag in about:flags? Or perhaps your computer isn't managed [1].

Also found an issue on Windows, where the grey background gets drawn over the menu's bottom border. It's especially obvious in the menu's bottom left corner [1].

I'll take a look at all of that as soon as I can. :-)

[1] https://support.google.com/chromebook/answer/1331549
[2] https://imgur.com/a/EAapw7j
Cc: wlarsen@google.com
+wlarsen@ FYI
namratakannan@, I noticed a small issue with the spec for Mac OS. The spec says to use a 16px margin on either side of the icon.

However, on Mac OS, the left margin of the menu is is 25px, not 16px. So, if we use 16px on the left, it won't be aligned with the other menu items.

Anyways, should I adjust the right margin to also be 25px? Or should I use 16px still?
macos.png
38.0 KB View Download
pixelmetrics.png
40.4 KB View Download
Hey nicolas, thanks for calling it out. Let us stick to the MacOS guidelines (25px) and ensure that it is aligned with the rest of the content.
Project Member

Comment 9 by bugdroid1@chromium.org, Dec 3

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c

commit 7897fa7f155d18e4ed202d5b99a6aa6d1d01320c
Author: Nicolas Ouellet-payeur <nicolaso@chromium.org>
Date: Mon Dec 03 23:29:56 2018

Fix App Menu's enterprise footnote alignment

Fixes the alignment of the "Managed by your organization" footnote in
the App Menu, to respect the spec from UX. Specifically:

- Footnote no longer spills over the menu's bottom border
- Add some top & bottom margin to make the footnote larger
- Fix capitalization on Mac OS ('Organization' => 'organization')
- Fix rounded corners not appearing on Mac OS

Bug: 893626
Change-Id: Iccaa6e702bc4ccdc756b34f362874059a4347a18
Reviewed-on: https://chromium-review.googlesource.com/c/1355888
Commit-Queue: Nicolas Ouellet-Payeur <nicolaso@chromium.org>
Reviewed-by: Michael Wasserman <msw@chromium.org>
Cr-Commit-Position: refs/heads/master@{#613317}
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/chrome/app/generated_resources.grd
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/chrome/browser/ui/toolbar/app_menu_model.cc
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/ui/views/controls/menu/menu_config.cc
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/ui/views/controls/menu/menu_config.h
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/ui/views/controls/menu/menu_item_view.cc
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/ui/views/controls/menu/menu_scroll_view_container.cc
[modify] https://crrev.com/7897fa7f155d18e4ed202d5b99a6aa6d1d01320c/ui/views/controls/menu/menu_scroll_view_container.h

namratakannan@: the patch from comment 9 is in Canary now, and should fix most of these issues. Can you take a another look?

I can't reproduce your issue on Windows. Make sure the flag is turned on, and your device is managed (see comment 5) when testing.
Checked on windows and I realized two issues:

1. The horizontal alignment of icon and text
2. Can we follow the padding that the update icon follows today on Windows? Image attached

BTW implementation on Mac looks good.


Managed by_Windows_Existing.png
81.4 KB View Download
Managed by_Windows_Desired.png
62.3 KB View Download
Reattaching last image
Managed by_Windows_Desired.png
62.5 KB View Download
FWIW the update icon also isn't aligned with the text baseline, it just looks less weird because of the shape of the icon.

Anyways, we can try enlarging the icon by 2px horizontally and moving it up by 4px.
4px.png
47.4 KB View Download

Sign in to add a comment