Flipper/Applications/Custom (UL, RM)/Unleashed/Scripts/js_examples/submenu.js
2024-08-06 23:09:52 -04:00

12 lines
262 B
JavaScript

let submenu = require("submenu");
submenu.addItem("Item 1", 0);
submenu.addItem("Item 2", 1);
submenu.addItem("Item 3", 2);
submenu.setHeader("Select an option:");
let result = submenu.show();
// Returns undefined when pressing back
print("Result:", result);