-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
259 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
## API Report File for "@contember/react-board-dnd-kit" | ||
|
||
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). | ||
```ts | ||
|
||
import { BoardBaseProps } from '@contember/react-board'; | ||
import { BoardBindingProps } from '@contember/react-board'; | ||
import { BoardColumn } from '@contember/react-board'; | ||
import { BoardItem } from '@contember/react-board'; | ||
import { BoardMethods } from '@contember/react-board'; | ||
import { default as React_2 } from 'react'; | ||
import { ReactNode } from 'react'; | ||
import { useSortable } from '@dnd-kit/sortable'; | ||
|
||
// @public (undocumented) | ||
export type BoardColumnRendererProps = { | ||
children?: ReactNode; | ||
value?: BoardColumn; | ||
dragOverlay?: boolean; | ||
sortableProps?: UseSortableProps; | ||
boardMethods?: BoardMethods<any>; | ||
dropIndicator?: 'before' | 'after'; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardDndKitRendererProps = BoardBindingProps<any>; | ||
|
||
// @public (undocumented) | ||
export type BoardItemRendererProps = { | ||
value?: BoardItem; | ||
dragOverlay?: boolean; | ||
sortableProps?: UseSortableProps; | ||
boardMethods?: BoardMethods<any>; | ||
dropIndicator?: 'before' | 'after'; | ||
}; | ||
|
||
// @public (undocumented) | ||
export const createBoardDndKit: <ColumnExtraProps extends {}, ItemExtraProps extends {}>({ Column, Item, Wrapper, usePortalProvider }: { | ||
Wrapper: React_2.ComponentType<{ | ||
children: ReactNode; | ||
}>; | ||
Column: React_2.ComponentType<BoardColumnRendererProps & ColumnExtraProps>; | ||
Item: React_2.ComponentType<BoardItemRendererProps & ItemExtraProps>; | ||
usePortalProvider?: (() => Element | null) | undefined; | ||
}) => React_2.FunctionComponent<BoardBaseProps<ColumnExtraProps & ItemExtraProps>>; | ||
|
||
// @public (undocumented) | ||
export const createBoardDndKitRenderer: <ColumnExtraProps extends {}, ItemExtraProps extends {}>({ Column, Item, Wrapper, usePortalProvider }: { | ||
Wrapper: React_2.ComponentType<{ | ||
children: ReactNode; | ||
}>; | ||
Column: React_2.ComponentType<BoardColumnRendererProps & ColumnExtraProps>; | ||
Item: React_2.ComponentType<BoardItemRendererProps & ItemExtraProps>; | ||
usePortalProvider?: (() => Element | null) | undefined; | ||
}) => React_2.FunctionComponent<{ | ||
columns: BoardColumn<any>[]; | ||
} & BoardMethods<any> & ColumnExtraProps & ItemExtraProps>; | ||
|
||
// @public (undocumented) | ||
export type UseSortableProps = ReturnType<typeof useSortable>; | ||
|
||
|
||
export * from "@contember/react-board"; | ||
|
||
// (No @packageDocumentation comment for this package) | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
## API Report File for "@contember/react-board-ui" | ||
|
||
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). | ||
```ts | ||
|
||
import { BoardBaseProps } from '@contember/react-board'; | ||
import { BoardColumnRendererProps } from '@contember/react-board-dnd-kit'; | ||
import { ComponentType } from 'react'; | ||
import { default as React_2 } from 'react'; | ||
|
||
// @public (undocumented) | ||
export const Board: ComponentType<BoardProps>; | ||
|
||
// @public (undocumented) | ||
export type BoardColumnExtraProps = { | ||
columnLabel?: React_2.ReactElement | ComponentType<BoardColumnRendererProps>; | ||
nullColumnLabel?: React_2.ReactNode; | ||
columnFooter?: React_2.ReactElement | ComponentType<BoardColumnRendererProps>; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardItemExtraProps = { | ||
children: React_2.ReactNode; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardProps = BoardBaseProps<BoardColumnExtraProps & BoardItemExtraProps>; | ||
|
||
|
||
export * from "@contember/react-board-dnd-kit"; | ||
|
||
// (No @packageDocumentation comment for this package) | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,156 @@ | ||
## API Report File for "@contember/react-board" | ||
|
||
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). | ||
```ts | ||
|
||
import { ComponentType } from 'react'; | ||
import { EntityAccessor } from '@contember/react-binding'; | ||
import { EntityListAccessor } from '@contember/react-binding'; | ||
import { NamedExoticComponent } from 'react'; | ||
import { ReactNode } from 'react'; | ||
import { SugaredQualifiedEntityList } from '@contember/react-binding'; | ||
import { SugaredRelativeEntityList } from '@contember/react-binding'; | ||
import { SugaredRelativeSingleEntity } from '@contember/react-binding'; | ||
import { SugaredRelativeSingleField } from '@contember/react-binding'; | ||
|
||
// @public (undocumented) | ||
export type BoardAddColumnMethod = (index: number | undefined, preprocess?: EntityAccessor.BatchUpdatesHandler) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardAddItemMethod<ColumnValue extends BoardColumnValue> = (column: ColumnValue | null, index: number | undefined, preprocess?: EntityAccessor.BatchUpdatesHandler) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardBaseProps<RendererExtraProps> = (BoardQualifiedDynamicProps | BoardRelativeDynamicProps | BoardQualifiedStaticProps | BoardRelativeStaticProps) & RendererExtraProps; | ||
|
||
// @public (undocumented) | ||
export type BoardBindingProps<ColumnValue extends BoardColumnValue> = { | ||
columns: BoardColumn<ColumnValue>[]; | ||
} & BoardMethods<ColumnValue>; | ||
|
||
// @public (undocumented) | ||
export type BoardColumn<ColumnValue extends BoardColumnValue = BoardColumnValue> = { | ||
id: string | number; | ||
index: number; | ||
value: ColumnValue | null; | ||
items: BoardItem[]; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardColumnValue = BoardStaticColumnValue | EntityAccessor; | ||
|
||
// @public (undocumented) | ||
export type BoardCommonProps = BoardNullBehaviourProps & { | ||
children: ReactNode; | ||
sortableBy?: string | SugaredRelativeSingleField; | ||
sortScope?: 'column' | 'board'; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardDynamicColumnsBindingProps = { | ||
columns: SugaredQualifiedEntityList['entities']; | ||
columnsSortableBy?: string | SugaredRelativeSingleField; | ||
discriminationField: string | SugaredRelativeSingleEntity; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardItem = { | ||
id: string | number; | ||
index: number; | ||
value: EntityAccessor; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardMethods<ColumnValue extends BoardColumnValue> = { | ||
moveColumn?: BoardMoveColumnMethod; | ||
addColumn?: BoardAddColumnMethod; | ||
removeColumn?: BoardRemoveColumnMethod; | ||
moveItem?: BoardMoveItemMethod<ColumnValue>; | ||
addItem?: BoardAddItemMethod<ColumnValue>; | ||
removeItem?: BoardRemoveItemMethod; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardMoveColumnMethod = (entity: EntityAccessor, index: number) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardMoveItemMethod<ColumnValue extends BoardColumnValue> = (entity: EntityAccessor, column: ColumnValue | null, index: number) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardNullBehaviourProps = { | ||
nullColumn?: 'never' | 'always' | 'auto'; | ||
nullColumnPlacement?: 'start' | 'end'; | ||
}; | ||
|
||
// @public (undocumented) | ||
export const BoardNullColumnPlaceholder = "__null_column"; | ||
|
||
// @public (undocumented) | ||
export type BoardQualifiedDynamicProps = BoardCommonProps & BoardDynamicColumnsBindingProps & BoardQualifiedItemsProps; | ||
|
||
// @public (undocumented) | ||
export type BoardQualifiedItemsProps = Pick<SugaredQualifiedEntityList, 'entities' | 'orderBy' | 'limit' | 'offset'>; | ||
|
||
// @public (undocumented) | ||
export type BoardQualifiedStaticProps = BoardCommonProps & BoardStaticColumnsBindingProps & BoardQualifiedItemsProps; | ||
|
||
// @public (undocumented) | ||
export type BoardRelativeDynamicProps = BoardCommonProps & BoardDynamicColumnsBindingProps & BoardRelativeItemsProps; | ||
|
||
// @public (undocumented) | ||
export type BoardRelativeItemsProps = Pick<SugaredRelativeEntityList, 'field' | 'orderBy' | 'limit' | 'offset'>; | ||
|
||
// @public (undocumented) | ||
export type BoardRelativeStaticProps = BoardCommonProps & BoardStaticColumnsBindingProps & BoardRelativeItemsProps; | ||
|
||
// @public (undocumented) | ||
export type BoardRemoveColumnMethod = (entity: EntityAccessor) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardRemoveItemMethod = (entity: EntityAccessor) => void; | ||
|
||
// @public (undocumented) | ||
export type BoardStaticColumnsBindingProps = { | ||
columns: { | ||
value: string; | ||
label: ReactNode; | ||
}[]; | ||
discriminationField: string | SugaredRelativeSingleField; | ||
}; | ||
|
||
// @public (undocumented) | ||
export type BoardStaticColumnValue = { | ||
value: string; | ||
label?: ReactNode; | ||
}; | ||
|
||
// @public (undocumented) | ||
export const createBoard: <RendererExtraProps extends {}>({ Renderer, ItemStaticRender, ColumnStaticRender }: CreateBoardArgs<RendererExtraProps>) => NamedExoticComponent<BoardBaseProps<RendererExtraProps>>; | ||
|
||
// @public (undocumented) | ||
export type CreateBoardArgs<T extends {}> = { | ||
Renderer: ComponentType<BoardBindingProps<any> & T>; | ||
ItemStaticRender?: ComponentType<T>; | ||
ColumnStaticRender?: ComponentType<T>; | ||
}; | ||
|
||
// @public (undocumented) | ||
export const useDynamicBoard: ({ sortableBy, sortScope, columnsSortableBy, discriminationField, columnEntities, itemEntities, nullColumnPlacement, nullColumn, }: UseDynamicBoardBindingProps) => BoardBindingProps<EntityAccessor>; | ||
|
||
// @public (undocumented) | ||
export type UseDynamicBoardBindingProps = Omit<BoardCommonProps, 'children'> & BoardDynamicColumnsBindingProps & { | ||
columnEntities: EntityListAccessor; | ||
itemEntities: EntityListAccessor; | ||
}; | ||
|
||
// @public (undocumented) | ||
export const useStaticBoard: ({ sortableBy, sortScope, columns, discriminationField, itemEntities, nullColumnPlacement, nullColumn, }: UseStaticBoardBindingProps) => BoardBindingProps<BoardStaticColumnValue>; | ||
|
||
// @public (undocumented) | ||
export type UseStaticBoardBindingProps = Omit<BoardCommonProps, 'children'> & BoardStaticColumnsBindingProps & { | ||
itemEntities: EntityListAccessor; | ||
}; | ||
|
||
// (No @packageDocumentation comment for this package) | ||
|
||
``` |