Skip to content

packages/fonts: consolidate the RedHat and PatternFly icon faces into @goauthentik/fonts - #24461

Merged
GirlBossRush merged 3 commits into
mainfrom
slice/fonts-package
Aug 6, 2026
Merged

GirlBossRush merged 3 commits into
mainfrom
slice/fonts-package

Conversation

@GirlBossRush

@GirlBossRush GirlBossRush commented Jul 29, 2026 •

Copy link
Copy Markdown
Contributor

Consolidates every font authentik ships into one package. Split out of #23341 so the theme package and the fonts land separately.

The RedHat text faces

They were checked in twice: web/fonts/RedHat held the six variable faces the app actually loads, and the theme package carried its own copy of those plus twenty-four static weights. The variable files were byte-identical in both places, but the two @font-face sets disagreed on naming — web bound RedHatText to the variable face, the theme bound it to the static Regular and used RedHatTextVF for the variable one.

Web's set is canonical, so it moves into the new package and the theme's copy is dropped. The theme now only names the families; @goauthentik/fonts binds them to files.

The icon faces

pficon and Font Awesome 5 Free were declared inside the vendored PatternFly icon stylesheets, with the font files beside them under web/src/styles/global/vendor/assets/. That put font bytes in a third place and tied the faces to stylesheets we re-vendor whenever PatternFly moves.

Both families move next to the RedHat faces, declared in icons.css — kept separate from faces.css so a consumer can take the brand text faces without the icon fonts. The icon classes stay with PatternFly; only the @font-face rules and the files move.

pficon.scss went with them. It was an unreferenced Sass source whose $pf-global--fonticon-path variable had nothing to resolve against.

No rendering change

Same bytes throughout — the emitted assets keep their content hashes across the move. Same family names, same vendor layer, one @font-face per family in each bundle (verified in the built CSS: six RedHat, one pficon, one Font Awesome, no duplicates).

The copies in shadow/patternfly-base.css are left alone. They come from the PatternFly package and their font URLs are already stubbed out by the bundled-text loader, because @font-face has no effect inside a shadow root — components inherit the faces registered on the document.

ESBuild outbase

outbase is now pinned to the monorepo root. Assets resolved from outside web/ otherwise land under a .. segment, which ESBuild sanitizes to _.._, and Go's //go:embed dist/* in static_outpost.go skips any path segment starting with _.

This is not new with the fonts. On main today, twelve MDX-pulled files under website/docs/ already build to dist/assets/_.._/website/docs/... and are therefore missing from embedded outpost builds. Moving the fonts out of web/ would have added them to that set; pinning outbase fixes both.

It does shift other emitted assets under an assets/web/ prefix. The hardcoded /static/dist/assets/{icons,images}/... paths in Python and TS are copied verbatim rather than emitted by ESBuild, so they are unaffected.

Note for follow-up: a handful of those MDX partials have basenames starting with _ (_nginx_ingress.md and friends). outbase cannot help there — Go's embed excludes them by filename — so they remain absent from the outpost embed.

Licensing

Addressing review feedback: the package declared MIT and shipped only Red Hat's OFL text, which described neither what it redistributes nor what redistribution requires.

license is now the SPDX expression MIT AND OFL-1.1 AND CC-BY-4.0, and the tarball carries the package's own MIT text, a NOTICE.md recording provenance per file, and each upstream's license under licenses/. OFL 1.1 requires the copyright notice and license to travel with any redistributed copy; CC BY 4.0 requires attribution where the icons are displayed.

Two things NOTICE.md states plainly rather than papering over: @patternfly/patternfly ships no license file, so the MIT text included is Red Hat's own copied from the sibling @patternfly/icons package; and Font Awesome's published license carries a copyright line tracking its current release rather than the 5.x release these files came from.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR consolidates the font assets and @font-face declarations used by the web/ frontend into a new pnpm workspace package, @goauthentik/fonts, and adjusts the web build so assets imported from outside web/ don’t land in paths that get excluded from the Go outpost embed.

