import type { ReadonlySignal } from '@preact/signals';
import type { CapabilityName } from '../../core/models/api/capability';
import type { ExistingLegalEntity } from '../../core/models/api/legal-entity';
import type { LegalEntityAssociation } from '../../core/models/api/legal-entity-association';
import type { TransferInstrumentOverview } from '../../core/models/api/transfer-instrument';
import type { AccountHolderOption } from '../../types/accountHolder';
import type { CountryCode } from '../../types/datasets/country-code';
import type { CapabilityProblems } from '../../types/errors/capability-problems';
import type { TrustMember } from '../../components/Trust/tasks/TrustMembers/types';
import type { UnincorporatedPartnershipMember } from '../../components/UnincorporatedPartnership/tasks/UnincorporatedPartnershipMembers/types';
import type { TaskStatus, TaskStatusWithReason } from './taskStatus';
import { TaskStatuses } from './taskStatus';
import type { TaskType } from './taskTypes';
export type TaskIdentifier = TaskType | `${TaskType}-${string}`;
export interface GlobalStore {
    taskTypes: ReadonlySignal<TaskType[]>;
    rootLegalEntity: ReadonlySignal<ExistingLegalEntity>;
    accountHolder: ReadonlySignal<AccountHolderOption | undefined>;
    trustMembers: ReadonlySignal<TrustMember[]>;
    unincorporatedPartnershipMembers: ReadonlySignal<UnincorporatedPartnershipMember[]>;
    capabilities: ReadonlySignal<CapabilityName[]>;
    capabilityProblems: ReadonlySignal<CapabilityProblems>;
    transferInstruments: ReadonlySignal<TransferInstrumentOverview[]>;
    legalRepresentative: ReadonlySignal<LegalEntityAssociation | undefined>;
    rootLegalEntityCountry: ReadonlySignal<CountryCode>;
    tasks: ReadonlySignal<TaskIdentifier[]>;
    taskStatuses: ReadonlySignal<TaskStatuses>;
    setTaskTypes(taskTypes: TaskType[]): void;
    setRootLegalEntity(rootLegalEntity: ExistingLegalEntity): void;
    setAccountHolder(accountHolder: AccountHolderOption | undefined): void;
    setTrustMembers(trustMembers: TrustMember[]): void;
    setUnincorporatedPartnershipMembers(unincorporatedPartnershipMembers: UnincorporatedPartnershipMember[]): void;
}
type TaskStatuses = Partial<Record<TaskIdentifier, TaskStatusWithReason>>;
/**
 * Initializes the store. Should only be called from {@link StoreProvider}.
 */
export declare const createGlobalStore: ({ rootLegalEntity: rootLegalEntityIn, }: {
    rootLegalEntity: ExistingLegalEntity;
}) => GlobalStore;
export declare const StoreContext: import("preact").Context<GlobalStore | null>;
export declare function useGlobalStore(): GlobalStore;
export declare const useGetTaskStatus: () => (taskType: TaskType, id?: string) => TaskStatus;
export {};
