Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release version 4.32.0 #483

Merged
merged 64 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
44420c0
Add ability to return menu template
ZIMkaRU Nov 29, 2024
6dcfab5
Add menu ipc channel handlers
ZIMkaRU Nov 29, 2024
02d1dc7
Add helper to init ipc channel handlers from list
ZIMkaRU Nov 29, 2024
5ea28ca
Init menu ipc channel handlers
ZIMkaRU Nov 29, 2024
4e8268a
Add menu invoke method names into preload script
ZIMkaRU Nov 29, 2024
97250d1
Add ability to remove the default title bar
ZIMkaRU Nov 29, 2024
dd1bfcb
Add ability to serialize menu for ipc
ZIMkaRU Dec 5, 2024
411be10
Add exec menu cmd handler
ZIMkaRU Dec 5, 2024
321fd4b
Register exec menu cmd handler in preload script
ZIMkaRU Dec 5, 2024
3eba427
Extend menu item ids
ZIMkaRU Dec 6, 2024
8928d1f
Customize menu item template to be serialized for ui
ZIMkaRU Dec 6, 2024
5f1e543
Fix reload menu option
ZIMkaRU Dec 9, 2024
5d81800
Bump electron up to 33.3.0 to have fix for titleBarStyle
ZIMkaRU Dec 10, 2024
ec62c9a
Update nodejs version in docker files
ZIMkaRU Dec 10, 2024
822eab4
Update nodejs installation script
ZIMkaRU Dec 10, 2024
c9d1caf
Update nodejs version in gh action workflows
ZIMkaRU Dec 10, 2024
a7628d1
Adjust backend deps instalation script
ZIMkaRU Dec 10, 2024
a750c2e
Fix folder ownership issue under docker
ZIMkaRU Dec 10, 2024
b6aa8b2
Setup main window title bar overlay
ZIMkaRU Dec 10, 2024
ef241aa
Fix security warning in renderer process
ZIMkaRU Dec 10, 2024
cd84da5
Disable hardware acceleration to fix errors and speed up
ZIMkaRU Dec 10, 2024
2913fb3
Show native title bar by default til ui implementation
ZIMkaRU Dec 11, 2024
9d69372
Add getTitle method to GeneralIpcChannelHandlers
ZIMkaRU Dec 11, 2024
7a48e4e
Register getTitle method in context bridge
ZIMkaRU Dec 11, 2024
def9192
Extend native menu options translation support
ZIMkaRU Jan 6, 2025
a18add5
Add en trinslations for native menu options
ZIMkaRU Jan 6, 2025
ee95e66
Add ru trinslations for native menu options
ZIMkaRU Jan 6, 2025
34d746e
Add shortcut accelerators to menu
ZIMkaRU Jan 7, 2025
5089709
Remap menu item accelerators separated by platforms
ZIMkaRU Jan 7, 2025
8db8542
Add shortcut accelerators separated by platforms to menu
ZIMkaRU Jan 7, 2025
d8ca92a
Adjust menu item ids for mac
ZIMkaRU Jan 8, 2025
8e2c771
Adjust menu item accelerators for mac
ZIMkaRU Jan 8, 2025
5d56bfa
Adjust menu item for mac
ZIMkaRU Jan 8, 2025
a911afc
Enhance en menu translation for mac
ZIMkaRU Jan 8, 2025
fc95c9b
Enhance ru menu translation for mac
ZIMkaRU Jan 8, 2025
2b0f4be
Unify menu item accelerator key codes
ZIMkaRU Jan 8, 2025
ae41888
Fix import menu item accelerator for mac
ZIMkaRU Jan 9, 2025
a753654
Fix user manual menu item accelerator for mac
ZIMkaRU Jan 9, 2025
b23d1e7
Fix toggle fullscreen menu item accelerator for mac
ZIMkaRU Jan 9, 2025
a482329
Prevent custom menu rendering for mac
ZIMkaRU Jan 10, 2025
81b78db
Set title bar overlay height for mac
ZIMkaRU Jan 10, 2025
1e5f3d3
Add ability to send hide-menu event via ipc to renderer
ZIMkaRU Jan 13, 2025
625e7c1
Register onHideMenuEvent method in preload script
ZIMkaRU Jan 13, 2025
e9a0692
Send hide menu event if main win full-screen entered-left
ZIMkaRU Jan 13, 2025
5ec8211
Bump electron up to 33.3.1
ZIMkaRU Jan 14, 2025
125c8b8
Fix main win full screen processing
ZIMkaRU Jan 14, 2025
0b046fa
Expose main win full screen state
ZIMkaRU Jan 14, 2025
2b8c132
Set main win full screen after init finished
ZIMkaRU Jan 14, 2025
0066efc
Drop wrong full screen eneting in window-state-keeper
ZIMkaRU Jan 14, 2025
ded5035
Add ability to hide ui menu bar using electron env var
ZIMkaRU Jan 14, 2025
40c022f
Add electron env var to show native menu bar
ZIMkaRU Jan 14, 2025
db9fbb5
Merge pull request #478 from ZIMkaRU/feature/move-electron-app-menu-b…
ezewer Jan 16, 2025
98f05fe
Add layout for minimization button for loading window
ZIMkaRU Jan 16, 2025
e3db104
Add window modification properties for loading window
ZIMkaRU Jan 16, 2025
88d8279
Add handler for loading window minimization
ZIMkaRU Jan 16, 2025
b4ed147
Register loading window minimization handler in preload script
ZIMkaRU Jan 16, 2025
524b0d9
Add listener for loading window minimization event
ZIMkaRU Jan 16, 2025
ae8fbd6
Fix approach for loading window minimization on mac
ZIMkaRU Jan 17, 2025
5be96fd
Fix loading window close behavior on mac
ZIMkaRU Jan 17, 2025
50cb307
Merge pull request #479 from ZIMkaRU/feature/add-button-to-minimize-l…
ezewer Jan 20, 2025
3b8f2ea
Bump version up to v4.32.0
ZIMkaRU Jan 21, 2025
aa9d074
Add changelog for v4.32.0
ZIMkaRU Jan 21, 2025
833aeb4
Update sub-modules
ZIMkaRU Jan 23, 2025
f53a2e9
Merge pull request #482 from ZIMkaRU/feature/release-electron-app
ezewer Jan 23, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/build-electron-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ jobs:
fi
- uses: actions/setup-node@v4
with:
node-version: 18.17.1
node-version: 20.18.1
- name: Cache Electron binaries
id: electron-cache
uses: actions/cache@v4
Expand Down Expand Up @@ -231,7 +231,7 @@ jobs:
uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18.17.1
node-version: 20.18.1
- name: Install main dev deps
run: npm i --development --no-audit --progress=false --force
- name: Download Linux Unpacked build
Expand Down Expand Up @@ -263,7 +263,7 @@ jobs:
uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18.17.1
node-version: 20.18.1
- name: Install main dev deps
run: npm i --development --no-audit --progress=false --force
- name: Download Linux Unpacked build
Expand Down Expand Up @@ -297,7 +297,7 @@ jobs:
uses: ./.github/actions/prepare-mac-runner
- uses: actions/setup-node@v4
with:
node-version: 18.17.1
node-version: 20.18.1
- name: Install main dev deps
run: npm i --development --no-audit --progress=false --force
- name: Download Mac Unpacked build
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
submodules: recursive
- uses: actions/setup-node@v4
with:
node-version: 18.17.1
node-version: 20.18.1
- name: Setup configs and install deps
run: ./scripts/setup.sh -u
- name: Run tests
Expand Down
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,25 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [4.32.0] - 2025-01-22

