@vuu-ui/vuu-table 0.8.12 → 0.8.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +4 -4
- package/esm/index.js +1 -1
- package/esm/index.js.map +4 -4
- package/index.css +1 -1
- package/index.css.map +3 -3
- package/package.json +9 -9
- package/types/vuu-table/src/{table-next/Row.d.ts → Row.d.ts} +5 -5
- package/types/vuu-table/src/Table.d.ts +72 -0
- package/types/vuu-table/src/cell-renderers/cell-utils.d.ts +7 -0
- package/types/vuu-table/src/cell-renderers/checkbox-cell/CheckboxCell.d.ts +3 -0
- package/types/vuu-table/src/cell-renderers/checkbox-cell/index.d.ts +1 -0
- package/types/vuu-table/src/cell-renderers/dropdown-cell/DropdownCell.d.ts +4 -0
- package/types/vuu-table/src/cell-renderers/index.d.ts +5 -0
- package/types/vuu-table/src/{table-next/cell-renderers → cell-renderers}/input-cell/InputCell.d.ts +1 -1
- package/types/vuu-table/src/cell-renderers/lookup-cell/LookupCell.d.ts +3 -0
- package/types/vuu-table/src/cell-renderers/lookup-cell/index.d.ts +1 -0
- package/types/vuu-table/src/cell-renderers/toggle-cell/ToggleCell.d.ts +4 -0
- package/types/vuu-table/src/cell-renderers/toggle-cell/index.d.ts +1 -0
- package/types/vuu-table/src/{table-next/column-header-pill → column-header-pill}/ColumnHeaderPill.d.ts +3 -3
- package/types/vuu-table/src/{table-next/column-header-pill → column-header-pill}/GroupColumnPill.d.ts +2 -2
- package/types/vuu-table/src/{table-next/column-header-pill → column-header-pill}/SortIndicator.d.ts +2 -2
- package/types/vuu-table/src/{table-next/column-menu → column-menu}/ColumnMenu.d.ts +2 -2
- package/types/vuu-table/src/{table-next/column-resizing → column-resizing}/useTableColumnResize.d.ts +2 -2
- package/types/vuu-table/src/{table-next/context-menu → context-menu}/index.d.ts +1 -1
- package/types/vuu-table/src/{table-next/context-menu/useTableContextMenu.d.ts → context-menu/useHandleTableContextMenu.d.ts} +3 -3
- package/types/vuu-table/src/header-cell/GroupHeaderCellNext.d.ts +10 -0
- package/types/vuu-table/src/{table-next/header-cell → header-cell}/HeaderCell.d.ts +2 -2
- package/types/vuu-table/src/{table-next/header-cell → header-cell}/index.d.ts +0 -1
- package/types/vuu-table/src/index.d.ts +9 -4
- package/types/vuu-table/src/{table-next/table-cell → table-cell}/TableCell.d.ts +1 -1
- package/types/vuu-table/src/{table-next/table-cell → table-cell}/TableGroupCell.d.ts +1 -1
- package/types/vuu-table/src/{table-next/table-config.d.ts → table-config.d.ts} +1 -1
- package/types/vuu-table/src/{table-next/table-dom-utils.d.ts → table-dom-utils.d.ts} +3 -1
- package/types/vuu-table/src/table-header/TableHeader.d.ts +18 -0
- package/types/vuu-table/src/table-header/useTableHeader.d.ts +15 -0
- package/types/vuu-table/src/useCell.d.ts +6 -0
- package/types/vuu-table/src/useCellEditing.d.ts +10 -0
- package/types/vuu-table/src/useControlledTableNavigation.d.ts +7 -0
- package/types/vuu-table/src/{table-next/useDataSource.d.ts → useDataSource.d.ts} +5 -3
- package/types/vuu-table/src/{table-next/useKeyboardNavigation.d.ts → useKeyboardNavigation.d.ts} +9 -2
- package/types/vuu-table/src/useSelection.d.ts +14 -0
- package/types/vuu-table/src/useTable.d.ts +66 -0
- package/types/vuu-table/src/useTableContextMenu.d.ts +11 -0
- package/types/vuu-table/src/{table-next/useTableModel.d.ts → useTableModel.d.ts} +12 -14
- package/types/vuu-table/src/{table-next/useTableViewport.d.ts → useTableViewport.d.ts} +2 -2
- package/types/vuu-table/src/{table-next/useVirtualViewport.d.ts → useVirtualViewport.d.ts} +2 -2
- package/types/vuu-ui-controls/src/drag-drop/DragDropState.d.ts +15 -0
- package/types/vuu-ui-controls/src/drag-drop/dragDropTypesNext.d.ts +91 -0
- package/types/vuu-layout/src/Component.d.ts +0 -7
- package/types/vuu-layout/src/DraggableLayout.d.ts +0 -7
- package/types/vuu-layout/src/dock-layout/DockLayout.d.ts +0 -10
- package/types/vuu-layout/src/dock-layout/Drawer.d.ts +0 -18
- package/types/vuu-layout/src/dock-layout/index.d.ts +0 -2
- package/types/vuu-layout/src/drag-drop/BoxModel.d.ts +0 -143
- package/types/vuu-layout/src/drag-drop/DragState.d.ts +0 -46
- package/types/vuu-layout/src/drag-drop/Draggable.d.ts +0 -24
- package/types/vuu-layout/src/drag-drop/DropMenu.d.ts +0 -10
- package/types/vuu-layout/src/drag-drop/DropTarget.d.ts +0 -61
- package/types/vuu-layout/src/drag-drop/DropTargetRenderer.d.ts +0 -18
- package/types/vuu-layout/src/drag-drop/dragDropTypes.d.ts +0 -51
- package/types/vuu-layout/src/drag-drop/index.d.ts +0 -4
- package/types/vuu-layout/src/flexbox/Flexbox.d.ts +0 -5
- package/types/vuu-layout/src/flexbox/FlexboxLayout.d.ts +0 -6
- package/types/vuu-layout/src/flexbox/FluidGrid.d.ts +0 -7
- package/types/vuu-layout/src/flexbox/FluidGridLayout.d.ts +0 -6
- package/types/vuu-layout/src/flexbox/Splitter.d.ts +0 -13
- package/types/vuu-layout/src/flexbox/flexbox-utils.d.ts +0 -12
- package/types/vuu-layout/src/flexbox/flexboxTypes.d.ts +0 -51
- package/types/vuu-layout/src/flexbox/index.d.ts +0 -4
- package/types/vuu-layout/src/flexbox/useResponsiveSizing.d.ts +0 -10
- package/types/vuu-layout/src/flexbox/useSplitterResizing.d.ts +0 -2
- package/types/vuu-layout/src/index.d.ts +0 -22
- package/types/vuu-layout/src/layout-action.d.ts +0 -22
- package/types/vuu-layout/src/layout-header/Header.d.ts +0 -13
- package/types/vuu-layout/src/layout-header/index.d.ts +0 -1
- package/types/vuu-layout/src/layout-persistence/LayoutPersistenceManager.d.ts +0 -53
- package/types/vuu-layout/src/layout-persistence/LocalLayoutPersistenceManager.d.ts +0 -18
- package/types/vuu-layout/src/layout-persistence/data.d.ts +0 -3
- package/types/vuu-layout/src/layout-persistence/index.d.ts +0 -4
- package/types/vuu-layout/src/layout-persistence/useLayoutContextMenuItems.d.ts +0 -8
- package/types/vuu-layout/src/layout-provider/LayoutProvider.d.ts +0 -15
- package/types/vuu-layout/src/layout-provider/LayoutProviderContext.d.ts +0 -9
- package/types/vuu-layout/src/layout-provider/index.d.ts +0 -2
- package/types/vuu-layout/src/layout-provider/useLayoutDragDrop.d.ts +0 -4
- package/types/vuu-layout/src/layout-reducer/flexUtils.d.ts +0 -22
- package/types/vuu-layout/src/layout-reducer/index.d.ts +0 -4
- package/types/vuu-layout/src/layout-reducer/insert-layout-element.d.ts +0 -8
- package/types/vuu-layout/src/layout-reducer/layout-reducer.d.ts +0 -3
- package/types/vuu-layout/src/layout-reducer/layoutTypes.d.ts +0 -168
- package/types/vuu-layout/src/layout-reducer/layoutUtils.d.ts +0 -31
- package/types/vuu-layout/src/layout-reducer/move-layout-element.d.ts +0 -3
- package/types/vuu-layout/src/layout-reducer/remove-layout-element.d.ts +0 -3
- package/types/vuu-layout/src/layout-reducer/replace-layout-element.d.ts +0 -6
- package/types/vuu-layout/src/layout-reducer/resize-flex-children.d.ts +0 -4
- package/types/vuu-layout/src/layout-reducer/wrap-layout-element.d.ts +0 -9
- package/types/vuu-layout/src/layout-view/View.d.ts +0 -11
- package/types/vuu-layout/src/layout-view/ViewContext.d.ts +0 -30
- package/types/vuu-layout/src/layout-view/index.d.ts +0 -4
- package/types/vuu-layout/src/layout-view/useView.d.ts +0 -21
- package/types/vuu-layout/src/layout-view/useViewActionDispatcher.d.ts +0 -9
- package/types/vuu-layout/src/layout-view/useViewResize.d.ts +0 -7
- package/types/vuu-layout/src/layout-view/viewTypes.d.ts +0 -21
- package/types/vuu-layout/src/measured-container/MeasuredContainer.d.ts +0 -9
- package/types/vuu-layout/src/measured-container/index.d.ts +0 -2
- package/types/vuu-layout/src/measured-container/useMeasuredContainer.d.ts +0 -22
- package/types/vuu-layout/src/measured-container/useResizeObserver.d.ts +0 -15
- package/types/vuu-layout/src/overflow-container/OverflowContainer.d.ts +0 -17
- package/types/vuu-layout/src/overflow-container/index.d.ts +0 -2
- package/types/vuu-layout/src/overflow-container/overflow-utils.d.ts +0 -49
- package/types/vuu-layout/src/overflow-container/useOverflowContainer.d.ts +0 -20
- package/types/vuu-layout/src/palette/Palette.d.ts +0 -22
- package/types/vuu-layout/src/palette/index.d.ts +0 -1
- package/types/vuu-layout/src/placeholder/Placeholder.d.ts +0 -12
- package/types/vuu-layout/src/placeholder/index.d.ts +0 -1
- package/types/vuu-layout/src/registry/ComponentRegistry.d.ts +0 -13
- package/types/vuu-layout/src/registry/index.d.ts +0 -1
- package/types/vuu-layout/src/responsive/breakpoints.d.ts +0 -4
- package/types/vuu-layout/src/responsive/index.d.ts +0 -3
- package/types/vuu-layout/src/responsive/use-breakpoints.d.ts +0 -7
- package/types/vuu-layout/src/responsive/useResizeObserver.d.ts +0 -13
- package/types/vuu-layout/src/responsive/utils.d.ts +0 -6
- package/types/vuu-layout/src/stack/Stack.d.ts +0 -4
- package/types/vuu-layout/src/stack/StackLayout.d.ts +0 -7
- package/types/vuu-layout/src/stack/index.d.ts +0 -3
- package/types/vuu-layout/src/stack/stackTypes.d.ts +0 -21
- package/types/vuu-layout/src/toolbar/Toolbar.d.ts +0 -19
- package/types/vuu-layout/src/toolbar/index.d.ts +0 -1
- package/types/vuu-layout/src/toolbar/toolbar-dom-utils.d.ts +0 -3
- package/types/vuu-layout/src/toolbar/useKeyboardNavigation.d.ts +0 -32
- package/types/vuu-layout/src/toolbar/useSelection.d.ts +0 -22
- package/types/vuu-layout/src/toolbar/useToolbar.d.ts +0 -28
- package/types/vuu-layout/src/tools/config-wrapper/ConfigWrapper.d.ts +0 -2
- package/types/vuu-layout/src/tools/config-wrapper/index.d.ts +0 -1
- package/types/vuu-layout/src/tools/devtools-box/layout-configurator.d.ts +0 -31
- package/types/vuu-layout/src/tools/devtools-tree/layout-tree-viewer.d.ts +0 -5
- package/types/vuu-layout/src/tools/index.d.ts +0 -3
- package/types/vuu-layout/src/use-persistent-state.d.ts +0 -11
- package/types/vuu-layout/src/utils/index.d.ts +0 -6
- package/types/vuu-layout/src/utils/pathUtils.d.ts +0 -31
- package/types/vuu-layout/src/utils/propUtils.d.ts +0 -5
- package/types/vuu-layout/src/utils/react-utils.d.ts +0 -4
- package/types/vuu-layout/src/utils/refUtils.d.ts +0 -2
- package/types/vuu-layout/src/utils/styleUtils.d.ts +0 -3
- package/types/vuu-layout/src/utils/typeOf.d.ts +0 -4
- package/types/vuu-table/src/table/ColumnResizer.d.ts +0 -8
- package/types/vuu-table/src/table/DragVisualizer.d.ts +0 -8
- package/types/vuu-table/src/table/RowBasedTable.d.ts +0 -4
- package/types/vuu-table/src/table/SortIndicator.d.ts +0 -7
- package/types/vuu-table/src/table/Table.d.ts +0 -9
- package/types/vuu-table/src/table/TableCell.d.ts +0 -4
- package/types/vuu-table/src/table/TableGroupCell.d.ts +0 -4
- package/types/vuu-table/src/table/TableGroupHeaderCell.d.ts +0 -13
- package/types/vuu-table/src/table/TableHeaderCell.d.ts +0 -11
- package/types/vuu-table/src/table/TableRow.d.ts +0 -16
- package/types/vuu-table/src/table/cell-renderers/index.d.ts +0 -1
- package/types/vuu-table/src/table/cell-renderers/json-cell/JsonCell.d.ts +0 -1
- package/types/vuu-table/src/table/cell-renderers/json-cell/index.d.ts +0 -1
- package/types/vuu-table/src/table/context-menu/buildContextMenuDescriptors.d.ts +0 -4
- package/types/vuu-table/src/table/context-menu/index.d.ts +0 -2
- package/types/vuu-table/src/table/context-menu/useTableContextMenu.d.ts +0 -16
- package/types/vuu-table/src/table/dataTableTypes.d.ts +0 -109
- package/types/vuu-table/src/table/filter-indicator.d.ts +0 -13
- package/types/vuu-table/src/table/index.d.ts +0 -10
- package/types/vuu-table/src/table/keyUtils.d.ts +0 -19
- package/types/vuu-table/src/table/useDataSource.d.ts +0 -41
- package/types/vuu-table/src/table/useDraggableColumn.d.ts +0 -9
- package/types/vuu-table/src/table/useKeyboardNavigation.d.ts +0 -22
- package/types/vuu-table/src/table/useMeasuredContainer.d.ts +0 -30
- package/types/vuu-table/src/table/useMeasuredSize.d.ts +0 -26
- package/types/vuu-table/src/table/useResizeObserver.d.ts +0 -15
- package/types/vuu-table/src/table/useSelection.d.ts +0 -9
- package/types/vuu-table/src/table/useTable.d.ts +0 -62
- package/types/vuu-table/src/table/useTableColumnResize.d.ts +0 -17
- package/types/vuu-table/src/table/useTableModel.d.ts +0 -80
- package/types/vuu-table/src/table/useTableScroll.d.ts +0 -29
- package/types/vuu-table/src/table/useVirtualViewport.d.ts +0 -17
- package/types/vuu-table/src/table-next/TableNext.d.ts +0 -4
- package/types/vuu-table/src/table-next/cell-renderers/dropdown-cell/DropdownCell.d.ts +0 -4
- package/types/vuu-table/src/table-next/cell-renderers/index.d.ts +0 -2
- package/types/vuu-table/src/table-next/header-cell/GroupHeaderCell.d.ts +0 -9
- package/types/vuu-table/src/table-next/header-cell/GroupHeaderCellNext.d.ts +0 -9
- package/types/vuu-table/src/table-next/index.d.ts +0 -5
- package/types/vuu-table/src/table-next/useCell.d.ts +0 -6
- package/types/vuu-table/src/table-next/useCellEditing.d.ts +0 -7
- package/types/vuu-table/src/table-next/useTableContextMenu.d.ts +0 -8
- package/types/vuu-table/src/table-next/useTableNext.d.ts +0 -66
- /package/types/vuu-table/src/{table-next/cell-renderers → cell-renderers}/dropdown-cell/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/cell-renderers → cell-renderers}/input-cell/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/column-header-pill → column-header-pill}/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/column-menu → column-menu}/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/column-resizing → column-resizing}/ColumnResizer.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/column-resizing → column-resizing}/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/context-menu → context-menu}/buildContextMenuDescriptors.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/moving-window.d.ts → moving-window.d.ts} +0 -0
- /package/types/vuu-table/src/{table-next/table-cell → table-cell}/index.d.ts +0 -0
- /package/types/vuu-table/src/{table-next/useInitialValue.d.ts → useInitialValue.d.ts} +0 -0
- /package/types/vuu-table/src/{table-next/useResizeObserver.d.ts → useResizeObserver.d.ts} +0 -0
- /package/types/vuu-table/src/{table-next/useTableScroll.d.ts → useTableScroll.d.ts} +0 -0
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { ReactElement } from "react";
|
|
2
|
-
import { LayoutChangeHandler, LayoutJSON } from "../layout-reducer";
|
|
3
|
-
import { LayoutProviderDispatch } from "./LayoutProviderContext";
|
|
4
|
-
export interface LayoutProviderProps {
|
|
5
|
-
children: ReactElement;
|
|
6
|
-
createNewChild?: (index?: number) => ReactElement;
|
|
7
|
-
pathToDropTarget?: string;
|
|
8
|
-
layout?: LayoutJSON;
|
|
9
|
-
onLayoutChange?: LayoutChangeHandler;
|
|
10
|
-
}
|
|
11
|
-
export declare const LayoutProviderVersion: () => JSX.Element;
|
|
12
|
-
export declare const LayoutProvider: (props: LayoutProviderProps) => ReactElement;
|
|
13
|
-
export declare const useLayoutProviderDispatch: () => LayoutProviderDispatch;
|
|
14
|
-
export declare const useLayoutCreateNewChild: () => ((index?: number | undefined) => ReactElement<any, string | import("react").JSXElementConstructor<any>>) | undefined;
|
|
15
|
-
export declare const useLayoutProviderVersion: () => number;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Dispatch, ReactElement } from "react";
|
|
2
|
-
import { DragStartAction, LayoutReducerAction, SaveAction } from "../layout-reducer";
|
|
3
|
-
export type LayoutProviderDispatch = Dispatch<LayoutReducerAction | SaveAction | DragStartAction>;
|
|
4
|
-
export interface LayoutProviderContextProps {
|
|
5
|
-
createNewChild?: (index?: number) => ReactElement;
|
|
6
|
-
dispatchLayoutProvider: LayoutProviderDispatch;
|
|
7
|
-
version: number;
|
|
8
|
-
}
|
|
9
|
-
export declare const LayoutProviderContext: import("react").Context<LayoutProviderContextProps>;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { MutableRefObject, ReactElement } from "react";
|
|
2
|
-
import { DragStartAction } from "../layout-reducer";
|
|
3
|
-
import { LayoutProviderDispatch } from "./LayoutProviderContext";
|
|
4
|
-
export declare const useLayoutDragDrop: (rootLayoutRef: MutableRefObject<ReactElement>, dispatch: LayoutProviderDispatch, pathToDropTarget?: string) => (action: DragStartAction) => void;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { dimension, rect, rectTuple } from "@vuu-ui/vuu-utils";
|
|
2
|
-
import React, { CSSProperties, ReactElement, ReactNode } from "react";
|
|
3
|
-
import { DropPos } from "../drag-drop/dragDropTypes";
|
|
4
|
-
export type flexDirection = "row" | "column";
|
|
5
|
-
type contraDimension = dimension;
|
|
6
|
-
type flexDimensionTuple = [dimension, contraDimension, flexDirection];
|
|
7
|
-
export type position = {
|
|
8
|
-
height?: number;
|
|
9
|
-
width?: number;
|
|
10
|
-
};
|
|
11
|
-
export declare const getFlexDimensions: (flexDirection?: flexDirection) => flexDimensionTuple;
|
|
12
|
-
export declare const getIntrinsicSize: (component: ReactElement) => {
|
|
13
|
-
height?: number | undefined;
|
|
14
|
-
width?: number | undefined;
|
|
15
|
-
} | undefined;
|
|
16
|
-
export declare function getFlexStyle(component: ReactElement, dimension: dimension, pos?: DropPos): any;
|
|
17
|
-
export declare function hasUnboundedFlexStyle(component: ReactElement): boolean;
|
|
18
|
-
export declare function getFlexOrIntrinsicStyle(component: ReactElement, dimension: dimension, pos: position): any;
|
|
19
|
-
export declare function wrapIntrinsicSizeComponentWithFlexbox(component: ReactElement, flexDirection: flexDirection, path: string, clientRect?: rect, dropRect?: rectTuple): React.FunctionComponentElement<any>;
|
|
20
|
-
export declare function createFlexbox(flexDirection: flexDirection, props: any, children: ReactNode, path: string): React.FunctionComponentElement<any>;
|
|
21
|
-
export declare function createPlaceHolder(path: string, size: number, style?: CSSProperties, props?: any): React.DetailedReactHTMLElement<any, HTMLElement>;
|
|
22
|
-
export {};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { ReactElement } from "react";
|
|
2
|
-
import { DropPos } from "../drag-drop";
|
|
3
|
-
import { LayoutModel } from "./layoutTypes";
|
|
4
|
-
type insertionPosition = "before" | "after";
|
|
5
|
-
export declare function getInsertTabBeforeAfter(stack: LayoutModel, pos: DropPos): any[];
|
|
6
|
-
export declare function insertIntoContainer(container: ReactElement, targetContainer: ReactElement, newComponent: ReactElement): ReactElement;
|
|
7
|
-
export declare function insertBesideChild(container: ReactElement, existingComponent: any, newComponent: any, insertionPosition: insertionPosition, pos?: DropPos, clientRect?: any, dropRect?: any): ReactElement;
|
|
8
|
-
export {};
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
import { CSSProperties, ReactElement } from "react";
|
|
2
|
-
import { DragDropRect, DragInstructions } from "../drag-drop";
|
|
3
|
-
import { DropTarget } from "../drag-drop/DropTarget";
|
|
4
|
-
import { ContributionLocation } from "../layout-view";
|
|
5
|
-
export interface WithProps {
|
|
6
|
-
props?: {
|
|
7
|
-
[key: string]: any;
|
|
8
|
-
};
|
|
9
|
-
}
|
|
10
|
-
export interface WithType {
|
|
11
|
-
props?: any;
|
|
12
|
-
title?: string;
|
|
13
|
-
type: string;
|
|
14
|
-
}
|
|
15
|
-
export interface LayoutRoot extends WithProps {
|
|
16
|
-
active?: number;
|
|
17
|
-
children?: ReactElement[];
|
|
18
|
-
type: string;
|
|
19
|
-
}
|
|
20
|
-
export interface LayoutJSON extends WithType {
|
|
21
|
-
active?: number;
|
|
22
|
-
children?: LayoutJSON[];
|
|
23
|
-
id?: string;
|
|
24
|
-
props?: {
|
|
25
|
-
[key: string]: any;
|
|
26
|
-
};
|
|
27
|
-
state?: any;
|
|
28
|
-
type: string;
|
|
29
|
-
style?: CSSProperties;
|
|
30
|
-
}
|
|
31
|
-
export interface WithActive {
|
|
32
|
-
active?: number;
|
|
33
|
-
}
|
|
34
|
-
export type LayoutModel = LayoutRoot | ReactElement | WithType;
|
|
35
|
-
export type layoutType = "Flexbox" | "View" | "DraggableLayout" | "Stack";
|
|
36
|
-
export declare const LayoutActionType: {
|
|
37
|
-
readonly ADD: "add";
|
|
38
|
-
readonly DRAG_START: "drag-start";
|
|
39
|
-
readonly DRAG_DROP: "drag-drop";
|
|
40
|
-
readonly LAYOUT_RESIZE: "layout-resize";
|
|
41
|
-
readonly MAXIMIZE: "maximize";
|
|
42
|
-
readonly MINIMIZE: "minimize";
|
|
43
|
-
readonly MOVE_CHILD: "move-child";
|
|
44
|
-
readonly REMOVE: "remove";
|
|
45
|
-
readonly REPLACE: "replace";
|
|
46
|
-
readonly RESTORE: "restore";
|
|
47
|
-
readonly SAVE: "save";
|
|
48
|
-
readonly SET_PROP: "set-prop";
|
|
49
|
-
readonly SET_PROPS: "set-props";
|
|
50
|
-
readonly SET_TITLE: "set-title";
|
|
51
|
-
readonly SPLITTER_RESIZE: "splitter-resize";
|
|
52
|
-
readonly SWITCH_TAB: "switch-tab";
|
|
53
|
-
readonly TEAROUT: "tearout";
|
|
54
|
-
};
|
|
55
|
-
export type AddAction = {
|
|
56
|
-
component: any;
|
|
57
|
-
path: string;
|
|
58
|
-
type: typeof LayoutActionType.ADD;
|
|
59
|
-
};
|
|
60
|
-
export type DragDropAction = {
|
|
61
|
-
draggedReactElement: ReactElement;
|
|
62
|
-
dragInstructions: any;
|
|
63
|
-
dropTarget: Partial<DropTarget>;
|
|
64
|
-
type: typeof LayoutActionType.DRAG_DROP;
|
|
65
|
-
};
|
|
66
|
-
export type MaximizeAction = {
|
|
67
|
-
path?: string;
|
|
68
|
-
type: typeof LayoutActionType.MAXIMIZE;
|
|
69
|
-
};
|
|
70
|
-
export type MinimizeAction = {
|
|
71
|
-
path?: string;
|
|
72
|
-
type: typeof LayoutActionType.MINIMIZE;
|
|
73
|
-
};
|
|
74
|
-
export type MoveChildAction = {
|
|
75
|
-
fromIndex: number;
|
|
76
|
-
toIndex: number;
|
|
77
|
-
path: string;
|
|
78
|
-
type: typeof LayoutActionType.MOVE_CHILD;
|
|
79
|
-
};
|
|
80
|
-
export type RemoveAction = {
|
|
81
|
-
path?: string;
|
|
82
|
-
type: typeof LayoutActionType.REMOVE;
|
|
83
|
-
};
|
|
84
|
-
export type ReplaceAction = {
|
|
85
|
-
replacement: any;
|
|
86
|
-
target: any;
|
|
87
|
-
type: typeof LayoutActionType.REPLACE;
|
|
88
|
-
};
|
|
89
|
-
export type RestoreAction = {
|
|
90
|
-
path?: string;
|
|
91
|
-
type: typeof LayoutActionType.RESTORE;
|
|
92
|
-
};
|
|
93
|
-
export type SetPropAction = {
|
|
94
|
-
path: string;
|
|
95
|
-
propName: string;
|
|
96
|
-
propValue: string | number | boolean;
|
|
97
|
-
type: typeof LayoutActionType.SET_PROP;
|
|
98
|
-
};
|
|
99
|
-
export type SetPropsAction = {
|
|
100
|
-
path: string;
|
|
101
|
-
props: {
|
|
102
|
-
[key: string]: unknown;
|
|
103
|
-
};
|
|
104
|
-
type: typeof LayoutActionType.SET_PROPS;
|
|
105
|
-
};
|
|
106
|
-
export type SetTitleAction = {
|
|
107
|
-
path: string;
|
|
108
|
-
title: string;
|
|
109
|
-
type: typeof LayoutActionType.SET_TITLE;
|
|
110
|
-
};
|
|
111
|
-
export type SplitterResizeAction = {
|
|
112
|
-
path: string;
|
|
113
|
-
sizes: {
|
|
114
|
-
currentSize: number;
|
|
115
|
-
flexBasis: number;
|
|
116
|
-
}[];
|
|
117
|
-
type: typeof LayoutActionType.SPLITTER_RESIZE;
|
|
118
|
-
};
|
|
119
|
-
export type LayoutResizeAction = {
|
|
120
|
-
path: string;
|
|
121
|
-
size: number;
|
|
122
|
-
type: typeof LayoutActionType.LAYOUT_RESIZE;
|
|
123
|
-
};
|
|
124
|
-
export type SwitchTabAction = {
|
|
125
|
-
id?: string;
|
|
126
|
-
nextIdx: number;
|
|
127
|
-
path: string;
|
|
128
|
-
type: typeof LayoutActionType.SWITCH_TAB;
|
|
129
|
-
};
|
|
130
|
-
export type TearoutAction = {
|
|
131
|
-
path?: string;
|
|
132
|
-
type: typeof LayoutActionType.TEAROUT;
|
|
133
|
-
};
|
|
134
|
-
export type LayoutReducerAction = AddAction | DragDropAction | LayoutResizeAction | MaximizeAction | MinimizeAction | MoveChildAction | RemoveAction | ReplaceAction | RestoreAction | SetPropAction | SetPropsAction | SetTitleAction | SplitterResizeAction | SwitchTabAction;
|
|
135
|
-
export type SaveAction = {
|
|
136
|
-
type: typeof LayoutActionType.SAVE;
|
|
137
|
-
};
|
|
138
|
-
export type AddToolbarContributionViewAction = {
|
|
139
|
-
content: ReactElement;
|
|
140
|
-
location: ContributionLocation;
|
|
141
|
-
type: "add-toolbar-contribution";
|
|
142
|
-
};
|
|
143
|
-
export type RemoveToolbarContributionViewAction = {
|
|
144
|
-
location: ContributionLocation;
|
|
145
|
-
type: "remove-toolbar-contribution";
|
|
146
|
-
};
|
|
147
|
-
export type MousedownViewAction = {
|
|
148
|
-
preDragActivity?: any;
|
|
149
|
-
index?: number;
|
|
150
|
-
type: "mousedown";
|
|
151
|
-
};
|
|
152
|
-
export type DragStartAction = {
|
|
153
|
-
payload?: ReactElement;
|
|
154
|
-
dragContainerPath?: string;
|
|
155
|
-
dragElement?: HTMLElement;
|
|
156
|
-
dragRect: DragDropRect;
|
|
157
|
-
dropTargets?: string[];
|
|
158
|
-
evt: MouseEvent;
|
|
159
|
-
instructions?: DragInstructions;
|
|
160
|
-
path: string;
|
|
161
|
-
type: typeof LayoutActionType.DRAG_START;
|
|
162
|
-
};
|
|
163
|
-
export type LayoutLevelChange = "switch-active-tab" | "edit-feature-title" | "save-feature-props" | "resize-component" | "remove-component" | "drag-drop-operation";
|
|
164
|
-
export type ApplicationLevelChange = "switch-active-layout" | "open-layout" | "close-layout" | "rename-layout";
|
|
165
|
-
export type LayoutChangeReason = LayoutLevelChange | ApplicationLevelChange;
|
|
166
|
-
export type LayoutChangeHandler = (layout: LayoutJSON, layoutChangeReason: LayoutChangeReason) => void;
|
|
167
|
-
export declare const isApplicationLevelChange: (layoutChangeReason: LayoutChangeReason) => layoutChangeReason is ApplicationLevelChange;
|
|
168
|
-
export declare const isLayoutLevelChange: (layoutChangeReason: LayoutChangeReason) => layoutChangeReason is LayoutLevelChange;
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import { dimension } from "@vuu-ui/vuu-utils";
|
|
2
|
-
import React, { CSSProperties, ReactElement } from "react";
|
|
3
|
-
import { ComponentWithId } from "../registry/ComponentRegistry";
|
|
4
|
-
import { LayoutJSON, LayoutModel, layoutType } from "./layoutTypes";
|
|
5
|
-
export declare const getManagedDimension: (style: CSSProperties) => [dimension, dimension];
|
|
6
|
-
export declare const applyLayoutProps: (component: ReactElement, path?: string) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
7
|
-
export interface LayoutProps extends ComponentWithId {
|
|
8
|
-
active?: number;
|
|
9
|
-
"data-path"?: string;
|
|
10
|
-
children?: ReactElement[];
|
|
11
|
-
column?: any;
|
|
12
|
-
dropTarget?: any;
|
|
13
|
-
key: string;
|
|
14
|
-
layout?: any;
|
|
15
|
-
path?: string;
|
|
16
|
-
resizeable?: boolean;
|
|
17
|
-
style: CSSProperties;
|
|
18
|
-
type?: string;
|
|
19
|
-
version?: number;
|
|
20
|
-
}
|
|
21
|
-
/**
|
|
22
|
-
* parse the declarative JSX and clone adding layout attributes
|
|
23
|
-
*/
|
|
24
|
-
export declare const processLayoutElement: (layoutElement: ReactElement, previousLayout?: ReactElement) => ReactElement;
|
|
25
|
-
export declare const applyLayout: (type: layoutType, props: LayoutProps, previousLayout?: LayoutModel) => LayoutModel;
|
|
26
|
-
export declare function layoutFromJson({ id, type, children, props, state }: LayoutJSON, path: string): ReactElement;
|
|
27
|
-
export declare function layoutToJSON(component: ReactElement): LayoutJSON;
|
|
28
|
-
export declare function componentToJson(component: ReactElement): LayoutJSON;
|
|
29
|
-
export declare function serializeProps(props?: LayoutProps): {
|
|
30
|
-
[key: string]: any;
|
|
31
|
-
} | undefined;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import React, { ReactElement } from 'react';
|
|
2
|
-
import { ReplaceAction } from './layoutTypes';
|
|
3
|
-
import { LayoutProps } from './layoutUtils';
|
|
4
|
-
export declare function replaceChild(model: ReactElement, { target, replacement }: ReplaceAction): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
5
|
-
export declare function _replaceChild(model: ReactElement, child: ReactElement, replacement: ReactElement<LayoutProps>): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
6
|
-
export declare function swapChild(model: ReactElement, child: ReactElement, replacement: ReactElement, op?: 'maximize' | 'minimize' | 'restore'): ReactElement;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import React, { ReactElement } from "react";
|
|
2
|
-
import { LayoutResizeAction, SplitterResizeAction } from "./layoutTypes";
|
|
3
|
-
export declare function resizeFlexChild(layoutRoot: ReactElement, { path, size }: LayoutResizeAction): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
4
|
-
export declare function resizeFlexChildren(layoutRoot: ReactElement, { path, sizes }: SplitterResizeAction): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ReactElement } from "react";
|
|
2
|
-
import { DropPos } from "../drag-drop/dragDropTypes";
|
|
3
|
-
import { DropTarget } from "../drag-drop/DropTarget";
|
|
4
|
-
export interface LayoutSpec {
|
|
5
|
-
type: "Stack" | "Flexbox";
|
|
6
|
-
flexDirection: "column" | "row";
|
|
7
|
-
showTabs?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export declare function wrap(container: ReactElement, existingComponent: any, newComponent: any, pos: DropPos, clientRect?: DropTarget["clientRect"], dropRect?: DropTarget["dropRect"]): ReactElement;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { ForwardedRef, ReactElement } from "react";
|
|
2
|
-
import { ViewProps } from "./viewTypes";
|
|
3
|
-
import "./View.css";
|
|
4
|
-
interface ViewComponentType {
|
|
5
|
-
(props: ViewProps & {
|
|
6
|
-
ref?: ForwardedRef<HTMLDivElement>;
|
|
7
|
-
}): ReactElement<ViewProps>;
|
|
8
|
-
displayName?: string;
|
|
9
|
-
}
|
|
10
|
-
declare const MemoView: ViewComponentType;
|
|
11
|
-
export { MemoView as View };
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import React, { SyntheticEvent } from "react";
|
|
2
|
-
import { ViewAction } from "./viewTypes";
|
|
3
|
-
export type ViewDispatch = <Action extends ViewAction = ViewAction>(action: Action, evt?: SyntheticEvent) => Promise<boolean | void>;
|
|
4
|
-
/**
|
|
5
|
-
* This API is available to any Feature hosted within Vuu (as all Features are wrapped
|
|
6
|
-
* with View component). It offers metadata about the View as well as access to the
|
|
7
|
-
* Vuu persistencew API;
|
|
8
|
-
*/
|
|
9
|
-
export interface ViewContextAPI {
|
|
10
|
-
/**
|
|
11
|
-
* disdpatcher for View actions. These are a subset of LayoutActions, specifically for
|
|
12
|
-
* View manipulation
|
|
13
|
-
*/
|
|
14
|
-
dispatch?: ViewDispatch | null;
|
|
15
|
-
id?: string;
|
|
16
|
-
load?: (key?: string) => unknown;
|
|
17
|
-
loadSession?: (key?: string) => unknown;
|
|
18
|
-
onConfigChange?: (config: unknown) => void;
|
|
19
|
-
path?: string;
|
|
20
|
-
purge?: (key: string) => void;
|
|
21
|
-
save?: (state: unknown, key: string) => void;
|
|
22
|
-
saveSession?: (state: unknown, key: string) => void;
|
|
23
|
-
setComponentProps: (props: {
|
|
24
|
-
[key: string]: unknown;
|
|
25
|
-
}) => void;
|
|
26
|
-
title?: string;
|
|
27
|
-
}
|
|
28
|
-
export declare const ViewContext: React.Context<ViewContextAPI>;
|
|
29
|
-
export declare const useViewDispatch: () => ViewDispatch | null;
|
|
30
|
-
export declare const useViewContext: () => ViewContextAPI;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { RefObject } from "react";
|
|
2
|
-
export interface ViewHookProps {
|
|
3
|
-
id: string;
|
|
4
|
-
rootRef: RefObject<HTMLDivElement>;
|
|
5
|
-
path?: string;
|
|
6
|
-
dropTargets?: string[];
|
|
7
|
-
title?: string;
|
|
8
|
-
}
|
|
9
|
-
export declare const useView: ({ id, rootRef, path, dropTargets, title: titleProp, }: ViewHookProps) => {
|
|
10
|
-
contributions: import("./useViewActionDispatcher").Contribution[] | undefined;
|
|
11
|
-
dispatchViewAction: import("./ViewContext").ViewDispatch;
|
|
12
|
-
load: (key?: string) => any;
|
|
13
|
-
loadSession: (key?: string) => any;
|
|
14
|
-
onConfigChange: ({ type: key, ...config }: any) => void;
|
|
15
|
-
onEditTitle: (title: string) => void;
|
|
16
|
-
purge: (key: any) => void;
|
|
17
|
-
restoredState: any;
|
|
18
|
-
save: (state: any, key: any) => void;
|
|
19
|
-
saveSession: (state: any, key: any) => void;
|
|
20
|
-
title: any;
|
|
21
|
-
};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ReactElement, RefObject } from "react";
|
|
2
|
-
import { ViewDispatch } from "./ViewContext";
|
|
3
|
-
export type ContributionLocation = "post-title" | "pre-title";
|
|
4
|
-
export type Contribution = {
|
|
5
|
-
index?: number;
|
|
6
|
-
location?: ContributionLocation;
|
|
7
|
-
content: ReactElement;
|
|
8
|
-
};
|
|
9
|
-
export declare const useViewActionDispatcher: (id: string, root: RefObject<HTMLDivElement>, viewPath?: string, dropTargets?: string[]) => [ViewDispatch, Contribution[] | undefined];
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { RefObject } from "react";
|
|
2
|
-
export interface ViewResizeHookProps {
|
|
3
|
-
mainRef: RefObject<HTMLDivElement>;
|
|
4
|
-
resize?: "defer" | "responsive";
|
|
5
|
-
rootRef: RefObject<HTMLDivElement>;
|
|
6
|
-
}
|
|
7
|
-
export declare const useViewResize: ({ mainRef, resize, rootRef, }: ViewResizeHookProps) => void;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { FunctionComponent, HTMLAttributes } from "react";
|
|
2
|
-
import { HeaderProps } from "../layout-header";
|
|
3
|
-
import { AddToolbarContributionViewAction, MaximizeAction, MinimizeAction, MousedownViewAction, RemoveAction, RemoveToolbarContributionViewAction, RestoreAction, TearoutAction } from "../layout-reducer";
|
|
4
|
-
export type ViewAction = MaximizeAction | MinimizeAction | MousedownViewAction | RemoveAction | RestoreAction | TearoutAction | AddToolbarContributionViewAction | RemoveToolbarContributionViewAction;
|
|
5
|
-
export type ResizeStrategy = "defer" | "responsive";
|
|
6
|
-
export interface ViewProps extends HTMLAttributes<HTMLDivElement> {
|
|
7
|
-
Header?: FunctionComponent<HeaderProps>;
|
|
8
|
-
closeable?: boolean;
|
|
9
|
-
collapsed?: boolean;
|
|
10
|
-
"data-path"?: string;
|
|
11
|
-
"data-resizeable"?: boolean;
|
|
12
|
-
dropTargets?: string[];
|
|
13
|
-
expanded?: boolean;
|
|
14
|
-
flexFill?: boolean;
|
|
15
|
-
header?: boolean | Partial<HeaderProps>;
|
|
16
|
-
orientation?: "vertical" | "horizontal";
|
|
17
|
-
path?: string;
|
|
18
|
-
resize?: ResizeStrategy;
|
|
19
|
-
resizeable?: boolean;
|
|
20
|
-
tearOut?: boolean;
|
|
21
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { HTMLAttributes } from "react";
|
|
2
|
-
import { MeasuredSize } from "./useMeasuredContainer";
|
|
3
|
-
import "./MeasuredContainer.css";
|
|
4
|
-
export interface MeasuredContainerProps extends HTMLAttributes<HTMLDivElement> {
|
|
5
|
-
height?: number | string;
|
|
6
|
-
onResize?: (size: MeasuredSize) => void;
|
|
7
|
-
width?: number | string;
|
|
8
|
-
}
|
|
9
|
-
export declare const MeasuredContainer: import("react").ForwardRefExoticComponent<MeasuredContainerProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { CSSProperties, RefObject } from "react";
|
|
2
|
-
import { MeasuredContainerProps } from "./MeasuredContainer";
|
|
3
|
-
export interface ClientSize {
|
|
4
|
-
clientHeight: number;
|
|
5
|
-
clientWidth: number;
|
|
6
|
-
}
|
|
7
|
-
export interface MeasuredProps extends Pick<MeasuredContainerProps, "height" | "onResize" | "width"> {
|
|
8
|
-
defaultHeight?: number;
|
|
9
|
-
defaultWidth?: number;
|
|
10
|
-
}
|
|
11
|
-
export type CssSize = Pick<CSSProperties, "height" | "width">;
|
|
12
|
-
export interface MeasuredSize {
|
|
13
|
-
height: number;
|
|
14
|
-
width: number;
|
|
15
|
-
}
|
|
16
|
-
export interface MeasuredContainerHookResult {
|
|
17
|
-
containerRef: RefObject<HTMLDivElement>;
|
|
18
|
-
cssSize: CssSize;
|
|
19
|
-
outerSize: CssSize;
|
|
20
|
-
innerSize?: MeasuredSize;
|
|
21
|
-
}
|
|
22
|
-
export declare const useMeasuredContainer: ({ defaultHeight, defaultWidth, height, onResize: onResizeProp, width, }: MeasuredProps) => MeasuredContainerHookResult;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { RefObject } from "react";
|
|
2
|
-
export declare const WidthHeight: string[];
|
|
3
|
-
export declare const WidthOnly: string[];
|
|
4
|
-
export type measurements<T = string | number> = {
|
|
5
|
-
height?: T;
|
|
6
|
-
clientHeight?: number;
|
|
7
|
-
clientWidth?: number;
|
|
8
|
-
contentHeight?: number;
|
|
9
|
-
contentWidth?: number;
|
|
10
|
-
scrollHeight?: number;
|
|
11
|
-
scrollWidth?: number;
|
|
12
|
-
width?: T;
|
|
13
|
-
};
|
|
14
|
-
export type ResizeHandler = (measurements: measurements<number>) => void;
|
|
15
|
-
export declare function useResizeObserver(ref: RefObject<Element | HTMLElement | null>, dimensions: readonly string[], onResize: ResizeHandler, reportInitialSize?: boolean): void;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { PopupMenuProps } from "@vuu-ui/vuu-popups";
|
|
2
|
-
import { orientationType } from "@vuu-ui/vuu-utils";
|
|
3
|
-
import React, { HTMLAttributes } from "react";
|
|
4
|
-
import { OverflowItem } from "./overflow-utils";
|
|
5
|
-
import "./OverflowContainer.css";
|
|
6
|
-
export interface OverflowContainerProps extends HTMLAttributes<HTMLDivElement> {
|
|
7
|
-
PopupMenuProps?: Partial<PopupMenuProps>;
|
|
8
|
-
allowDragDrop?: boolean;
|
|
9
|
-
debugId?: string;
|
|
10
|
-
height: number;
|
|
11
|
-
onMoveItem?: (fromIndex: number, toIndex: number) => void;
|
|
12
|
-
onSwitchWrappedItemIntoView?: (overflowItem: OverflowItem) => void;
|
|
13
|
-
orientation?: orientationType;
|
|
14
|
-
overflowIcon?: string;
|
|
15
|
-
overflowPosition?: "start" | "end" | number;
|
|
16
|
-
}
|
|
17
|
-
export declare const OverflowContainer: React.ForwardRefExoticComponent<OverflowContainerProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { orientationType } from "@vuu-ui/vuu-utils";
|
|
2
|
-
export type OverflowItem = {
|
|
3
|
-
index: string;
|
|
4
|
-
label: string;
|
|
5
|
-
overflowPriority: string;
|
|
6
|
-
};
|
|
7
|
-
export declare const isOverflowElement: (element: HTMLElement | null) => boolean;
|
|
8
|
-
export declare const sortByScreenOrder: (elements: HTMLElement[]) => HTMLElement[];
|
|
9
|
-
export declare const NO_WRAPPED_ITEMS: OverflowItem[];
|
|
10
|
-
/**
|
|
11
|
-
Identify wrapped items by comparing position of each item. Any item
|
|
12
|
-
not to the right of preceeding item has wrapped. Note: on-screen
|
|
13
|
-
position of items does not necessarily match document position, due
|
|
14
|
-
to use of css order. This is taken into account by sorting.
|
|
15
|
-
TODO support Vertical orientation
|
|
16
|
-
*/
|
|
17
|
-
export declare const getNonWrappedAndWrappedItems: (container: HTMLElement, orientation?: orientationType) => [OverflowItem[], OverflowItem[]];
|
|
18
|
-
export declare const applyOverflowClassToWrappedItems: (container: HTMLElement, overflowedItems: OverflowItem[], classBase?: string) => void;
|
|
19
|
-
export declare const overflowIndicatorHasWrappedButShouldNotHave: (wrappedItems: OverflowItem[]) => boolean;
|
|
20
|
-
export declare const highPriorityItemsHaveWrappedButShouldNotHave: (nonWrappedItems: OverflowItem[], wrappedItems: OverflowItem[]) => boolean;
|
|
21
|
-
/**
|
|
22
|
-
An edge case that may occur when reducing width from unwrapped to
|
|
23
|
-
wrapped, or on first render.
|
|
24
|
-
We overflow one or more items. Then, when the overflowIndicator assumes
|
|
25
|
-
full width, it may itself overflow.
|
|
26
|
-
*/
|
|
27
|
-
export declare const correctForWrappedOverflowIndicator: (container: HTMLElement, overflowedItems: OverflowItem[]) => Promise<OverflowItem[]>;
|
|
28
|
-
/**
|
|
29
|
-
An edge case that may occur when reducing width from unwrapped to
|
|
30
|
-
wrapped, or on first render.
|
|
31
|
-
We overflow one or more items. Then, when the overflowIndicator assumes
|
|
32
|
-
full width, it may itself overflow.
|
|
33
|
-
*/
|
|
34
|
-
export declare const correctForWrappedHighPriorityItems: (container: HTMLElement, nonWrapped: OverflowItem[], wrapped: OverflowItem[]) => Promise<[OverflowItem[], OverflowItem[]]>;
|
|
35
|
-
export declare const markElementAsWrapped: (container: HTMLElement, item: OverflowItem) => void;
|
|
36
|
-
export declare const getElementsMarkedAsWrapped: (container: HTMLElement) => HTMLElement[];
|
|
37
|
-
export declare const unmarkItemsWhichAreNoLongerWrapped: (container: HTMLElement, wrappedItems: OverflowItem[]) => void;
|
|
38
|
-
/**
|
|
39
|
-
An edge case. If container has grown but we still have one
|
|
40
|
-
wrapped item - could the wrapped item return to the fold if the overflow
|
|
41
|
-
indicaor were removed ?
|
|
42
|
-
*/
|
|
43
|
-
export declare const removeOverflowIndicatorIfNoLongerNeeded: (container: HTMLElement) => boolean;
|
|
44
|
-
/**
|
|
45
|
-
* This is used both when an overflow menu is used to select an overflowed item
|
|
46
|
-
* and when a high priority item has overflowed, whilst lower priority items
|
|
47
|
-
* remain in view.
|
|
48
|
-
*/
|
|
49
|
-
export declare const switchWrappedItemIntoView: (container: HTMLElement, overflowItem: OverflowItem) => [OverflowItem[], OverflowItem[]];
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { MenuActionHandler, MenuBuilder } from "@vuu-ui/vuu-data-types";
|
|
3
|
-
import { OverflowItem } from "./overflow-utils";
|
|
4
|
-
import { OverflowContainerProps } from "./OverflowContainer";
|
|
5
|
-
export interface OverflowContainerHookProps extends Pick<OverflowContainerProps, "allowDragDrop" | "onMoveItem" | "orientation"> {
|
|
6
|
-
itemCount: number;
|
|
7
|
-
onSwitchWrappedItemIntoView?: (overflowItem: OverflowItem) => void;
|
|
8
|
-
}
|
|
9
|
-
export declare const useOverflowContainer: ({ allowDragDrop, itemCount, onMoveItem, onSwitchWrappedItemIntoView, orientation, }: OverflowContainerHookProps) => {
|
|
10
|
-
draggable?: JSX.Element | undefined;
|
|
11
|
-
dropIndicator?: JSX.Element | undefined;
|
|
12
|
-
draggedItemIndex?: number | undefined;
|
|
13
|
-
isDragging: boolean;
|
|
14
|
-
isScrolling: import("react").RefObject<boolean>;
|
|
15
|
-
revealOverflowedItems: boolean;
|
|
16
|
-
menuActionHandler: MenuActionHandler;
|
|
17
|
-
menuBuilder: MenuBuilder<string, unknown>;
|
|
18
|
-
onItemMouseDown: import("react").MouseEventHandler<Element> | undefined;
|
|
19
|
-
rootRef: (el: HTMLDivElement | null) => void;
|
|
20
|
-
};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { ListItemProps, ListProps } from "@vuu-ui/vuu-ui-controls";
|
|
2
|
-
import { HTMLAttributes, ReactElement } from "react";
|
|
3
|
-
import { ViewProps } from "../layout-view";
|
|
4
|
-
import "./Palette.css";
|
|
5
|
-
export interface PaletteItemProps extends ListItemProps {
|
|
6
|
-
children: ReactElement;
|
|
7
|
-
closeable?: boolean;
|
|
8
|
-
header?: boolean;
|
|
9
|
-
idx?: number;
|
|
10
|
-
resize?: "defer";
|
|
11
|
-
resizeable?: boolean;
|
|
12
|
-
}
|
|
13
|
-
export declare const PaletteItem: import("react").MemoExoticComponent<({ className, children: component, idx, resizeable, header, closeable, ...props }: PaletteItemProps) => JSX.Element>;
|
|
14
|
-
export interface PaletteProps extends Omit<HTMLAttributes<HTMLDivElement>, "onDragStart" | "onDrop" | "onSelect"> {
|
|
15
|
-
ListProps?: Partial<ListProps>;
|
|
16
|
-
ViewProps?: Partial<ViewProps>;
|
|
17
|
-
children: ReactElement[];
|
|
18
|
-
itemHeight?: number;
|
|
19
|
-
orientation: "horizontal" | "vertical";
|
|
20
|
-
selection?: string;
|
|
21
|
-
}
|
|
22
|
-
export declare const Palette: ({ ListProps, ViewProps, children, className, itemHeight, orientation, ...props }: PaletteProps) => JSX.Element;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./Palette";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { HTMLAttributes } from "react";
|
|
2
|
-
import "./Placeholder.css";
|
|
3
|
-
export interface PlaceholderProps extends HTMLAttributes<HTMLDivElement> {
|
|
4
|
-
closeable?: boolean;
|
|
5
|
-
flexFill?: boolean;
|
|
6
|
-
resizeable?: boolean;
|
|
7
|
-
shim?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export declare const Placeholder: {
|
|
10
|
-
({ className, closeable, flexFill, resizeable, shim, ...props }: PlaceholderProps): JSX.Element;
|
|
11
|
-
displayName: string;
|
|
12
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './Placeholder';
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { FunctionComponent } from "react";
|
|
2
|
-
export type layoutComponentType = "component" | "container" | "view";
|
|
3
|
-
export interface ComponentWithId {
|
|
4
|
-
id: string;
|
|
5
|
-
[key: string]: unknown;
|
|
6
|
-
}
|
|
7
|
-
export declare const ComponentRegistry: {
|
|
8
|
-
[key: string]: FunctionComponent<ComponentWithId>;
|
|
9
|
-
};
|
|
10
|
-
export declare function isContainer(componentType: string): boolean;
|
|
11
|
-
export declare function isView(componentType: string): boolean;
|
|
12
|
-
export declare const isLayoutComponent: (type: string) => boolean;
|
|
13
|
-
export declare function registerComponent(componentName: string, component: FunctionComponent<any>, type?: layoutComponentType): void;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './ComponentRegistry';
|