Skip to content
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

Content modelling/659 Preview Host Documents via iFrame #9640

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Commits on Nov 25, 2024

  1. add service to get html for host document preview

    calls the gov.uk frontend to get the raw HTML of the page
    in the future we could find the embedded content block inside that
    HTML and transform it.
    Harriethw committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    2246670 View commit details
    Browse the repository at this point in the history
  2. return content id for host

    sp that we can use this id to get the preview HTML
    Harriethw committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    99de250 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    64b3a80 View commit details
    Browse the repository at this point in the history
  4. and preview view

    Harriethw committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    4f5d64f View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    996cf00 View commit details
    Browse the repository at this point in the history
  6. replace existing content block with one under preview

    here we iterate through the snapshot of HTML from
    the frontend, and find the `<span>` containing the
    existing edition of the Content Block we are
    previewing. We then replace it with the `render`
    output of the content block we are currently
    previewing.
    Harriethw committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    a7a8ef4 View commit details
    Browse the repository at this point in the history
  7. provisionally style preview of content blocks

    a minimal styling to help us see the changed
    blocks in the build - TBC on actual UI design.
    Harriethw committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    bab3030 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    5a7cd8f View commit details
    Browse the repository at this point in the history