Skip to content

Conversation

@JayadityaGit
Copy link
Contributor

@JayadityaGit JayadityaGit commented Aug 8, 2025

Requirements

  • This PR has a title that briefly describes the work done including the ticket number. If there is a ticket, make sure your PR title includes a conventional commit label. See existing PR titles for inspiration.
  • My work conforms to the OpenMRS 3.0 Styleguide and design documentation.
  • My work includes tests or is validated by existing tests.

Summary

This draft PR introduces bold text support (<strong> tag) specifically in the "Basic Overview" section of the onboarding tutorial for now.

The goal is to enhance the readability of key instructions by enabling bold formatting through basic HTML.

To achieve this, dangerouslySetInnerHTML is used to render content from the config that includes <strong> tags.

⚠️ This is an early-stage implementation and not yet scoped or sanitized. It is limited to the "Basic Overview" section for now, and created to spark discussion around possible approaches and safety measures.

Related Issue

Jira Ticket: O3-4950

Other

  • Content is from a trusted config source, not user input.
  • Next steps may include:
    • Limiting allowed tags
    • Adding a sanitization layer
    • Discussing safer alternatives to dangerouslySetInnerHTML

This draft PR is shared for early feedback and guidance from the team.

@JayadityaGit JayadityaGit marked this pull request as draft August 8, 2025 03:14
@JayadityaGit
Copy link
Contributor Author

JayadityaGit commented Aug 8, 2025

Hi @denniskigen 👋

Just a quick reminder to have a look at this draft PR whenever you get a chance. Since this is still in the early stages, I’d appreciate your feedback on the approach and whether using dangerouslySetInnerHTML for enabling bolding — or if you'd recommend a different direction.

Thanks in advance! 😊

@JayadityaGit
Copy link
Contributor Author

useCase

During a patient visit tutorial the user needs to click on the patient who does not have an "active visit" label, but this is important instruction is blending in with rest of the content, with bolding included this would be very helpful @denniskigen .

@JayadityaGit JayadityaGit changed the title feat(O3-4950): enable <strong> tag in tutorial content using dangerouslySetInnerHTML (feat)O3-4950: enable <strong> tag in tutorial content using dangerouslySetInnerHTML Aug 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant