import { Tag } from '@wix/bex-utils/@wix/ambassador-os-tags-v1-tag/types';
import { TagsBIReporter } from './TagsBIReporter';
import { WixPatternsContainer } from '../WixPatternsContainer';
import { Fqdn, ToastConfig } from '../../model';
import { CollectionState } from '../CollectionState';
import { CollectionOptimisticActions } from '../CollectionOptimisticActions';
import { TaskState } from '../TaskState';
import { TagErrorVisualType, TypedEmitter } from '../../util';
import { CreateManyParams, DeleteManyParams, UpdateManyParams } from '../OptimisticActions';
import { TagsService } from '../../services/tagsService';
import type { errorHandler } from '@wix/essentials';
export declare const TAG_MAX_LENGTH = 30;
export interface TagsManagementStateParams {
    readonly container: WixPatternsContainer;
    readonly fqdn: Fqdn;
}
export declare class TagsManagementState {
    readonly collection: CollectionState<Tag>;
    readonly optimisticActions: CollectionOptimisticActions<Tag, {}>;
    readonly container: WixPatternsContainer;
    readonly fqdn: Fqdn;
    readonly initTask: TaskState<unknown>;
    readonly tagsService: TagsService;
    readonly events: TypedEmitter<{
        showToast: (toastConfig: ToastConfig) => unknown;
        hideToast: (toastConfig: ToastConfig) => unknown;
    }>;
    overrideShowToast: boolean;
    _resolvedListTagsError?: errorHandler.ResolvedError;
    readonly shouldAllowTagsPagination: boolean;
    constructor(params: TagsManagementStateParams);
    init(): (() => void) | undefined;
    retry(): void;
    get items(): Tag[];
    get hasMore(): boolean;
    loadMore(): Promise<void>;
    get isError(): boolean;
    get error(): errorHandler.ResolvedError | undefined;
    get isLoading(): boolean;
    get isSuccessful(): boolean;
    get fqdnString(): string;
    getTagById(tagId: string): Tag | undefined;
    getTagNameById(tagId: string): string | null | undefined;
    private _isFqdnValid;
    private _optimisticActionBaseParams;
    private get tagsLimit();
    private hasReachedTagsLimit;
    private showTagsLimitErrorToast;
    createTag(params: {
        name: string;
        origin: string;
        tagSubOrigin?: string;
        filteredListSize: number;
        id?: string;
        isFromSearch?: boolean;
        onSuccess?: (tag: Tag) => void | Promise<void>;
        optimisticActionParams?: Partial<CreateManyParams<Tag>>;
        tagsBIReporter: TagsBIReporter;
        visualType?: TagErrorVisualType;
    }): Promise<void>;
    updateTag({ tagToUpdate, previousName, origin, tagSubOrigin, filteredListSize, isFromSearch, optimisticActionParams, tagsBIReporter, }: {
        tagToUpdate: Tag;
        previousName: string;
        origin: string;
        tagSubOrigin?: string;
        filteredListSize: number;
        isFromSearch?: boolean;
        optimisticActionParams?: Partial<UpdateManyParams<Tag, {}>>;
        tagsBIReporter: TagsBIReporter;
    }): Promise<void>;
    deleteTag({ tagToDelete, origin, tagSubOrigin, filteredListSize, isFromSearch, optimisticActionParams, tagsBIReporter, }: {
        tagToDelete: Tag;
        origin: string;
        tagSubOrigin?: string;
        filteredListSize: number;
        isFromSearch?: boolean;
        optimisticActionParams?: Partial<DeleteManyParams<Tag, {}>>;
        tagsBIReporter: TagsBIReporter;
    }): Promise<void>;
}
//# sourceMappingURL=TagsManagementState.d.ts.map