import { VegaSlimmer } from '../../../../vega-slimmer/vega-slimmer-core';
import { CodeNodeType } from '../../types';
import { CodeBlockRange } from './code-block-range';
/**
 * The result of re-calculating the next offset and content after insert or delete operation.
 */
export declare type NextOffsetAndContentResult = {
  nextOffset: number;
  updatedContent: string;
};
/**
 * The abstract class used to control the code block input paste action.
 */
export declare abstract class CodeInputPaste extends VegaSlimmer {
  /**
   * Delete the selected text from a string.
   *
   * @param {string} oldValue - The original string value.
   * @param {number} contentStartOffset - The start index for deletion.
   * @param {number} length - The length of text to delete.
   * @returns {string} The content after deletion.
   */
  protected deleteSelectedText(oldValue: string, contentStartOffset: number, length: number): string;
  /**
   * Collect the code nodes content from the code nodes array.
   *
   * @param {CodeNodeType[]} codeNodes - The code nodes array.
   * @returns {string} The concatenated content of code nodes.
   */
  protected getCodeNodesContent(codeNodes: CodeNodeType[]): string;
  /**
   * Stop event propagation.
   *
   * @param {Event} e - The event object.
   */
  protected stopEventPropagation(e: Event): void;
  /**
   * Re-calculate the next offset and content after insert or delete operation.
   *
   * @param {CodeBlockRange} range - The current code block range.
   * @param {string} content - The current code content.
   * @param {string} newlyAddedContent - The new content to be inserted.
   * @returns {NextOffsetAndContentResult} The next offset and updated content.
   */
  protected reCalculateRangeAndContent(range: CodeBlockRange, content: string, newlyAddedContent: string): NextOffsetAndContentResult;
}
