Font & Typography

This guide covers font packages, typography components, token system, and best practices.


Overview

The Akinon UI Kit uses a carefully selected typography system that includes:

  • Jost Variable – A modern, geometric sans-serif variable font as the primary typeface

  • Typography Components – React components for semantic text rendering

  • Token-based System – Consistent styling through design tokens


Font Packages

@akinon/fonts-jost-variable

Jost is the primary font family used across all Akinon applications. We distribute it as a variable font, which means:

  • Single file contains all weight variations (100-900)

  • Smaller bundle size compared to multiple static font files

  • Smooth weight transitions for animations

  • Better performance and reduced HTTP requests

Installation

Usage

Import the font in your application's entry point:

Font Specifications

Property
Value

Font Family

'Jost Variable'

Weights

100, 200, 300, 400, 500, 600, 700, 800, 900

Styles

Normal, Italic

Subsets

Latin, Latin Extended, Cyrillic

Format

WOFF2 (Variable)

License

OFL-1.1 (Open Font License)

CSS Configuration

Apply the font to your application:

circle-exclamation

Typography Components

The Akinon UI Kit provides semantic typography components built on Ant Design's Typography system.

Installation

Available Components

Component
HTML Element
Purpose

Title

<h1> - <h5>

Headings and titles

Text

<span>

Inline text with styling

Paragraph

<p>

Block-level text content

Link

<a>

Hyperlinks with styling


Title Component

Use for headings and page titles. Supports levels 1-5 corresponding to <h1> - <h5>.

Title Props

Prop
Type
Default
Description

level

1 | 2 | 3 | 4 | 5

1

Heading level (h1-h5)

copyable

boolean | CopyConfig

false

Enable copy functionality

delete

boolean

false

Strike-through style

disabled

boolean

false

Disabled state

editable

boolean | EditConfig

false

Editable content

ellipsis

boolean | EllipsisConfig

false

Truncate with ellipsis

mark

boolean

false

Highlight text

underline

boolean

false

Underline style

type

'secondary' | 'success' | 'warning' | 'danger'

-

Text color type


Text Component

Use for inline text with various styling options.

Text Props

Prop
Type
Default
Description

code

boolean

false

Code style (monospace)

copyable

boolean | CopyConfig

false

Enable copy functionality

delete

boolean

false

Strike-through style

disabled

boolean

false

Disabled state

editable

boolean | EditConfig

false

Editable content

ellipsis

boolean | EllipsisConfig

false

Truncate with ellipsis

italic

boolean

false

Italic style

keyboard

boolean

false

Keyboard key style

mark

boolean

false

Highlight text

strong

boolean

false

Bold text

underline

boolean

false

Underline style

type

'secondary' | 'success' | 'warning' | 'danger'

-

Text color type


Paragraph Component

Use for block-level text content with multi-line support.

Paragraph with Ellipsis


Use for hyperlinks with consistent styling.

Link Props

Prop
Type
Default
Description

href

string

-

Link URL

target

string

-

Link target (_blank, _self, etc.)

disabled

boolean

false

Disabled state

ellipsis

boolean

false

Truncate with ellipsis

type

'secondary' | 'success' | 'warning' | 'danger'

-

Link color type


Using Typography with Theme Provider

To ensure typography tokens are applied correctly, wrap your application with AkinonUiProvider:

Custom Font Family Override

You can override the default font family through the provider:


Best Practices

1. Use Semantic Components

Always use the appropriate typography component for the content:

2. Maintain Heading Hierarchy

Follow proper heading order for accessibility:

3. Use Type Variants for Context

Leverage type variants to communicate meaning:

4. Handle Long Text with Ellipsis

Use ellipsis for potentially long content:

5. Use Utility Classes Instead of Custom CSS

The Akinon UI Kit is designed to be non-themable to ensure consistency across all applications. Instead of writing custom CSS:

For available utility classes, see the Utility Classes documentation.

6. Consider Internationalization

The Jost Variable font includes Cyrillic and Latin Extended subsets:


Troubleshooting

Font Not Loading

  1. Verify the font package is installed:

  2. Check the import statement in your entry file:

  3. Inspect browser network tab for WOFF2 file requests

Typography Components Not Styled

Ensure AkinonUiProvider wraps your application:


Last updated

Was this helpful?