Closed Bug 1811321 Opened 2 years ago Closed 1 year ago

Handling disablePiP signal: display the warning dialog

Categories

(Toolkit :: Picture-in-Picture, task)

task
Points:
8

Tracking

()

RESOLVED FIXED
115 Branch
Tracking Status
firefox115 --- fixed

People

(Reporter: asafko, Assigned: niklas)

References

(Blocks 1 open bug)

Details

(Whiteboard: [fidefe-pip3])

Attachments

(2 files)

User story
As a website developer, I want to notify users that using PiP on my website will result in suboptimal experience and is not recommended.

Acceptance criteria

  1. For pages with videos where we have received a disablePiP signal:
    a. no PiP toggles are displayed over the videos from this domain (so a user can’t open them in a familiar manner, and control doesn’t break any of the rich overlays the website might have),

  2. on click, url bar icon displays a warning in a dialog which explains the developers’ warning/note on PiP not being the best experience for their website.

Please see the separate story for user overrides here.

Blocks: 1811324
Points: --- → 8
Whiteboard: [fidefe-pip3]
Severity: -- → N/A
Assignee: nobody → nbaumgardner
Status: NEW → ASSIGNED

Text for the disable dialog warning.
Tag: Picture-in-Picture

Headline: This website does not recommend Picture-in-Picture

Body: Videos might not display as the developer intended while Picture-in-Picture is enabled. Learn more.

Toggle text: Enable anyway

One challenge is that we don't yet have an updated paragraph in SUMO that we would want to link users too, but I think it's ok to link to the top of the SUMO PiP page where the table contents is visible for now.

Attachment #9327792 - Attachment description: WIP: Bug 1811321 - Create PiP panel for disablePiP. r=#pip-reviewers → Bug 1811321 - Create PiP panel for disablePiP. r=#pip-reviewers

emilio, in the patch above the .pip-body-text can overflow off-panel if the panel's min-width changes to width or max-width. Adding min-width:0 or setting --panel-width doesn't help.
Can you please take a look and see what am I missing?

Flags: needinfo?(emilio)

So that is because of this flex-shrink declaration, which was introduced to fix bug 1822819.

We need to somehow either communicate that size to the view, or remove that without regressing that bug. It seems we do some of it already with this code, maybe that could use --panel-width instead, so that stuff is consistent?

Flags: needinfo?(emilio)
Attached image Panel.png

We decided to introduce a small change to the text that would reduce the title length

Pushed by nbaumgardner@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/8eb0f2e49298 Create PiP panel for disablePiP. r=pip-reviewers,fluent-reviewers,desktop-theme-reviewers,flod,dao,kpatenio

Backed out for causing failures due to unreferenced files on pictureInPicturePanel.xhtml

[task 2023-05-16T15:33:41.629Z] 15:33:41     INFO - Buffered messages finished
[task 2023-05-16T15:33:41.631Z] 15:33:41     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/static/browser_all_files_referenced.js | there should be no unreferenced files - Got 1, expected +0
[task 2023-05-16T15:33:41.632Z] 15:33:41     INFO - Stack trace:
[task 2023-05-16T15:33:41.632Z] 15:33:41     INFO - chrome://mochikit/content/browser-test.js:test_is:1612
[task 2023-05-16T15:33:41.632Z] 15:33:41     INFO - chrome://mochitests/content/browser/browser/base/content/test/static/browser_all_files_referenced.js:checkAllTheFiles:1053
[task 2023-05-16T15:33:41.632Z] 15:33:41     INFO - chrome://mochikit/content/browser-test.js:handleTask:1133
[task 2023-05-16T15:33:41.632Z] 15:33:41     INFO - chrome://mochikit/content/browser-test.js:_runTaskBasedTest:1205
[task 2023-05-16T15:33:41.633Z] 15:33:41     INFO - chrome://mochikit/content/browser-test.js:Tester_execTest:1347
[task 2023-05-16T15:33:41.633Z] 15:33:41     INFO - chrome://mochikit/content/browser-test.js:nextTest/<:1122
[task 2023-05-16T15:33:41.633Z] 15:33:41     INFO - chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:SimpleTest.waitForFocus/<:1056
[task 2023-05-16T15:33:41.634Z] 15:33:41     INFO - Not taking screenshot here: see the one that was previously logged
[task 2023-05-16T15:33:41.636Z] 15:33:41     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/static/browser_all_files_referenced.js | unreferenced file: chrome://global/content/pictureinpicture/pictureInPicturePanel.xhtml - 
Flags: needinfo?(nbaumgardner)
Blocks: 1834554
Pushed by nbaumgardner@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/4cb3c38c40ff Create PiP panel for disablePiP. r=pip-reviewers,fluent-reviewers,desktop-theme-reviewers,flod,dao,kpatenio
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 115 Branch
Duplicate of this bug: 1811324
Flags: needinfo?(nbaumgardner)
Duplicate of this bug: 1611831
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: