New issue
Advanced search Search tips

Issue 787234 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 2
Type: Bug



Sign in to add a comment

[MD Extensions] Options dialog incorrectly sized.

Project Member Reported by dpa...@chromium.org, Nov 21 2017

Issue description

It seems that the cr-dialog's default styles interfere with the desired size of the options dialog.

Repro steps:
1) install https://chrome.google.com/webstore/detail/window-resizer/kkelicaakdanhinjdeammmilcgefonfh.
2) Go to details page and click "Extension options". A new dialog shows up.

Expected: The dialog is sized properly.
Actual: The dialog is too narrow. Note this works fine in the old UI.
 
options_dialog_too_small.png
61.0 KB View Download
options_dialog_correct_size.png
97.0 KB View Download

Comment 1 by dpa...@chromium.org, Nov 22 2017

Owner: dpa...@chromium.org
Status: Assigned (was: Available)
Investigating this...

Comment 2 by dpa...@chromium.org, Nov 22 2017

Status: Started (was: Assigned)

Comment 4 by dpa...@chromium.org, Nov 23 2017

Uploading screencasts of before and after.
options_dialog_before.mp4
2.9 MB View Download
options_dialog_after.mp4
2.7 MB View Download
Project Member

Comment 5 by bugdroid1@chromium.org, Nov 30 2017

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

commit 08c0cf8984048bc5c40d01fc679c11b97c17e5a5
Author: dpapad <dpapad@chromium.org>
Date: Thu Nov 30 00:52:35 2017

MD Extensions polish: Update options dialog sizing logic.

 - Remove unwanted default paddings and border of cr-dialog.
 - Fix sizing logic to respect the user provided preferred values
   (with some constraints).
 - Simplify logic to size the options dialog, by using width: fit-content,
   (no need to use JS to calculate min-width for the title + icon).
 - Eliminate flicker (previously the dialog was re-sized twice).
 - Updated tests to use a real extension that specifies an options_ui in the
   manifest.json, to ensure that the onpreferredsizechanged logic works end-to-end.

Bug:  787234 
Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: Ic1e9b372c5889f08abc42cf1c460291b7b63062e
Reviewed-on: https://chromium-review.googlesource.com/786084
Commit-Queue: Demetrios Papadopoulos <dpapad@chromium.org>
Reviewed-by: Devlin <rdevlin.cronin@chromium.org>
Reviewed-by: Dan Beam (no longer on Chrome) <dbeam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#520353}
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/browser/resources/md_extensions/options_dialog.html
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/browser/resources/md_extensions/options_dialog.js
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/browser/ui/webui/extensions/extension_settings_browsertest.cc
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/browser/ui/webui/extensions/extension_settings_browsertest.h
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/test/BUILD.gn
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/test/data/webui/extensions/cr_extensions_browsertest.js
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/chrome/test/data/webui/extensions/extension_options_dialog_test.js
[modify] https://crrev.com/08c0cf8984048bc5c40d01fc679c11b97c17e5a5/ui/webui/resources/cr_elements/cr_dialog/cr_dialog.html

Comment 6 by dpa...@chromium.org, Nov 30 2017

Status: Fixed (was: Started)

Sign in to add a comment