Skip to main content

Aliases

This page provides information about type aliases used throughout Flet code.

Below are the aliases.

AnimationValue

Union of bool, int, Animation and None

BorderRadiusValue

Union of int, float, BorderRadius and None

MarginValue

Union of int, float, Margin and None

Number

Union of int, float

OffsetValue

Union of Offset, None, and union of two; two valued tuples of 1st element of type float and 2nd of type int

OptionalEventCallback

Union of None and callable with single argument of type ControlEvent and return value of None

OptionalNumber

Union of int, float and None

OptionalString

Union of str and None

PaddingValue

Union of int, float, Padding and None

ResponsiveNumber

Union of dict of str and Number, and Number.

RotateValue

Union of int, float, Rotate and None

ScaleValue

Union of int, float, Scale and None

Wrapper

Callable with arbitrary number of parameters and return type of typing.Any.