@evergis/react 4.0.9 → 4.0.11
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/index.js +13 -0
- package/dist/index.js.map +1 -1
- package/dist/react.esm.js +13 -0
- package/dist/react.esm.js.map +1 -1
- package/package.json +4 -5
package/dist/index.js
CHANGED
|
@@ -11651,6 +11651,8 @@ const LogTerminal = ({ log, terminalOptions, className, styles }) => {
|
|
|
11651
11651
|
background: theme.palette.background,
|
|
11652
11652
|
foreground: theme.palette.textPrimary,
|
|
11653
11653
|
cursor: theme.palette.primary,
|
|
11654
|
+
selectionBackground: theme.palette.primary,
|
|
11655
|
+
selectionForeground: theme.palette.textPrimary,
|
|
11654
11656
|
},
|
|
11655
11657
|
...terminalOptions,
|
|
11656
11658
|
});
|
|
@@ -11667,6 +11669,17 @@ const LogTerminal = ({ log, terminalOptions, className, styles }) => {
|
|
|
11667
11669
|
const handleResize = () => {
|
|
11668
11670
|
fitAddon.fit();
|
|
11669
11671
|
};
|
|
11672
|
+
// Add Ctrl+C support for xterm
|
|
11673
|
+
terminal.attachCustomKeyEventHandler(arg => {
|
|
11674
|
+
if (arg.ctrlKey && arg.code === "KeyC" && arg.type === "keydown") {
|
|
11675
|
+
const selection = terminal.getSelection();
|
|
11676
|
+
if (selection) {
|
|
11677
|
+
navigator.clipboard.writeText(selection);
|
|
11678
|
+
return false;
|
|
11679
|
+
}
|
|
11680
|
+
}
|
|
11681
|
+
return true;
|
|
11682
|
+
});
|
|
11670
11683
|
window.addEventListener("resize", handleResize);
|
|
11671
11684
|
// Cleanup
|
|
11672
11685
|
return () => {
|