import { ElementAppenderShowConfig } from '../../ui/element-appender';
import { ElementBoundBox, ElementPositionBox, ElementScrollDimension, PlacementType, PositionAlignmentType } from '../../../types/ui.type';
import { BasePositionCalculationStrategy } from './base-position-calculation-strategy';
import { Nullable } from '../../../types/general';
/**
 * calculate position by screen container
 */
export declare class ScreenPositionCalculationStrategy extends BasePositionCalculationStrategy {
  showConfig: ElementAppenderShowConfig;
  private previousPositionBox;
  private previousTargetRect;
  private scrollFrameRequestId;
  private usePreviousPlacement;
  private readonly scrollPositionUpdateStrategy;
  /**
   * For screen-positioned appendable we may get a lot of scroll events.
   * This hook throttles the check with requestAnimationFrame and only allows an adjust when
   * the strategy determines we should update.
   *
   * @returns {boolean} True when controller should perform a position adjustment.
   */
  shouldAdjustPosition(): boolean;
  /**
   * Clears any pending scroll animation frame callback.
   * Call this when popover is hidden/destroyed to avoid leaks and stale callbacks.
   */
  clearScrollFrame(): void;
  /**
   * Get the position of the element in the container according to the target element and the placement
   * If give a translocation, it will apply the translocation to the result.
   *
   * @param {boolean} usePreviousPlacement - Should keep use previous placement and alignment.
   * @returns {ElementPositionBox} A function that takes in a container, element, target, placement, and translocation and
   * returns an ElementPositionBox.
   */
  getPosition(usePreviousPlacement: boolean): ElementPositionBox;
  /**
   * It returns the position of an element relative to its container and also includes the scroll height of container.
   *
   * @returns {ElementBoundBox} An object with the properties width, height, top, and left.
   */
  protected getTargetBoundBox(): ElementBoundBox;
  /**
   * "Get the width and height of an element."
   *
   * The function takes a single parameter, a container element, and returns an object with two
   * properties: width and height
   *
   * @returns {ElementScrollDimension} An object with two properties: width and height.
   */
  protected getElementScrollDimension(): ElementScrollDimension;
  /**
   * Whether the alignment space is enough
   *
   * @param {ElementScrollDimension} containerBox - The bounding box of the container element.
   * @param {ElementBoundBox} targetBox - The position of the target element.
   * @param {ElementBoundBox} elementBox - The box of the element that we're trying to position.
   * @param {PlacementType} placement - The placement of the element relative to the target.
   * @param {PlacementType} alignment - The alignment of the element relative to the target.
   * @returns {boolean} return true if it has enough space, otherwise false
   */
  protected hasEnoughAlignmentSpace(containerBox: ElementScrollDimension, targetBox: ElementBoundBox, elementBox: ElementBoundBox, placement: PlacementType, alignment: PositionAlignmentType): boolean;
  /**
   * Screen-specific suitable placement selection.
   * Tries to find a placement that has enough alignment space within the viewport first,
   * otherwise falls back to the base strategy.
   *
   * @param {ElementScrollDimension} containerBox - The bounding box of the container.
   * @param {ElementBoundBox} elementBox - The box of the element to place.
   * @param {ElementBoundBox} targetBox - The box of the target element.
   * @param {PlacementType[]} placements - Ordered list of placements to try.
   * @returns {Nullable<PlacementType>} The chosen placement.
   */
  protected getSuitablePlacement(containerBox: ElementScrollDimension, elementBox: ElementBoundBox, targetBox: ElementBoundBox, placements: PlacementType[]): Nullable<PlacementType>;
}
