import Gtk from "gi://Gtk"; import type { SpinButtonUpdatePolicy } from "../../../enums/gtk3-index"; import type { GjsContext } from "../../../reconciler/gjs-renderer"; import type { HostContext } from "../../../reconciler/host-context"; import { BaseElement, type GjsElement } from "../../gjs-element"; import type { ElementMargin } from "../../utils/apply-margin"; import { ElementLifecycleController } from "../../utils/element-extenders/element-lifecycle-controller"; import type { SyntheticEvent } from "../../utils/element-extenders/event-handlers"; import { EventHandlers } from "../../utils/element-extenders/event-handlers"; import type { DiffedProps } from "../../utils/element-extenders/map-properties"; import { PropertyMapper } from "../../utils/element-extenders/map-properties"; import type { AlignmentProps } from "../../utils/property-maps-factories/create-alignment-prop-mapper"; import type { ChildPropertiesProps } from "../../utils/property-maps-factories/create-child-props-mapper"; import type { ExpandProps } from "../../utils/property-maps-factories/create-expand-prop-mapper"; import type { MarginProps } from "../../utils/property-maps-factories/create-margin-prop-mapper"; import type { SizeRequestProps } from "../../utils/property-maps-factories/create-size-request-prop-mapper"; import type { StyleProps } from "../../utils/property-maps-factories/create-style-prop-mapper"; import type { TooltipProps } from "../../utils/property-maps-factories/create-tooltip-prop-mapper"; type NumberInputPropsMixin = ChildPropertiesProps & SizeRequestProps & AlignmentProps & MarginProps & ExpandProps & StyleProps & TooltipProps; export type NumberInputEvent

= {}> = SyntheticEvent; export interface NumberInputProps extends NumberInputPropsMixin { defaultValue?: number; increments?: number; rmbIncrements?: number; margin?: ElementMargin; max?: number; min?: number; numericOnly?: boolean; precision?: number; snapToTicks?: boolean; updatePolicy?: SpinButtonUpdatePolicy; value?: number; wrapOnBounds?: boolean; onChange?: (event: NumberInputEvent<{ value: number; }>) => void; onKeyPress?: (event: NumberInputEvent) => void; onKeyRelease?: (event: NumberInputEvent) => void; } export declare class NumberInputElement extends BaseElement implements GjsElement<"NUMBER_INPUT", Gtk.SpinButton> { static getContext(currentContext: HostContext): HostContext; readonly kind = "NUMBER_INPUT"; protected widget: Gtk.SpinButton; protected parent: GjsElement | null; readonly lifecycle: ElementLifecycleController; protected readonly handlers: EventHandlers; protected isFirstRender: boolean; protected readonly propsMapper: PropertyMapper; constructor(props: DiffedProps); updateProps(props: DiffedProps): void; appendChild(): void; insertBefore(): void; remove(parent: GjsElement): void; render(): void; notifyWillMountTo(parent: GjsElement): boolean; notifyMounted(): void; notifyChildWillUnmount(): void; show(): void; hide(): void; getWidget(): Gtk.SpinButton; getParentElement(): GjsElement | null; } export {};