canvu-react 0.3.25 → 0.3.26
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/dist/chatbot.d.cts +1 -1
- package/dist/chatbot.d.ts +1 -1
- package/dist/react.cjs +15 -7
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +2 -2
- package/dist/react.d.ts +2 -2
- package/dist/react.js +15 -7
- package/dist/react.js.map +1 -1
- package/dist/realtime.cjs +21 -3
- package/dist/realtime.cjs.map +1 -1
- package/dist/realtime.d.cts +2 -2
- package/dist/realtime.d.ts +2 -2
- package/dist/realtime.js +21 -3
- package/dist/realtime.js.map +1 -1
- package/dist/{types-7kfWcm0L.d.cts → types-BLXR7g_L.d.cts} +7 -0
- package/dist/{types-C4k_AMvi.d.ts → types-Cm7IsgL4.d.ts} +7 -0
- package/package.json +1 -1
package/dist/chatbot.d.cts
CHANGED
package/dist/chatbot.d.ts
CHANGED
package/dist/react.cjs
CHANGED
|
@@ -6515,7 +6515,12 @@ function PresenceRemoteLayer({
|
|
|
6515
6515
|
const markup = peer.markupStroke;
|
|
6516
6516
|
let strokeNode = null;
|
|
6517
6517
|
if (markup && markup.points.length > 0) {
|
|
6518
|
-
const
|
|
6518
|
+
const fallbackPaint = strokePaint(markup.tool, color);
|
|
6519
|
+
const paint = {
|
|
6520
|
+
stroke: markup.stroke ?? fallbackPaint.stroke,
|
|
6521
|
+
strokeOpacity: markup.strokeOpacity ?? fallbackPaint.strokeOpacity,
|
|
6522
|
+
widthWorld: markup.strokeWidth ?? fallbackPaint.widthWorld
|
|
6523
|
+
};
|
|
6519
6524
|
const d = markup.points.length >= 2 ? smoothFreehandPointsToPathD([...markup.points]) : null;
|
|
6520
6525
|
if (d) {
|
|
6521
6526
|
strokeNode = /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7424,14 +7429,15 @@ var VectorViewport = react.forwardRef(
|
|
|
7424
7429
|
const directRemoteStrokePreviewRef = react.useRef(false);
|
|
7425
7430
|
const remoteStrokePreviewFrameRef = react.useRef(null);
|
|
7426
7431
|
const pendingRemoteStrokePreviewRef = react.useRef(null);
|
|
7427
|
-
const
|
|
7432
|
+
const flushRemoteStrokePreviewWithStyle = react.useCallback(() => {
|
|
7428
7433
|
remoteStrokePreviewFrameRef.current = null;
|
|
7429
7434
|
const pending = pendingRemoteStrokePreviewRef.current;
|
|
7430
7435
|
if (!pending) return;
|
|
7431
7436
|
onPlacementPreviewChangeRef.current?.({
|
|
7432
7437
|
kind: "stroke",
|
|
7433
7438
|
tool: pending.tool,
|
|
7434
|
-
points: pending.points
|
|
7439
|
+
points: pending.points,
|
|
7440
|
+
style: { ...strokeStyleRef.current }
|
|
7435
7441
|
});
|
|
7436
7442
|
}, []);
|
|
7437
7443
|
const emitRemoteStrokePreview = react.useCallback(
|
|
@@ -7441,10 +7447,10 @@ var VectorViewport = react.forwardRef(
|
|
|
7441
7447
|
pendingRemoteStrokePreviewRef.current = { tool, points };
|
|
7442
7448
|
if (remoteStrokePreviewFrameRef.current != null) return;
|
|
7443
7449
|
remoteStrokePreviewFrameRef.current = requestAnimationFrame(
|
|
7444
|
-
|
|
7450
|
+
flushRemoteStrokePreviewWithStyle
|
|
7445
7451
|
);
|
|
7446
7452
|
},
|
|
7447
|
-
[
|
|
7453
|
+
[flushRemoteStrokePreviewWithStyle]
|
|
7448
7454
|
);
|
|
7449
7455
|
const emitRemoteStrokePreviewClear = react.useCallback(() => {
|
|
7450
7456
|
if (remoteStrokePreviewFrameRef.current != null) {
|
|
@@ -8707,7 +8713,8 @@ var VectorViewport = react.forwardRef(
|
|
|
8707
8713
|
setPlacementPreview({
|
|
8708
8714
|
kind: "stroke",
|
|
8709
8715
|
tool,
|
|
8710
|
-
points: [startPoint]
|
|
8716
|
+
points: [startPoint],
|
|
8717
|
+
style: { ...strokeStyleRef.current }
|
|
8711
8718
|
});
|
|
8712
8719
|
}
|
|
8713
8720
|
captureInteractionPointer(e.currentTarget, e.pointerId);
|
|
@@ -9074,7 +9081,8 @@ var VectorViewport = react.forwardRef(
|
|
|
9074
9081
|
setPlacementPreview({
|
|
9075
9082
|
kind: "stroke",
|
|
9076
9083
|
tool: st.tool,
|
|
9077
|
-
points: interpolated
|
|
9084
|
+
points: interpolated,
|
|
9085
|
+
style: { ...strokeStyleRef.current }
|
|
9078
9086
|
});
|
|
9079
9087
|
}
|
|
9080
9088
|
return;
|