@rpg-engine/long-bow 0.1.72 → 0.1.73
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/dist/long-bow.cjs.development.js +10 -6
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +10 -6
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/DraggableContainer.tsx +10 -2
package/package.json
CHANGED
|
@@ -55,7 +55,7 @@ export const DraggableContainer: React.FC<IDraggableContainerProps> = ({
|
|
|
55
55
|
}, []);
|
|
56
56
|
|
|
57
57
|
return (
|
|
58
|
-
<
|
|
58
|
+
<DraggableRef ref={draggableRef}>
|
|
59
59
|
<Draggable
|
|
60
60
|
cancel={`.container-close,${cancelDrag}`}
|
|
61
61
|
onDrag={(_e, data: DraggableData) => {
|
|
@@ -93,7 +93,7 @@ export const DraggableContainer: React.FC<IDraggableContainerProps> = ({
|
|
|
93
93
|
{children}
|
|
94
94
|
</Container>
|
|
95
95
|
</Draggable>
|
|
96
|
-
</
|
|
96
|
+
</DraggableRef>
|
|
97
97
|
);
|
|
98
98
|
};
|
|
99
99
|
|
|
@@ -102,6 +102,14 @@ interface IContainerProps {
|
|
|
102
102
|
height: string;
|
|
103
103
|
}
|
|
104
104
|
|
|
105
|
+
const DraggableRef = styled.div`
|
|
106
|
+
width: 100%;
|
|
107
|
+
height: 100%;
|
|
108
|
+
display: flex;
|
|
109
|
+
justify-content: center;
|
|
110
|
+
align-items: center;
|
|
111
|
+
`;
|
|
112
|
+
|
|
105
113
|
const Container = styled.div<IContainerProps>`
|
|
106
114
|
height: ${props => props.height};
|
|
107
115
|
width: ${({ width }) => width};
|