|
@@ -201,14 +201,24 @@ export default function useDrag(
|
|
|
baseSize.winHeight = baseSize.maxHeight - 100;
|
|
|
}
|
|
|
|
|
|
- const translateY = (baseSize.windowHeight - baseSize.defaultHeight) / 2;
|
|
|
- baseSize.transformX =
|
|
|
- baseSize.windowWidth - baseSize.defaultWidth - initPos.right;
|
|
|
- baseSize.transformY = translateY;
|
|
|
dragStyles.maxHeight = getSizeToUnit(baseSize.maxHeight);
|
|
|
|
|
|
- baseSize.width = baseSize.defaultWidth;
|
|
|
- baseSize.height = baseSize.defaultHeight;
|
|
|
+ if (windowInfo.windowType === 'LARGE') {
|
|
|
+ baseSize.transformX = (baseSize.windowWidth - baseSize.winWidth) / 2;
|
|
|
+ baseSize.transformY =
|
|
|
+ (baseSize.windowHeight - baseSize.winHeight) / 2 -
|
|
|
+ baseSize.layoutTopHeight / 2;
|
|
|
+ baseSize.width = baseSize.winWidth;
|
|
|
+ baseSize.height = baseSize.winHeight;
|
|
|
+ } else {
|
|
|
+ const translateY =
|
|
|
+ (baseSize.windowHeight - baseSize.defaultHeight) / 2;
|
|
|
+ baseSize.transformX =
|
|
|
+ baseSize.windowWidth - baseSize.defaultWidth - initPos.right;
|
|
|
+ baseSize.transformY = translateY;
|
|
|
+ baseSize.width = baseSize.defaultWidth;
|
|
|
+ baseSize.height = baseSize.defaultHeight;
|
|
|
+ }
|
|
|
|
|
|
// 初始化定位
|
|
|
if (initSize?.defaultPosition === 'center') {
|