@patreon/studio
Version:
Patreon Studio Design System
17 lines (16 loc) • 810 B
TypeScript
import type { StyleVariableObject } from 'types/component';
import type { CustomTypographyBundle } from './types';
/**
* Generates a className and style object which can be used to style a custom typography bundle.
*
* This function requires that you define all the propeties of your typographic style
* completely. If you only need to change a few properties, use the `typeTokens` object
* to fill in the original, default values.
*
* @warning this should be only used as an escape hatch for when Text components
* and typography bundles are not capable of supporting the desired typography.
*/
export declare function escapeForCustomText({ fontStack, fontSize, fontWeight, letterSpacing, lineHeight, fontWidth, }: CustomTypographyBundle): {
className: string;
style: StyleVariableObject;
};