1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-23 08:15:22 +03:00
betaflight-configurator/src/js
Kyle K 16266ec979 Simplify flashingMessage function
i18next uses `:` to denote a namespace for messages.

The firmware flashing tab has a `flashingMessage` function that is used to update the bar at the bottom, it can either be passed a message key, or a properly formatted string.

`Loaded Local Firmware: (473178 bytes)` was getting looked up as a key, which generates the following warning

i18next.min.js:1 i18next::translator: key " (473178 bytes)" for namespace "Loaded Local Firmware" for languages "en" won't get resolved as namespace was not yet loaded This means something IS WRONG in your application setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!

Proposed fix is to just look at the message for a `:` and excluding those before asking the localization system if its a key.

Revised to just remove the lookup
2019-11-10 22:43:43 +00:00
..
msp Add more parameters to GPS Rescue (#1812) 2019-11-10 11:32:31 +13:00
protocols Fix critical and major bugs from Sonar in JS files 2019-11-05 13:15:44 +01:00
tabs Simplify flashingMessage function 2019-11-10 22:43:43 +00:00
utils ISSUE-1609: Create communication mechanism between windows, implement dark theme for sticks window using it. Small fix for Tip popup window. 2019-10-15 00:50:30 +03:00
workers Fix parsing of hex addresses. 2019-08-07 20:07:39 +02:00
Analytics.js Added analytics for new configurator elements. 2019-09-15 22:15:25 +12:00
backup_restore.js Remove tabs and some trailing spaces 2019-11-03 13:46:19 +01:00
Beepers.js Remove clickable labels for switches 2019-09-09 22:11:53 +02:00
boards.js Move src files 2018-01-24 22:50:40 +01:00
CliAutoComplete.js Fix critical and major bugs from Sonar in JS files 2019-11-05 13:15:44 +01:00
Clipboard.js Add paste from clipboard option to VTX tab 2019-09-12 15:41:43 +02:00
ConfigInserter.js clean up some more code smells 2019-10-03 21:52:02 +00:00
ConfigStorage.js Small bug fixes 2019-08-16 22:15:58 +00:00
DarkTheme.js Squash all dark theme files into a single file 2019-10-23 17:39:40 +02:00
data_storage.js Fixed ownership of installed files on debian. 2019-03-24 11:52:59 +13:00
default_huffman_tree.js Move src files 2018-01-24 22:50:40 +01:00
eventPage.js get rid of superflorous notification 2019-08-15 22:19:46 +00:00
fc.js Add more parameters to GPS Rescue (#1812) 2019-11-10 11:32:31 +13:00
Features.js Remove clickable labels for switches 2019-09-09 22:11:53 +02:00
FirmwareCache.js Small bug fixes 2019-08-16 22:15:58 +00:00
gui.js Fix critical and major bugs from Sonar in JS files 2019-11-05 13:15:44 +01:00
huffman.js Move src files 2018-01-24 22:50:40 +01:00
injected_methods.js Move src files 2018-01-24 22:50:40 +01:00
jenkins_loader.js Some minor cleanup for hacktoberfest 2019-10-02 20:51:49 +00:00
localization.js i18next: assign languageChanged hook after initialization 2019-10-29 23:16:52 +00:00
LogoManager.js Set file type descriptions for open / save dialogs. 2018-07-17 22:01:18 +12:00
main.js Clean Sonar issues from main.js 2019-11-10 09:20:41 +01:00
model.js FIx memory leak on model rendering 2019-09-28 13:14:14 +02:00
msp.js Fixed vulnerabilities found by SonarCloud. 2019-11-02 21:06:33 +13:00
peripherals.js Use i18next as i18n framework 2018-01-27 12:19:17 +01:00
port_handler.js initial go at flashing unified target with a config 2019-09-05 04:15:22 +00:00
port_usage.js Use i18next as i18n framework 2018-01-27 12:19:17 +01:00
RateCurve.js Updated to MSP API v1.42 & rebased onto master. 2019-04-12 20:36:45 +01:00
release_checker.js Fixed 'use strict' directives 2018-06-15 11:25:12 +10:00
serial.js log certain errors to the GUI's log to help with noticing hardware issues 2019-07-08 00:58:32 +00:00
serial_backend.js Increaseto1.8 2019-11-02 10:51:02 +01:00
TuningSliders.js Tuning sliders yaw P fix 2019-09-16 12:18:52 +02:00