Nano zoom fix #12
This commit is contained in:
21
.idea/workspace.xml
generated
21
.idea/workspace.xml
generated
@@ -4,10 +4,9 @@
|
||||
<option name="autoReloadType" value="SELECTIVE" />
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="8497df64-d86b-4c98-ac58-c157d9d3fb1e" name="Changes" comment="Nano zoom fix #12">
|
||||
<change beforePath="$PROJECT_DIR$/frontend/package.json" beforeDir="false" afterPath="$PROJECT_DIR$/frontend/package.json" afterDir="false" />
|
||||
<list default="true" id="8497df64-d86b-4c98-ac58-c157d9d3fb1e" name="Changes" comment="Nano zoom fix #11">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/frontend/src/App.jsx" beforeDir="false" afterPath="$PROJECT_DIR$/frontend/src/App.jsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/package-lock.json" beforeDir="false" afterPath="$PROJECT_DIR$/package-lock.json" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
@@ -113,7 +112,7 @@
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1733439468142</updated>
|
||||
<workItem from="1733439479708" duration="5489000" />
|
||||
<workItem from="1733448523969" duration="279000" />
|
||||
<workItem from="1733448523969" duration="687000" />
|
||||
</task>
|
||||
<task id="LOCAL-00001" summary="Nano zoom fix #11">
|
||||
<option name="closed" value="true" />
|
||||
@@ -123,15 +122,23 @@
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1733447944692</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="2" />
|
||||
<task id="LOCAL-00002" summary="Nano zoom fix #11">
|
||||
<option name="closed" value="true" />
|
||||
<created>1733448864234</created>
|
||||
<option name="number" value="00002" />
|
||||
<option name="presentableId" value="LOCAL-00002" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1733448864234</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="3" />
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
<option name="version" value="3" />
|
||||
</component>
|
||||
<component name="VcsManagerConfiguration">
|
||||
<MESSAGE value="Nano zoom fix #11" />
|
||||
<MESSAGE value="Nano zoom fix #12" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="Nano zoom fix #12" />
|
||||
<MESSAGE value="Nano zoom fix #11" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="Nano zoom fix #11" />
|
||||
</component>
|
||||
</project>
|
||||
@@ -22,15 +22,21 @@ const App = () => {
|
||||
theme: { background: '#1e1e1e', foreground: '#ffffff' },
|
||||
macOptionIsMeta: true,
|
||||
allowProposedApi: true,
|
||||
fontSize: 14, // Set the default font size initially
|
||||
fontSize: 14,
|
||||
});
|
||||
|
||||
fitAddon.current = new FitAddon();
|
||||
terminal.current.loadAddon(fitAddon.current);
|
||||
|
||||
let resizeObserver = new ResizeObserver(() => {
|
||||
fitAddon.current.fit();
|
||||
notifyServerOfResize();
|
||||
});
|
||||
|
||||
if (terminalRef.current) {
|
||||
terminal.current.open(terminalRef.current);
|
||||
console.log('Terminal opened successfully.');
|
||||
resizeObserver.observe(terminalRef.current);
|
||||
} else {
|
||||
console.error('Terminal reference is not valid!');
|
||||
}
|
||||
@@ -72,6 +78,7 @@ const App = () => {
|
||||
socket.current.close();
|
||||
}
|
||||
window.removeEventListener('resize', resizeTerminal);
|
||||
resizeObserver.disconnect();
|
||||
};
|
||||
}, []);
|
||||
|
||||
@@ -159,4 +166,4 @@ const App = () => {
|
||||
);
|
||||
};
|
||||
|
||||
export default App;
|
||||
export default App;
|
||||
Reference in New Issue
Block a user