import { InitialArrayType } from "../types";
export type ShuttleState = {
  /**
   * The source container data as an array.
   */
  source: any[],

  /**
   * The target container data as an array.
   */
  target: any[],

  /**
   * The selection indexes used for quickly applying classNames.
   */
  selected: {
    /**
     * The source containers selections.
     */
    source: Set<number>,

    /**
     * The target container selections.
     */
    target: Set<number>,
    ...
  },
  disabled: {
    /**
     * The source containers disabled items.
     */
    source: Set<any>,

    /**
     * The target container disabled items.
     */
    target: Set<any>,
    ...
  },
  ...
};
export type InitialState =
  | InitialArrayType<any>
  | Promise<InitialArrayType<any>>;
export type InitialSelections = InitialArrayType<number>;
export type DisabledSelections = InitialArrayType<any>;
export type InitArgs = {
  source: any[],
  target: any[],
  selections: InitialSelections,
  disabled: DisabledSelections,
  ...
};
declare export function init(x: InitArgs): ShuttleState;

/**
 * useShuttleState allows you to own the state of the Shuttle. Pass in custom
 * data without trying to remember what prop needs to be set and with what params.
 * Save this result in a variable and spread ot back to `<Shuttle>`. Let the Shuttle
 * know:
 *
 * 1. What your data is
 * 2. What (if any) items need to be pre-selected
 * 3. What (if any) custom state reducers you want to process -- you can even override Shuttle state reducers here too!
 * @param initialState
 * @param initialSelections
 * @param reducers
 */
declare export function useShuttleState(
  initialState?: InitialState,
  initialSelections?: InitialSelections,
  disabled?: DisabledSelections,
  reducers?: { [key: string]: Function, ... }
): {
  shuttleState: any,
  setShuttleState: any,
  ...
};
