Swiftpack.co - nrkno/nrk-sans-styles as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by nrkno.
nrkno/nrk-sans-styles 1.1.6
Definitions of the font styles of NRK Sans.
⭐️ 3
🕓 5 weeks ago
iOS tvOS
.package(url: "https://github.com/nrkno/nrk-sans-styles.git", from: "1.1.6")

nrk-sans-styles

Why?

Most of the text styles of NRK Sans override the default attribute values of the font. This repository (alongside Figma) should be considered the truth when it comes to these attributes.

How?

As part of the build pipeline, the platforms should fetch the font-definitions from this repository.

Format

The definitions under "tv" should be used in all large-screen applications — smart TV, Apple TV, Android TV, etc. The definitions under "responsive" should be used for everything else.

  • size, int: The point size
  • lineHeight, float, Relative to Size
  • explicitLineHeight, int: The total lineheight (Android TV Compose only)
  • letterSpacing, float, Relative to Size
  • "weight", int
  • "width", int
{
    "responsive": {
        "title9": {
            "size": 29,
            "lineHeight": 1.20,
            "explicitLineHeight": 35,
            "letterSpacing": 0.004,
            "weight": 660,
            "width": 100
        },
        { /* ... */ }
    },
    "tv": {
        "title9": {
            "size": 29,
            "lineHeight": 1.3,
            "explicitLineHeight": 38,
            "letterSpacing": -0.002,
            "weight": 400,
            "width": 100
        },
        { /* ... */ }
    }
}

GitHub

link
Stars: 3
Last commit: 5 weeks ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

1.1.6
5 weeks ago

Label letterspacing removed

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics