@vuu-ui/vuu-layout 3.1.0-beta.1 → 3.1.0-beta.3

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.
Files changed (90) hide show
  1. package/package.json +10 -10
  2. package/src/{debug.mjs → debug.js} +1 -1
  3. package/src/dock-layout/{DockLayout.mjs → DockLayout.js} +1 -1
  4. package/src/dock-layout/index.js +2 -0
  5. package/src/drag-drop/{BoxModel.mjs → BoxModel.js} +1 -1
  6. package/src/drag-drop/{DragState.mjs → DragState.js} +1 -1
  7. package/src/drag-drop/{Draggable.mjs → Draggable.js} +5 -5
  8. package/src/drag-drop/{DropTarget.mjs → DropTarget.js} +2 -2
  9. package/src/drag-drop/{DropTargetRenderer.mjs → DropTargetRenderer.js} +1 -1
  10. package/src/drag-drop/index.js +3 -0
  11. package/src/flexbox/{Flexbox.mjs → Flexbox.js} +1 -1
  12. package/src/flexbox/{FlexboxLayout.mjs → FlexboxLayout.js} +3 -3
  13. package/src/flexbox/{flexbox-utils.mjs → flexbox-utils.js} +2 -2
  14. package/src/flexbox/index.js +2 -0
  15. package/src/flexbox/{useSplitterResizing.mjs → useSplitterResizing.js} +3 -3
  16. package/src/index.js +20 -0
  17. package/src/layout-header/{Header.mjs → Header.js} +1 -1
  18. package/src/layout-header/index.js +1 -0
  19. package/src/layout-header/{useHeader.mjs → useHeader.js} +1 -1
  20. package/src/layout-provider/{LayoutProvider.mjs → LayoutProvider.js} +4 -4
  21. package/src/layout-provider/index.js +2 -0
  22. package/src/layout-provider/{useLayoutDragDrop.mjs → useLayoutDragDrop.js} +3 -3
  23. package/src/layout-reducer/{flexUtils.mjs → flexUtils.js} +1 -1
  24. package/src/layout-reducer/index.js +4 -0
  25. package/src/layout-reducer/{insert-layout-element.mjs → insert-layout-element.js} +3 -3
  26. package/src/layout-reducer/{layout-reducer.mjs → layout-reducer.js} +9 -9
  27. package/src/layout-reducer/{layoutUtils.mjs → layoutUtils.js} +2 -2
  28. package/src/layout-reducer/{move-layout-element.mjs → move-layout-element.js} +2 -2
  29. package/src/layout-reducer/{remove-layout-element.mjs → remove-layout-element.js} +4 -4
  30. package/src/layout-reducer/{replace-layout-element.mjs → replace-layout-element.js} +2 -2
  31. package/src/layout-reducer/{resize-flex-children.mjs → resize-flex-children.js} +2 -2
  32. package/src/layout-reducer/{wrap-layout-element.mjs → wrap-layout-element.js} +3 -3
  33. package/src/layout-view/{View.mjs → View.js} +5 -5
  34. package/src/layout-view/{useView.mjs → useView.js} +3 -3
  35. package/src/layout-view/{useViewResize.mjs → useViewResize.js} +1 -1
  36. package/src/layout-view-actions/{useViewActionDispatcher.mjs → useViewActionDispatcher.js} +4 -4
  37. package/src/palette/{Palette.mjs → Palette.js} +2 -2
  38. package/src/palette/index.js +1 -0
  39. package/src/placeholder/{LayoutStartPanel.mjs → LayoutStartPanel.js} +1 -1
  40. package/src/placeholder/{Placeholder.mjs → Placeholder.js} +2 -2
  41. package/src/placeholder/index.js +1 -0
  42. package/src/responsive/index.js +2 -0
  43. package/src/stack/{Stack.mjs → Stack.js} +1 -1
  44. package/src/stack/{StackLayout.mjs → StackLayout.js} +6 -6
  45. package/src/stack/index.js +3 -0
  46. package/src/tabs/index.js +1 -0
  47. package/src/tools/config-wrapper/{ConfigWrapper.mjs → ConfigWrapper.js} +2 -2
  48. package/src/tools/config-wrapper/index.js +1 -0
  49. package/src/tools/index.js +3 -0
  50. package/src/utils/index.js +5 -0
  51. package/src/utils/{pathUtils.mjs → pathUtils.js} +2 -2
  52. package/src/dock-layout/index.mjs +0 -2
  53. package/src/drag-drop/index.mjs +0 -3
  54. package/src/flexbox/index.mjs +0 -2
  55. package/src/index.mjs +0 -20
  56. package/src/layout-header/index.mjs +0 -1
  57. package/src/layout-provider/index.mjs +0 -2
  58. package/src/layout-reducer/index.mjs +0 -4
  59. package/src/palette/index.mjs +0 -1
  60. package/src/placeholder/index.mjs +0 -1
  61. package/src/responsive/index.mjs +0 -2
  62. package/src/stack/index.mjs +0 -3
  63. package/src/tabs/index.mjs +0 -1
  64. package/src/tools/config-wrapper/index.mjs +0 -1
  65. package/src/tools/index.mjs +0 -3
  66. package/src/utils/index.mjs +0 -5
  67. /package/src/{Component.mjs → Component.js} +0 -0
  68. /package/src/{LayoutContainer.mjs → LayoutContainer.js} +0 -0
  69. /package/src/dock-layout/{Drawer.mjs → Drawer.js} +0 -0
  70. /package/src/drag-drop/{dragDropTypes.mjs → dragDropTypes.js} +0 -0
  71. /package/src/flexbox/{Splitter.mjs → Splitter.js} +0 -0
  72. /package/src/flexbox/{flexboxTypes.mjs → flexboxTypes.js} +0 -0
  73. /package/src/{layout-action.mjs → layout-action.js} +0 -0
  74. /package/src/layout-header/{ActionButton.mjs → ActionButton.js} +0 -0
  75. /package/src/layout-provider/{LayoutProviderContext.mjs → LayoutProviderContext.js} +0 -0
  76. /package/src/layout-reducer/{layoutTypes.mjs → layoutTypes.js} +0 -0
  77. /package/src/layout-view/{useViewBroadcastChannel.mjs → useViewBroadcastChannel.js} +0 -0
  78. /package/src/layout-view/{viewTypes.mjs → viewTypes.js} +0 -0
  79. /package/src/layout-view-actions/{ViewContext.mjs → ViewContext.js} +0 -0
  80. /package/src/layout-view-actions/{useViewContributions.mjs → useViewContributions.js} +0 -0
  81. /package/src/responsive/{measureMinimumNodeSize.mjs → measureMinimumNodeSize.js} +0 -0
  82. /package/src/responsive/{useResizeObserver.mjs → useResizeObserver.js} +0 -0
  83. /package/src/responsive/{utils.mjs → utils.js} +0 -0
  84. /package/src/stack/{stackTypes.mjs → stackTypes.js} +0 -0
  85. /package/src/tabs/{TabPanel.mjs → TabPanel.js} +0 -0
  86. /package/src/{use-persistent-state.mjs → use-persistent-state.js} +0 -0
  87. /package/src/utils/{propUtils.mjs → propUtils.js} +0 -0
  88. /package/src/utils/{refUtils.mjs → refUtils.js} +0 -0
  89. /package/src/utils/{styleUtils.mjs → styleUtils.js} +0 -0
  90. /package/src/utils/{typeOf.mjs → typeOf.js} +0 -0
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "3.1.0-beta.1",
2
+ "version": "3.1.0-beta.3",
3
3
  "description": "VUU Layout Components",