### Added

- Added the backend logic to move the electron app menu bar to the UI title instead of the electron one so that we can customize the electron menu, as the native electron menu API doesn't provide that. It allows us to build the menu in the UI in one small line with the main app title and typical window buttons (minimize, maximize, and close in the top corner). This is very useful as it saves overall space and at the same time constantly displays the menu and does not require the user to press the `Alt` key to display it (as practice has shown, because of the last one, many inexperienced users do not even know about the existence of menu functions). PRs: [bfx-report-electron#478](https://github.com/bitfinexcom/bfx-report-electron/pull/478), [bfx-facs-db-better-sqlite#11](https://github.com/bitfinexcom/bfx-facs-db-better-sqlite/pull/11)
- Added a small typical `_` button (in the top right corner) to minimize the loading window. PR: [bfx-report-electron#479](https://github.com/bitfinexcom/bfx-report-electron/pull/479)
- Added the logout flow for web users and prevented the issue when logged-out users are still logged in after the page refreshing. PR: [bfx-report-ui#889](https://github.com/bitfinexcom/bfx-report-ui/pull/889)

### Changed

- Renamed `Filter` button to `Generate` and also disabled it during the initial synchronization to prevent `Tax Report` generation errors. Implemented corresponding notice for the users during the initial sync. PR: [bfx-report-ui#888](https://github.com/bitfinexcom/bfx-report-ui/pull/888)
- Actualized app download link generation flow. PR: [bfx-report-ui#890](https://github.com/bitfinexcom/bfx-report-ui/pull/890)
- Actualized `Reports` translations and extended coverage for newly added elements/features. PR: [bfx-report-ui#891](https://github.com/bitfinexcom/bfx-report-ui/pull/891)
- Improved theme setting flow and fixed issues noted after the latest `Electron` version update. PR: [bfx-report-ui#893](https://github.com/bitfinexcom/bfx-report-ui/pull/893)

### Fixed

- Fixed `isAuthTokenGenerationError` flag processing in query response for the 2FA re-login after token expiration. PR: [bfx-report-ui#892](https://github.com/bitfinexcom/bfx-report-ui/pull/892)

## [4.31.0] - 2024-12-04

### Added
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.linux-builder
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM electronuserland/builder:18
FROM electronuserland/builder:20

ARG NODE_VERSION="18.17.1"
ARG NODE_VERSION="20.18.1"

ENV IS_BFX_API_STAGING=${IS_BFX_API_STAGING:-0}
ENV IS_DEV_ENV=${IS_DEV_ENV:-0}
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.mac-builder
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM electronuserland/builder:18
FROM electronuserland/builder:20

ARG NODE_VERSION="18.17.1"
ARG NODE_VERSION="20.18.1"

ENV IS_BFX_API_STAGING=${IS_BFX_API_STAGING:-0}
ENV IS_DEV_ENV=${IS_DEV_ENV:-0}
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.ui-builder
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM electronuserland/builder:18
FROM electronuserland/builder:20

ARG NODE_VERSION="18.17.1"
ARG NODE_VERSION="20.18.1"

ENV IS_BFX_API_STAGING=${IS_BFX_API_STAGING:-0}
ENV IS_DEV_ENV=${IS_DEV_ENV:-0}
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.win-builder
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM electronuserland/builder:18-wine
FROM electronuserland/builder:20-wine

ARG NODE_VERSION="18.17.1"
ARG NODE_VERSION="20.18.1"

ENV IS_BFX_API_STAGING=${IS_BFX_API_STAGING:-0}
ENV IS_DEV_ENV=${IS_DEV_ENV:-0}
Expand Down
2 changes: 1 addition & 1 deletion bfx-reports-framework
32 changes: 29 additions & 3 deletions build/locales/en/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,32 @@
"quitLabel": "Quit"
},
"fileSubMenu": {
"label": "File"
"label": "File",
"closeLabel": "Close",
"quitLabel": "Quit"
},
"editSubMenu": {
"label": "Edit"
"label": "Edit",
"undoLabel": "Undo",
"redoLabel": "Redo",
"cutLabel": "Cut",
"copyLabel": "Copy",
"pasteLabel": "Paste",
"pasteAndMatchStyleLabel": "Paste And Match Style",
"deleteLabel": "Delete",
"selectAllLabel": "Select All",
"substitutionsSubMenu": {
"label": "Substitutions",
"showSubstitutions": "Show Substitutions",
"toggleSmartQuotes": "Smart Quotes",
"toggleSmartDashes": "Smart Dashes",
"toggleTextReplacement": "Text Replacement"
},
"speechSubMenu": {
"label": "Speech",
"startSpeakingLabel": "Start Speaking",
"stopSpeakingLabel": "Stop Speaking"
}
},
"viewSubMenu": {
"label": "View",
Expand All @@ -28,7 +50,11 @@
"togglefullscreenLabel": "Toggle Full Screen"
},
"windowSubMenu": {
"label": "Window"
"label": "Window",
"minimizeLabel": "Minimize",
"zoomLabel": "Zoom",
"frontLabel": "Bring All to Front",
"windowLabel": "Window"
},
"toolsSubMenu": {
"label": "Tools",
Expand Down
34 changes: 30 additions & 4 deletions build/locales/ru/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,39 @@
},
"menu": {
"macMainSubmenu": {
"servicesLabel": "Услуги",
"servicesLabel": "Службы",
"hideLabel": "Скрыть",
"hideOthersLabel": "Скрыть Другие",
"unhideLabel": "Показать",
"quitLabel": "Выйти"
},
"fileSubMenu": {
"label": "Файл"
"label": "Файл",
"closeLabel": "Закрыть",
"quitLabel": "Выйти"
},
"editSubMenu": {
"label": "Редактировать"
"label": "Редактировать",
"undoLabel": "Отменить",
"redoLabel": "Повторить",
"cutLabel": "Вырезать",
"copyLabel": "Копировать",
"pasteLabel": "Вставить",
"pasteAndMatchStyleLabel": "Вставить и Сопоставить Стиль",
"deleteLabel": "Удалить",
"selectAllLabel": "Выбрать Все",
"substitutionsSubMenu": {
"label": "Подстановки",
"showSubstitutions": "Показать Подстановки",
"toggleSmartQuotes": "Умные Цитаты",
"toggleSmartDashes": "Умные Тире",
"toggleTextReplacement": "Замена текста"
},
"speechSubMenu": {
"label": "Речь",
"startSpeakingLabel": "Начать Говорить",
"stopSpeakingLabel": "Перестать Говорить"
}
},
"viewSubMenu": {
"label": "Вид",
Expand All @@ -28,7 +50,11 @@
"togglefullscreenLabel": "Переключить на Полный Экран"
},
"windowSubMenu": {
"label": "Окно"
"label": "Окно",
"minimizeLabel": "Свернуть",
"zoomLabel": "Увеличить",
"frontLabel": "На Передний План",
"windowLabel": "Окно"
},
"toolsSubMenu": {
"label": "Инструменты",
Expand Down
3 changes: 2 additions & 1 deletion electronEnv.json.example
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"NODE_ENV": "production",
"IS_AUTO_UPDATE_DISABLED": false,
"REPO_OWNER": "bitfinexcom"
"REPO_OWNER": "bitfinexcom",
"SHOW_NATIVE_TITLE_BAR": true
}
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ app.setName(productName)

process.traceProcessWarnings = true
app.allowRendererProcessReuse = true
process.env.ELECTRON_DISABLE_SECURITY_WARNINGS = true

require('./src/error-manager')
.initLogger()
Expand Down
10 changes: 4 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "bfx-report-electron",
"version": "4.31.0",
"version": "4.32.0",
"repository": "https://github.com/bitfinexcom/bfx-report-electron",
"description": "Reporting tool",
"author": "bitfinex.com",
"main": "index.js",
"engine": {
"node": ">=18.17.1"
"node": ">=20.18.1"
},
"license": "Apache-2.0",
"dependencies": {
Expand Down Expand Up @@ -35,18 +35,16 @@
"yauzl": "3.2.0"
},
"devDependencies": {
"@mapbox/node-pre-gyp": "1.0.11",
"@wdio/cli": "8.22.1",
"@wdio/junit-reporter": "8.21.0",
"@wdio/local-runner": "8.22.1",
"@wdio/mocha-framework": "8.22.0",
"@wdio/spec-reporter": "8.21.0",
"app-builder-bin": "4.2.0",
"concurrently": "9.0.1",
"cross-env": "7.0.3",
"dotenv": "16.3.1",
"electron": "27.3.11",
"electron-builder": "24.10.0",
"electron": "33.3.1",
"electron-builder": "24.13.3",
"mocha": "10.2.0",
"standard": "17.1.0",
"wdio-electron-service": "5.4.0"
Expand Down
5 changes: 0 additions & 5 deletions scripts/build-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,6 @@ else
"$ROOT/$ELECTRON_ENV_FILE_NAME"; rm -f "$ROOT/$ELECTRON_ENV_FILE_NAME.bak"
fi

changeDirOwnershipToCurrUser "$ELECTRON_CACHE" "$(id -u):$(id -g)"
changeDirOwnershipToCurrUser "$ELECTRON_BUILDER_CACHE" "$(id -u):$(id -g)"
changeDirOwnershipToCurrUser "$COMMON_UI_BUILD_FOLDER"
changeDirOwnershipToCurrUser "$COMMON_DIST_FOLDER"

makeLastCommitJson "$ROOT/$LAST_COMMIT_FILE_NAME"

echo -e "\n${COLOR_BLUE}Making backend config files${COLOR_NORMAL}"
Expand Down
2 changes: 0 additions & 2 deletions scripts/build-ui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,6 @@ if [ $isDevEnv == 1 ]; then
export CI_ENVIRONMENT_NAME="development"
fi

changeDirOwnershipToCurrUser "$COMMON_UI_BUILD_FOLDER"

rm -rf "$UI_BUILD_FOLDER/"*

if [ -d "$COMMON_UI_BUILD_FOLDER" ]; then
Expand Down
14 changes: 7 additions & 7 deletions scripts/helpers/install-backend-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ function installBackendDeps {
echo -e "\n${COLOR_BLUE}Installing the main dev deps...${COLOR_NORMAL}"
rm -rf ./node_modules
npm i --development --no-audit --progress=false --force
npm ls --depth=0 --only=dev 1<&-
npm ls --depth=0 1<&-

export npm_config_target_platform="$targetPlatform"
export npm_config_platform="$targetPlatform"
Expand All @@ -55,9 +55,9 @@ function installBackendDeps {
export npm_config_disturl="$DIST_URL"

echo -e "\n${COLOR_BLUE}Installing the main prod deps...${COLOR_NORMAL}"
npm i --production --include=dev --no-audit --progress=false --force
npm i --omit=dev --include=dev --no-audit --progress=false --force
checkNodeModulesDir "$ROOT"
depsErr=$(npm ls --depth=0 --only=prod 2>&1 >/dev/null | grep -E -v "missing: eslint|--omit=dev" || [[ $? == 1 ]])
depsErr=$(npm ls --depth=0 --omit=dev 2>&1 >/dev/null | grep -E -v "missing: eslint" || [[ $? == 1 ]])
if [ -n "$depsErr" ]; then
echo -e "$depsErr" >&2
exit 1
Expand All @@ -66,16 +66,16 @@ function installBackendDeps {
cd "$EXPRESS_FOLDER"
echo -e "\n${COLOR_BLUE}Installing the prod express deps...${COLOR_NORMAL}"
rm -rf ./node_modules
npm i --production --no-audit --progress=false
npm i --omit=dev --no-audit --progress=false
checkNodeModulesDir "$EXPRESS_FOLDER"
npm ls --depth=0 --only=prod 1<&-
npm ls --depth=0 --omit=dev 1<&-

cd "$WORKER_FOLDER"
echo -e "\n${COLOR_BLUE}Installing the prod worker deps...${COLOR_NORMAL}"
rm -rf ./node_modules
npm i --production --no-audit --progress=false
npm i --omit=dev --no-audit --progress=false
checkNodeModulesDir "$WORKER_FOLDER"
npm ls --depth=0 --only=prod 1<&-
npm ls --depth=0 --omit=dev 1<&-

cd "$INSTALL_BACKEND_CURRDIR"
}
3 changes: 1 addition & 2 deletions scripts/helpers/install-nodejs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ script as required NodeJS version!${COLOR_NORMAL}" >&2
exit 1
fi

version="${1:-"18.17.1"}"
version="${1:-"20.18.1"}"

echo -e "\n${COLOR_BLUE}Installing the NodeJS v$version...${COLOR_NORMAL}"

Expand All @@ -26,6 +26,5 @@ unlink /usr/local/LICENSE
unlink /usr/local/README.md

npm cache clear --force 2>/dev/null
npm install --global [email protected]

echo -e "\n${COLOR_GREEN}The NodeJS has been installed successful${COLOR_NORMAL}"
1 change: 1 addition & 0 deletions src/app-states.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@

module.exports = {
isMainWinMaximized: false,
isMainWinFullScreen: false,
loadURL: null
}
Loading