Skip to main content

Icons and Logos

Yle Design System icons and graphical assets are distributed across three packages depending on use case.


What's available

  • Regular Icons — icons for UI actions, navigation, media, and social platforms.
  • Illustrative Icons — large expressive icons for empty states, onboarding, and confirmation moments.
  • Logos & Assets — Yle service logos and graphical assets such as age-rating badges.

PackagePurpose
@yleisradio/yds-iconsTypeScript types for icon names and SVG icons.
@yleisradio/yds-icons-reactReact SVG components for web.
@yleisradio/yds-icons-react-nativeReact Native SVG components for mobile.

Installation

React (web)

npm install @yleisradio/yds-icons-react

Peer dependencies:

npm install react react-dom @yleisradio/yds-core

React Native (mobile)

npm install @yleisradio/yds-icons-react-native

Peer dependencies:

npm install react react-native react-native-svg @yleisradio/yds-core

Types only

npm install @yleisradio/yds-icons

Usage

React

Import icons by their component name directly from the package:

import { Menu, Search, ArrowRight } from '@yleisradio/yds-icons-react';

<Menu />
<Search width={20} height={20} color="currentColor" />
<ArrowRight title="Go to next page" />

React Native

The API is identical — swap the package name:

import { Menu, Search, ArrowRight } from '@yleisradio/yds-icons-react-native';

<Menu />
<Search width={20} height={20} color="currentColor" />

Icon name types

Use @yleisradio/yds-icons when you need to pass or store icon names as strings, for example in a generic icon component:

import type { IconsIconName } from '@yleisradio/yds-icons';

interface Props {
icon: IconsIconName;
}

Available type exports:

TypeDescription
IconsIconNameAll Yle icon names (e.g. 'menu', 'search', 'arrow-right').
PlayerIconNamePlayer-specific icon names (e.g. 'play', 'pause', 'volume-high').
ExternalServiceIconNameExternal service icon names (e.g. 'facebook', 'youtube').

Props

Regular icons (React)

All regular icon components extend the standard SVGProps<SVGSVGElement> interface with two additional props.

PropTypeDefaultDescription
widthstring | number'24'Width of the icon.
heightstring | number'24'Height of the icon.
colorstring'currentColor'Fill colour. Inherits from CSS by default.
titlestringundefinedAccessible label. When set, the icon is not hidden from assistive technology.
titleIdstringundefinedid applied to the <title> element, used with aria-labelledby.

Icons without a title are rendered with aria-hidden="true". Provide a title when the icon carries meaning that is not conveyed by surrounding text.

Regular icons (React Native)

All regular icon components accept SvgProps from react-native-svg.

PropTypeDefaultDescription
widthstring | number'24'Width of the icon.
heightstring | number'24'Height of the icon.
colorstring'currentColor'Fill colour.

Illustrative icons (React Native only)

Illustrative icons extend SvgProps with two additional props for theming.

PropTypeDefaultDescription
theme'light' | 'dark' | undefinedundefinedForce a specific colour theme. When undefined, the icon uses its built-in colours. Prefer using the OnDark variant over setting theme="dark" manually.
colors{ primary: string; secondary: string }undefinedOverride the primary and secondary colours directly.