Commit 78483bf
authored
fix(cdk/drag-drop): pointer position calculation for SVG with viewBox (#19863)
* fix(cdk/drag-drop): pointer position calculation for SVG with viewBox
Fixes a bug in the Angular Material `drag-drop` component where the pointer position is incorrectly
calculated for SVG with viewBox. This is because mouse coordinates retrieved using the screen
coordinate system, but coordinates must be in SVG space, which is defined by the viewBox attribute.
* save ownerSVGElement in a property1 parent 39d48c7 commit 78483bf
2 files changed
Lines changed: 50 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
94 | 105 | | |
95 | 106 | | |
96 | 107 | | |
| |||
5330 | 5341 | | |
5331 | 5342 | | |
5332 | 5343 | | |
| 5344 | + | |
| 5345 | + | |
| 5346 | + | |
| 5347 | + | |
| 5348 | + | |
| 5349 | + | |
| 5350 | + | |
| 5351 | + | |
| 5352 | + | |
| 5353 | + | |
| 5354 | + | |
| 5355 | + | |
| 5356 | + | |
5333 | 5357 | | |
5334 | 5358 | | |
5335 | 5359 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
166 | 171 | | |
167 | 172 | | |
168 | 173 | | |
| |||
380 | 385 | | |
381 | 386 | | |
382 | 387 | | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
383 | 392 | | |
384 | 393 | | |
385 | 394 | | |
| |||
427 | 436 | | |
428 | 437 | | |
429 | 438 | | |
430 | | - | |
| 439 | + | |
431 | 440 | | |
432 | 441 | | |
433 | 442 | | |
| |||
1049 | 1058 | | |
1050 | 1059 | | |
1051 | 1060 | | |
1052 | | - | |
1053 | | - | |
1054 | | - | |
1055 | | - | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
| 1069 | + | |
| 1070 | + | |
| 1071 | + | |
| 1072 | + | |
| 1073 | + | |
| 1074 | + | |
| 1075 | + | |
| 1076 | + | |
1056 | 1077 | | |
1057 | 1078 | | |
1058 | 1079 | | |
| |||
0 commit comments