-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remove script tag #25418
remove script tag #25418
Conversation
Hi @torhoehn. Thank you for your contribution
For more details, please, review the Magento Contributor Guide documentation. |
@magento give me test instance |
Hi @kalpmehta. Thank you for your request. I'm working on Magento instance for you |
Hi @kalpmehta, here is your new Magento instance. |
Hi @kalpmehta, thank you for the review.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @torhoehn,
could you please make sure the tooltip is also initialized for order items renderer as well for shipment, invoice and credit memo.
So we would get the same behavior for all tabs.
E.g.
Shipment Items: Magento/Sales/view/frontend/templates/order/shipment/items/renderer/default.phtml
Order Items: Magento/Sales/view/frontend/templates/order/items/renderer/default.phtml
@dmytro-ch You're absolutely right and I added it. |
@torhoehn, great, thank you! |
@engcom-Bravo This expected behaviour, because until now the fix #25393 is not inside of this branch. If you want I could merge 2.3-develop into this feature, so you we can see if everything works as it should. |
Ok @torhoehn, please take care from Your side as much as You can on that all the fixes will persist in the develop. Thank You. ✔️ QA Passed. |
@magento give me test instance |
Hi @torhoehn. Thank you for your request. I'm working on Magento instance for you |
Hi @torhoehn, here is your new Magento instance. |
@engcom-Bravo Everything works as expected now! |
Hi @dmytro-ch, thank you for the review. |
Hi @torhoehn, thank you for your contribution! |
@@ -17,7 +17,7 @@ | |||
<?php if (!$block->getPrintStatus()) : ?> | |||
<?php $_formatedOptionValue = $block->getFormatedOptionValue($_option) ?> | |||
<dd<?= (isset($_formatedOptionValue['full_view']) ? ' class="tooltip wrapper"' : '') ?>> | |||
<?= $block->escapeHtml($_formatedOptionValue['value']) ?> | |||
<?= $block->escapeHtml($_formatedOptionValue['value'], ['a', 'img']) ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
img
tag is not allowed in the html Escaper class:
https://github.com/magento/magento2/blob/2.4-develop/lib/internal/Magento/Framework/Escaper.php#L40
This generates an error The following tag(s) are not allowed: img
when go to the Order page in My Account
The line in the Escaper:
https://github.com/magento/magento2/blob/2.4-develop/lib/internal/Magento/Framework/Escaper.php#L457
Probably removing the img
from allowed tags passed as the second parameter should be enough.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I created pull request, that fixed critical error
#29863
Description (*)
Removed script tag, but tooltip still opens correctly.
Fixed Issues (if relevant)
Manual testing scenarios (*)
Questions or comments
Contribution checklist (*)