Closed sprankhub closed 8 months ago
Tested and can confirm this patch does fix the issue.One thing to note is that in order for the youtube-no-cookie link to be loaded by pagebuilder, the Maximum Width
must be specified. Otherwise the following error is thrown:
Temporarily allowed to save HTML value that contains restricted elements. Allowed HTML tags are: div, a, p, span, em, strong, ul, li, ol, h5, h4, h3, h2, h1, table, tbody, tr, td, th, tfoot, img, hr, figure, button, i, u, br, b, iframe, style, pre, svg, animate, animateMotion, animateTransform, circle, clipPath, defs, desc, ellipse, feBlend, feColorMatrix, feComponentTransfer, feComposite, feConvolveMatrix, feDiffuseLighting, feDisplacementMap, feDistantLight, feFlood, feFuncA, feFuncB, feFuncG, feFuncR, feGaussianBlur, feImage, feMerge, feMergeNode, feMorphology, feOffset, fePointLight, feSpecularLighting, feSpotLight, feTile, feTurbulence, filter, foreignObject, g, image, line, linearGradient, marker, mask, metadata, mpath, path, pattern, polygon, polyline, radialGradient, rect, set, stop, switch, symbol, text, textPath, title, tspan, use, view
Hmm indeed, unfortunately, it is a bit more involved than this :-/ I will try to work on a proper fix.
Another issue you'll most probably face is that Page Builder will revert back to using www.youtube.com
when it reads the saved data and pre-populates the Video content type's fields.
For example, both https://www.youtube.com/watch?v=dQw4w9WgXcQ and https://youtu.be/dQw4w9WgXcQ (note the different domains) get converted to https://www.youtube.com/embed/dQw4w9WgXcQ when the data is read, meaning if the content is re-saved - even without changes - it'll go back to using the cookie-based domain.
With my latest changes, this should now work as expected. Mind testing, @bluemwhitew?
@magento run all tests
The requested builds are added to the queue. You should be able to see them here within a few minutes. Please re-request them if they don't show in a reasonable amount of time.
@bluemwhitew, mind testing the changes from this PR?
@paras89, I think the failing tests are unrelated to this PR...?
@paras89, would you be able to have a look at this PR?
I mistakenly approved this rather than 👍 , was on autopilot and too used to approving internal Ampersand PRs, whoops 😆
@sprankhub,
I would highly suggest adding (or extending) Magento Functional Testing Framework (MFTF) tests to support this changeset, which will make it easier to validate.
Thanks for the advice, @bluemwhitew. I value my time highly, though. If any Adobe official said "we'll merge this as soon as there is MFTF coverage", I'll consider implementing this. Until then, I save my time for more valuable tasks...
@sidolov, I feel bad for tagging you directly, but I currently do not know how else I could move this forward. Would you be able to move this forward?
@magento run all tests
The requested builds are added to the queue. You should be able to see them here within a few minutes. Please message the #magento-devops slack channel if they don't show in a reasonable amount of time and a representative will look into any issues.
@magento run all tests
The requested builds are added to the queue. You should be able to see them here within a few minutes. Please message the #magento-devops slack channel if they don't show in a reasonable amount of time and a representative will look into any issues.
@engcom-Hotel, I extended a fitting MFTF test. The failing WebAPI Tests look unrelated to me.
Could you have another look, please?
@magento run WebAPI Tests
The requested builds are added to the queue. You should be able to see them here within a few minutes. Please message the #magento-devops slack channel if they don't show in a reasonable amount of time and a representative will look into any issues.
Awesome job on this, @sprankhub! 🤘🏻
Hi @sprankhub,
Thanks for the collaboration & contribution!
Preconditions:
2.4-develop
and PHP 8.1
Manual testing scenario:
Before: :heavy_multiplication_x:
After: :heavy_check_mark:
This PR is in development by an internal team, it will be completed and delivered to the mainline according to our standards and processes. All the original community commits will be preserved.
Thanks @devarul for the updates. We are moving this PR On Hold
till that time.
Description (*)
Adds support for youtube-nocookie.com domain.
Bug
826
Fixed Issues (if relevant)
Builds
Manual testing scenarios (*)
See magento/magento2-page-builder#826.
Questions or comments
Checklist