New issue
Advanced search Search tips

Issue 901045 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner: ----
Closed: Nov 19
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug



Sign in to add a comment

Updating a notification breaks the ui layout

Project Member Reported by knollr@chromium.org, Nov 1

Issue description

Chrome Version: 70.0.3538.77
OS: Linux

What steps will reproduce the problem?
(1) Create a new Notification with a tag and empty title & body (new Notification('', {tag: 'tag', body: ''}))
(2) Update the Notification with a body (new Notification('', {tag: 'tag', body: 'body'}))
(3) Update the Notification with a title (new Notification('Title', {tag: 'tag', body: 'body'}))

What is the expected result?
A Notification on screen with the title in the first line, and the body below that.

What happens instead?
The title is at the very bottom of the Notification.

I assume this will also happen on older Windows systems, basically every system that does not use native notifications, though I've only tested on Linux.

This happens because the NotificationView only calls AddChildView on CreateOrUpdateTitleView and similar calls - and removes the views if the title is empty.
Instead, we need to keep the relative ordering of the UI elements of the Notifications.
 
notification.png
3.2 KB View Download
Labels: Hotlist-DesktopUIConsider
Labels: Group-Notifications
Labels: -Hotlist-DesktopUIConsider Hotlist-DesktopUITriaged
Labels: Needs-Feedback
Please provide a sample html testcase for reproducing the bug.
Status: Fixed (was: Untriaged)
You can verify this on https://tests.peter.sh/notification-generator

1) Create a notification with title "Empty" and tag "tag-1"
2) Create a notification with title "Short sentence (LTR)" and tag "tag-1"

After this, the title of the notification should be at the top of the notification view.

Sign in to add a comment