@markdy/mdx 0.8.17 → 0.8.19
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/README.md +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -75,4 +75,4 @@ Fenced block metadata is passed as props to `MarkdyDiagram`. Snake-case aliases
|
|
|
75
75
|
| `scene_boundary_progress=false` | `sceneBoundaryProgress={false}` | Preferred flag for the scene-boundary progress bar |
|
|
76
76
|
| `playback_rate=0.5` | `playbackRate={0.5}` | Normalized timeline speed multiplier; `1` is Markdy's normal pace |
|
|
77
77
|
| `interactive_viewport=true` | `interactiveViewport={true}` | Enable wheel zoom and drag pan on the rendered viewport |
|
|
78
|
-
| `controls=true` | `controls={true}` | Show a compact toolbar with play/pause, restart, speed, and view reset controls
|
|
78
|
+
| `controls=true` | `controls={true}` | Show a compact toolbar with play/pause, restart, speed, and view reset controls; also enables viewport interaction |
|
package/dist/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ type MarkdyDiagramProps = {
|
|
|
19
19
|
title?: string;
|
|
20
20
|
description?: string;
|
|
21
21
|
};
|
|
22
|
-
declare function MarkdyDiagram({ code, width, height, bg, assets, autoplay, loop, copyright, progressBar, sceneBoundaryProgress, playbackRate,
|
|
22
|
+
declare function MarkdyDiagram({ code, width, height, bg, assets, autoplay, loop, copyright, progressBar, sceneBoundaryProgress, playbackRate, controls, interactiveViewport, className, title, description, }: MarkdyDiagramProps): react.JSX.Element;
|
|
23
23
|
|
|
24
24
|
type MarkdyFenceDefaults = Partial<{
|
|
25
25
|
width: number;
|
package/dist/index.js
CHANGED
|
@@ -40,8 +40,8 @@ function MarkdyDiagram({
|
|
|
40
40
|
progressBar = false,
|
|
41
41
|
sceneBoundaryProgress,
|
|
42
42
|
playbackRate = 1,
|
|
43
|
-
interactiveViewport = false,
|
|
44
43
|
controls = false,
|
|
44
|
+
interactiveViewport = controls,
|
|
45
45
|
className,
|
|
46
46
|
title = "Markdy animation",
|
|
47
47
|
description
|
|
@@ -54,8 +54,8 @@ function MarkdyDiagram({
|
|
|
54
54
|
const resolvedProgressBar = coerceBoolean(progressBar, false);
|
|
55
55
|
const resolvedSceneBoundaryProgress = coerceBoolean(sceneBoundaryProgress, resolvedProgressBar);
|
|
56
56
|
const resolvedPlaybackRate = coerceNumber(playbackRate, 1);
|
|
57
|
-
const resolvedInteractiveViewport = coerceBoolean(interactiveViewport, false);
|
|
58
57
|
const resolvedControls = coerceBoolean(controls, false);
|
|
58
|
+
const resolvedInteractiveViewport = resolvedControls || coerceBoolean(interactiveViewport, false);
|
|
59
59
|
const rootRef = useRef(null);
|
|
60
60
|
const diagramRef = useRef(null);
|
|
61
61
|
const hydratedRef = useRef(false);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@markdy/mdx",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.19",
|
|
4
4
|
"description": "MDX plugin and lightweight React component for diagram-native animated Markdy diagrams.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"unist-util-visit": "^5.0.0",
|
|
45
|
-
"@markdy/renderer-dom": "0.8.
|
|
45
|
+
"@markdy/renderer-dom": "0.8.19"
|
|
46
46
|
},
|
|
47
47
|
"peerDependencies": {
|
|
48
48
|
"react": ">=18.0.0",
|