Commit 5f737f8 1 parent 3dce322 commit 5f737f8 Copy full SHA for 5f737f8
File tree 1 file changed +4
-2
lines changed
front-end/h5/src/components/core/support
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -25,8 +25,8 @@ export default {
25
25
*/
26
26
getPointStyle ( point , isWrapElement = true ) {
27
27
const pos = this . position
28
- const top = pos . top - 4 // !#zh 减4是为了让元素能够处于 border 的中间
29
- const left = pos . left - 4
28
+ const top = pos . top // !#zh 减4是为了让元素能够处于 border 的中间
29
+ const left = pos . left
30
30
const height = pos . height
31
31
const width = pos . width
32
32
let hasT = / t / . test ( point )
@@ -51,6 +51,8 @@ export default {
51
51
}
52
52
}
53
53
const style = {
54
+ marginLeft : ( hasL || hasR ) ? '-3px' : 0 ,
55
+ marginTop : ( hasT || hasB ) ? '-3px' : 0 ,
54
56
left : `${ newLeft + ( isWrapElement ? 0 : left ) } px` ,
55
57
top : `${ newTop + ( isWrapElement ? 0 : top ) } px` ,
56
58
cursor : point . split ( '' ) . reverse ( ) . map ( m => directionKey [ m ] ) . join ( '' ) + '-resize'
You can’t perform that action at this time.
0 commit comments