add support for the ui hash within events and triggers

fixes #795