react-application-core
Version:
A react-based application core for the business applications.
165 lines (164 loc) • 6.59 kB
TypeScript
/// <reference types="react" />
import { AnyT, IDataWrapper, IDisabledWrapper, IEmptyDataMessageWrapper, IEmptyMessageWrapper, IEntity, IFilterWrapper, IFullWrapper, IItemConfigurationWrapper, IKeyValue, IListConfigurationWrapper, IListWrapper, ILocalPaginationWrapper, IOnSelectWrapper, IOriginalDataWrapper, IPagesCountWrapper, IRawDataWrapper, IRowsWrapper, ISelectedWrapper, ISorterWrapper, ITotalCountWrapper } from '../definitions.interface';
import { IGenericComponentProps } from './generic-component-definition.interface';
import { IGenericContainerProps } from './generic-container-definition.interface';
import { IPresetsIconEntity, IPresetsTemplateEntity, IReduxLifeCycleEntity } from './entity-definition.interface';
import { IReduxPaginatedEntity } from './page-definition.interface';
import { IEnhancedGenericComponentProps } from './enhanced-generic-component-definition.interface';
import { IPresetsRowEntity } from './row-definition.interface';
import { IPresetsSelectedElementEntity } from './selected-element-definition.interface';
import { ISortDirectionsEntity } from './sort-definition.interface';
/**
* @redux-entity
* @stable [08.05.2020]
*/
export interface IReduxPaginatedDataEntity<TEntity = IEntity, TRawData = AnyT> extends IReduxPaginatedEntity, IDataWrapper<TEntity[]>, IOriginalDataWrapper<TEntity[]>, IRawDataWrapper<TRawData> {
}
/**
* @redux-entity
* @stable [08.05.2020]
*/
export interface IReduxListEntity<TEntity = IEntity, TRawData = AnyT> extends IReduxPaginatedDataEntity<TEntity, TRawData>, IReduxLifeCycleEntity, ISortDirectionsEntity, ISelectedWrapper<TEntity> {
}
/**
* @presets-entity
* @stable [11.06.2020]
*/
export interface IPresetsListEntity<TEntity extends IEntity = IEntity> extends IPresetsSelectedElementEntity, /* [11.06.2020] */ IListItemConfigurationEntity, /* [11.06.2020] */ IEmptyDataMessageWrapper, /* [11.06.2020] */ IEmptyMessageWrapper<string | boolean>, /* [11.06.2020] */ IFilterWrapper<(entity: TEntity) => boolean>, /* [11.06.2020] */ IFullWrapper, /* [11.06.2020] */ ILocalPaginationWrapper, /* [16.07.2020] */ IOnSelectWrapper<TEntity>, /* [11.06.2020] */ ISorterWrapper {
}
/**
* @generic-entity
* @stable [11.06.2020]
*/
export interface IGenericListEntity<TEntity extends IEntity = IEntity, TRawData = AnyT> extends IPresetsListEntity<TEntity>, IReduxListEntity<TEntity, TRawData> {
}
/**
* @presets-entity
* @stable [01.06.2020]
*/
export interface IPresetsBaseListItemEntity<TRawData extends IEntity = IEntity> extends IPresetsTemplateEntity<TRawData>, IPresetsIconEntity, IDisabledWrapper {
}
/**
* @presets-entity
* @stable [17.08.2020]
*/
export interface IPresetsListItemEntity<TRawData = IEntity> extends IPresetsBaseListItemEntity<TRawData>, IPresetsRowEntity<TRawData> {
}
/**
* @generic-entity
* @stable [01.06.2020]
*/
export interface IGenericListItemEntity<TEntity = IEntity> extends IPresetsListItemEntity<TEntity> {
}
/**
* @props
* @stable [01.06.2020]
*/
export interface IListItemProps<TEntity = IEntity> extends IGenericComponentProps, IGenericListItemEntity<TEntity> {
}
/**
* @configuration-entity
* @stable [11.06.2020]
*/
export interface IListItemConfigurationEntity<TProps = IListItemProps> extends IItemConfigurationWrapper<TProps> {
}
/**
* @redux-holder-entity
* @stable [11.06.2020]
*/
export interface IReduxListHolderEntity<TEntity = IEntity, TRawData = AnyT, TList = IReduxListEntity<TEntity, TRawData>> extends IListWrapper<TList> {
}
/**
* @configuration-entity
* @stable [08.05.2020]
*/
export interface IListConfigurationEntity<TProps extends IListProps = IListProps> extends IListConfigurationWrapper<TProps> {
}
/**
* @props
* @stable [27.10.2019]
*/
export interface IListProps extends IEnhancedGenericComponentProps, IGenericListEntity {
}
/**
* @config-entity
* @stable [16.07.2020]
*/
export interface IListRowsConfigEntity extends IPagesCountWrapper, IRowsWrapper<JSX.Element[]>, ITotalCountWrapper {
}
/**
* TODO
*/
export interface ICardListProps extends IKeyValue {
}
/**
* @generic-entity
* @stable [30.03.2020]
*/
export interface IGenericListContainerEntity extends IReduxListHolderEntity, IListConfigurationEntity {
}
/**
* @props
* @stable [30.03.2020]
*/
export interface IBaseListContainerProps extends IGenericContainerProps, IReduxListHolderEntity {
}
/**
* @props
* @stable [30.03.2020]
*/
export interface IListContainerProps extends IGenericContainerProps, IGenericListContainerEntity {
}
/**
* @props
* @stable [11.06.2020]
*/
export interface IBasicListProps extends IEnhancedGenericComponentProps, IGenericListEntity {
}
/**
* @classes
* @stable [04.05.2020]
*/
export declare enum ListClassesEnum {
CARD_LIST = "rac-card-list",
FULL_LIST = "rac-full-list",
LIST = "rac-list",
LIST_ITEM = "rac-list-item",
LIST_ITEM_CONTENT = "rac-list-item__content",
LIST_ITEM_DECORATED = "rac-list-item-decorated",
LIST_ITEM_HOVERED = "rac-list-item-hovered",
LIST_ITEM_ICON = "rac-list-item__icon",
LIST_ITEM_LAST = "rac-list-item-last",
LIST_ITEM_ODD = "rac-list-item-odd",
LIST_ITEM_SELECTABLE = "rac-list-item-selectable",
LIST_ITEM_SELECTED = "rac-list-item-selected",
LIST_ITEM_UNSELECTED = "rac-list-item-unselected"
}
/**
* @initial-redux-entity
* @stable [29.07.2020]
*/
export declare const INITIAL_REDUX_LIST_ENTITY: Readonly<IReduxListEntity<IEntity, any>>;
/**
* @default-entity
* @stable [04.05.2020]
*/
export declare const DEFAULT_SELECTABLE_LIST_ITEM_ENTITY: Readonly<IPresetsListItemEntity<IEntity>>;
/**
* @default-entity
* @stable [04.05.2020]
*/
export declare const DEFAULT_NOT_HOVERED_LIST_ITEM_ENTITY: Readonly<IPresetsListItemEntity<IEntity>>;
/**
* @stable [30.03.2020]
*/
export declare const LIST_CANCEL_LOAD_ACTION_TYPE = "list.cancel.load";
export declare const LIST_CREATE_ACTION_TYPE = "list.create";
export declare const LIST_LAZY_LOAD_ACTION_TYPE = "list.lazy.load";
export declare const LIST_LOAD_ACTION_TYPE = "list.load";
export declare const LIST_MERGE_ACTION_TYPE = "list.merge";
export declare const LIST_SELECT_ACTION_TYPE = "list.select";
export declare const LIST_LAZY_LOAD_DONE_ACTION_TYPE: string;
export declare const LIST_LAZY_LOAD_ERROR_ACTION_TYPE: string;
export declare const LIST_LOAD_DONE_ACTION_TYPE: string;
export declare const LIST_LOAD_ERROR_ACTION_TYPE: string;