前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >linked page contained in ParagraphComponent could not be loaded under SmartEdit

linked page contained in ParagraphComponent could not be loaded under SmartEdit

作者头像
Jerry Wang
发布2022-03-10 19:32:23
3970
发布2022-03-10 19:32:23
举报

Describe the bug This issue is reported by customer.

When a Spartacus page link is contained in a ParagraphComponent, the link could NOT be loaded under SmartEdit succcessfully.

Tell us the version of Spartacus

  • Library version: 4.2

To Reproduce Steps to reproduce the behavior:

  1. Make some changes in backoffice. For me, I use a local Hybris server.

Maintain cms.components.allowUnsafeJavaScript=true in hybris\config\local.properties,then start server.

  1. Search for Component with ID NoticeTextParagraph.

In its property field, maintain content as:

代码语言:javascript
复制
<div><a href="/Open-Catalogue/Office-Equipment%252C-Supplies-%2526-Accessories/Hand-Tools/Measuring-%2526-Layout-Tools/c/1358">Jerry Link</a></div>

Save the change, it will appear in the footer area under footer navigation area, as below:

  1. log in SmartEdit, click homepage:

Error:

SmartEdit hangs there:

SmartEdit is having difficulty loading the page. The page is either not compatible with SmartEdit or connection to it has been lost. Wait for the page to load or disable editing by going to Preview mode.

However, if we directly click the same OOTB navigation link which is NOT within a paragraphComponent, the link could be opened in SmartEdit without errors:

Desktop (please complete the following information):

  • OS: Windows10
  • Browser:chrome

some initial comparison between two scenarios

I made some comparison between two scenarios: link contained in ParagraphComponent vs OOTB navigation link and observed two differences.

behavior

link contained in ParagraphComponent

OOTB navigation link

href attribute rendered in html

href="/Open-Catalogue/Office-Equipment%252C-Supplies-%2526-Accessories/Hand-Tools/Measuring-%2526-Layout-Tools/c/1358"

href="/powertools-spa/en/USD/Open-Catalogue/Office-Equipment%252C-Supplies-%2526-Accessories/Hand-Tools/Measuring-%2526-Layout-Tools/c/1358"

screenshot

cmsTicketId appended in CMS request?

no:https://localhost:9002/occ/v2/powertools-spa/cms/pages?pageType=CategoryPage&code=1358&lang=en&curr=USD

yes:https://localhost:9002/occ/v2/powertools-spa/cms/pages?pageType=CategoryPage&code=1355&lang=en&curr=USD&cmsTicketId=6478827360217344df347bfa-b4c5-4210-98a1-c35b92a76ce1

本文参与 腾讯云自媒体分享计划,分享自作者个人站点/博客。
如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • some initial comparison between two scenarios
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档