@craftercms/studio-ui
Version:
Services, components, models & utils to build CrafterCMS authoring extensions.
208 lines (206 loc) • 6.01 kB
TypeScript
/*
* Copyright (C) 2007-2022 Crafter Software Corporation. All Rights Reserved.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3 as published by
* the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
import { DetailedItem } from '../../models/Item';
import { PathNavigatorStateProps } from '../../components/PathNavigator/PathNavigator';
import { GetChildrenResponse } from '../../models/GetChildrenResponse';
import { AjaxError } from 'rxjs/ajax';
import { GetChildrenOptions } from '../../models';
type PayloadWithId<P> = P & {
id: string;
};
export type PathNavInitPayload = PayloadWithId<{
rootPath: string;
locale?: string;
collapsed?: boolean;
excludes?: string[];
limit?: number;
currentPath?: string;
keyword?: string;
offset?: number;
sortStrategy?: GetChildrenOptions['sortStrategy'];
order?: GetChildrenOptions['order'];
}>;
export declare const pathNavigatorInit: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PathNavInitPayload,
string
>;
export declare const pathNavigatorSetLocaleCode: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
locale: string;
}>,
string
>;
export declare const pathNavigatorUpdate: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<Partial<PathNavigatorStateProps>>,
string
>;
export declare const pathNavigatorSetCollapsed: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
collapsed: boolean;
}>,
string
>;
export declare const pathNavigatorSetCurrentPath: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
path: string;
}>,
string
>;
export declare const pathNavigatorConditionallySetPath: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
path: string;
keyword?: string;
}>,
string
>;
export declare const pathNavigatorConditionallySetPathComplete: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
path: string;
parent?: DetailedItem;
children: GetChildrenResponse;
}>,
string
>;
export declare const pathNavigatorConditionallySetPathFailed: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
error: {
status: number;
message: string;
};
},
string
>;
export declare const pathNavigatorRefresh: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
},
string
>;
export declare const pathNavigatorBackgroundRefresh: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
},
string
>;
export declare const pathNavigatorBulkRefresh: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
requests: PayloadWithId<{
backgroundRefresh?: boolean;
}>[];
},
string
>;
export declare const pathNavigatorItemChecked: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
item: DetailedItem;
}>,
string
>;
export declare const pathNavigatorItemUnchecked: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
item: DetailedItem;
}>,
string
>;
export declare const pathNavigatorClearChecked: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
},
string
>;
export declare const pathNavigatorFetchParentItems: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
path: string;
excludes?: string[];
limit: number;
offset?: number;
keyword?: string;
sortStrategy: string;
order: string;
}>,
string
>;
export declare const pathNavigatorFetchPath: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
path: string;
keyword?: string;
}>,
string
>;
export declare const pathNavigatorFetchPathComplete: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
parent?: DetailedItem;
children: GetChildrenResponse;
}>,
string
>;
export declare const pathNavigatorBulkFetchPathComplete: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
paths: PayloadWithId<{
parent?: DetailedItem;
children: GetChildrenResponse;
}>[];
},
string
>;
export declare const pathNavigatorFetchParentItemsComplete: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
items: DetailedItem[];
children: GetChildrenResponse;
}>,
string
>;
export declare const pathNavigatorFetchPathFailed: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
error: Omit<AjaxError, 'request' | 'xhr'>;
},
string
>;
export declare const pathNavigatorBulkFetchPathFailed: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
ids: string[];
error: Omit<AjaxError, 'request' | 'xhr'>;
},
string
>;
export declare const pathNavigatorSetKeyword: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
keyword: string;
}>,
string
>;
export declare const pathNavigatorChangePage: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
offset: number;
}>,
string
>;
export declare const pathNavigatorChangeLimit: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
PayloadWithId<{
limit: number;
offset: number;
}>,
string
>;
export declare const pathNavRootPathMissing: import('@reduxjs/toolkit').ActionCreatorWithOptionalPayload<
{
id: string;
},
string
>;
export {};