Skip to content

Visual Editor messes up a heading's attributes #13634

Open

Description

@fkohrt

System details

RStudio Edition : RStudio Pro (Server on posit.cloud)
RStudio Version : 2023.06.1 Build 524.pro1
OS Version      : Ubuntu 20.04.6 LTS
R Version       : 4.3.1

Steps to reproduce the problem

Create a Quarto Presentation using the visual markdown editor as follows:

  1. Add a new paragraph
  2. Turn the paragraph into a level-1 header
  3. Edit the paragraph's attributes: under Other, enter the following:
    • background-iframe="https://www.google.com/maps/embed?pb=!4v1567634732542!6m8!1m7!1sCAoSK0FGMVFpcFBwdDA1a3pFdm9mWVk0Y3Z4dS1zX3JEUGVMT25ib0I3QnRqem8.!2m2!1d51.50178371216957!2d-0.1407569859987906!3f232.50377602784036!4f-2.7819907211537895!5f0.7820865974627469"
    • background-interactive="true"

Notice how the URL of the background website gets messed up after clicking OK.

Describe the problem in detail

The attribute of a heading gets messed up if it contains particular characters.

Describe the behavior you expected

I would have expected the visual editor to produce the following source:

---
title: "Background Test"
format: revealjs
editor: visual
---

# {background-iframe="https://www.google.com/maps/embed?pb=!4v1567634732542!6m8!1m7!1sCAoSK0FGMVFpcFBwdDA1a3pFdm9mWVk0Y3Z4dS1zX3JEUGVMT25ib0I3QnRqem8.!2m2!1d51.50178371216957!2d-0.1407569859987906!3f232.50377602784036!4f-2.7819907211537895!5f0.7820865974627469" background-interactive="true"}
  • I have read the guide for submitting good bug reports.
  • I have installed the latest version of RStudio, and confirmed that the issue still persists.
  • If I am reporting an RStudio crash, I have included a diagnostics report.
  • I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.

Activity

  1. added
    new
    on Sep 14, 2023
  2. ronblum commented on Sep 15, 2023

    @ronblum
    Contributor

    @fkohrt Thank you for raising the issue! We'll review it as we continue development RStudio and the visual editor.

    Reproducible on MacOS 14 in RStudio Desktop 2022.07.2+576 and 2023.09.0+440.

  3. added
    visual markdown
    and removed
    new
    on Sep 15, 2023
  4. github-actions commented on Mar 14, 2024

    @github-actions

    This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs, per https://github.com/rstudio/rstudio/wiki/Issue-Grooming. Thank you for your contributions.

  5. added
    stale
    on Mar 14, 2024
  6. fkohrt commented on Mar 14, 2024

    @fkohrt
    Author

    Still an issue

  7. removed
    stale
    on Mar 15, 2024
  8. github-actions commented on Sep 17, 2024

    @github-actions

    This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs, per https://github.com/rstudio/rstudio/wiki/Issue-Grooming. Thank you for your contributions.

  9. added
    stale
    on Sep 17, 2024
  10. fkohrt commented on Sep 17, 2024

    @fkohrt
    Author

    Still an issue

  11. removed
    stale
    on Sep 18, 2024
  12. self-assigned this
    on Feb 20, 2025
  13. ronblum commented on Feb 20, 2025

    @ronblum
    Contributor

    Reproduced by @jthomasmock, with the query parameters getting stripped.

  14. added this to the Backlog milestone on Feb 20, 2025
  15. kevinushey commented on Sep 4, 2025

    @kevinushey
    Collaborator

    If I understand correctly, the issue here is that all content following an = in a value is stripped? So that a=b=c just becomes a=b.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugvisual markdown

    Type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions