Skip to content

@line/bot-sdkDocs


@line/bot-sdk / messagingApi / FlexImage

Type Alias: FlexImage

FlexImage: FlexComponentBase & object

Type declaration

action?

optional action: Action

See

action Documentation

align?

optional align: AlignEnum

Alignment style in horizontal direction.

See

align Documentation

animated?

optional animated: boolean

When this is true, an animated image (APNG) plays. You can specify a value of true up to 10 images in a single message. You can't send messages that exceed this limit. This is false by default. Animated images larger than 300 KB aren't played back.

See

animated Documentation

aspectMode?

optional aspectMode: AspectModeEnum

The display style of the image if the aspect ratio of the image and that specified by the aspectRatio property do not match.

See

aspectMode Documentation

aspectRatio?

optional aspectRatio: string

Aspect ratio of the image. {width}:{height} format. Specify the value of {width} and {height} in the range from 1 to 100000. However, you cannot set {height} to a value that is more than three times the value of {width}. The default value is 1:1.

See

aspectRatio Documentation

backgroundColor?

optional backgroundColor: string

Background color of the image. Use a hexadecimal color code.

See

backgroundColor Documentation

flex?

optional flex: number

The ratio of the width or height of this component within the parent box.

See

flex Documentation

gravity?

optional gravity: GravityEnum

Alignment style in vertical direction.

See

gravity Documentation

margin?

optional margin: string

The minimum amount of space to include before this component in its parent container.

See

margin Documentation

offsetBottom?

optional offsetBottom: string

Offset.

See

offsetBottom Documentation

offsetEnd?

optional offsetEnd: string

Offset.

See

offsetEnd Documentation

offsetStart?

optional offsetStart: string

Offset.

See

offsetStart Documentation

offsetTop?

optional offsetTop: string

Offset.

See

offsetTop Documentation

position?

optional position: PositionEnum

Reference for offsetTop, offsetBottom, offsetStart, and offsetEnd. Specify one of the following values: relative: Use the previous box as reference. absolute: Use the top left of parent element as reference. The default value is relative.

See

position Documentation

size?

optional size: string

The maximum image width. This is md by default.

See

size Documentation

type

type: "image"

url

url: string

Image URL (Max character limit: 2000) Protocol: HTTPS (TLS 1.2 or later) Image format: JPEG or PNG Maximum image size: 1024×1024 pixels Maximum file size: 10 MB (300 KB when the animated property is true)

See

url Documentation

Defined in

lib/messaging-api/model/flexImage.ts:18