import React from "react";
import { TrelloClient } from "trello.js";
import Cache from "@trello-cli/cache";
import { TrelloBoard, TrelloList, TrelloCard, TrelloLabel, TrelloMember } from "../types";
interface TrelloState {
    boards: TrelloBoard[];
    currentBoard: TrelloBoard | null;
    lists: TrelloList[];
    cardsByList: Record<string, TrelloCard[]>;
    boardLabels: TrelloLabel[];
    members: TrelloMember[];
    loading: boolean;
    error: string | null;
    lastSynced: Date | null;
}
type TrelloAction = {
    type: "SET_BOARDS";
    boards: TrelloBoard[];
} | {
    type: "SET_CURRENT_BOARD";
    board: TrelloBoard | null;
} | {
    type: "SET_LISTS";
    lists: TrelloList[];
} | {
    type: "SET_CARDS";
    listId: string;
    cards: TrelloCard[];
} | {
    type: "SET_ALL_CARDS";
    cardsByList: Record<string, TrelloCard[]>;
} | {
    type: "ADD_CARD";
    listId: string;
    card: TrelloCard;
} | {
    type: "REMOVE_CARD";
    listId: string;
    cardId: string;
} | {
    type: "UPDATE_CARD";
    card: TrelloCard;
} | {
    type: "MOVE_CARD";
    cardId: string;
    fromListId: string;
    toListId: string;
    card: TrelloCard;
} | {
    type: "ADD_LIST";
    list: TrelloList;
} | {
    type: "SET_MEMBERS";
    members: TrelloMember[];
} | {
    type: "SET_BOARD_LABELS";
    labels: TrelloLabel[];
} | {
    type: "SET_LOADING";
    loading: boolean;
} | {
    type: "SET_ERROR";
    error: string | null;
} | {
    type: "SET_SYNCED";
};
interface TrelloContextType {
    state: TrelloState;
    dispatch: React.Dispatch<TrelloAction>;
    client: TrelloClient;
    cache: Cache;
    loadBoards: () => Promise<void>;
    loadBoard: (board: TrelloBoard) => Promise<void>;
    createCard: (listId: string, name: string, opts?: {
        desc?: string;
        due?: string;
        position?: "top" | "bottom";
    }) => Promise<TrelloCard>;
    createList: (name: string) => Promise<TrelloList>;
    moveCard: (cardId: string, fromListId: string, toListId: string) => Promise<void>;
    archiveCard: (cardId: string, listId: string) => Promise<void>;
    deleteCard: (cardId: string, listId: string) => Promise<void>;
    updateCard: (cardId: string, updates: {
        name?: string;
        desc?: string;
        due?: string | null;
    }) => Promise<TrelloCard>;
    addLabelToCard: (cardId: string, labelId: string) => Promise<void>;
    removeLabelFromCard: (cardId: string, labelId: string) => Promise<void>;
    addMemberToCard: (cardId: string, memberId: string) => Promise<void>;
    removeMemberFromCard: (cardId: string, memberId: string) => Promise<void>;
    loadCardDetails: (cardId: string) => Promise<void>;
    createChecklist: (cardId: string, name: string) => Promise<void>;
    deleteChecklist: (cardId: string, checklistId: string) => Promise<void>;
    createCheckItem: (checklistId: string, name: string, cardId: string) => Promise<void>;
    deleteCheckItem: (cardId: string, checkItemId: string) => Promise<void>;
    toggleCheckItem: (cardId: string, checkItemId: string, currentState: "complete" | "incomplete") => Promise<void>;
    addAttachment: (cardId: string, url: string, name?: string) => Promise<void>;
    deleteAttachment: (cardId: string, attachmentId: string) => Promise<void>;
    syncCache: () => Promise<void>;
    loadAssignedCards: () => Promise<TrelloCard[]>;
}
export declare function TrelloProvider({ children, client, cache, }: {
    children: React.ReactNode;
    client: TrelloClient;
    cache: Cache;
}): import("react/jsx-runtime").JSX.Element;
export declare function useTrello(): TrelloContextType;
export {};
