Type
Description
useEffect(() => {
const superdoc = new SuperDoc({
selector: "#document",
toolbar: "#toolbar",
documentMode: "editing",
pagination: true,
rulers: true,
});
const handleWheel = (event) => {
if (event.ctrlKey) {
event.preventDefault();
if (event.deltaY > 0) {
console.log("down");
console.log(superdoc.activeEditor.options);
superdoc.activeEditor.setOptions({
scale: 2,
});
} else {
console.log("up");
}
}
};
window.addEventListener("wheel", handleWheel, { passive: false });
return () => {
window.removeEventListener("wheel", handleWheel);
};
}, []);
Current Behavior
I tried using setOptions to control the scale but it doesn't work, and i can't find any relative method in official document...
Expected Behavior
Control the doc's scale by code
Steps to Reproduce
None
SuperDoc Version
0.17.0
Browser & Version
Chrome
OS
Windows 11
Additional Context
No response
Checklist
Type
Description
useEffect(() => {
const superdoc = new SuperDoc({
selector: "#document",
toolbar: "#toolbar",
documentMode: "editing",
pagination: true,
rulers: true,
});
}, []);
Current Behavior
I tried using
setOptionsto control the scale but it doesn't work, and i can't find any relative method in official document...Expected Behavior
Control the doc's scale by code
Steps to Reproduce
None
SuperDoc Version
0.17.0
Browser & Version
Chrome
OS
Windows 11
Additional Context
No response
Checklist