Changes:

  • Introduces packages/fonts to centralize Red Hat variable faces and the PatternFly 4 icon font faces (pficon, Font Awesome 5 Free) behind faces.css and icons.css.
  • Updates web/ global stylesheet entrypoints to import fonts from @goauthentik/fonts, and removes @font-face blocks from vendored PatternFly icon CSS (leaving only the icon classes).
  • Pins ESBuild outbase to the monorepo root to prevent _.._ path sanitization from breaking //go:embed dist/* for outpost builds.

Reviewed changes

Copilot reviewed 9 out of 26 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
web/src/styles/interface.global.css Switches global interface entrypoint to import font faces/icons from @goauthentik/fonts.
web/src/styles/flows.global.css Switches global flows entrypoint to import font faces/icons from @goauthentik/fonts.
web/src/styles/global/vendor/patternfly-pf-icons.css Removes pficon @font-face from vendored CSS, leaving only icon classes and a note.
web/src/styles/global/vendor/patternfly-fa-icons.css Removes Font Awesome @font-face from vendored CSS, leaving only icon classes and a note.
web/src/styles/global/vendor/assets/pficon/pficon.scss Deletes unreferenced vendored Sass source for pficon.
web/scripts/build-web.mjs Sets ESBuild outbase to the monorepo root to avoid _.._ path segments that break Go embedding.
web/package.json Removes the #fonts import mapping and adds a dependency on @goauthentik/fonts.
web/pnpm-lock.yaml Records the new @goauthentik/fonts workspace link for web/.
pnpm-workspace.yaml Adds packages/fonts to the workspace.
pnpm-lock.yaml Adds the packages/fonts importer entry.
packages/fonts/package.json Adds the @goauthentik/fonts package manifest and publish configuration.
packages/fonts/faces.css Provides @font-face rules for Red Hat variable faces.
packages/fonts/icons.css Provides @font-face rules for pficon and Font Awesome, previously in vendored PatternFly CSS.
packages/fonts/OFL.txt Adds an OFL license text file (currently Red Hat-specific).
packages/fonts/.prettierignore Adds a Prettier ignore file for the new package.
packages/fonts/RedHatMonoVF.woff2 Adds the Red Hat Mono variable font asset.
packages/fonts/RedHatMonoVF-Italic.woff2 Adds the Red Hat Mono italic variable font asset.
packages/fonts/pficon.woff2 Adds the PatternFly pficon font asset (woff2).
packages/fonts/pficon.woff Adds the PatternFly pficon font asset (woff).
packages/fonts/fa-solid-900.woff2 Adds the Font Awesome solid font asset (woff2).
packages/fonts/fa-solid-900.woff Adds the Font Awesome solid font asset (woff).
packages/fonts/RedHatDisplayVF.woff2 Adds the Red Hat Display variable font asset.
packages/fonts/RedHatDisplayVF-Italic.woff2 Adds the Red Hat Display italic variable font asset.
packages/fonts/RedHatTextVF.woff2 Adds the Red Hat Text variable font asset.
packages/fonts/RedHatTextVF-Italic.woff2 Adds the Red Hat Text italic variable font asset.
CODEOWNERS Adds code ownership for /packages/fonts.
Files not reviewed (2)
  • pnpm-lock.yaml: Generated file
  • web/pnpm-lock.yaml: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/fonts/package.json Resolved
@codecov

codecov Bot commented Jul 29, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.22%. Comparing base (530750f) to head (061c102).
⚠️ Report is 1 commits behind head on main.
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #24461   +/-   ##
=======================================
  Coverage   91.22%   91.22%           
=======================================
  Files        1128     1128           
  Lines       70739    70739           
  Branches     3874     3874           
=======================================
+ Hits        64533    64534    +1     
+ Misses       6171     6170    -1     
  Partials       35       35           
