From 86ff7f58bab9e093c1411bb2d4021cb8bad00fa2 Mon Sep 17 00:00:00 2001 From: Pierre Ferran Date: Sat, 25 May 2024 20:10:24 -0400 Subject: [PATCH 1/2] Keyboard shortcut and button (Cmd/Ctrl + M) for mini mode #39 --- package-lock.json | 18 ++++++++++++++---- package.json | 1 + src/app/components/navbar.tsx | 11 +++++++++++ src/index.html | 2 ++ src/index.ts | 29 +++++++++++++++++++++++++++++ src/preload.ts | 2 ++ 6 files changed, 59 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0118023..6bc2255 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,6 +21,7 @@ "i": "^0.3.7", "npm": "^10.5.1", "react": "^18.2.0", + "react-bootstrap-icons": "^1.11.4", "react-dom": "^18.2.0", "sass": "^1.74.1", "styled-components": "^5.3.11", @@ -13339,7 +13340,6 @@ "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", - "dev": true, "engines": { "node": ">=0.10.0" } @@ -14458,7 +14458,6 @@ "version": "15.8.1", "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz", "integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==", - "dev": true, "dependencies": { "loose-envify": "^1.4.0", "object-assign": "^4.1.1", @@ -14468,8 +14467,7 @@ "node_modules/prop-types/node_modules/react-is": { "version": "16.13.1", "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", - "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", - "dev": true + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" }, "node_modules/proxy-addr": { "version": "2.0.7", @@ -14643,6 +14641,18 @@ "node": ">=0.10.0" } }, + "node_modules/react-bootstrap-icons": { + "version": "1.11.4", + "resolved": "https://registry.npmjs.org/react-bootstrap-icons/-/react-bootstrap-icons-1.11.4.tgz", + "integrity": "sha512-lnkOpNEZ/Zr7mNxvjA9efuarCPSgtOuGA55XiRj7ASJnBjb1wEAdtJOd2Aiv9t07r7FLI1IgyZPg9P6jqWD/IA==", + "license": "MIT", + "dependencies": { + "prop-types": "^15.7.2" + }, + "peerDependencies": { + "react": ">=16.8.6" + } + }, "node_modules/react-dom": { "version": "18.3.1", "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.3.1.tgz", diff --git a/package.json b/package.json index b962a50..3a18ecb 100644 --- a/package.json +++ b/package.json @@ -71,6 +71,7 @@ "i": "^0.3.7", "npm": "^10.5.1", "react": "^18.2.0", + "react-bootstrap-icons": "^1.11.4", "react-dom": "^18.2.0", "sass": "^1.74.1", "styled-components": "^5.3.11", diff --git a/src/app/components/navbar.tsx b/src/app/components/navbar.tsx index e8b583f..9ecb866 100644 --- a/src/app/components/navbar.tsx +++ b/src/app/components/navbar.tsx @@ -11,6 +11,7 @@ import { } from "../helpers/CallsignHelper"; import useUtilStore from "../store/utilStore"; import { Configuration } from "../../config"; +import { FullscreenExit } from "react-bootstrap-icons"; const Navbar: React.FC = () => { const [showModal, setShowModal] = useState(false); @@ -204,6 +205,16 @@ const Navbar: React.FC = () => { onWheel={handleRadioGainMouseWheel} value={radioGain} > + {platform === "linux" && (