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

Setting a custom font overwrites markdown styles #305

Open
3 tasks done
peteralt opened this issue Mar 15, 2024 · 0 comments
Open
3 tasks done

Setting a custom font overwrites markdown styles #305

peteralt opened this issue Mar 15, 2024 · 0 comments

Comments

@peteralt
Copy link

peteralt commented Mar 15, 2024

Describe the bug
When I set a custom font for my .text TextStyle, it takes the new font, but any attributes like bold or italic are being overwritten and dismissed.

Sample:

Markdown(text)
    .markdownTextStyle(\.text) {
        FontFamily(.custom(CustomFont.pawp.fontName))
    }

Checklist

  • I can reproduce this issue with a vanilla SwiftUI project.
  • I can reproduce this issue using the main branch of this package.
  • This bug hasn't been addressed in an existing GitHub issue.

Expected behavior
I would expect the styling to still apply even with the new custom font.

Version information

  • MarkdownUI: 2.3.0
  • OS: macOS 14.3.1 (23D60)
  • Xcode: 15.3

Additional context
Add any other context about the problem here.

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

No branches or pull requests

1 participant