David Lechner
c84afea181
style: make use of more blueprint styles
...
https://blueprintjs.com/docs/#core/typography
Also fix wrapping license text while we are touching this.
2022-07-27 16:55:46 -05:00
David Lechner
e6609b9054
firmware/installPybricksDialog: fix <div> inside <p>
...
fixes:
Warning: validateDOMNesting(...): <div> cannot appear as a descendant of <p>.
Also some other style tweaks while we are touching this.
2022-07-27 16:22:46 -05:00
David Lechner
ad774e0f7c
suppress redux non-serializable error for error objects
2022-07-27 15:34:39 -05:00
David Lechner
3953816350
components/hubPicker: back state with localStorage
...
This saves the selected hub in localStorage. This will "remember" the
state between app launches and also synchronize the state between
various users of the component. Both of these should mean fewer clicks
required by the user.
2022-07-27 15:30:39 -05:00
David Lechner
8bece7d957
tour: add new tour component
2022-07-27 15:19:36 -05:00
David Lechner
2b7f1b1cbf
firmware/sagas: show progress for BLE flashing
2022-07-27 15:19:36 -05:00
David Lechner
1148b169d5
firmware: add progress indication for DFU USB flash
2022-07-27 15:19:36 -05:00
David Lechner
8dadc8826c
firmware/installPybricksDialog: increase height
...
This ensures the dialog doesn't change size when clicking next even
with longer translations.
2022-07-27 15:19:36 -05:00
David Lechner
4e85b5c1b8
firmware/installPybricksDialog: rename flash button
...
This makes it clear there are two steps, connect and then flash.
2022-07-27 15:19:36 -05:00
David Lechner
76444c032c
firmware/installPybricksDialog: add warning for windows/linux usb
...
This warns the user before failure. Otherwise they will click the flash
button and no devices will appear in the scan dialog.
2022-07-27 15:19:36 -05:00
David Lechner
934330272f
alerts/sagas: avoid reentrancy for dismiss
...
This fixes react complaining about calling setState from an invalid
context.
2022-07-22 15:29:11 -05:00
David Lechner
e6782cb291
index: avoid more non-serializable dev tool errors
2022-07-22 15:07:10 -05:00
David Lechner
9d1f3651c5
alerts/actions: fix alertsShowAlert action with props
2022-07-22 14:45:47 -05:00
David Lechner
e3430260f9
firmware/alerts/NoDfuHub: fix translation key
2022-07-22 14:03:33 -05:00
David Lechner
d6df128860
i18n: use automatic type inference of translation keys
...
Finally figured out a way to make typescript strongly type translation
keys so we can avoid the tedium of creating enums of translation keys.
2022-07-22 13:48:50 -05:00
David Lechner
6d07713eb5
firmware: implement flashing via USB DFU
2022-07-21 18:36:32 -05:00
David Lechner
28f63d5d85
utils/math: add crc32 function
...
This matches the STM32 hardware CRC.
2022-07-21 14:27:27 -05:00
David Lechner
bb6f86ff18
firmware/installPybricksDialog: add bootloader discrimination
...
Also fix license not showing for newer hubs.
2022-07-20 18:51:45 -05:00
David Lechner
709c3c554b
bump @pybricks/firmware to 5.0.0
...
This contains a breaking change where main.py is now optional so we
have to handle that case.
2022-07-20 18:01:35 -05:00
David Lechner
1d2c55eba6
ble/alerts: move old firmware from notifications
...
also add button to open new install firmware dialog
2022-07-20 17:26:08 -05:00
David Lechner
0721a24ef8
firmware/installPybricksDialog: fix some layout issues
2022-07-20 15:24:36 -05:00
David Lechner
af8a31d50c
firmware: add select picker for selecting custom main.py
2022-07-20 14:25:40 -05:00
David Lechner
85deb42f76
firmware: add multi-step dialog
2022-07-20 12:32:17 -05:00
David Lechner
b70777178c
editor/sagas: avoid console noise in tests
2022-07-18 14:54:44 -05:00
David Lechner
cabd53ac49
ble/actions: drop fail to connect reason
...
This is not longer used and can be removed.
2022-07-18 14:51:42 -05:00
David Lechner
c0215aa3ec
ble/sagas: move console logging to saga
2022-07-18 14:46:04 -05:00
David Lechner
d3be7775b2
ble/alerts: move missing service from notifications
2022-07-18 14:43:30 -05:00
David Lechner
5a77686e27
ble/alerts/NoGatt: move gatt message from notifications
2022-07-15 18:26:48 -05:00
David Lechner
bfdd7e728b
lwp3-bootloader/sagas-ble: remove obsolete comment
2022-07-15 18:05:48 -05:00
David Lechner
a86967573c
ble: add 1 second delay after connecting
...
This might help with some people that have connection issues where the
OS is still busy enumerating the device when we are trying to read
characteristics.
2022-07-15 18:05:48 -05:00
David Lechner
662a1ae097
ble/sagas: rework connect saga
...
This gets rid of a bunch of try/catch and repeated code.
2022-07-15 18:05:48 -05:00
David Lechner
bbe7eb4df3
ble: avoid aliases for UUID constants
2022-07-15 18:05:48 -05:00
David Lechner
15ecdf998d
ble/sagas: use alerts for unexpected error instead of notifications
2022-07-15 13:47:37 -05:00
David Lechner
ef0cd6507d
ble/alerts: move bluetooth not available from notifications
2022-07-15 13:19:31 -05:00
David Lechner
f86a9ad051
ble/alerts: move and improve no web bluetooth message
2022-07-15 13:16:53 -05:00
David Lechner
b2b173e103
utils/os: add Linux and iOS
...
Also update to navigator.userAgentData to avoid warnings from chromium.
2022-07-15 12:37:36 -05:00
David Lechner
e9f9aca3ef
ble/sagas: don't spam console in tests
2022-07-15 11:42:44 -05:00
David Lechner
ecd32e61b9
ble/actions: namespace actions
...
This way we don't have to use aliases when importing.
2022-07-15 11:16:23 -05:00
David Lechner
25e86c2f60
ble/sagas: flatten tests
...
This removes much of the nesting in tests to make the code easier to
read. Also we can now add more coverage for all of the skipped error
paths.
2022-07-14 20:44:24 -05:00
David Lechner
af2386178d
ble/sagas: add basic test
...
This gets about 50% coverage of the ble sagas.
2022-07-14 18:15:34 -05:00
David Lechner
c3fec0b779
app: drop last focused feature
...
This feature that keeps track of last focused item in the activities
panel broke child dialogs like the about dialog.
Fixes: https://github.com/pybricks/support/issues/682
2022-07-06 17:56:08 -05:00
David Lechner
7232bf6153
add better error message when no files to backup
...
Instead of showing unexpected error, show message explaining that
there are no files to be backed up and how to fix it.
Fixes: https://github.com/pybricks/support/issues/681
2022-07-06 17:56:08 -05:00
David Lechner
1e0d44bbe4
Fixed deleting files that are not open in the editor.
2022-07-06 17:56:08 -05:00
David Lechner
2e555fb9fc
fix error message when flashing firmware
...
We missed a check for MPY ABI v6 compatibility.
2022-07-06 15:06:35 -05:00
David Lechner
ed0e6789b7
update to @pybricks/mpy-cross-v6@2.0.0
...
This fixes `mpy-cross.wasm` from the v6 package overwriting the same
file from the v5 package.
2022-07-06 14:34:48 -05:00
David Lechner
c4b0a9a781
add version to docs path
...
This adds the @pybricks/ide-docs package version to the static path.
This should ensure that we don't get a cached older version in the
browser when the ide-docs package is updated.
2022-07-06 14:17:53 -05:00
David Lechner
90cd4865e8
Add support for MPY ABI v6.
...
Pybricks firmware v3.2.0b2 has updated to MicroPython 1.19 which
includes breaking changes to the MPY binary file format.
2022-07-06 12:51:01 -05:00
Bert
ac86a829e7
Bump copyright year to 2022 in constants.ts ( #935 )
2022-06-26 09:59:57 -05:00
David Lechner
096eea7077
editor: add basic intellisense
...
This adds basic intellisense for code completion and function signatures
using the Python `jedi` package running in a Pyodide environment.
2022-06-24 19:15:32 -05:00
David Lechner
2686e0e5d3
use redux toolkit
...
Using redux directly has been deprecated. Using redux toolkit offers
some more safety checks (and could potientially replace some use of
sagas).
2022-06-15 12:03:29 -05:00