seat-editor 3.5.45 → 3.5.46
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.
|
@@ -385,7 +385,7 @@ const LayerView = (props) => {
|
|
|
385
385
|
y: y - startBox.y,
|
|
386
386
|
};
|
|
387
387
|
const pointerMoveGhost = (ev) => {
|
|
388
|
-
var _a;
|
|
388
|
+
var _a, _b;
|
|
389
389
|
if (allowedDrag) {
|
|
390
390
|
isDragging.current = true;
|
|
391
391
|
const p = svg.createSVGPoint();
|
|
@@ -426,6 +426,7 @@ const LayerView = (props) => {
|
|
|
426
426
|
const dataPreview = hoverUnderghostId.current;
|
|
427
427
|
const hoveredBefore = svg.querySelector(`g[data-id="${dataPreview}"]`);
|
|
428
428
|
if (hoveredBefore) {
|
|
429
|
+
console.log((_a = hoveredBefore.firstChild) === null || _a === void 0 ? void 0 : _a.children);
|
|
429
430
|
dataBeforeHoveredUnderGhost.forEach((item) => {
|
|
430
431
|
var _a, _b, _c;
|
|
431
432
|
(_c = (_b = (_a = hoveredBefore.firstChild) === null || _a === void 0 ? void 0 : _a.children) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.setAttribute(item.key, item.value);
|
|
@@ -444,7 +445,7 @@ const LayerView = (props) => {
|
|
|
444
445
|
if (dataHoveredGhostId !== dataGhostId) {
|
|
445
446
|
hoverUnderghostId.current = dataHoveredGhostId;
|
|
446
447
|
}
|
|
447
|
-
const posSVG = p.matrixTransform((
|
|
448
|
+
const posSVG = p.matrixTransform((_b = svg.getScreenCTM()) === null || _b === void 0 ? void 0 : _b.inverse());
|
|
448
449
|
// posisi awal ghost di bawah kursor tanpa matrix dulu
|
|
449
450
|
const newX = posSVG.x - offset.x;
|
|
450
451
|
const newY = posSVG.y - offset.y;
|
|
@@ -384,7 +384,7 @@ const LayerView = (props) => {
|
|
|
384
384
|
y: y - startBox.y,
|
|
385
385
|
};
|
|
386
386
|
const pointerMoveGhost = (ev) => {
|
|
387
|
-
var _a;
|
|
387
|
+
var _a, _b;
|
|
388
388
|
if (allowedDrag) {
|
|
389
389
|
isDragging.current = true;
|
|
390
390
|
const p = svg.createSVGPoint();
|
|
@@ -425,6 +425,7 @@ const LayerView = (props) => {
|
|
|
425
425
|
const dataPreview = hoverUnderghostId.current;
|
|
426
426
|
const hoveredBefore = svg.querySelector(`g[data-id="${dataPreview}"]`);
|
|
427
427
|
if (hoveredBefore) {
|
|
428
|
+
console.log((_a = hoveredBefore.firstChild) === null || _a === void 0 ? void 0 : _a.children);
|
|
428
429
|
dataBeforeHoveredUnderGhost.forEach((item) => {
|
|
429
430
|
var _a, _b, _c;
|
|
430
431
|
(_c = (_b = (_a = hoveredBefore.firstChild) === null || _a === void 0 ? void 0 : _a.children) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.setAttribute(item.key, item.value);
|
|
@@ -443,7 +444,7 @@ const LayerView = (props) => {
|
|
|
443
444
|
if (dataHoveredGhostId !== dataGhostId) {
|
|
444
445
|
hoverUnderghostId.current = dataHoveredGhostId;
|
|
445
446
|
}
|
|
446
|
-
const posSVG = p.matrixTransform((
|
|
447
|
+
const posSVG = p.matrixTransform((_b = svg.getScreenCTM()) === null || _b === void 0 ? void 0 : _b.inverse());
|
|
447
448
|
// posisi awal ghost di bawah kursor tanpa matrix dulu
|
|
448
449
|
const newX = posSVG.x - offset.x;
|
|
449
450
|
const newY = posSVG.y - offset.y;
|