Repository navigation
Conversation
…d preview red: the portal hardcodes admin.da.live for the document, the room name and the image upload, and admin.hlx.page for preview, so it can't open hlx6 (source bus) documents. the lint disables on the two missing imports go away with the fix.
the standalone portal read the document, named its collab room, uploaded images and previewed against admin.da.live / admin.hlx.page only. on hlx6 (source bus) sites the HEAD 404s, so nothing became editable. - read org/site from both mountpoint shapes (the sidekick passes the source bus url on hlx6 sites) - resolve the document with getSourceUrl + source.getMetadata and name the room with that url, the same one the da-live editors use - upload images with source.uploadMedia and use the returned url - preview with aem.preview - export getSourceUrl from nx2/utils/api.js
red: da-live's prose2aem builds the picture sources from the resolved img.src (da.live/plugins/media_...) and, in live mode, strips the first two path segments of any *.da.live image url, so neither the portal's origin nor the preview origin works. relative refs resolve against the page like delivered html.
replaces the preview-origin rewrite: da-live's prose2aem strips the first two path segments of *.da.live image urls in live mode, so the rewritten src lost its file name. the portal now leaves ./media_ refs relative in img and source srcset, and the page resolves them like delivered html. getInstrumentedHTML and render.js are back to main.
|
Hello, I'm the AEM Code Sync Bot and I will run some actions to deploy your branch.
Commits |
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
on Helix 6 sites, check the document on the source bus and use its URL as the collab room name. upload images to the media bus and preview through the Helix 6 API. use the legacy APIs if the upgrade check doesn't confirm Helix 6.
fixes scdemos/demo#180
test URLs (standalone portal, open from a Helix 6 page):