How to use Enhanced Input Action with UI?

Im trying to make a widget that simply lets me use the new “back” to exit and other functions like drop, next tab, etc. im able to get the input to show up visually on the button, but it does not function. here is the code im using. what am i doing wrong? when i click the button it does the expected result, but i need it to do that when i press the input

using { /Fortnite.com/Devices }

using { /Verse.org/Input/UI }

using { /Verse.org/Simulation }

using { /UnrealEngine.com/ControlInput }

using { /UnrealEngine.com/Temporary/UI }

hello_world_device := class(creative_device):

OnBegin<override>()<suspends>:void=

    for(Player : GetPlayspace().GetPlayers()):

        Widget := NewWidgetBlueprint{}

        if(PlayerUI := GetPlayerUI\[Player\], PlayerInput := GetPlayerInput\[Player\]):

            PlayerUI.AddWidget(Widget, player_ui_slot{ InputMode := ui_input_mode.All })

            PlayerInput.AddInputMapping(InventoryMenuMapping)

            PlayerInput.GetInputEvents(Drop).ActivationTriggeredEvent.Subscribe(Test)



Test(Player:player, KeyDown:logic):void=

    Print("KeyDown:{KeyDown?and"yes"or"no"}?")

Have you figured out how to do it? Can’t find any solution.

Hello! Thanks to you guys I could figure how to solve it in my case.
I added the MenuNavigationMapping that one has the Back action.
And with that it worked and shows the button in the UI.

From the digest

# MenuNavigationMapping includes the following actions with default key bindings:
        #   * NextTab: E/Gamepad Right Shoulder
        #   * PreviousTab: Q/Gamepad Left Shoulder
        #   * NextPage: C/Gamepad Right Trigger
        #   * PreviousPage: Z/Gamepad Left Trigger
        #   * Back: Escape/Gamepad Back Button
        MenuNavigationMapping<public>:input_mapping = external {}

This is what I used for buttons created with verse.

BackButton := button_regular:
            DefaultText := BackMsg
            TriggeringInputAction := option { (/Verse.org/Input/UI:)Back }

Figured it out. Have to use the mapping like @Abrizzer said, then you also have to ensure its a regular widget, not a modal dialogue widget. for some reason it being modal dialogue completely breaks it

Hi all, just for posterity - I think this thread also contains relevant info.