Flag Coverage Δ
conformance 35.14% <ø> (+<0.01%) ⬆️
e2e 39.92% <ø> (+<0.01%) ⬆️
integration 31.69% <ø> (+<0.01%) ⬆️
rust 38.90% <ø> (ø)
unit 92.90% <ø> (+<0.01%) ⬆️
unit-migrate 92.92% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

@netlify

netlify Bot commented Jul 29, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for authentik-storybook ready!

Name Link
🔨 Latest commit 061c102
🔍 Latest deploy log https://app.netlify.com/projects/authentik-storybook/deploys/6a71267c602d0000089ccbb1
😎 Deploy Preview https://deploy-preview-24461--authentik-storybook.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jul 29, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for authentik-integrations ready!

Name Link
🔨 Latest commit b8a3cc5
🔍 Latest deploy log https://app.netlify.com/projects/authentik-integrations/deploys/6a7117934eb9ee0008b95a72
😎 Deploy Preview https://deploy-preview-24461--authentik-integrations.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jul 29, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for authentik-docs ready!

Name Link
🔨 Latest commit b8a3cc5
🔍 Latest deploy log https://app.netlify.com/projects/authentik-docs/deploys/6a71179338bc2f0008622fd5
😎 Deploy Preview https://deploy-preview-24461--authentik-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI review requested due to automatic review settings July 29, 2026 16:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 30 changed files in this pull request and generated no new comments.

Files not reviewed (2)
  • pnpm-lock.yaml: Generated file
  • web/pnpm-lock.yaml: Generated file

Copilot AI review requested due to automatic review settings August 3, 2026 22:34

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 30 changed files in this pull request and generated no new comments.

Files not reviewed (2)
  • pnpm-lock.yaml: Generated file
  • web/pnpm-lock.yaml: Generated file

@github-actions

github-actions Bot commented Aug 3, 2026 •

Copy link
Copy Markdown
Contributor

authentik PR Installation instructions

Instructions for docker-compose

Add the following block to your .env file:

AUTHENTIK_IMAGE=ghcr.io/goauthentik/dev-server
AUTHENTIK_TAG=gh-061c102f17d80d8145a4c3c16bd9bf73a3b71e84
AUTHENTIK_OUTPOSTS__CONTAINER_IMAGE_BASE=ghcr.io/goauthentik/dev-%(type)s:gh-%(build_hash)s

Afterwards, run the upgrade commands from the latest release notes.

Instructions for Kubernetes

Add the following block to your values.yml file:

authentik:
    outposts:
        container_image_base: ghcr.io/goauthentik/dev-%(type)s:gh-%(build_hash)s
global:
    image:
        repository: ghcr.io/goauthentik/dev-server
        tag: gh-061c102f17d80d8145a4c3c16bd9bf73a3b71e84

Afterwards, run the upgrade commands from the latest release notes.

…onts

The RedHat typefaces were checked in twice: web/fonts/RedHat held the six
variable faces the app actually loads, and packages/theme carried its own
copy of those plus twenty-four static weights. The variable files were
byte-identical in both places, but the two @font-face sets disagreed on
naming — web bound "RedHatText" to the variable face while the theme
bound it to the static Regular and used "RedHatTextVF" for the variable
one.

Move web's set, which is the canonical one, into a new assets-only
package and drop the theme's copy entirely. The theme now only names the
families; @goauthentik/fonts binds them to files. Nothing about what the
browser loads changes: same bytes, same family names, same vendor layer.

The package has no build step, and only faces.css needs an exports entry
— the url() references beside it resolve relative to that file in both
ESBuild and Vite.

ESBuild's `outbase` is now pinned to the monorepo root. Assets pulled
from a workspace package outside web/ otherwise land under a `..`
segment, which ESBuild sanitizes to `_.._`; Go's `//go:embed dist/*` in
static_outpost.go skips any segment starting with `_`, so the faces would
have gone missing from the embedded outpost build.
The pficon and Font Awesome faces were declared inside the vendored
PatternFly icon stylesheets, with the font files sitting beside them
under web/src/styles/global/vendor/assets/. That put font bytes in three
places across the repo and tied the faces to stylesheets we re-vendor
whenever PatternFly moves.

