PromucFlow_constructor/app/client/src/constants/Layers.tsx

55 lines
1.4 KiB
TypeScript
Raw Normal View History

2020-05-28 18:10:26 +00:00
import React from "react";
export enum Indices {
2020-05-28 18:10:26 +00:00
Layer0,
Layer1,
Layer2,
Layer3,
Layer4,
Layer5,
Layer6,
Layer7,
Layer8,
Layer9,
Layer21 = 21,
2020-05-28 18:10:26 +00:00
LayerMax = 99999,
}
export const Layers = {
dropZone: Indices.Layer0,
2020-05-28 18:10:26 +00:00
dragPreview: Indices.Layer1,
// All Widgets Parent layer
positionedWidget: Indices.Layer1,
// Modal needs to higher than other widgets.
modalWidget: Indices.Layer2,
// Dropdown portaled to the canvas
dropdownWidget: Indices.Layer2,
// dropdown portaled to Modal Container with higher index than Overlay
dropdownModalWidget: Indices.Layer21,
selectedWidget: Indices.Layer2,
// Layers when dragging
animatedSnappingDropZone: Indices.Layer2,
animatedDropZone: Indices.Layer3,
// Must be higher than any widget
widgetName: Indices.Layer3,
2020-05-28 18:10:26 +00:00
apiPane: Indices.Layer3,
// Propane needs to match sidebar to show propane on top side bar.
// Sidebar needs to be more than modal so that u can use side bar whilst u have the modal showing up on the canvas.
sideBar: Indices.Layer3,
propertyPane: Indices.Layer3,
2020-05-28 18:10:26 +00:00
help: Indices.Layer4,
contextMenu: Indices.Layer4,
2020-05-28 18:10:26 +00:00
dynamicAutoComplete: Indices.Layer5,
2021-04-23 13:50:55 +00:00
debugger: Indices.Layer6,
productUpdates: Indices.Layer7,
portals: Indices.Layer8,
header: Indices.Layer9,
appComments: Indices.Layer7,
2020-05-28 18:10:26 +00:00
max: Indices.LayerMax,
};
export const LayersContext = React.createContext(Layers);