Skip to content
pixi-silk
GitHub repository
Interface

ZoomControlOptions

import type { ZoomControlOptions } from 'pixi-silk/ui/camera';

Options of ZoomControl.

Properties#

PropertyTypeDescriptionDefined in
color?string | numberText and icon colour. Default white.ui/camera.ts:680
fill?string | numberPanel colour, drawn at 92% alpha. Default 0x1c1c1e.ui/camera.ts:678
label?LabelFactoryBuilds the percentage text. Default a PixiJS Text at resolution 3. Pass silkLabel() from pixi-silk/text to draw it as SDF text instead.ui/camera.ts:689
onLabel?"reset" | "none" | "fit"What a click on the percentage does: fit the content, go to 100%, or nothing. Default fit.ui/camera.ts:684
step?numberZoom factor of one click on - or +. Default 1.5.ui/camera.ts:682