@atlaskit/tokens
Version:
Design tokens are the single source of truth to name and store design decisions.
14 lines (13 loc) • 455 B
TypeScript
import type { ThemeState } from './theme-state';
/**
* Converts a theme object to a string formatted for the `data-theme` HTML attribute.
*
* @param {object} themes The themes that should be applied.
*
* @example
* ```
* themeObjectToString({ dark: 'dark', light: 'light', spacing: 'spacing' });
* // returns 'dark:dark light:light spacing:spacing'
* ```
*/
export declare const themeObjectToString: (themeState: Partial<ThemeState>) => string;