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

Modifiers for fonts #878

Open
LukasKorba opened this issue Oct 28, 2023 · 0 comments
Open

Modifiers for fonts #878

LukasKorba opened this issue Oct 28, 2023 · 0 comments
Labels
C-tech-debt Technical debt that should be paid-in-full, eventually.

Comments

@LukasKorba
Copy link
Collaborator

The Zashi is all about 2 custom fonts with several wights and different sizes. So in the end the SwiftUI side looks like this:

     Text(...)
          .font(.custom(FontFamily.Inter.regular.name, size: 13))

      // or

     Text(...)
          .font(.custom(FontFamily.Archivo.bold.name, size: 17))

Idea is to implement a modifier(s) that simplifies it into:

     Text(...)
          .inter(.regular, 13)

      // or

     Text(...)
          .archivo(.bold, 17)
@LukasKorba LukasKorba added the C-tech-debt Technical debt that should be paid-in-full, eventually. label Nov 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-tech-debt Technical debt that should be paid-in-full, eventually.
Projects
None yet
Development

No branches or pull requests

1 participant