4
4
  "main": "src/index.ts",
5
5
  "author": "heswell",
@@ -11,20 +11,20 @@
11
11
  },
12
12
  "types": "types/index.d.ts",
13
13
  "devDependencies": {
14
- "@vuu-ui/vuu-data-types": "3.1.0-beta.1",
15
- "@vuu-ui/vuu-filter-types": "3.1.0-beta.1"
14
+ "@vuu-ui/vuu-data-types": "3.1.0-beta.3",
15
+ "@vuu-ui/vuu-filter-types": "3.1.0-beta.3"
16
16
  },
17
17
  "dependencies": {
18
18
  "@salt-ds/core": "1.54.1",
19
19
  "@salt-ds/styles": "0.2.1",
20
20
  "@salt-ds/window": "0.1.1",
21
- "@vuu-ui/vuu-data-react": "3.1.0-beta.1",
22
- "@vuu-ui/vuu-datatable": "3.1.0-beta.1",
23
- "@vuu-ui/vuu-filters": "3.1.0-beta.1",
24
- "@vuu-ui/vuu-popups": "3.1.0-beta.1",
25
- "@vuu-ui/vuu-table": "3.1.0-beta.1",
26
- "@vuu-ui/vuu-ui-controls": "3.1.0-beta.1",
27
- "@vuu-ui/vuu-utils": "3.1.0-beta.1"
21
+ "@vuu-ui/vuu-data-react": "3.1.0-beta.3",
22
+ "@vuu-ui/vuu-datatable": "3.1.0-beta.3",
23
+ "@vuu-ui/vuu-filters": "3.1.0-beta.3",
24
+ "@vuu-ui/vuu-popups": "3.1.0-beta.3",
25
+ "@vuu-ui/vuu-table": "3.1.0-beta.3",
26
+ "@vuu-ui/vuu-ui-controls": "3.1.0-beta.3",
27
+ "@vuu-ui/vuu-utils": "3.1.0-beta.3"
28
28
  },
