1
mirror of https://github.com/DarkFlippers/unleashed-firmware.git synced 2025-12-12 04:34:43 +04:00

JS: Expose button event type in gui/widget button callback (#4252)

* JS: Expose button event type in gui/widget button callback --nobuild

* js_sdk: bump major version

* unit_tests: fix js test

* js: fix gui widget demo

---------

Co-authored-by: Anna Antonenko <portasynthinca3@gmail.com>
Co-authored-by: hedger <hedger@users.noreply.github.com>
This commit is contained in:
WillyJL
2025-09-24 00:16:47 +02:00
committed by GitHub
parent f4138e5999
commit 8bd66c9920
15 changed files with 107 additions and 37 deletions

View File

@@ -4,12 +4,12 @@ let flipper = require("flipper");
tests.assert_eq(1337, 1337);
tests.assert_eq("hello", "hello");
tests.assert_eq("compatible", sdkCompatibilityStatus(0, 1));
tests.assert_eq("compatible", sdkCompatibilityStatus(1, 0));
tests.assert_eq("firmwareTooOld", sdkCompatibilityStatus(100500, 0));
tests.assert_eq("firmwareTooNew", sdkCompatibilityStatus(-100500, 0));
tests.assert_eq(true, doesSdkSupport(["baseline"]));
tests.assert_eq(false, doesSdkSupport(["abobus", "other-nonexistent-feature"]));
tests.assert_eq("flipperdevices", flipper.firmwareVendor);
tests.assert_eq(0, flipper.jsSdkVersion[0]);
tests.assert_eq(3, flipper.jsSdkVersion[1]);
tests.assert_eq(1, flipper.jsSdkVersion[0]);
tests.assert_eq(0, flipper.jsSdkVersion[1]);