stickyflow 0.9.0 → 0.9.2
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.
- package/CHANGELOG.md +16 -0
- package/dist/binding/index.cjs +9 -9
- package/dist/binding/index.js +3 -3
- package/dist/{chunk-B3YRZVMR.cjs → chunk-2GKXPZRL.cjs} +23 -23
- package/dist/{chunk-B3YRZVMR.cjs.map → chunk-2GKXPZRL.cjs.map} +1 -1
- package/dist/{chunk-SQBF2BKT.cjs → chunk-3EOG34QN.cjs} +48 -44
- package/dist/chunk-3EOG34QN.cjs.map +1 -0
- package/dist/{chunk-CM35H45Z.js → chunk-AAP24GBG.js} +3 -3
- package/dist/{chunk-CM35H45Z.js.map → chunk-AAP24GBG.js.map} +1 -1
- package/dist/{chunk-QL7MNEMT.cjs → chunk-C25NWWIH.cjs} +48 -3
- package/dist/chunk-C25NWWIH.cjs.map +1 -0
- package/dist/{chunk-ZCGZJBAT.js → chunk-C3LVKPWQ.js} +19 -15
- package/dist/chunk-C3LVKPWQ.js.map +1 -0
- package/dist/{chunk-YSXD5IVZ.cjs → chunk-EURX7QT3.cjs} +672 -657
- package/dist/chunk-EURX7QT3.cjs.map +1 -0
- package/dist/{chunk-FS6L462E.js → chunk-G2N3KJYJ.js} +22 -7
- package/dist/chunk-G2N3KJYJ.js.map +1 -0
- package/dist/{chunk-OUWGWDJ2.cjs → chunk-MR32IJQO.cjs} +15 -15
- package/dist/{chunk-OUWGWDJ2.cjs.map → chunk-MR32IJQO.cjs.map} +1 -1
- package/dist/{chunk-D2266VBZ.js → chunk-Q6FBISNP.js} +48 -3
- package/dist/chunk-Q6FBISNP.js.map +1 -0
- package/dist/{chunk-BUVUJMWT.js → chunk-XNNNIOJU.js} +4 -4
- package/dist/{chunk-BUVUJMWT.js.map → chunk-XNNNIOJU.js.map} +1 -1
- package/dist/index.cjs +36 -36
- package/dist/index.js +5 -5
- package/dist/interaction/index.cjs +230 -230
- package/dist/interaction/index.js +2 -2
- package/dist/stickyflow-diagram.global.js +37 -37
- package/dist/stickyflow-diagram.global.js.map +1 -1
- package/dist/viewer/index.cjs +9 -9
- package/dist/viewer/index.js +4 -4
- package/dist/web-component/index.cjs +6 -6
- package/dist/web-component/index.js +4 -4
- package/package.json +1 -1
- package/dist/chunk-D2266VBZ.js.map +0 -1
- package/dist/chunk-FS6L462E.js.map +0 -1
- package/dist/chunk-QL7MNEMT.cjs.map +0 -1
- package/dist/chunk-SQBF2BKT.cjs.map +0 -1
- package/dist/chunk-YSXD5IVZ.cjs.map +0 -1
- package/dist/chunk-ZCGZJBAT.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { render } from './chunk-
|
|
2
|
-
import { parseContractVersion, isContractCompatible, Emitter, resolveOwner, CHANGE_COLOR, findOwnerNode, isPrimary, linkSelectionOverlay, pathSelectionOverlay, isometricSelectionOverlay, shapeSelectionOverlay, DERIVED_HEIGHT_ROLES, quickDuplicateBubbles, isCameraGesture, linkChangeOverlay, shapeChangeOverlay, startChangeFade, REDUCED_MOTION_DURATION_MS, FLASH_DURATION_MS } from './chunk-
|
|
3
|
-
import { getComponentDescriptor, formatRollingNumber, DEFAULT_ROLLING_NUMBER_STYLE } from './chunk-
|
|
1
|
+
import { render } from './chunk-G2N3KJYJ.js';
|
|
2
|
+
import { parseContractVersion, isContractCompatible, Emitter, resolveOwner, CHANGE_COLOR, findOwnerNode, isPrimary, linkSelectionOverlay, pathSelectionOverlay, isometricSelectionOverlay, shapeSelectionOverlay, DERIVED_HEIGHT_ROLES, quickDuplicateBubbles, isCameraGesture, linkChangeOverlay, shapeChangeOverlay, startChangeFade, REDUCED_MOTION_DURATION_MS, FLASH_DURATION_MS } from './chunk-AAP24GBG.js';
|
|
3
|
+
import { getComponentDescriptor, formatRollingNumber, DEFAULT_ROLLING_NUMBER_STYLE } from './chunk-Q6FBISNP.js';
|
|
4
4
|
|
|
5
5
|
// src/runtime/viewer/components/rollingNumberDom.ts
|
|
6
6
|
var HTML_NAMESPACE = "http://www.w3.org/1999/xhtml";
|
|
@@ -505,12 +505,16 @@ function patchSceneElement(current, next) {
|
|
|
505
505
|
function ownerIdOf(element) {
|
|
506
506
|
return element.getAttribute("data-sf-id") ?? element.id;
|
|
507
507
|
}
|
|
508
|
+
function keyedElements(svg) {
|
|
509
|
+
const seen = /* @__PURE__ */ new Map();
|
|
510
|
+
return Array.from(svg.querySelectorAll(":scope > [id]"), (element) => {
|
|
511
|
+
const count = seen.get(element.id) ?? 0;
|
|
512
|
+
seen.set(element.id, count + 1);
|
|
513
|
+
return [`${element.id}#${count}`, element];
|
|
514
|
+
});
|
|
515
|
+
}
|
|
508
516
|
function currentElementsById(svg) {
|
|
509
|
-
|
|
510
|
-
for (const element of svg.querySelectorAll(":scope > [id]")) {
|
|
511
|
-
elements.set(element.id, element);
|
|
512
|
-
}
|
|
513
|
-
return elements;
|
|
517
|
+
return new Map(keyedElements(svg));
|
|
514
518
|
}
|
|
515
519
|
function reusableElement(current, next, markTouched) {
|
|
516
520
|
if (current && current.tagName === next.tagName) {
|
|
@@ -543,15 +547,15 @@ function patchSceneNodes(svg, next) {
|
|
|
543
547
|
touchedOwnerIds.add(ownerId);
|
|
544
548
|
};
|
|
545
549
|
let previousSibling = definitions;
|
|
546
|
-
for (const nextElement of next
|
|
547
|
-
retainedIds.add(
|
|
550
|
+
for (const [key, nextElement] of keyedElements(next)) {
|
|
551
|
+
retainedIds.add(key);
|
|
548
552
|
newOwnerIds.add(ownerIdOf(nextElement));
|
|
549
|
-
const liveElement = reusableElement(currentById.get(
|
|
553
|
+
const liveElement = reusableElement(currentById.get(key), nextElement, markTouched);
|
|
550
554
|
placeAfter(svg, liveElement, previousSibling);
|
|
551
555
|
previousSibling = liveElement;
|
|
552
556
|
}
|
|
553
|
-
for (const [
|
|
554
|
-
if (!retainedIds.has(
|
|
557
|
+
for (const [key, element] of currentById) {
|
|
558
|
+
if (!retainedIds.has(key)) {
|
|
555
559
|
touchedOwnerIds.add(ownerIdOf(element));
|
|
556
560
|
element.remove();
|
|
557
561
|
}
|
|
@@ -4713,5 +4717,5 @@ function createViewer(options) {
|
|
|
4713
4717
|
}
|
|
4714
4718
|
|
|
4715
4719
|
export { SHADER_DEFAULTS, connectInteraction, createViewer, registerShaderProgram, shaderProgram };
|
|
4716
|
-
//# sourceMappingURL=chunk-
|
|
4717
|
-
//# sourceMappingURL=chunk-
|
|
4720
|
+
//# sourceMappingURL=chunk-C3LVKPWQ.js.map
|
|
4721
|
+
//# sourceMappingURL=chunk-C3LVKPWQ.js.map
|