29
29
  "peerDependencies": {
30
30
  "clsx": "^2.0.0",
@@ -1,4 +1,4 @@
1
- import { typeOf } from "./utils/index.mjs";
1
+ import { typeOf } from "./utils/index.js";
2
2
  const tree = (el, depth = 0)=>{
3
3
  const type = typeOf(el);
4
4
  const spaces = " ";
@@ -4,7 +4,7 @@ import clsx from "clsx";
4
4
  import { useComponentCssInjection } from "@salt-ds/styles";
5
5
  import { useWindow } from "@salt-ds/window";
6
6
  import { useMemo } from "react";
7
- import Drawer from "./Drawer.mjs";
7
+ import Drawer from "./Drawer.js";
8
8
  import DockLayout from "./DockLayout.css";
9
9
  const isDrawer = (component)=>component.type === Drawer;
10
10
  const isVertical = (element)=>element.props.position && element.props.position.match(/top|bottom/);
@@ -0,0 +1,2 @@
1
+ export { default as DockLayout } from "./DockLayout.js";
2
+ export { default as Drawer } from "./Drawer.js";
@@ -1,5 +1,5 @@
1
1
  import { boxContainsPoint, isContainer } from "@vuu-ui/vuu-utils";
2
- import { getProps, typeOf } from "../utils/index.mjs";
2
+ import { getProps, typeOf } from "../utils/index.js";
3
3
  const positionValues = {
4
4
  north: 1,
5
5
  east: 2,
@@ -1,4 +1,4 @@
1
- import { pointPositionWithinRect } from "./BoxModel.mjs";
1
+ import { pointPositionWithinRect } from "./BoxModel.js";
2
2
  const SCALE_FACTOR = 0.4;
3
3
  class DragState {
4
4
  constraint;
@@ -1,8 +1,8 @@
1
- import { findTarget, followPath, getProps } from "../utils/index.mjs";
2
- import { BoxModel } from "./BoxModel.mjs";
3
- import { DragState } from "./DragState.mjs";
4
- import { DropTarget, identifyDropTarget } from "./DropTarget.mjs";
5
- import DropTargetRenderer from "./DropTargetRenderer.mjs";
1
+ import { findTarget, followPath, getProps } from "../utils/index.js";
2
+ import { BoxModel } from "./BoxModel.js";
3
+ import { DragState } from "./DragState.js";
4
+ import { DropTarget, identifyDropTarget } from "./DropTarget.js";
5
+ import DropTargetRenderer from "./DropTargetRenderer.js";
6
6
  let _dragStartCallback;
7
7
  let _dragMoveCallback;
8
8
  let _dragEndCallback;
@@ -1,5 +1,5 @@
1
- import { getProps, typeOf } from "../utils/index.mjs";
2
- import { BoxModel, Position, RelativeDropPosition, getPosition, positionValues } from "./BoxModel.mjs";
1
+ import { getProps, typeOf } from "../utils/index.js";
2
+ import { BoxModel, Position, RelativeDropPosition, getPosition, positionValues } from "./BoxModel.js";
3
3
  const isTabstrip = (dropTarget)=>dropTarget.pos.tab && "Stack" === typeOf(dropTarget.component) && dropTarget.pos.position.Header;
4
4
  const { north: north, south: south, east: east, west: west } = positionValues;
5
5
  const eastwest = east + west;
@@ -1,4 +1,4 @@
1
- import { RelativeDropPosition } from "./BoxModel.mjs";
1
+ import { RelativeDropPosition } from "./BoxModel.js";
2
2
  let _hoverDropTarget = null;
3
3
  let _shiftedTab = null;
4
4
  const start = ([x, y])=>`M${x},${y}`;
@@ -0,0 +1,3 @@
1
+ export * from "./dragDropTypes.js";
2
+ export * from "./Draggable.js";
3
+ export * from "./DropTarget.js";
@@ -4,7 +4,7 @@ import { useComponentCssInjection } from "@salt-ds/styles";
4
4
  import { useWindow } from "@salt-ds/window";
5
5
  import clsx from "clsx";
6
6
  import { forwardRef } from "react";
7
- import { useSplitterResizing } from "./useSplitterResizing.mjs";
7
+ import { useSplitterResizing } from "./useSplitterResizing.js";
8
8
  import Flexbox_0 from "./Flexbox.css";
9
9
  const classBase = "hwFlexbox";
10
10
  const Flexbox_Flexbox = /*#__PURE__*/ forwardRef(function(props, ref) {
@@ -1,9 +1,9 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useCallback } from "react";
3
- import { Action } from "../layout-action.mjs";
4
- import { useLayoutProviderDispatch } from "../layout-provider/index.mjs";
3
+ import { Action } from "../layout-action.js";
4
+ import { useLayoutProviderDispatch } from "../layout-provider/index.js";
5
5
  import { registerComponent } from "@vuu-ui/vuu-utils";
6
- import Flexbox from "./Flexbox.mjs";
6
+ import Flexbox from "./Flexbox.js";
7
7
  const FlexboxLayout_FlexboxLayout = function(props) {
8
8
  const { path } = props;
9
9
  const dispatch = useLayoutProviderDispatch();
@@ -1,5 +1,5 @@
1
- import { getIntrinsicSize, hasUnboundedFlexStyle } from "../layout-reducer/flexUtils.mjs";
2
- import { getProp } from "../utils/index.mjs";
1
+ import { getIntrinsicSize, hasUnboundedFlexStyle } from "../layout-reducer/flexUtils.js";
2
+ import { getProp } from "../utils/index.js";
3
3
  const NO_INTRINSIC_SIZE = {};
4
4
  const SPLITTER = 1;
5
5
  const PLACEHOLDER = 2;
@@ -0,0 +1,2 @@
1
+ export * from "./FlexboxLayout.js";
2
+ export { default as Flexbox } from "./Flexbox.js";
@@ -1,8 +1,8 @@
1
1
  import { getUniqueId } from "@vuu-ui/vuu-utils";
2
2
  import react, { useCallback, useMemo, useRef } from "react";
3
- import { Placeholder } from "../placeholder/index.mjs";
4
- import { Splitter } from "./Splitter.mjs";
5
- import { PLACEHOLDER, SPLITTER, findSplitterAndPlaceholderPositions, gatherChildMeta, identifyResizeParties } from "./flexbox-utils.mjs";
3
+ import { Placeholder } from "../placeholder/index.js";
4
+ import { Splitter } from "./Splitter.js";
5
+ import { PLACEHOLDER, SPLITTER, findSplitterAndPlaceholderPositions, gatherChildMeta, identifyResizeParties } from "./flexbox-utils.js";
6
6
  const originalContentOnly = (meta)=>!meta.splitter && !meta.placeholder;
7
7
  const useSplitterResizing = ({ children: childrenProp, onSplitterMoved, style })=>{
8
8
  const rootRef = useRef(null);
package/src/index.js ADDED
@@ -0,0 +1,20 @@
1
+ export * from "./dock-layout/index.js";
2
+ export * from "./drag-drop/index.js";
3
+ export * from "./flexbox/index.js";
4
+ export * from "./layout-header/index.js";
5
+ export * from "./layout-provider/index.js";
6
+ export * from "./layout-reducer/index.js";
7
+ export * from "./LayoutContainer.js";
8
+ export * from "./palette/index.js";
9
+ export * from "./placeholder/index.js";
10
+ export * from "./responsive/index.js";
11
+ export * from "./stack/index.js";
12
+ export * from "./use-persistent-state.js";
13
+ export * from "./utils/index.js";
14
+ export * from "./layout-view/viewTypes.js";
15
+ export * from "./layout-view/View.js";
16
+ export * from "./layout-view/useViewBroadcastChannel.js";
17
+ export { default as Component } from "./Component.js";
18
+ export { Action } from "./layout-action.js";
19
+ export { useViewActionDispatcher } from "./layout-view-actions/useViewActionDispatcher.js";
20
+ export { ViewContext, useViewContext, useViewDispatch } from "./layout-view-actions/ViewContext.js";
@@ -4,7 +4,7 @@ import { useWindow } from "@salt-ds/window";
4
4
  import { EditableLabel, IconButton } from "@vuu-ui/vuu-ui-controls";
5
5
  import clsx from "clsx";
6
6
  import { cloneElement } from "react";
7
- import { useHeader } from "./useHeader.mjs";
7
+ import { useHeader } from "./useHeader.js";
8
8
  import Header from "./Header.css";
9
9
  const classBase = "vuuHeader";
10
10
  const Header_Header = ({ allowRename = false, className: classNameProp, contributions, collapsed, closeable, onCollapse, onEditTitle, onExpand, orientation: orientationProp = "horizontal", style, title = "Untitled" })=>{
@@ -0,0 +1 @@
1
+ export * from "./Header.js";
@@ -1,5 +1,5 @@
1
1
  import { useCallback, useRef, useState } from "react";
2
- import { useViewDispatch } from "../layout-view-actions/ViewContext.mjs";
2
+ import { useViewDispatch } from "../layout-view-actions/ViewContext.js";
3
3
  import { queryClosest } from "@vuu-ui/vuu-utils";
4
4
  const useHeader = ({ onCollapse, onEditTitle, onExpand, title })=>{
5
5
  const [editing, setEditing] = useState(false);
@@ -1,10 +1,10 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { VuuShellLocation, usePlaceholderJSON } from "@vuu-ui/vuu-utils";
3
3
  import { useCallback, useContext, useEffect, useMemo, useRef, useState } from "react";
4
- import { LayoutActionType, cloneElementAddLayoutProps, layoutFromJson, layoutQuery, layoutReducer, layoutToJSON } from "../layout-reducer/index.mjs";
5
- import { findTarget, getChildProp, getProp, getProps, typeOf } from "../utils/index.mjs";
6
- import { LayoutProviderContext } from "./LayoutProviderContext.mjs";
7
- import { useLayoutDragDrop } from "./useLayoutDragDrop.mjs";
4
+ import { LayoutActionType, cloneElementAddLayoutProps, layoutFromJson, layoutQuery, layoutReducer, layoutToJSON } from "../layout-reducer/index.js";
5
+ import { findTarget, getChildProp, getProp, getProps, typeOf } from "../utils/index.js";
6
+ import { LayoutProviderContext } from "./LayoutProviderContext.js";
7
+ import { useLayoutDragDrop } from "./useLayoutDragDrop.js";
8
8
  const isWorkspaceContainer = (props)=>props.id === VuuShellLocation.WorkspaceContainer;
9
9
  const isMultiWorkspaceContainer = (props)=>props.id === VuuShellLocation.MultiWorkspaceContainer;
10
10
  const shouldSave = (action)=>[
@@ -0,0 +1,2 @@
1
+ export * from "./LayoutProvider.js";
2
+ export * from "./LayoutProviderContext.js";
@@ -1,7 +1,7 @@
1
1
  import { useCallback, useRef } from "react";
2
- import { Draggable } from "../drag-drop/index.mjs";
3
- import { getIntrinsicSize } from "../layout-reducer/flexUtils.mjs";
4
- import { followPath, resolvePath } from "../utils/index.mjs";
2
+ import { Draggable } from "../drag-drop/index.js";
3
+ import { getIntrinsicSize } from "../layout-reducer/flexUtils.js";
4
+ import { followPath, resolvePath } from "../utils/index.js";
5
5
  const NO_INSTRUCTIONS = {};
6
6
  const NO_OFFSETS = [
7
7
  0,
@@ -1,6 +1,6 @@
1
1
  import { getLayoutComponent, uuid } from "@vuu-ui/vuu-utils";
2
2
  import react from "react";
3
- import { getProps, resetPath } from "../utils/index.mjs";
3
+ import { getProps, resetPath } from "../utils/index.js";
4
4
  const placeHolderProps = {
5
5
  "data-placeholder": true,
6
6
  "data-resizeable": true
@@ -0,0 +1,4 @@
1
+ export * from "./flexUtils.js";
2
+ export * from "./layout-reducer.js";
3
+ export * from "./layoutTypes.js";
4
+ export * from "./layoutUtils.js";
@@ -1,8 +1,8 @@
1
1
  import { uuid } from "@vuu-ui/vuu-utils";
2
2
  import react from "react";
3
- import { getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.mjs";
4
- import { createPlaceHolder, getFlexDimensions, getFlexOrIntrinsicStyle, getIntrinsicSize, wrapIntrinsicSizeComponentWithFlexbox } from "./flexUtils.mjs";
5
- import { getDefaultTabLabel, getManagedDimension } from "./layoutUtils.mjs";
3
+ import { getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.js";
4
+ import { createPlaceHolder, getFlexDimensions, getFlexOrIntrinsicStyle, getIntrinsicSize, wrapIntrinsicSizeComponentWithFlexbox } from "./flexUtils.js";
5
+ import { getDefaultTabLabel, getManagedDimension } from "./layoutUtils.js";
6
6
  function getInsertTabBeforeAfter(stack, pos) {
7
7
  const { children: tabs } = stack.props;
8
8
  const tabCount = tabs.length;
@@ -1,14 +1,14 @@
1
1
  import { isContainer } from "@vuu-ui/vuu-utils";
2
2
  import react from "react";
3
- import { findTarget, followPath, followPathToParent, getProp, getProps, typeOf } from "../utils/index.mjs";
4
- import { getIntrinsicSize } from "./flexUtils.mjs";
5
- import { getInsertTabBeforeAfter, insertBesideChild, insertIntoContainer } from "./insert-layout-element.mjs";
6
- import { moveChild } from "./move-layout-element.mjs";
7
- import { LayoutActionType } from "./layoutTypes.mjs";
8
- import { removeChild } from "./remove-layout-element.mjs";
9
- import { _replaceChild, replaceChild, swapChild } from "./replace-layout-element.mjs";
10
- import { resizeFlexChild, resizeFlexChildren } from "./resize-flex-children.mjs";
11
- import { wrap } from "./wrap-layout-element.mjs";
3
+ import { findTarget, followPath, followPathToParent, getProp, getProps, typeOf } from "../utils/index.js";
4
+ import { getIntrinsicSize } from "./flexUtils.js";
5
+ import { getInsertTabBeforeAfter, insertBesideChild, insertIntoContainer } from "./insert-layout-element.js";
6
+ import { moveChild } from "./move-layout-element.js";
7
+ import { LayoutActionType } from "./layoutTypes.js";
8
+ import { removeChild } from "./remove-layout-element.js";
9
+ import { _replaceChild, replaceChild, swapChild } from "./replace-layout-element.js";
10
+ import { resizeFlexChild, resizeFlexChildren } from "./resize-flex-children.js";
11
+ import { wrap } from "./wrap-layout-element.js";
12
12
  const layoutReducer = (state, action)=>{
13
13
  switch(action.type){
14
14
  case LayoutActionType.ADD:
@@ -1,7 +1,7 @@
1
1
  import { getLayoutComponent, isContainer, isLayoutComponent, uuid } from "@vuu-ui/vuu-utils";
2
2
  import react, { cloneElement } from "react";
3
- import { getPersistentState, hasPersistentState, setPersistentState } from "../use-persistent-state.mjs";
4
- import { expandFlex, followPathToParent, getProps, typeOf } from "../utils/index.mjs";
3
+ import { getPersistentState, hasPersistentState, setPersistentState } from "../use-persistent-state.js";
4
+ import { expandFlex, followPathToParent, getProps, typeOf } from "../utils/index.js";
5
5
  const getManagedDimension = (style)=>"column" === style.flexDirection ? [
6
6
  "height",
7
7
  "width"
@@ -1,6 +1,6 @@
1
1
  import { cloneElement } from "react";
2
- import { followPath, getProps } from "../utils/index.mjs";
3
- import { swapChild } from "./replace-layout-element.mjs";
2
+ import { followPath, getProps } from "../utils/index.js";
3
+ import { swapChild } from "./replace-layout-element.js";
4
4
  function moveChild(layoutRoot, { fromIndex, path, toIndex }) {
5
5
  const target = followPath(layoutRoot, path, true);
6
6
  const { children } = getProps(target);
@@ -1,9 +1,9 @@
1
1
  import { VuuShellLocation } from "@vuu-ui/vuu-utils";
2
2
  import react from "react";
3
- import { followPath, followPathToParent, getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.mjs";
4
- import { createPlaceHolder } from "./flexUtils.mjs";
5
- import { layoutFromJson } from "./layoutUtils.mjs";
6
- import { swapChild } from "./replace-layout-element.mjs";
3
+ import { followPath, followPathToParent, getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.js";
4
+ import { createPlaceHolder } from "./flexUtils.js";
5
+ import { layoutFromJson } from "./layoutUtils.js";
6
+ import { swapChild } from "./replace-layout-element.js";
7
7
  function removeChild(layoutRoot, { path }) {
8
8
  const target = followPath(layoutRoot, path);
9
9
  let targetParent = followPathToParent(layoutRoot, path);
@@ -1,6 +1,6 @@
1
1
  import react from "react";
2
- import { getProp, getProps, nextStep } from "../utils/index.mjs";
3
- import { applyLayoutProps } from "./layoutUtils.mjs";
2
+ import { getProp, getProps, nextStep } from "../utils/index.js";
3
+ import { applyLayoutProps } from "./layoutUtils.js";
4
4
  function replaceChild(model, { target, replacement }) {
5
5
  return _replaceChild(model, target, replacement);
6
6
  }
@@ -1,6 +1,6 @@
1
1
  import react from "react";
2
- import { followPath, getProps } from "../utils/index.mjs";
3
- import { swapChild } from "./replace-layout-element.mjs";
2
+ import { followPath, getProps } from "../utils/index.js";
3
+ import { swapChild } from "./replace-layout-element.js";
4
4
  function resizeFlexChild(layoutRoot, { path, size }) {
5
5
  const target = followPath(layoutRoot, path, true);
6
6
  const { style } = getProps(target);
@@ -1,8 +1,8 @@
1
1
  import { getLayoutComponent, uuid } from "@vuu-ui/vuu-utils";
2
2
  import react from "react";
3
- import { getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.mjs";
4
- import { createFlexbox, createPlaceHolder, getFlexStyle, getIntrinsicSize, wrapIntrinsicSizeComponentWithFlexbox } from "./flexUtils.mjs";
5
- import { applyLayoutProps } from "./layoutUtils.mjs";
3
+ import { getProp, getProps, nextStep, resetPath, typeOf } from "../utils/index.js";
4
+ import { createFlexbox, createPlaceHolder, getFlexStyle, getIntrinsicSize, wrapIntrinsicSizeComponentWithFlexbox } from "./flexUtils.js";
5
+ import { applyLayoutProps } from "./layoutUtils.js";
6
6
  const isHtmlElement = (component)=>{
7
7
  const [firstLetter] = typeOf(component);
8
8
  return firstLetter === firstLetter.toLowerCase();
@@ -5,10 +5,10 @@ import { useComponentCssInjection } from "@salt-ds/styles";
5
5
  import { useWindow } from "@salt-ds/window";
6
6
  import clsx from "clsx";
7
7
  import react, { forwardRef, useCallback, useMemo, useRef, useState } from "react";
8
- import { Header as Header_mjs_Header } from "../layout-header/Header.mjs";
9
- import { useView } from "./useView.mjs";
10
- import { useViewResize } from "./useViewResize.mjs";
11
- import { ViewContext } from "../layout-view-actions/ViewContext.mjs";
8
+ import { Header as Header_js_Header } from "../layout-header/Header.js";
9
+ import { useView } from "./useView.js";
10
+ import { useViewResize } from "./useViewResize.js";
11
+ import { ViewContext } from "../layout-view-actions/ViewContext.js";
12
12
  import View_0 from "./View.css";
13
13
  const classBase = "vuuView";
14
14
  const getProps = (state, props)=>{
@@ -19,7 +19,7 @@ const getProps = (state, props)=>{
19
19
  return state || props;
20
20
  };
21
21
  const View_View = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
22
- const { Header = Header_mjs_Header, allowRename, children, className, collapsed, closeable, "data-path": dataPath, "data-resizeable": dataResizeable, dropTargets, expanded, flexFill, id: idProp, header, onCollapse, onExpand, orientation = "horizontal", path = dataPath, resize = "responsive", resizeable = dataResizeable, restoreStyle, tearOut, style = {}, title: titleProp, ...restProps } = props;
22
+ const { Header = Header_js_Header, allowRename, children, className, collapsed, closeable, "data-path": dataPath, "data-resizeable": dataResizeable, dropTargets, expanded, flexFill, id: idProp, header, onCollapse, onExpand, orientation = "horizontal", path = dataPath, resize = "responsive", resizeable = dataResizeable, restoreStyle, tearOut, style = {}, title: titleProp, ...restProps } = props;
23
23
  const targetWindow = useWindow();
24
24
  useComponentCssInjection({
25
25
  testId: "vuu-view",
@@ -1,7 +1,7 @@
1
1
  import { useCallback, useMemo } from "react";
2
- import { useLayoutProviderDispatch } from "../layout-provider/LayoutProvider.mjs";
3
- import { usePersistentState } from "../use-persistent-state.mjs";
4
- import { useViewActionDispatcher } from "../layout-view-actions/useViewActionDispatcher.mjs";
2
+ import { useLayoutProviderDispatch } from "../layout-provider/LayoutProvider.js";
3
+ import { usePersistentState } from "../use-persistent-state.js";
4
+ import { useViewActionDispatcher } from "../layout-view-actions/useViewActionDispatcher.js";
5
5
  const useView = ({ id, rootRef, path, dropTargets, title: titleProp })=>{
6
6
  const layoutDispatch = useLayoutProviderDispatch();
7
7
  const { loadState, purgeState, saveState } = usePersistentState();
@@ -1,4 +1,4 @@
1
- import { WidthHeight, useResizeObserver } from "../responsive/index.mjs";
1
+ import { WidthHeight, useResizeObserver } from "../responsive/index.js";
2
2
  import { useCallback, useRef } from "react";
3
3
  const NO_MEASUREMENT = [];
4
4
  const useViewResize = ({ mainRef, resize = "responsive", rootRef })=>{
@@ -1,9 +1,9 @@
1
1
  import { useSessionDataSource } from "@vuu-ui/vuu-data-react";
2
2
  import { useCallback } from "react";
3
- import { useLayoutProviderDispatch } from "../layout-provider/LayoutProvider.mjs";
4
- import { useViewBroadcastChannel } from "../layout-view/useViewBroadcastChannel.mjs";
5
- import { usePersistentState } from "../use-persistent-state.mjs";
6
- import { useViewContributions } from "./useViewContributions.mjs";
3
+ import { useLayoutProviderDispatch } from "../layout-provider/LayoutProvider.js";
4
+ import { useViewBroadcastChannel } from "../layout-view/useViewBroadcastChannel.js";
5
+ import { usePersistentState } from "../use-persistent-state.js";
6
+ import { useViewContributions } from "./useViewContributions.js";
7
7
  const useViewActionDispatcher = (id, rootRef, viewPath, dropTargets)=>{
8
8
  const { purgeState } = usePersistentState();
9
9
  const { clearDataSource: clearDataSourceFromSessionState } = useSessionDataSource();
@@ -5,8 +5,8 @@ import { useComponentCssInjection } from "@salt-ds/styles";
5
5
  import { useWindow } from "@salt-ds/window";
6
6
  import clsx from "clsx";
7
7
  import { cloneElement, memo, useCallback } from "react";
8
- import { useLayoutProviderDispatch } from "../layout-provider/index.mjs";
9
- import { View } from "../layout-view/View.mjs";
8
+ import { useLayoutProviderDispatch } from "../layout-provider/index.js";
9
+ import { View } from "../layout-view/View.js";
10
10
  import Palette from "./Palette.css";
11
11
  const classBase = "vuuPalette";
12
12
  const clonePaletteItem = (paletteItem)=>{
@@ -0,0 +1 @@
1
+ export * from "./Palette.js";
@@ -4,7 +4,7 @@ import { VuuShellLocation } from "@vuu-ui/vuu-utils";
4
4
  import { useComponentCssInjection } from "@salt-ds/styles";
5
5
  import { useWindow } from "@salt-ds/window";
6
6
  import { useMemo, useState } from "react";
7
- import { useViewContext } from "../layout-view-actions/ViewContext.mjs";
7
+ import { useViewContext } from "../layout-view-actions/ViewContext.js";
8
8
  import LayoutStartPanel from "./LayoutStartPanel.css";
9
9
  const classBase = "vuuLayoutStartPanel";
10
10
  const LayoutStartPanel_LayoutStartPanel = (htmlAttributes)=>{
@@ -3,8 +3,8 @@ import clsx from "clsx";
3
3
  import { useComponentCssInjection } from "@salt-ds/styles";
4
4
  import { useWindow } from "@salt-ds/window";
5
5
  import { registerComponent } from "@vuu-ui/vuu-utils";
6
- import { LayoutStartPanel } from "./LayoutStartPanel.mjs";
7
- import { View } from "../layout-view/View.mjs";
6
+ import { LayoutStartPanel } from "./LayoutStartPanel.js";
7
+ import { View } from "../layout-view/View.js";
8
8
  import Placeholder from "./Placeholder.css";
9
9
  const classBase = "vuuPlaceholder";
10
10
  const PlaceholderCore = ({ showStartMenu = true })=>/*#__PURE__*/ jsx(Fragment, {
@@ -0,0 +1 @@
1
+ export * from "./Placeholder.js";
@@ -0,0 +1,2 @@
1
+ export * from "./useResizeObserver.js";
2
+ export * from "./utils.js";
@@ -5,7 +5,7 @@ import clsx from "clsx";
5
5
  import { useComponentCssInjection } from "@salt-ds/styles";
6
6
  import { useWindow } from "@salt-ds/window";
7
7
  import react, { forwardRef, useCallback, useRef } from "react";
8
- import { getDefaultTabLabel } from "../layout-reducer/index.mjs";
8
+ import { getDefaultTabLabel } from "../layout-reducer/index.js";
9
9
  import Stack_0 from "./Stack.css";
10
10
  const classBase = "vuuTabs";
11
11
  const getDefaultTabIcon = ()=>void 0;
@@ -1,12 +1,12 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { registerComponent, useId } from "@vuu-ui/vuu-utils";
3
3
  import react, { useCallback, useRef } from "react";
4
- import { useLayoutCreateNewChild, useLayoutProviderDispatch } from "../layout-provider/index.mjs";
5
- import { getDefaultTabLabel } from "../layout-reducer/index.mjs";
6
- import { useViewActionDispatcher } from "../layout-view-actions/useViewActionDispatcher.mjs";
7
- import { useViewBroadcastChannel } from "../layout-view/useViewBroadcastChannel.mjs";
8
- import { usePersistentState } from "../use-persistent-state.mjs";
9
- import { Stack } from "./Stack.mjs";
4
+ import { useLayoutCreateNewChild, useLayoutProviderDispatch } from "../layout-provider/index.js";
5
+ import { getDefaultTabLabel } from "../layout-reducer/index.js";
6
+ import { useViewActionDispatcher } from "../layout-view-actions/useViewActionDispatcher.js";
7
+ import { useViewBroadcastChannel } from "../layout-view/useViewBroadcastChannel.js";
8
+ import { usePersistentState } from "../use-persistent-state.js";
9
+ import { Stack } from "./Stack.js";
10
10
  const StackLayout = (props)=>{
11
11
  const rootRef = useRef(null);
12
12
  const dispatch = useLayoutProviderDispatch();
@@ -0,0 +1,3 @@
1
+ export * from "./Stack.js";
2
+ export * from "./StackLayout.js";
3
+ export * from "./stackTypes.js";
@@ -0,0 +1 @@
1
+ export { default as TabPanel } from "./TabPanel.js";
@@ -1,7 +1,7 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import react, { useState } from "react";
3
- import { LayoutConfigurator, LayoutTreeViewer } from "../index.mjs";
4
- import { followPathToComponent } from "../../index.mjs";
3
+ import { LayoutConfigurator, LayoutTreeViewer } from "../index.js";
4
+ import { followPathToComponent } from "../../index.js";
5
5
  const ConfigWrapper = ({ children })=>{
6
6
  const designMode = false;
7
7
  const [layout, setLayout] = useState(children);
@@ -0,0 +1 @@
1
+ export * from "./ConfigWrapper.js";
@@ -0,0 +1,3 @@
1
+ export * from "./config-wrapper/index.js";
2
+ export * from "./devtools-box/layout-configurator.js";
3
+ export * from "./devtools-tree/layout-tree-viewer.js";
@@ -0,0 +1,5 @@
1
+ export * from "./pathUtils.js";
2
+ export * from "./propUtils.js";
3
+ export * from "./refUtils.js";
4
+ export * from "./styleUtils.js";
5
+ export * from "./typeOf.js";
@@ -1,7 +1,7 @@
1
1
  import { isContainer } from "@vuu-ui/vuu-utils";
2
2
  import react, { isValidElement } from "react";
3
- import { getProp, getProps } from "./propUtils.mjs";
4
- import { typeOf } from "./typeOf.mjs";
3
+ import { getProp, getProps } from "./propUtils.js";
4
+ import { typeOf } from "./typeOf.js";
5
5
  const removeFinalPathSegment = (path)=>{
6
6
  const pos = path.lastIndexOf(".");
7
7
  if (-1 === pos) return path;
@@ -1,2 +0,0 @@
1
- export { default as DockLayout } from "./DockLayout.mjs";
2
- export { default as Drawer } from "./Drawer.mjs";
@@ -1,3 +0,0 @@
1
- export * from "./dragDropTypes.mjs";
2
- export * from "./Draggable.mjs";
3
- export * from "./DropTarget.mjs";
@@ -1,2 +0,0 @@
1
- export * from "./FlexboxLayout.mjs";
2
- export { default as Flexbox } from "./Flexbox.mjs";
package/src/index.mjs DELETED
@@ -1,20 +0,0 @@
1
- export * from "./dock-layout/index.mjs";
2
- export * from "./drag-drop/index.mjs";
3
- export * from "./flexbox/index.mjs";
4
- export * from "./layout-header/index.mjs";
5
- export * from "./layout-provider/index.mjs";
6
- export * from "./layout-reducer/index.mjs";
7
- export * from "./LayoutContainer.mjs";
8
- export * from "./palette/index.mjs";
9
- export * from "./placeholder/index.mjs";
10
- export * from "./responsive/index.mjs";
11
- export * from "./stack/index.mjs";
12
- export * from "./use-persistent-state.mjs";
13
- export * from "./utils/index.mjs";
14
- export * from "./layout-view/viewTypes.mjs";
15
- export * from "./layout-view/View.mjs";
16
- export * from "./layout-view/useViewBroadcastChannel.mjs";
17
- export { default as Component } from "./Component.mjs";
18
- export { Action } from "./layout-action.mjs";
19
- export { useViewActionDispatcher } from "./layout-view-actions/useViewActionDispatcher.mjs";
20
- export { ViewContext, useViewContext, useViewDispatch } from "./layout-view-actions/ViewContext.mjs";
@@ -1 +0,0 @@
1
- export * from "./Header.mjs";
@@ -1,2 +0,0 @@
1
- export * from "./LayoutProvider.mjs";
2
- export * from "./LayoutProviderContext.mjs";
@@ -1,4 +0,0 @@
1
- export * from "./flexUtils.mjs";
2
- export * from "./layout-reducer.mjs";
3
- export * from "./layoutTypes.mjs";
4
- export * from "./layoutUtils.mjs";
@@ -1 +0,0 @@
1
- export * from "./Palette.mjs";
@@ -1 +0,0 @@
1
- export * from "./Placeholder.mjs";
@@ -1,2 +0,0 @@
1
- export * from "./useResizeObserver.mjs";
2
- export * from "./utils.mjs";
@@ -1,3 +0,0 @@
1
- export * from "./Stack.mjs";
2
- export * from "./StackLayout.mjs";
3
- export * from "./stackTypes.mjs";
@@ -1 +0,0 @@
1
- export { default as TabPanel } from "./TabPanel.mjs";
@@ -1 +0,0 @@
1
- export * from "./ConfigWrapper.mjs";
@@ -1,3 +0,0 @@
1
- export * from "./config-wrapper/index.mjs";
2
- export * from "./devtools-box/layout-configurator.mjs";
3
- export * from "./devtools-tree/layout-tree-viewer.mjs";
@@ -1,5 +0,0 @@
1
- export * from "./pathUtils.mjs";
2
- export * from "./propUtils.mjs";
3
- export * from "./refUtils.mjs";
4
- export * from "./styleUtils.mjs";
5
- export * from "./typeOf.mjs";
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes