UNPKG

874 BTypeScriptView Raw
1import { CSSProperties } from './createTypography';
2
3export function isUnitless(value: string): boolean;
4
5export function getUnit(input: string): string;
6
7export function toUnitless(value: string): number;
8
9export function convertLength(baseFontSize: string): (length: string, toUnit: string) => string;
10
11export interface AlignPropertyParams {
12 size: number;
13 grid: number;
14}
15export function alignProperty(params: AlignPropertyParams): number;
16
17export interface FontGridParams {
18 lineHeight: number;
19 pixels: number;
20 htmlFontSize: number;
21}
22export function fontGrid(params: FontGridParams): number;
23
24export interface ResponsivePropertyParams {
25 cssProperty: string;
26 min: number;
27 max: number;
28 unit?: string;
29 breakpoints?: number[];
30 transform?: (value: number) => number;
31}
32export function responsiveProperty(params: ResponsivePropertyParams): CSSProperties;