Move both families next to the RedHat faces and declare them in a new
icons.css, kept separate from faces.css so a consumer can take the brand
text faces without the icon fonts. The icon classes stay with PatternFly
— only the @font-face rules and the files move. Same bytes: the emitted
assets keep their content hashes.

pficon.scss went too. It was an unreferenced Sass source whose
`$pf-global--fonticon-path` variable had nothing to resolve against.

The copies in shadow/patternfly-base.css are left alone. They come from
the PatternFly package and their font URLs are already stubbed out by the
bundled-text loader, because @font-face has no effect inside a shadow
root — components inherit the faces registered on the document.
The package declared MIT and shipped only Red Hat's OFL text, which
described neither what it redistributes nor what redistribution requires.
Three upstreams are bundled, under three different terms:

  RedHat text faces   OFL-1.1, (c) The Red Hat Project Authors
  pficon              MIT, (c) Red Hat, Inc., via PatternFly
  Font Awesome 5 Free OFL-1.1 for the font files, CC-BY-4.0 for the
                      icons they encode, (c) Fonticons, Inc.

Declare that as an SPDX expression, add the package's own MIT text, and
ship each upstream's license alongside a NOTICE.md recording provenance
per file. OFL 1.1 requires the copyright notice and license to travel
with any redistributed copy, and CC BY 4.0 requires attribution where the
icons are displayed; `files` now carries all of it into the tarball.

Two things NOTICE.md is explicit about rather than papering over:
@patternfly/patternfly ships no license file, so the MIT text here is Red
Hat's own copied from the sibling @patternfly/icons package; and Font
Awesome's published license carries a copyright line tracking its current
release rather than the 5.x release these files came from.
Copilot AI review requested due to automatic review settings August 3, 2026 23:38

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 16 out of 32 changed files in this pull request and generated no new comments.

Files not reviewed (2)
  • pnpm-lock.yaml: Generated file
  • web/pnpm-lock.yaml: Generated file
Suppressed comments (2)

packages/fonts/NOTICE.md:36

  • NOTICE.md says the CC BY 4.0 license is included in full via licenses/FontAwesome-Free.txt, but that file only references CC BY 4.0 by URL and does not include the CC BY 4.0 license text. Since the package’s SPDX expression includes CC-BY-4.0, consider vendoring the CC BY 4.0 license text (either as a dedicated licenses/CC-BY-4.0.txt or appended to FontAwesome-Free.txt) and update NOTICE.md to point at the correct file(s).
- Copyright Fonticons, Inc., <https://fontawesome.com>
- Font files: SIL Open Font License 1.1. Reserved Font Name: "Font Awesome"
- The icons the fonts encode: CC BY 4.0, <https://creativecommons.org/licenses/by/4.0/>
- Full text in `licenses/FontAwesome-Free.txt`

web/docs/arch/2026-06-18-How-CSS-Is-Made-And-Next-Steps.md:38

  • This architecture doc still says the PatternFly icon stylesheets provide the icon @font-face rules, but those were moved to @goauthentik/fonts/icons.css (the PatternFly files now only contain the icon classes). Updating this list avoids future confusion when tracing where icon fonts are registered.
4. @patternfly/.../patternfly-fa-icons.css, patternfly-pf-icons.css — icon @font-face + classes
5. @patternfly/.../components/Spinner/spinner.css
6. @goauthentik/fonts/faces.css — RedHat @font-face

@GirlBossRush
GirlBossRush merged commit 7ec8872 into main Aug 6, 2026
147 checks passed
@GirlBossRush
GirlBossRush deleted the slice/fonts-package branch August 6, 2026 14:10
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.

4 participants