fix:校准画布编辑与图片导出文字水平垂直位置偏移问题,修改屏幕尺寸为960x1361像素

This commit is contained in:
Zhukj
2026-04-20 10:16:25 +08:00
parent 2afee798f8
commit c93dd4c304
3 changed files with 74 additions and 50 deletions

View File

@@ -261,7 +261,7 @@ html, body {
position: relative;
width: 100%;
max-width: 360px;
aspect-ratio: 3 / 5;
aspect-ratio: 960 / 1361;
box-shadow: 0 4px 20px rgba(0,0,0,0.15);
background: #fff;
overflow: hidden;
@@ -372,36 +372,34 @@ html, body {
position: absolute;
min-width: 80px;
min-height: 32px;
padding: 4px 8px;
padding: 0;
font-size: 16px;
color: #000;
font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
background: transparent;
border: 2px solid transparent;
outline: 2px solid transparent;
border-radius: 4px;
outline: none;
cursor: grab;
white-space: nowrap;
line-height: 1.4;
-webkit-user-select: none;
user-select: none;
transition: border-color 0.2s;
transition: outline-color 0.2s;
z-index: 10;
/* 确保输入框内容超出时不影响父容器和其他元素 */
overflow: visible;
max-width: none;
box-sizing: border-box;
}
/* 选中状态(单击/长按) - 仅显示虚线边框 */
/* 选中状态(单击/长按) - 仅显示虚线轮廓 */
.text-input.selected {
border: 2px dashed rgba(74, 144, 226, 0.6);
outline: 2px dashed rgba(74, 144, 226, 0.6);
cursor: grab;
}
/* 编辑状态(双击) - 显示实线边框 */
/* 编辑状态(双击) - 显示实线轮廓 */
.text-input.editing {
border: 2px solid #4a90e2;
outline: 2px solid #4a90e2;
background: rgba(255,255,255,0.1);
cursor: text;
-webkit-user-select: text;