react-native-skia-responsive-text
Version:
A library providing a wrapper for the React Native Skia Text component, offering features like user-friendly text alignment, efficient multiline text management, and straightforward text truncation.
28 lines • 1.02 kB
TypeScript
/// <reference types="react" />
/// <reference types="react" />
import { SkFont, TextProps } from '@shopify/react-native-skia';
import { SharedValue } from 'react-native-reanimated';
import { AnimatableProps, AnimationSettings, EllipsizeMode, HorizontalAlignment, TextOverflow, VerticalAlignment } from '../types';
type ResponsiveTextProps = Omit<TextProps, 'x' | 'y'> & {
ellipsizeMode?: EllipsizeMode;
font: SkFont;
height?: number;
numberOfLines?: number;
onMeasure?: (width: number, height: number) => void;
overflow?: TextOverflow;
width?: number;
} & AnimatableProps<{
backgroundColor?: string;
horizontalAlignment?: HorizontalAlignment;
lineHeight?: number;
verticalAlignment?: VerticalAlignment;
x?: number;
y?: number;
}> & ({
animationProgress?: SharedValue<number>;
} | {
animationSettings?: AnimationSettings;
});
declare const _default: (props: ResponsiveTextProps) => JSX.Element;
export default _default;
//# sourceMappingURL=ResponsiveText.d.ts.map